commit 5b407775307c4b1487b370eab9028d1bed83636d Author: Daniil Gentili Date: Wed May 1 14:53:46 2024 +0200 Bump diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000..e494c5f283 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +_site +.jekyll-cache diff --git a/.woodpecker.yml b/.woodpecker.yml new file mode 100644 index 0000000000..8c948b1179 --- /dev/null +++ b/.woodpecker.yml @@ -0,0 +1,31 @@ +steps: + build: + image: danog/gojekyll + when: + branch: master + event: push + secrets: + - DEPLOY_KEY + commands: + - apt-get update && apt-get -y install openssh-client git + - mkdir -p $HOME/.ssh + - ssh-keyscan -t rsa github.com >> $HOME/.ssh/known_hosts + - echo "$DEPLOY_KEY" > $HOME/.ssh/id_rsa + - chmod 0600 $HOME/.ssh/id_rsa + - git config --global user.email "daniil@daniil.it" + - git config --global user.name "Daniil Gentili" + - git remote add o git@github.com:danog/MadelineProtoDocs.git + - git fetch o gh-pages + - cd docs + - gojekyll clean + - gojekyll build + - rm -rf /tmp/_site + - cp -a _site /tmp/ + - cd .. + - git fetch o gh-pages + - git checkout gh-pages + - rm -rf * + - cp -a /tmp/_site/* . + - git add -A + - git commit -am 'Update' + - git push o gh-pages diff --git a/docs/.well-known/amphtml/apikey.pub b/docs/.well-known/amphtml/apikey.pub new file mode 100644 index 0000000000..9da3d54c9d --- /dev/null +++ b/docs/.well-known/amphtml/apikey.pub @@ -0,0 +1,9 @@ +-----BEGIN PUBLIC KEY----- +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwGcqZ+kZ2QFmGLlQTrZQ +vkJscTcn0RS09H62yhrwhnbHzQ0LSgJxSiPBdZB/prGPV6FgsMvcqXi4jfqHVef6 +tat/x8X7zEdYEBfrI05B/TmGN0QQkoN5OQ0hsEjWUzkv5R0GaYB6RtpQ5RcZiHll +bDZCn0Dyir0PttyKooXHDIQWMOXz4HkzboJk0FaqgddKHX/CE1VUZdOZPDCG7O7A ++HJIEXkVCua5YepDQs19r8RPifgfVOKxhFe0RP/e2jZw816gMQFlI7+jNAJG7IFH +vE3UrvTmyR3gQPugzDipxLdgRjm3rCKcHFWO51jjTMpxwnUitPjBPX93aRzqJ0kV +oQIDAQAB +-----END PUBLIC KEY----- diff --git a/docs/API_docs/constructors/account.authorizationForm.md b/docs/API_docs/constructors/account.authorizationForm.md new file mode 100644 index 0000000000..01c1099268 --- /dev/null +++ b/docs/API_docs/constructors/account.authorizationForm.md @@ -0,0 +1,34 @@ +--- +title: "account.authorizationForm" +description: "Telegram Passport authorization form" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_authorizationForm.html +--- +# Constructor: account.authorizationForm +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Telegram Passport](https://core.telegram.org/passport) authorization form + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|required\_types|Array of [SecureRequiredType](/API_docs/types/SecureRequiredType.html) | Yes|Required [Telegram Passport](https://core.telegram.org/passport) documents| +|values|Array of [SecureValue](/API_docs/types/SecureValue.html) | Yes|Already submitted [Telegram Passport](https://core.telegram.org/passport) documents| +|errors|Array of [SecureValueError](/API_docs/types/SecureValueError.html) | Yes|[Telegram Passport](https://core.telegram.org/passport) errors| +|users|Array of [User](/API_docs/types/User.html) | Yes|Info about the bot to which the form will be submitted| +|privacy\_policy\_url|[string](/API_docs/types/string.html) | Optional|URL of the service's privacy policy| + + + +### Type: [account.AuthorizationForm](/API_docs/types/account.AuthorizationForm.html) + + +### Example: + +``` +$account_authorizationForm = ['_' => 'account.authorizationForm', 'required_types' => [SecureRequiredType, SecureRequiredType], 'values' => [SecureValue, SecureValue], 'errors' => [SecureValueError, SecureValueError], 'users' => [User, User], 'privacy_policy_url' => 'string']; +``` diff --git a/docs/API_docs/constructors/account.authorizations.md b/docs/API_docs/constructors/account.authorizations.md new file mode 100644 index 0000000000..fc0238cd1f --- /dev/null +++ b/docs/API_docs/constructors/account.authorizations.md @@ -0,0 +1,31 @@ +--- +title: "account.authorizations" +description: "Logged-in sessions" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_authorizations.html +--- +# Constructor: account.authorizations +[Back to constructors index](/API_docs/constructors/index.html) + + + +Logged-in sessions + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|authorization\_ttl\_days|[int](/API_docs/types/int.html) | Yes|Time-to-live of session| +|authorizations|Array of [Authorization](/API_docs/types/Authorization.html) | Yes|Logged-in sessions| + + + +### Type: [account.Authorizations](/API_docs/types/account.Authorizations.html) + + +### Example: + +``` +$account_authorizations = ['_' => 'account.authorizations', 'authorization_ttl_days' => int, 'authorizations' => [Authorization, Authorization]]; +``` diff --git a/docs/API_docs/constructors/account.autoDownloadSettings.md b/docs/API_docs/constructors/account.autoDownloadSettings.md new file mode 100644 index 0000000000..86491561f1 --- /dev/null +++ b/docs/API_docs/constructors/account.autoDownloadSettings.md @@ -0,0 +1,32 @@ +--- +title: "account.autoDownloadSettings" +description: "Media autodownload settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_autoDownloadSettings.html +--- +# Constructor: account.autoDownloadSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Media autodownload settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|low|[AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html) | Yes|Low data usage preset| +|medium|[AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html) | Yes|Medium data usage preset| +|high|[AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html) | Yes|High data usage preset| + + + +### Type: [account.AutoDownloadSettings](/API_docs/types/account.AutoDownloadSettings.html) + + +### Example: + +``` +$account_autoDownloadSettings = ['_' => 'account.autoDownloadSettings', 'low' => AutoDownloadSettings, 'medium' => AutoDownloadSettings, 'high' => AutoDownloadSettings]; +``` diff --git a/docs/API_docs/constructors/account.autoSaveSettings.md b/docs/API_docs/constructors/account.autoSaveSettings.md new file mode 100644 index 0000000000..bb5ca77421 --- /dev/null +++ b/docs/API_docs/constructors/account.autoSaveSettings.md @@ -0,0 +1,35 @@ +--- +title: "account.autoSaveSettings" +description: "Contains media autosave settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_autoSaveSettings.html +--- +# Constructor: account.autoSaveSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains media autosave settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users\_settings|[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) | Yes|Default media autosave settings for private chats| +|chats\_settings|[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) | Yes|Default media autosave settings for [groups and supergroups](https://core.telegram.org/api/channel)| +|broadcasts\_settings|[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) | Yes|Default media autosave settings for [channels](https://core.telegram.org/api/channel)| +|exceptions|Array of [AutoSaveException](/API_docs/types/AutoSaveException.html) | Yes|Peer-specific granular autosave settings| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in the peer-specific granular autosave settings| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the peer-specific granular autosave settings| + + + +### Type: [account.AutoSaveSettings](/API_docs/types/account.AutoSaveSettings.html) + + +### Example: + +``` +$account_autoSaveSettings = ['_' => 'account.autoSaveSettings', 'users_settings' => AutoSaveSettings, 'chats_settings' => AutoSaveSettings, 'broadcasts_settings' => AutoSaveSettings, 'exceptions' => [AutoSaveException, AutoSaveException], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/account.businessChatLinks.md b/docs/API_docs/constructors/account.businessChatLinks.md new file mode 100644 index 0000000000..77c9a5d6aa --- /dev/null +++ b/docs/API_docs/constructors/account.businessChatLinks.md @@ -0,0 +1,30 @@ +--- +title: "account.businessChatLinks" +description: "account.businessChatLinks attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_businessChatLinks.html +--- +# Constructor: account.businessChatLinks +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|links|Array of [BusinessChatLink](/API_docs/types/BusinessChatLink.html) | Yes| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes| +|users|Array of [User](/API_docs/types/User.html) | Yes| + + + +### Type: [account.BusinessChatLinks](/API_docs/types/account.BusinessChatLinks.html) + + +### Example: + +``` +$account_businessChatLinks = ['_' => 'account.businessChatLinks', 'links' => [BusinessChatLink, BusinessChatLink], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/account.connectedBots.md b/docs/API_docs/constructors/account.connectedBots.md new file mode 100644 index 0000000000..0faa8819c8 --- /dev/null +++ b/docs/API_docs/constructors/account.connectedBots.md @@ -0,0 +1,29 @@ +--- +title: "account.connectedBots" +description: "account.connectedBots attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_connectedBots.html +--- +# Constructor: account.connectedBots +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|connected\_bots|Array of [ConnectedBot](/API_docs/types/ConnectedBot.html) | Yes| +|users|Array of [User](/API_docs/types/User.html) | Yes| + + + +### Type: [account.ConnectedBots](/API_docs/types/account.ConnectedBots.html) + + +### Example: + +``` +$account_connectedBots = ['_' => 'account.connectedBots', 'connected_bots' => [ConnectedBot, ConnectedBot], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/account.contentSettings.md b/docs/API_docs/constructors/account.contentSettings.md new file mode 100644 index 0000000000..eec1d25ab9 --- /dev/null +++ b/docs/API_docs/constructors/account.contentSettings.md @@ -0,0 +1,31 @@ +--- +title: "account.contentSettings" +description: "Sensitive content settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_contentSettings.html +--- +# Constructor: account.contentSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Sensitive content settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|sensitive\_enabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether viewing of sensitive (NSFW) content is enabled| +|sensitive\_can\_change|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current client can change the sensitive content settings to view NSFW content| + + + +### Type: [account.ContentSettings](/API_docs/types/account.ContentSettings.html) + + +### Example: + +``` +$account_contentSettings = ['_' => 'account.contentSettings', 'sensitive_enabled' => Bool, 'sensitive_can_change' => Bool]; +``` diff --git a/docs/API_docs/constructors/account.emailVerified.md b/docs/API_docs/constructors/account.emailVerified.md new file mode 100644 index 0000000000..02da88ec24 --- /dev/null +++ b/docs/API_docs/constructors/account.emailVerified.md @@ -0,0 +1,30 @@ +--- +title: "account.emailVerified" +description: "The email was verified correctly." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_emailVerified.html +--- +# Constructor: account.emailVerified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The email was verified correctly. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|email|[string](/API_docs/types/string.html) | Yes|The verified email address.| + + + +### Type: [account.EmailVerified](/API_docs/types/account.EmailVerified.html) + + +### Example: + +``` +$account_emailVerified = ['_' => 'account.emailVerified', 'email' => 'string']; +``` diff --git a/docs/API_docs/constructors/account.emailVerifiedLogin.md b/docs/API_docs/constructors/account.emailVerifiedLogin.md new file mode 100644 index 0000000000..51247a3ff9 --- /dev/null +++ b/docs/API_docs/constructors/account.emailVerifiedLogin.md @@ -0,0 +1,31 @@ +--- +title: "account.emailVerifiedLogin" +description: "The email was verified correctly, and a login code was just sent to it." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_emailVerifiedLogin.html +--- +# Constructor: account.emailVerifiedLogin +[Back to constructors index](/API_docs/constructors/index.html) + + + +The email was verified correctly, and a login code was just sent to it. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|email|[string](/API_docs/types/string.html) | Yes|The verified email address.| +|sent\_code|[auth.SentCode](/API_docs/constructors/auth.SentCode.html) | Yes|Info about the sent [login code](https://core.telegram.org/api/auth)| + + + +### Type: [account.EmailVerified](/API_docs/types/account.EmailVerified.html) + + +### Example: + +``` +$account_emailVerifiedLogin = ['_' => 'account.emailVerifiedLogin', 'email' => 'string', 'sent_code' => auth.SentCode]; +``` diff --git a/docs/API_docs/constructors/account.emojiStatuses.md b/docs/API_docs/constructors/account.emojiStatuses.md new file mode 100644 index 0000000000..a8612e88cd --- /dev/null +++ b/docs/API_docs/constructors/account.emojiStatuses.md @@ -0,0 +1,31 @@ +--- +title: "account.emojiStatuses" +description: "A list of emoji statuses" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_emojiStatuses.html +--- +# Constructor: account.emojiStatuses +[Back to constructors index](/API_docs/constructors/index.html) + + + +A list of [emoji statuses](https://core.telegram.org/api/emoji-status) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|statuses|Array of [EmojiStatus](/API_docs/types/EmojiStatus.html) | Yes|[Emoji statuses](https://core.telegram.org/api/emoji-status)| + + + +### Type: [account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + + +### Example: + +``` +$account_emojiStatuses = ['_' => 'account.emojiStatuses', 'hash' => long, 'statuses' => [EmojiStatus, EmojiStatus]]; +``` diff --git a/docs/API_docs/constructors/account.emojiStatusesNotModified.md b/docs/API_docs/constructors/account.emojiStatusesNotModified.md new file mode 100644 index 0000000000..cc319aaee8 --- /dev/null +++ b/docs/API_docs/constructors/account.emojiStatusesNotModified.md @@ -0,0 +1,25 @@ +--- +title: "account.emojiStatusesNotModified" +description: "The server-side list of emoji statuses hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_emojiStatusesNotModified.html +--- +# Constructor: account.emojiStatusesNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The server-side list of [emoji statuses](https://core.telegram.org/api/emoji-status) hasn't changed + + + + +### Type: [account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + + +### Example: + +``` +$account_emojiStatusesNotModified = ['_' => 'account.emojiStatusesNotModified']; +``` diff --git a/docs/API_docs/constructors/account.password.md b/docs/API_docs/constructors/account.password.md new file mode 100644 index 0000000000..00d2dee824 --- /dev/null +++ b/docs/API_docs/constructors/account.password.md @@ -0,0 +1,42 @@ +--- +title: "account.password" +description: "Configuration for two-factor authorization" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_password.html +--- +# Constructor: account.password +[Back to constructors index](/API_docs/constructors/index.html) + + + +Configuration for two-factor authorization + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_recovery|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user has a recovery method configured| +|has\_secure\_values|[Bool](/API_docs/types/Bool.html) | Optional|Whether telegram [passport](https://core.telegram.org/passport) is enabled| +|has\_password|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user has a password| +|current\_algo|[PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html) | Optional|The [KDF algorithm for SRP two-factor authentication](https://core.telegram.org/api/srp) of the current password| +|srp\_B|[bytes](/API_docs/types/bytes.html) | Optional|Srp B param for [SRP authorization](https://core.telegram.org/api/srp)| +|srp\_id|[long](/API_docs/types/long.html) | Optional|Srp ID param for [SRP authorization](https://core.telegram.org/api/srp)| +|hint|[string](/API_docs/types/string.html) | Optional|Text hint for the password| +|email\_unconfirmed\_pattern|[string](/API_docs/types/string.html) | Optional|A [password recovery email](https://core.telegram.org/api/srp#email-verification) with the specified [pattern](https://core.telegram.org/api/pattern) is still awaiting verification| +|new\_algo|[PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html) | Yes|The [KDF algorithm for SRP two-factor authentication](https://core.telegram.org/api/srp) to use when creating new passwords| +|new\_secure\_algo|[SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html) | Yes|The KDF algorithm for telegram [passport](https://core.telegram.org/passport)| +|secure\_random|[bytes](/API_docs/types/bytes.html) | Yes|Secure random string| +|pending\_reset\_date|[int](/API_docs/types/int.html) | Optional|The 2FA password will be automatically removed at this date, unless the user cancels the operation| +|login\_email\_pattern|[string](/API_docs/types/string.html) | Optional|A verified login email with the specified [pattern](https://core.telegram.org/api/pattern) is configured| + + + +### Type: [account.Password](/API_docs/types/account.Password.html) + + +### Example: + +``` +$account_password = ['_' => 'account.password', 'has_recovery' => Bool, 'has_secure_values' => Bool, 'has_password' => Bool, 'current_algo' => PasswordKdfAlgo, 'srp_B' => 'bytes', 'srp_id' => long, 'hint' => 'string', 'email_unconfirmed_pattern' => 'string', 'new_algo' => PasswordKdfAlgo, 'new_secure_algo' => SecurePasswordKdfAlgo, 'secure_random' => 'bytes', 'pending_reset_date' => int, 'login_email_pattern' => 'string']; +``` diff --git a/docs/API_docs/constructors/account.passwordInputSettings.md b/docs/API_docs/constructors/account.passwordInputSettings.md new file mode 100644 index 0000000000..de652141f9 --- /dev/null +++ b/docs/API_docs/constructors/account.passwordInputSettings.md @@ -0,0 +1,34 @@ +--- +title: "account.passwordInputSettings" +description: "Settings for setting up a new password" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_passwordInputSettings.html +--- +# Constructor: account.passwordInputSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Settings for setting up a new password + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_algo|[PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html) | Optional|The [SRP algorithm](https://core.telegram.org/api/srp) to use| +|new\_password\_hash|[bytes](/API_docs/types/bytes.html) | Optional|The [computed password hash](https://core.telegram.org/api/srp)| +|hint|[string](/API_docs/types/string.html) | Optional|Text hint for the password| +|email|[string](/API_docs/types/string.html) | Optional|Password recovery email| +|new\_secure\_settings|[SecureSecretSettings](/API_docs/types/SecureSecretSettings.html) | Optional|Telegram [passport](https://core.telegram.org/passport) settings| + + + +### Type: [account.PasswordInputSettings](/API_docs/types/account.PasswordInputSettings.html) + + +### Example: + +``` +$account_passwordInputSettings = ['_' => 'account.passwordInputSettings', 'new_algo' => PasswordKdfAlgo, 'new_password_hash' => 'bytes', 'hint' => 'string', 'email' => 'string', 'new_secure_settings' => SecureSecretSettings]; +``` diff --git a/docs/API_docs/constructors/account.passwordSettings.md b/docs/API_docs/constructors/account.passwordSettings.md new file mode 100644 index 0000000000..214597ed4d --- /dev/null +++ b/docs/API_docs/constructors/account.passwordSettings.md @@ -0,0 +1,31 @@ +--- +title: "account.passwordSettings" +description: "Private info associated to the password info (recovery email, telegram passport info & so on)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_passwordSettings.html +--- +# Constructor: account.passwordSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Private info associated to the password info (recovery email, telegram [passport](https://core.telegram.org/passport) info & so on) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|email|[string](/API_docs/types/string.html) | Optional|[2FA Recovery email](https://core.telegram.org/api/srp#email-verification)| +|secure\_settings|[SecureSecretSettings](/API_docs/types/SecureSecretSettings.html) | Optional|Telegram [passport](https://core.telegram.org/passport) settings| + + + +### Type: [account.PasswordSettings](/API_docs/types/account.PasswordSettings.html) + + +### Example: + +``` +$account_passwordSettings = ['_' => 'account.passwordSettings', 'email' => 'string', 'secure_settings' => SecureSecretSettings]; +``` diff --git a/docs/API_docs/constructors/account.privacyRules.md b/docs/API_docs/constructors/account.privacyRules.md new file mode 100644 index 0000000000..d4c88e3bbb --- /dev/null +++ b/docs/API_docs/constructors/account.privacyRules.md @@ -0,0 +1,32 @@ +--- +title: "account.privacyRules" +description: "Privacy rules" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_privacyRules.html +--- +# Constructor: account.privacyRules +[Back to constructors index](/API_docs/constructors/index.html) + + + +Privacy rules + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|rules|Array of [PrivacyRule](/API_docs/types/PrivacyRule.html) | Yes|Privacy rules| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats to which the rules apply| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users to which the rules apply| + + + +### Type: [account.PrivacyRules](/API_docs/types/account.PrivacyRules.html) + + +### Example: + +``` +$account_privacyRules = ['_' => 'account.privacyRules', 'rules' => [PrivacyRule, PrivacyRule], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/account.resetPasswordFailedWait.md b/docs/API_docs/constructors/account.resetPasswordFailedWait.md new file mode 100644 index 0000000000..f4f0aff2f6 --- /dev/null +++ b/docs/API_docs/constructors/account.resetPasswordFailedWait.md @@ -0,0 +1,30 @@ +--- +title: "account.resetPasswordFailedWait" +description: "You recently requested a password reset that was canceled, please wait until the specified date before requesting another reset." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_resetPasswordFailedWait.html +--- +# Constructor: account.resetPasswordFailedWait +[Back to constructors index](/API_docs/constructors/index.html) + + + +You recently requested a password reset that was canceled, please wait until the specified date before requesting another reset. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|retry\_date|[int](/API_docs/types/int.html) | Yes|Wait until this date before requesting another reset.| + + + +### Type: [account.ResetPasswordResult](/API_docs/types/account.ResetPasswordResult.html) + + +### Example: + +``` +$account_resetPasswordFailedWait = ['_' => 'account.resetPasswordFailedWait', 'retry_date' => int]; +``` diff --git a/docs/API_docs/constructors/account.resetPasswordOk.md b/docs/API_docs/constructors/account.resetPasswordOk.md new file mode 100644 index 0000000000..a1f3196d74 --- /dev/null +++ b/docs/API_docs/constructors/account.resetPasswordOk.md @@ -0,0 +1,25 @@ +--- +title: "account.resetPasswordOk" +description: "The 2FA password was reset successfully." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_resetPasswordOk.html +--- +# Constructor: account.resetPasswordOk +[Back to constructors index](/API_docs/constructors/index.html) + + + +The 2FA password was reset successfully. + + + + +### Type: [account.ResetPasswordResult](/API_docs/types/account.ResetPasswordResult.html) + + +### Example: + +``` +$account_resetPasswordOk = ['_' => 'account.resetPasswordOk']; +``` diff --git a/docs/API_docs/constructors/account.resetPasswordRequestedWait.md b/docs/API_docs/constructors/account.resetPasswordRequestedWait.md new file mode 100644 index 0000000000..0d22463630 --- /dev/null +++ b/docs/API_docs/constructors/account.resetPasswordRequestedWait.md @@ -0,0 +1,30 @@ +--- +title: "account.resetPasswordRequestedWait" +description: "You successfully requested a password reset, please wait until the specified date before finalizing the reset." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_resetPasswordRequestedWait.html +--- +# Constructor: account.resetPasswordRequestedWait +[Back to constructors index](/API_docs/constructors/index.html) + + + +You successfully requested a password reset, please wait until the specified date before finalizing the reset. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|until\_date|[int](/API_docs/types/int.html) | Yes|Wait until this date before finalizing the reset.| + + + +### Type: [account.ResetPasswordResult](/API_docs/types/account.ResetPasswordResult.html) + + +### Example: + +``` +$account_resetPasswordRequestedWait = ['_' => 'account.resetPasswordRequestedWait', 'until_date' => int]; +``` diff --git a/docs/API_docs/constructors/account.resolvedBusinessChatLinks.md b/docs/API_docs/constructors/account.resolvedBusinessChatLinks.md new file mode 100644 index 0000000000..8c9284f172 --- /dev/null +++ b/docs/API_docs/constructors/account.resolvedBusinessChatLinks.md @@ -0,0 +1,93 @@ +--- +title: "account.resolvedBusinessChatLinks" +description: "account.resolvedBusinessChatLinks attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_resolvedBusinessChatLinks.html +--- +# Constructor: account.resolvedBusinessChatLinks +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[long](/API_docs/types/long.html) | Yes| +|message|[string](/API_docs/types/string.html) | Yes| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes| +|users|Array of [User](/API_docs/types/User.html) | Yes| + + + +### Type: [account.ResolvedBusinessChatLinks](/API_docs/types/account.ResolvedBusinessChatLinks.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$account_resolvedBusinessChatLinks = ['_' => 'account.resolvedBusinessChatLinks', 'peer' => long, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/account.savedRingtone.md b/docs/API_docs/constructors/account.savedRingtone.md new file mode 100644 index 0000000000..d198c697f6 --- /dev/null +++ b/docs/API_docs/constructors/account.savedRingtone.md @@ -0,0 +1,25 @@ +--- +title: "account.savedRingtone" +description: "The notification sound was already in MP3 format and was saved without any modification" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_savedRingtone.html +--- +# Constructor: account.savedRingtone +[Back to constructors index](/API_docs/constructors/index.html) + + + +The notification sound was already in MP3 format and was saved without any modification + + + + +### Type: [account.SavedRingtone](/API_docs/types/account.SavedRingtone.html) + + +### Example: + +``` +$account_savedRingtone = ['_' => 'account.savedRingtone']; +``` diff --git a/docs/API_docs/constructors/account.savedRingtoneConverted.md b/docs/API_docs/constructors/account.savedRingtoneConverted.md new file mode 100644 index 0000000000..d590f35639 --- /dev/null +++ b/docs/API_docs/constructors/account.savedRingtoneConverted.md @@ -0,0 +1,30 @@ +--- +title: "account.savedRingtoneConverted" +description: "The notification sound was not in MP3 format and was successfully converted and saved, use the returned Document to refer to the notification sound from now on" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_savedRingtoneConverted.html +--- +# Constructor: account.savedRingtoneConverted +[Back to constructors index](/API_docs/constructors/index.html) + + + +The notification sound was not in MP3 format and was successfully converted and saved, use the returned [Document](../types/Document.html) to refer to the notification sound from now on + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document|[Document](/API_docs/types/Document.html) | Optional|The converted notification sound| + + + +### Type: [account.SavedRingtone](/API_docs/types/account.SavedRingtone.html) + + +### Example: + +``` +$account_savedRingtoneConverted = ['_' => 'account.savedRingtoneConverted', 'document' => Document]; +``` diff --git a/docs/API_docs/constructors/account.savedRingtones.md b/docs/API_docs/constructors/account.savedRingtones.md new file mode 100644 index 0000000000..637dc256be --- /dev/null +++ b/docs/API_docs/constructors/account.savedRingtones.md @@ -0,0 +1,31 @@ +--- +title: "account.savedRingtones" +description: "A list of saved notification sounds" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_savedRingtones.html +--- +# Constructor: account.savedRingtones +[Back to constructors index](/API_docs/constructors/index.html) + + + +A list of saved notification sounds + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|ringtones|Array of [Document](/API_docs/types/Document.html) | Yes|Saved notification sounds| + + + +### Type: [account.SavedRingtones](/API_docs/types/account.SavedRingtones.html) + + +### Example: + +``` +$account_savedRingtones = ['_' => 'account.savedRingtones', 'hash' => long, 'ringtones' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/account.savedRingtonesNotModified.md b/docs/API_docs/constructors/account.savedRingtonesNotModified.md new file mode 100644 index 0000000000..eb87a61636 --- /dev/null +++ b/docs/API_docs/constructors/account.savedRingtonesNotModified.md @@ -0,0 +1,25 @@ +--- +title: "account.savedRingtonesNotModified" +description: "The notification sound list hasn't changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_savedRingtonesNotModified.html +--- +# Constructor: account.savedRingtonesNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The notification sound list hasn't changed. + + + + +### Type: [account.SavedRingtones](/API_docs/types/account.SavedRingtones.html) + + +### Example: + +``` +$account_savedRingtonesNotModified = ['_' => 'account.savedRingtonesNotModified']; +``` diff --git a/docs/API_docs/constructors/account.sentEmailCode.md b/docs/API_docs/constructors/account.sentEmailCode.md new file mode 100644 index 0000000000..24caf4d283 --- /dev/null +++ b/docs/API_docs/constructors/account.sentEmailCode.md @@ -0,0 +1,31 @@ +--- +title: "account.sentEmailCode" +description: "The sent email code" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_sentEmailCode.html +--- +# Constructor: account.sentEmailCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +The sent email code + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|email\_pattern|[string](/API_docs/types/string.html) | Yes|The email (to which the code was sent) must match this [pattern](https://core.telegram.org/api/pattern)| +|length|[int](/API_docs/types/int.html) | Yes|The length of the verification code| + + + +### Type: [account.SentEmailCode](/API_docs/types/account.SentEmailCode.html) + + +### Example: + +``` +$account_sentEmailCode = ['_' => 'account.sentEmailCode', 'email_pattern' => 'string', 'length' => int]; +``` diff --git a/docs/API_docs/constructors/account.takeout.md b/docs/API_docs/constructors/account.takeout.md new file mode 100644 index 0000000000..dad3f1773d --- /dev/null +++ b/docs/API_docs/constructors/account.takeout.md @@ -0,0 +1,30 @@ +--- +title: "account.takeout" +description: "Takeout info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_takeout.html +--- +# Constructor: account.takeout +[Back to constructors index](/API_docs/constructors/index.html) + + + +Takeout info + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Takeout ID| + + + +### Type: [account.Takeout](/API_docs/types/account.Takeout.html) + + +### Example: + +``` +$account_takeout = ['_' => 'account.takeout', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/account.themes.md b/docs/API_docs/constructors/account.themes.md new file mode 100644 index 0000000000..dab085d1a2 --- /dev/null +++ b/docs/API_docs/constructors/account.themes.md @@ -0,0 +1,31 @@ +--- +title: "account.themes" +description: "Installed themes" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_themes.html +--- +# Constructor: account.themes +[Back to constructors index](/API_docs/constructors/index.html) + + + +Installed themes + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|themes|Array of [Theme](/API_docs/types/Theme.html) | Yes|Themes| + + + +### Type: [account.Themes](/API_docs/types/account.Themes.html) + + +### Example: + +``` +$account_themes = ['_' => 'account.themes', 'hash' => long, 'themes' => [Theme, Theme]]; +``` diff --git a/docs/API_docs/constructors/account.themesNotModified.md b/docs/API_docs/constructors/account.themesNotModified.md new file mode 100644 index 0000000000..d2f72998bd --- /dev/null +++ b/docs/API_docs/constructors/account.themesNotModified.md @@ -0,0 +1,25 @@ +--- +title: "account.themesNotModified" +description: "No new themes were installed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_themesNotModified.html +--- +# Constructor: account.themesNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new themes were installed + + + + +### Type: [account.Themes](/API_docs/types/account.Themes.html) + + +### Example: + +``` +$account_themesNotModified = ['_' => 'account.themesNotModified']; +``` diff --git a/docs/API_docs/constructors/account.tmpPassword.md b/docs/API_docs/constructors/account.tmpPassword.md new file mode 100644 index 0000000000..b7e0f4172f --- /dev/null +++ b/docs/API_docs/constructors/account.tmpPassword.md @@ -0,0 +1,31 @@ +--- +title: "account.tmpPassword" +description: "Temporary payment password" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_tmpPassword.html +--- +# Constructor: account.tmpPassword +[Back to constructors index](/API_docs/constructors/index.html) + + + +Temporary payment password + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|tmp\_password|[bytes](/API_docs/types/bytes.html) | Yes|Temporary password| +|valid\_until|[int](/API_docs/types/int.html) | Yes|Validity period| + + + +### Type: [account.TmpPassword](/API_docs/types/account.TmpPassword.html) + + +### Example: + +``` +$account_tmpPassword = ['_' => 'account.tmpPassword', 'tmp_password' => 'bytes', 'valid_until' => int]; +``` diff --git a/docs/API_docs/constructors/account.wallPapers.md b/docs/API_docs/constructors/account.wallPapers.md new file mode 100644 index 0000000000..893e7ff944 --- /dev/null +++ b/docs/API_docs/constructors/account.wallPapers.md @@ -0,0 +1,31 @@ +--- +title: "account.wallPapers" +description: "Installed wallpapers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_wallPapers.html +--- +# Constructor: account.wallPapers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Installed [wallpapers](https://core.telegram.org/api/wallpapers) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|wallpapers|Array of [WallPaper](/API_docs/types/WallPaper.html) | Yes|[Wallpapers](https://core.telegram.org/api/wallpapers)| + + + +### Type: [account.WallPapers](/API_docs/types/account.WallPapers.html) + + +### Example: + +``` +$account_wallPapers = ['_' => 'account.wallPapers', 'hash' => long, 'wallpapers' => [WallPaper, WallPaper]]; +``` diff --git a/docs/API_docs/constructors/account.wallPapersNotModified.md b/docs/API_docs/constructors/account.wallPapersNotModified.md new file mode 100644 index 0000000000..b09ea919f2 --- /dev/null +++ b/docs/API_docs/constructors/account.wallPapersNotModified.md @@ -0,0 +1,25 @@ +--- +title: "account.wallPapersNotModified" +description: "No new wallpapers were found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_wallPapersNotModified.html +--- +# Constructor: account.wallPapersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new [wallpapers](https://core.telegram.org/api/wallpapers) were found + + + + +### Type: [account.WallPapers](/API_docs/types/account.WallPapers.html) + + +### Example: + +``` +$account_wallPapersNotModified = ['_' => 'account.wallPapersNotModified']; +``` diff --git a/docs/API_docs/constructors/account.webAuthorizations.md b/docs/API_docs/constructors/account.webAuthorizations.md new file mode 100644 index 0000000000..cf74b49df0 --- /dev/null +++ b/docs/API_docs/constructors/account.webAuthorizations.md @@ -0,0 +1,31 @@ +--- +title: "account.webAuthorizations" +description: "Web authorizations" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/account_webAuthorizations.html +--- +# Constructor: account.webAuthorizations +[Back to constructors index](/API_docs/constructors/index.html) + + + +Web authorizations + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|authorizations|Array of [WebAuthorization](/API_docs/types/WebAuthorization.html) | Yes|Web authorization list| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [account.WebAuthorizations](/API_docs/types/account.WebAuthorizations.html) + + +### Example: + +``` +$account_webAuthorizations = ['_' => 'account.webAuthorizations', 'authorizations' => [WebAuthorization, WebAuthorization], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/accountDaysTTL.md b/docs/API_docs/constructors/accountDaysTTL.md new file mode 100644 index 0000000000..d3460f28f2 --- /dev/null +++ b/docs/API_docs/constructors/accountDaysTTL.md @@ -0,0 +1,29 @@ +--- +title: "accountDaysTTL" +description: "Time to live in days of the current account" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: accountDaysTTL +[Back to constructors index](/API_docs/constructors/index.html) + + + +Time to live in days of the current account + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|days|[int](/API_docs/types/int.html) | Yes|This account will self-destruct in the specified number of days| + + + +### Type: [AccountDaysTTL](/API_docs/types/AccountDaysTTL.html) + + +### Example: + +``` +$accountDaysTTL = ['_' => 'accountDaysTTL', 'days' => int]; +``` diff --git a/docs/API_docs/constructors/appWebViewResultUrl.md b/docs/API_docs/constructors/appWebViewResultUrl.md new file mode 100644 index 0000000000..532437887e --- /dev/null +++ b/docs/API_docs/constructors/appWebViewResultUrl.md @@ -0,0 +1,29 @@ +--- +title: "appWebViewResultUrl" +description: "Contains the link that must be used to open a direct link Mini App." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: appWebViewResultUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains the link that must be used to open a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|The URL to open| + + + +### Type: [AppWebViewResult](/API_docs/types/AppWebViewResult.html) + + +### Example: + +``` +$appWebViewResultUrl = ['_' => 'appWebViewResultUrl', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/attachMenuBot.md b/docs/API_docs/constructors/attachMenuBot.md new file mode 100644 index 0000000000..faf3f3d3ce --- /dev/null +++ b/docs/API_docs/constructors/attachMenuBot.md @@ -0,0 +1,40 @@ +--- +title: "attachMenuBot" +description: "Represents a bot mini app that can be launched from the attachment/side menu »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuBot +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [bot mini app that can be launched from the attachment/side menu »](https://core.telegram.org/api/bots/attach) + +At least one of the `show_in_attach_menu` or the `show_in_side_menu` flags will always be set. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inactive|[Bool](/API_docs/types/Bool.html) | Optional|If set, before launching the mini app the client should ask the user to add the mini app to the attachment/side menu, and only if the user accepts, after invoking [messages.toggleBotInAttachMenu](../methods/messages.toggleBotInAttachMenu.html) the app should be opened.| +|has\_settings|[Bool](/API_docs/types/Bool.html) | Optional|Deprecated flag, can be ignored.| +|request\_write\_access|[Bool](/API_docs/types/Bool.html) | Optional|Whether the bot would like to send messages to the user.| +|show\_in\_attach\_menu|[Bool](/API_docs/types/Bool.html) | Optional|Whether, when installed, an attachment menu entry should be shown for the Mini App.| +|show\_in\_side\_menu|[Bool](/API_docs/types/Bool.html) | Optional|Whether, when installed, an entry in the main view side menu should be shown for the Mini App.| +|side\_menu\_disclaimer\_needed|[Bool](/API_docs/types/Bool.html) | Optional|If `inactive` if set and the user hasn't previously accepted the third-party mini apps [Terms of Service](https://telegram.org/tos/mini-apps) for this bot, when showing the mini app installation prompt, an additional mandatory checkbox to accept the [mini apps TOS](https://telegram.org/tos/mini-apps) and a disclaimer indicating that this Mini App is not affiliated to Telegram should be shown.| +|bot\_id|[long](/API_docs/types/long.html) | Yes|Bot ID| +|short\_name|[string](/API_docs/types/string.html) | Yes|Attachment menu item name| +|peer\_types|Array of [AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) | Optional|List of dialog types where this attachment menu entry should be shown| +|icons|Array of [AttachMenuBotIcon](/API_docs/types/AttachMenuBotIcon.html) | Yes|List of platform-specific static icons and animations to use for the attachment menu button| + + + +### Type: [AttachMenuBot](/API_docs/types/AttachMenuBot.html) + + +### Example: + +``` +$attachMenuBot = ['_' => 'attachMenuBot', 'inactive' => Bool, 'has_settings' => Bool, 'request_write_access' => Bool, 'show_in_attach_menu' => Bool, 'show_in_side_menu' => Bool, 'side_menu_disclaimer_needed' => Bool, 'bot_id' => long, 'short_name' => 'string', 'peer_types' => [AttachMenuPeerType, AttachMenuPeerType], 'icons' => [AttachMenuBotIcon, AttachMenuBotIcon]]; +``` diff --git a/docs/API_docs/constructors/attachMenuBotIcon.md b/docs/API_docs/constructors/attachMenuBotIcon.md new file mode 100644 index 0000000000..5993924c7b --- /dev/null +++ b/docs/API_docs/constructors/attachMenuBotIcon.md @@ -0,0 +1,31 @@ +--- +title: "attachMenuBotIcon" +description: "Represents an attachment menu icon for bot mini apps »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuBotIcon +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an attachment menu icon for [bot mini apps »](https://core.telegram.org/api/bots/attach) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|name|[string](/API_docs/types/string.html) | Yes|One of the following values: note that animated icons must be played when the user clicks on the button, activating the bot mini app.

`default_static` \- Default attachment menu icon in SVG format
`placeholder_static` \- Default placeholder for opened Web Apps in SVG format
`ios_static` \- Attachment menu icon in SVG format for the official iOS app
`ios_animated` \- Animated attachment menu icon in TGS format for the official iOS app
`android_animated` \- Animated attachment menu icon in TGS format for the official Android app
`macos_animated` \- Animated attachment menu icon in TGS format for the official native Mac OS app
`ios_side_menu_static` \- Side menu icon in PNG format for the official iOS app
`android_side_menu_static` \- Side menu icon in SVG format for the official android app
`macos_side_menu_static` \- Side menu icon in PNG format for the official native Mac OS app| +|icon|[Document](/API_docs/types/Document.html) | Optional|The actual icon file.| +|colors|Array of [AttachMenuBotIconColor](/API_docs/types/AttachMenuBotIconColor.html) | Optional|Attachment menu icon colors.| + + + +### Type: [AttachMenuBotIcon](/API_docs/types/AttachMenuBotIcon.html) + + +### Example: + +``` +$attachMenuBotIcon = ['_' => 'attachMenuBotIcon', 'name' => 'string', 'icon' => Document, 'colors' => [AttachMenuBotIconColor, AttachMenuBotIconColor]]; +``` diff --git a/docs/API_docs/constructors/attachMenuBotIconColor.md b/docs/API_docs/constructors/attachMenuBotIconColor.md new file mode 100644 index 0000000000..c1a9ca928a --- /dev/null +++ b/docs/API_docs/constructors/attachMenuBotIconColor.md @@ -0,0 +1,30 @@ +--- +title: "attachMenuBotIconColor" +description: "Represents an attachment menu icon color for bot mini apps »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuBotIconColor +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an attachment menu icon color for [bot mini apps »](https://core.telegram.org/api/bots/attach) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|name|[string](/API_docs/types/string.html) | Yes|One of the following values:
`light_icon` \- Color of the attachment menu icon (light mode)
`light_text` \- Color of the attachment menu label, once selected (light mode)
`dark_icon` \- Color of the attachment menu icon (dark mode)
`dark_text` \- Color of the attachment menu label, once selected (dark mode)| +|color|[int](/API_docs/types/int.html) | Yes|Color in RGB24 format| + + + +### Type: [AttachMenuBotIconColor](/API_docs/types/AttachMenuBotIconColor.html) + + +### Example: + +``` +$attachMenuBotIconColor = ['_' => 'attachMenuBotIconColor', 'name' => 'string', 'color' => int]; +``` diff --git a/docs/API_docs/constructors/attachMenuBots.md b/docs/API_docs/constructors/attachMenuBots.md new file mode 100644 index 0000000000..ef40fbb651 --- /dev/null +++ b/docs/API_docs/constructors/attachMenuBots.md @@ -0,0 +1,31 @@ +--- +title: "attachMenuBots" +description: "Represents a list of bot mini apps that can be launched from the attachment menu »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuBots +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a list of [bot mini apps that can be launched from the attachment menu »](https://core.telegram.org/api/bots/attach) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|bots|Array of [AttachMenuBot](/API_docs/types/AttachMenuBot.html) | Yes|List of [bot mini apps that can be launched from the attachment menu »](https://core.telegram.org/api/bots/attach)| +|users|Array of [User](/API_docs/types/User.html) | Yes|Info about related users/bots| + + + +### Type: [AttachMenuBots](/API_docs/types/AttachMenuBots.html) + + +### Example: + +``` +$attachMenuBots = ['_' => 'attachMenuBots', 'hash' => long, 'bots' => [AttachMenuBot, AttachMenuBot], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/attachMenuBotsBot.md b/docs/API_docs/constructors/attachMenuBotsBot.md new file mode 100644 index 0000000000..a5f7f1d08a --- /dev/null +++ b/docs/API_docs/constructors/attachMenuBotsBot.md @@ -0,0 +1,30 @@ +--- +title: "attachMenuBotsBot" +description: "Represents a bot mini app that can be launched from the attachment menu »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuBotsBot +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [bot mini app that can be launched from the attachment menu »](https://core.telegram.org/api/bots/attach) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|bot|[AttachMenuBot](/API_docs/types/AttachMenuBot.html) | Yes|Represents a [bot mini app that can be launched from the attachment menu »](https://core.telegram.org/api/bots/attach)
| +|users|Array of [User](/API_docs/types/User.html) | Yes|Info about related users and bots| + + + +### Type: [AttachMenuBotsBot](/API_docs/types/AttachMenuBotsBot.html) + + +### Example: + +``` +$attachMenuBotsBot = ['_' => 'attachMenuBotsBot', 'bot' => AttachMenuBot, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/attachMenuBotsNotModified.md b/docs/API_docs/constructors/attachMenuBotsNotModified.md new file mode 100644 index 0000000000..26844d3aa9 --- /dev/null +++ b/docs/API_docs/constructors/attachMenuBotsNotModified.md @@ -0,0 +1,24 @@ +--- +title: "attachMenuBotsNotModified" +description: "The list of bot mini apps hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuBotsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of bot mini apps hasn't changed + + + + +### Type: [AttachMenuBots](/API_docs/types/AttachMenuBots.html) + + +### Example: + +``` +$attachMenuBotsNotModified = ['_' => 'attachMenuBotsNotModified']; +``` diff --git a/docs/API_docs/constructors/attachMenuPeerTypeBotPM.md b/docs/API_docs/constructors/attachMenuPeerTypeBotPM.md new file mode 100644 index 0000000000..1c34ca39a4 --- /dev/null +++ b/docs/API_docs/constructors/attachMenuPeerTypeBotPM.md @@ -0,0 +1,24 @@ +--- +title: "attachMenuPeerTypeBotPM" +description: "The bot attachment menu entry is available in private chats with other bots (excluding the bot that offers the current attachment menu)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuPeerTypeBotPM +[Back to constructors index](/API_docs/constructors/index.html) + + + +The bot attachment menu entry is available in private chats with other bots (excluding the bot that offers the current attachment menu) + + + + +### Type: [AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) + + +### Example: + +``` +$attachMenuPeerTypeBotPM = ['_' => 'attachMenuPeerTypeBotPM']; +``` diff --git a/docs/API_docs/constructors/attachMenuPeerTypeBroadcast.md b/docs/API_docs/constructors/attachMenuPeerTypeBroadcast.md new file mode 100644 index 0000000000..ba29b3dcd4 --- /dev/null +++ b/docs/API_docs/constructors/attachMenuPeerTypeBroadcast.md @@ -0,0 +1,24 @@ +--- +title: "attachMenuPeerTypeBroadcast" +description: "The bot attachment menu entry is available in channels" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuPeerTypeBroadcast +[Back to constructors index](/API_docs/constructors/index.html) + + + +The bot attachment menu entry is available in channels + + + + +### Type: [AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) + + +### Example: + +``` +$attachMenuPeerTypeBroadcast = ['_' => 'attachMenuPeerTypeBroadcast']; +``` diff --git a/docs/API_docs/constructors/attachMenuPeerTypeChat.md b/docs/API_docs/constructors/attachMenuPeerTypeChat.md new file mode 100644 index 0000000000..becb2e176e --- /dev/null +++ b/docs/API_docs/constructors/attachMenuPeerTypeChat.md @@ -0,0 +1,24 @@ +--- +title: "attachMenuPeerTypeChat" +description: "The bot attachment menu entry is available in groups and supergroups" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuPeerTypeChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +The bot attachment menu entry is available in [groups and supergroups](https://core.telegram.org/api/channel) + + + + +### Type: [AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) + + +### Example: + +``` +$attachMenuPeerTypeChat = ['_' => 'attachMenuPeerTypeChat']; +``` diff --git a/docs/API_docs/constructors/attachMenuPeerTypePM.md b/docs/API_docs/constructors/attachMenuPeerTypePM.md new file mode 100644 index 0000000000..b9dccac628 --- /dev/null +++ b/docs/API_docs/constructors/attachMenuPeerTypePM.md @@ -0,0 +1,24 @@ +--- +title: "attachMenuPeerTypePM" +description: "The bot attachment menu entry is available in private chats with other users (not bots)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuPeerTypePM +[Back to constructors index](/API_docs/constructors/index.html) + + + +The bot attachment menu entry is available in private chats with other users (not bots) + + + + +### Type: [AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) + + +### Example: + +``` +$attachMenuPeerTypePM = ['_' => 'attachMenuPeerTypePM']; +``` diff --git a/docs/API_docs/constructors/attachMenuPeerTypeSameBotPM.md b/docs/API_docs/constructors/attachMenuPeerTypeSameBotPM.md new file mode 100644 index 0000000000..ed0cfe3324 --- /dev/null +++ b/docs/API_docs/constructors/attachMenuPeerTypeSameBotPM.md @@ -0,0 +1,24 @@ +--- +title: "attachMenuPeerTypeSameBotPM" +description: "The bot attachment menu entry is available in the chat with the bot that offers it" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: attachMenuPeerTypeSameBotPM +[Back to constructors index](/API_docs/constructors/index.html) + + + +The bot attachment menu entry is available in the chat with the bot that offers it + + + + +### Type: [AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) + + +### Example: + +``` +$attachMenuPeerTypeSameBotPM = ['_' => 'attachMenuPeerTypeSameBotPM']; +``` diff --git a/docs/API_docs/constructors/auth.authorization.md b/docs/API_docs/constructors/auth.authorization.md new file mode 100644 index 0000000000..9636582196 --- /dev/null +++ b/docs/API_docs/constructors/auth.authorization.md @@ -0,0 +1,34 @@ +--- +title: "auth.authorization" +description: "Contains user authorization info." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_authorization.html +--- +# Constructor: auth.authorization +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains user authorization info. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|setup\_password\_required|[Bool](/API_docs/types/Bool.html) | Optional|Suggests the user to set up a 2-step verification password to be able to log in again| +|otherwise\_relogin\_days|[int](/API_docs/types/int.html) | Optional|Iff setup\_password\_required is set and the user declines to set a 2-step verification password, they will be able to log into their account via SMS again only after this many days pass.| +|tmp\_sessions|[int](/API_docs/types/int.html) | Optional|Temporary [passport](https://core.telegram.org/passport) sessions| +|future\_auth\_token|[bytes](/API_docs/types/bytes.html) | Optional|A [future auth token](https://core.telegram.org/api/auth#future-auth-tokens)| +|user|[User](/API_docs/types/User.html) | Optional|Info on authorized user| + + + +### Type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + + +### Example: + +``` +$auth_authorization = ['_' => 'auth.authorization', 'setup_password_required' => Bool, 'otherwise_relogin_days' => int, 'tmp_sessions' => int, 'future_auth_token' => 'bytes', 'user' => User]; +``` diff --git a/docs/API_docs/constructors/auth.authorizationSignUpRequired.md b/docs/API_docs/constructors/auth.authorizationSignUpRequired.md new file mode 100644 index 0000000000..2e80b339a6 --- /dev/null +++ b/docs/API_docs/constructors/auth.authorizationSignUpRequired.md @@ -0,0 +1,30 @@ +--- +title: "auth.authorizationSignUpRequired" +description: "An account with this phone number doesn't exist on telegram: the user has to enter basic information and sign up" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_authorizationSignUpRequired.html +--- +# Constructor: auth.authorizationSignUpRequired +[Back to constructors index](/API_docs/constructors/index.html) + + + +An account with this phone number doesn't exist on telegram: the user has to [enter basic information and sign up](https://core.telegram.org/api/auth) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|terms\_of\_service|[help.TermsOfService](/API_docs/constructors/help.TermsOfService.html) | Optional|Telegram's terms of service: the user must read and accept the terms of service before signing up to telegram| + + + +### Type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + + +### Example: + +``` +$auth_authorizationSignUpRequired = ['_' => 'auth.authorizationSignUpRequired', 'terms_of_service' => help.TermsOfService]; +``` diff --git a/docs/API_docs/constructors/auth.codeTypeCall.md b/docs/API_docs/constructors/auth.codeTypeCall.md new file mode 100644 index 0000000000..acb4195eff --- /dev/null +++ b/docs/API_docs/constructors/auth.codeTypeCall.md @@ -0,0 +1,25 @@ +--- +title: "auth.codeTypeCall" +description: "The next time, the authentication code is to be delivered via an outgoing phone call." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_codeTypeCall.html +--- +# Constructor: auth.codeTypeCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The next time, the authentication code is to be delivered via an outgoing phone call. + + + + +### Type: [auth.CodeType](/API_docs/types/auth.CodeType.html) + + +### Example: + +``` +$auth_codeTypeCall = ['_' => 'auth.codeTypeCall']; +``` diff --git a/docs/API_docs/constructors/auth.codeTypeFlashCall.md b/docs/API_docs/constructors/auth.codeTypeFlashCall.md new file mode 100644 index 0000000000..64baafa8d6 --- /dev/null +++ b/docs/API_docs/constructors/auth.codeTypeFlashCall.md @@ -0,0 +1,25 @@ +--- +title: "auth.codeTypeFlashCall" +description: "The next time, the authentication code will be delivered via an immediately canceled incoming call." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_codeTypeFlashCall.html +--- +# Constructor: auth.codeTypeFlashCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The next time, the authentication code will be delivered via an immediately canceled incoming call. + + + + +### Type: [auth.CodeType](/API_docs/types/auth.CodeType.html) + + +### Example: + +``` +$auth_codeTypeFlashCall = ['_' => 'auth.codeTypeFlashCall']; +``` diff --git a/docs/API_docs/constructors/auth.codeTypeFragmentSms.md b/docs/API_docs/constructors/auth.codeTypeFragmentSms.md new file mode 100644 index 0000000000..3b5e4f77cf --- /dev/null +++ b/docs/API_docs/constructors/auth.codeTypeFragmentSms.md @@ -0,0 +1,25 @@ +--- +title: "auth.codeTypeFragmentSms" +description: "The next time, the authentication code will be delivered via fragment.com" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_codeTypeFragmentSms.html +--- +# Constructor: auth.codeTypeFragmentSms +[Back to constructors index](/API_docs/constructors/index.html) + + + +The next time, the authentication code will be delivered via [fragment.com](https://fragment.com) + + + + +### Type: [auth.CodeType](/API_docs/types/auth.CodeType.html) + + +### Example: + +``` +$auth_codeTypeFragmentSms = ['_' => 'auth.codeTypeFragmentSms']; +``` diff --git a/docs/API_docs/constructors/auth.codeTypeMissedCall.md b/docs/API_docs/constructors/auth.codeTypeMissedCall.md new file mode 100644 index 0000000000..1544c84c14 --- /dev/null +++ b/docs/API_docs/constructors/auth.codeTypeMissedCall.md @@ -0,0 +1,25 @@ +--- +title: "auth.codeTypeMissedCall" +description: "The next time, the authentication code will be delivered via an immediately canceled incoming call, handled manually by the user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_codeTypeMissedCall.html +--- +# Constructor: auth.codeTypeMissedCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The next time, the authentication code will be delivered via an immediately canceled incoming call, handled manually by the user. + + + + +### Type: [auth.CodeType](/API_docs/types/auth.CodeType.html) + + +### Example: + +``` +$auth_codeTypeMissedCall = ['_' => 'auth.codeTypeMissedCall']; +``` diff --git a/docs/API_docs/constructors/auth.codeTypeSms.md b/docs/API_docs/constructors/auth.codeTypeSms.md new file mode 100644 index 0000000000..920173b051 --- /dev/null +++ b/docs/API_docs/constructors/auth.codeTypeSms.md @@ -0,0 +1,25 @@ +--- +title: "auth.codeTypeSms" +description: "The next time, the authentication code will be delivered via an immediately canceled incoming call." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_codeTypeSms.html +--- +# Constructor: auth.codeTypeSms +[Back to constructors index](/API_docs/constructors/index.html) + + + +The next time, the authentication code will be delivered via an immediately canceled incoming call. + + + + +### Type: [auth.CodeType](/API_docs/types/auth.CodeType.html) + + +### Example: + +``` +$auth_codeTypeSms = ['_' => 'auth.codeTypeSms']; +``` diff --git a/docs/API_docs/constructors/auth.exportedAuthorization.md b/docs/API_docs/constructors/auth.exportedAuthorization.md new file mode 100644 index 0000000000..e0550a60cd --- /dev/null +++ b/docs/API_docs/constructors/auth.exportedAuthorization.md @@ -0,0 +1,31 @@ +--- +title: "auth.exportedAuthorization" +description: "Data for copying of authorization between data centers." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_exportedAuthorization.html +--- +# Constructor: auth.exportedAuthorization +[Back to constructors index](/API_docs/constructors/index.html) + + + +Data for copying of authorization between data centers. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|current user identifier| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|authorizes key| + + + +### Type: [auth.ExportedAuthorization](/API_docs/types/auth.ExportedAuthorization.html) + + +### Example: + +``` +$auth_exportedAuthorization = ['_' => 'auth.exportedAuthorization', 'id' => long, 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/auth.loggedOut.md b/docs/API_docs/constructors/auth.loggedOut.md new file mode 100644 index 0000000000..6d01af37eb --- /dev/null +++ b/docs/API_docs/constructors/auth.loggedOut.md @@ -0,0 +1,30 @@ +--- +title: "auth.loggedOut" +description: "Future auth token » to be used on subsequent authorizations" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_loggedOut.html +--- +# Constructor: auth.loggedOut +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Future auth token »](https://core.telegram.org/api/auth#future-auth-tokens) to be used on subsequent authorizations + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|future\_auth\_token|[bytes](/API_docs/types/bytes.html) | Optional|[Future auth token »](https://core.telegram.org/api/auth#future-auth-tokens) to be used on subsequent authorizations| + + + +### Type: [auth.LoggedOut](/API_docs/types/auth.LoggedOut.html) + + +### Example: + +``` +$auth_loggedOut = ['_' => 'auth.loggedOut', 'future_auth_token' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/auth.loginToken.md b/docs/API_docs/constructors/auth.loginToken.md new file mode 100644 index 0000000000..d44af4deb7 --- /dev/null +++ b/docs/API_docs/constructors/auth.loginToken.md @@ -0,0 +1,31 @@ +--- +title: "auth.loginToken" +description: "Login token (for QR code login)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_loginToken.html +--- +# Constructor: auth.loginToken +[Back to constructors index](/API_docs/constructors/index.html) + + + +Login token (for [QR code login](https://core.telegram.org/api/qr-login)) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|expires|[int](/API_docs/types/int.html) | Yes|Expiration date of QR code| +|token|[bytes](/API_docs/types/bytes.html) | Yes|Token to render in QR code| + + + +### Type: [auth.LoginToken](/API_docs/types/auth.LoginToken.html) + + +### Example: + +``` +$auth_loginToken = ['_' => 'auth.loginToken', 'expires' => int, 'token' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/auth.loginTokenMigrateTo.md b/docs/API_docs/constructors/auth.loginTokenMigrateTo.md new file mode 100644 index 0000000000..ca1103b75e --- /dev/null +++ b/docs/API_docs/constructors/auth.loginTokenMigrateTo.md @@ -0,0 +1,31 @@ +--- +title: "auth.loginTokenMigrateTo" +description: "Repeat the query to the specified DC" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_loginTokenMigrateTo.html +--- +# Constructor: auth.loginTokenMigrateTo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Repeat the query to the specified DC + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID| +|token|[bytes](/API_docs/types/bytes.html) | Yes|Token to use for login| + + + +### Type: [auth.LoginToken](/API_docs/types/auth.LoginToken.html) + + +### Example: + +``` +$auth_loginTokenMigrateTo = ['_' => 'auth.loginTokenMigrateTo', 'dc_id' => int, 'token' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/auth.loginTokenSuccess.md b/docs/API_docs/constructors/auth.loginTokenSuccess.md new file mode 100644 index 0000000000..7e01a2123e --- /dev/null +++ b/docs/API_docs/constructors/auth.loginTokenSuccess.md @@ -0,0 +1,30 @@ +--- +title: "auth.loginTokenSuccess" +description: "Login via token (QR code) succeeded!" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_loginTokenSuccess.html +--- +# Constructor: auth.loginTokenSuccess +[Back to constructors index](/API_docs/constructors/index.html) + + + +Login via token (QR code) succeeded! + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|authorization|[auth.Authorization](/API_docs/constructors/auth.Authorization.html) | Yes|Authorization info| + + + +### Type: [auth.LoginToken](/API_docs/types/auth.LoginToken.html) + + +### Example: + +``` +$auth_loginTokenSuccess = ['_' => 'auth.loginTokenSuccess', 'authorization' => auth.Authorization]; +``` diff --git a/docs/API_docs/constructors/auth.passwordRecovery.md b/docs/API_docs/constructors/auth.passwordRecovery.md new file mode 100644 index 0000000000..7e5f7cf497 --- /dev/null +++ b/docs/API_docs/constructors/auth.passwordRecovery.md @@ -0,0 +1,30 @@ +--- +title: "auth.passwordRecovery" +description: "Recovery info of a 2FA password, only for accounts with a recovery email configured." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_passwordRecovery.html +--- +# Constructor: auth.passwordRecovery +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recovery info of a [2FA password](https://core.telegram.org/api/srp), only for accounts with a [recovery email configured](https://core.telegram.org/api/srp#email-verification). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|email\_pattern|[string](/API_docs/types/string.html) | Yes|The email to which the recovery code was sent must match this [pattern](https://core.telegram.org/api/pattern).| + + + +### Type: [auth.PasswordRecovery](/API_docs/types/auth.PasswordRecovery.html) + + +### Example: + +``` +$auth_passwordRecovery = ['_' => 'auth.passwordRecovery', 'email_pattern' => 'string']; +``` diff --git a/docs/API_docs/constructors/auth.sentCode.md b/docs/API_docs/constructors/auth.sentCode.md new file mode 100644 index 0000000000..e88334a612 --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCode.md @@ -0,0 +1,33 @@ +--- +title: "auth.sentCode" +description: "Contains info about a sent verification code." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCode.html +--- +# Constructor: auth.sentCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a sent verification code. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[auth.SentCodeType](/API_docs/constructors/auth.SentCodeType.html) | Yes|Phone code type| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Yes|Phone code hash, to be stored and later re-used with [auth.signIn](../methods/auth.signIn.html)| +|next\_type|[auth.CodeType](/API_docs/constructors/auth.CodeType.html) | Optional|Phone code type that will be sent next, if the phone code is not received within `timeout` seconds: to send it use [auth.resendCode](../methods/auth.resendCode.html)| +|timeout|[int](/API_docs/types/int.html) | Optional|Timeout for reception of the phone code| + + + +### Type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + + +### Example: + +``` +$auth_sentCode = ['_' => 'auth.sentCode', 'type' => auth.SentCodeType, 'phone_code_hash' => 'string', 'next_type' => auth.CodeType, 'timeout' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeSuccess.md b/docs/API_docs/constructors/auth.sentCodeSuccess.md new file mode 100644 index 0000000000..62dd19f7bc --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeSuccess.md @@ -0,0 +1,30 @@ +--- +title: "auth.sentCodeSuccess" +description: "The user successfully authorized using future auth tokens" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeSuccess.html +--- +# Constructor: auth.sentCodeSuccess +[Back to constructors index](/API_docs/constructors/index.html) + + + +The user successfully authorized using [future auth tokens](https://core.telegram.org/api/auth#future-auth-tokens) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|authorization|[auth.Authorization](/API_docs/constructors/auth.Authorization.html) | Yes|Authorization info| + + + +### Type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + + +### Example: + +``` +$auth_sentCodeSuccess = ['_' => 'auth.sentCodeSuccess', 'authorization' => auth.Authorization]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeApp.md b/docs/API_docs/constructors/auth.sentCodeTypeApp.md new file mode 100644 index 0000000000..57247ff0c5 --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeApp.md @@ -0,0 +1,30 @@ +--- +title: "auth.sentCodeTypeApp" +description: "The code was sent through the telegram app" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeApp.html +--- +# Constructor: auth.sentCodeTypeApp +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code was sent through the telegram app + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|length|[int](/API_docs/types/int.html) | Yes|Length of the code in bytes| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeApp = ['_' => 'auth.sentCodeTypeApp', 'length' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeCall.md b/docs/API_docs/constructors/auth.sentCodeTypeCall.md new file mode 100644 index 0000000000..cc44637d3b --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeCall.md @@ -0,0 +1,30 @@ +--- +title: "auth.sentCodeTypeCall" +description: "The code will be sent via a phone call: a synthesized voice will tell the user which verification code to input." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeCall.html +--- +# Constructor: auth.sentCodeTypeCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code will be sent via a phone call: a synthesized voice will tell the user which verification code to input. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|length|[int](/API_docs/types/int.html) | Yes|Length of the verification code| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeCall = ['_' => 'auth.sentCodeTypeCall', 'length' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeEmailCode.md b/docs/API_docs/constructors/auth.sentCodeTypeEmailCode.md new file mode 100644 index 0000000000..684acc2b68 --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeEmailCode.md @@ -0,0 +1,35 @@ +--- +title: "auth.sentCodeTypeEmailCode" +description: "The code was sent via the previously configured login email »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeEmailCode.html +--- +# Constructor: auth.sentCodeTypeEmailCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code was sent via the [previously configured login email »](https://core.telegram.org/api/auth#email-verification) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|apple\_signin\_allowed|[Bool](/API_docs/types/Bool.html) | Optional|Whether authorization through Apple ID is allowed| +|google\_signin\_allowed|[Bool](/API_docs/types/Bool.html) | Optional|Whether authorization through Google ID is allowed| +|email\_pattern|[string](/API_docs/types/string.html) | Yes|[Pattern](https://core.telegram.org/api/pattern) of the email| +|length|[int](/API_docs/types/int.html) | Yes|Length of the sent verification code| +|reset\_available\_period|[int](/API_docs/types/int.html) | Optional|Clients should wait for the specified amount of seconds before allowing the user to invoke [auth.resetLoginEmail](../methods/auth.resetLoginEmail.html) (will be 0 for [Premium](https://core.telegram.org/api/premium) users).| +|reset\_pending\_date|[int](/API_docs/types/int.html) | Optional|An email reset was already requested, and will occur at the specified date.| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeEmailCode = ['_' => 'auth.sentCodeTypeEmailCode', 'apple_signin_allowed' => Bool, 'google_signin_allowed' => Bool, 'email_pattern' => 'string', 'length' => int, 'reset_available_period' => int, 'reset_pending_date' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeFirebaseSms.md b/docs/API_docs/constructors/auth.sentCodeTypeFirebaseSms.md new file mode 100644 index 0000000000..c1758f2ddd --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeFirebaseSms.md @@ -0,0 +1,33 @@ +--- +title: "auth.sentCodeTypeFirebaseSms" +description: "An authentication code should be delivered via SMS after Firebase attestation, as described in the auth documentation »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeFirebaseSms.html +--- +# Constructor: auth.sentCodeTypeFirebaseSms +[Back to constructors index](/API_docs/constructors/index.html) + + + +An authentication code should be delivered via SMS after Firebase attestation, as described in the [auth documentation »](https://core.telegram.org/api/auth). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|nonce|[bytes](/API_docs/types/bytes.html) | Optional|On Android, the nonce to be used as described in the [auth documentation »](https://core.telegram.org/api/auth)| +|receipt|[string](/API_docs/types/string.html) | Optional|On iOS, must be compared with the `receipt` extracted from the received push notification.| +|push\_timeout|[int](/API_docs/types/int.html) | Optional|On iOS: if a push notification with the `ios_push_secret` isn't received within `push_timeout` seconds, the `next_type` authentication method must be used, with [auth.resendCode](../methods/auth.resendCode.html).| +|length|[int](/API_docs/types/int.html) | Yes|Length of the code that will be delivered.| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeFirebaseSms = ['_' => 'auth.sentCodeTypeFirebaseSms', 'nonce' => 'bytes', 'receipt' => 'string', 'push_timeout' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeFlashCall.md b/docs/API_docs/constructors/auth.sentCodeTypeFlashCall.md new file mode 100644 index 0000000000..401ad549e4 --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeFlashCall.md @@ -0,0 +1,30 @@ +--- +title: "auth.sentCodeTypeFlashCall" +description: "The code will be sent via a flash phone call, that will be closed immediately. The phone code will then be the phone number itself, just make sure that the phone number matches the specified pattern." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeFlashCall.html +--- +# Constructor: auth.sentCodeTypeFlashCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code will be sent via a flash phone call, that will be closed immediately. The phone code will then be the phone number itself, just make sure that the phone number matches the specified pattern. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pattern|[string](/API_docs/types/string.html) | Yes|[pattern](https://core.telegram.org/api/pattern) to match| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeFlashCall = ['_' => 'auth.sentCodeTypeFlashCall', 'pattern' => 'string']; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeFragmentSms.md b/docs/API_docs/constructors/auth.sentCodeTypeFragmentSms.md new file mode 100644 index 0000000000..4378e2d3be --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeFragmentSms.md @@ -0,0 +1,31 @@ +--- +title: "auth.sentCodeTypeFragmentSms" +description: "The code was delivered via fragment.com." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeFragmentSms.html +--- +# Constructor: auth.sentCodeTypeFragmentSms +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code was delivered via [fragment.com](https://fragment.com). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Open the specified URL to log into [fragment.com](https://fragment.com) with the wallet that owns the specified phone number and view the code.| +|length|[int](/API_docs/types/int.html) | Yes|Length of the delivered code.| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeFragmentSms = ['_' => 'auth.sentCodeTypeFragmentSms', 'url' => 'string', 'length' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeMissedCall.md b/docs/API_docs/constructors/auth.sentCodeTypeMissedCall.md new file mode 100644 index 0000000000..5dcf2f81a3 --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeMissedCall.md @@ -0,0 +1,31 @@ +--- +title: "auth.sentCodeTypeMissedCall" +description: "The code will be sent via a flash phone call, that will be closed immediately. The last digits of the phone number that calls are the code that must be entered manually by the user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeMissedCall.html +--- +# Constructor: auth.sentCodeTypeMissedCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code will be sent via a flash phone call, that will be closed immediately. The last digits of the phone number that calls are the code that must be entered manually by the user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prefix|[string](/API_docs/types/string.html) | Yes|Prefix of the phone number from which the call will be made| +|length|[int](/API_docs/types/int.html) | Yes|Length of the verification code| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeMissedCall = ['_' => 'auth.sentCodeTypeMissedCall', 'prefix' => 'string', 'length' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeSetUpEmailRequired.md b/docs/API_docs/constructors/auth.sentCodeTypeSetUpEmailRequired.md new file mode 100644 index 0000000000..3e45cb2e9a --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeSetUpEmailRequired.md @@ -0,0 +1,31 @@ +--- +title: "auth.sentCodeTypeSetUpEmailRequired" +description: "The user should add and verify an email address in order to login as described here »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeSetUpEmailRequired.html +--- +# Constructor: auth.sentCodeTypeSetUpEmailRequired +[Back to constructors index](/API_docs/constructors/index.html) + + + +The user should add and verify an email address in order to login as described [here »](https://core.telegram.org/api/auth#email-verification). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|apple\_signin\_allowed|[Bool](/API_docs/types/Bool.html) | Optional|Whether authorization through Apple ID is allowed| +|google\_signin\_allowed|[Bool](/API_docs/types/Bool.html) | Optional|Whether authorization through Google ID is allowed| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeSetUpEmailRequired = ['_' => 'auth.sentCodeTypeSetUpEmailRequired', 'apple_signin_allowed' => Bool, 'google_signin_allowed' => Bool]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeSms.md b/docs/API_docs/constructors/auth.sentCodeTypeSms.md new file mode 100644 index 0000000000..6d4d87b3bb --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeSms.md @@ -0,0 +1,30 @@ +--- +title: "auth.sentCodeTypeSms" +description: "The code was sent via SMS" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeSms.html +--- +# Constructor: auth.sentCodeTypeSms +[Back to constructors index](/API_docs/constructors/index.html) + + + +The code was sent via SMS + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|length|[int](/API_docs/types/int.html) | Yes|Length of the code in bytes| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeSms = ['_' => 'auth.sentCodeTypeSms', 'length' => int]; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeSmsPhrase.md b/docs/API_docs/constructors/auth.sentCodeTypeSmsPhrase.md new file mode 100644 index 0000000000..f115d64f0b --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeSmsPhrase.md @@ -0,0 +1,28 @@ +--- +title: "auth.sentCodeTypeSmsPhrase" +description: "auth.sentCodeTypeSmsPhrase attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeSmsPhrase.html +--- +# Constructor: auth.sentCodeTypeSmsPhrase +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|beginning|[string](/API_docs/types/string.html) | Optional| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeSmsPhrase = ['_' => 'auth.sentCodeTypeSmsPhrase', 'beginning' => 'string']; +``` diff --git a/docs/API_docs/constructors/auth.sentCodeTypeSmsWord.md b/docs/API_docs/constructors/auth.sentCodeTypeSmsWord.md new file mode 100644 index 0000000000..220c2bfc12 --- /dev/null +++ b/docs/API_docs/constructors/auth.sentCodeTypeSmsWord.md @@ -0,0 +1,28 @@ +--- +title: "auth.sentCodeTypeSmsWord" +description: "auth.sentCodeTypeSmsWord attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/auth_sentCodeTypeSmsWord.html +--- +# Constructor: auth.sentCodeTypeSmsWord +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|beginning|[string](/API_docs/types/string.html) | Optional| + + + +### Type: [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + + +### Example: + +``` +$auth_sentCodeTypeSmsWord = ['_' => 'auth.sentCodeTypeSmsWord', 'beginning' => 'string']; +``` diff --git a/docs/API_docs/constructors/authorization.md b/docs/API_docs/constructors/authorization.md new file mode 100644 index 0000000000..d3c71d87a2 --- /dev/null +++ b/docs/API_docs/constructors/authorization.md @@ -0,0 +1,46 @@ +--- +title: "authorization" +description: "Logged-in session" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: authorization +[Back to constructors index](/API_docs/constructors/index.html) + + + +Logged-in session + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|current|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is the current session| +|official\_app|[Bool](/API_docs/types/Bool.html) | Optional|Whether the session is from an official app| +|password\_pending|[Bool](/API_docs/types/Bool.html) | Optional|Whether the session is still waiting for a 2FA password| +|encrypted\_requests\_disabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether this session will accept encrypted chats| +|call\_requests\_disabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether this session will accept phone calls| +|unconfirmed|[Bool](/API_docs/types/Bool.html) | Optional|Whether the session is [unconfirmed, see here »](https://core.telegram.org/api/auth#confirming-login) for more info.| +|hash|[long](/API_docs/types/long.html) | Yes|Identifier| +|device\_model|[string](/API_docs/types/string.html) | Yes|Device model| +|platform|[string](/API_docs/types/string.html) | Yes|Platform| +|system\_version|[string](/API_docs/types/string.html) | Yes|System version| +|api\_id|[int](/API_docs/types/int.html) | Yes|[API ID](https://core.telegram.org/api/obtaining_api_id)| +|app\_name|[string](/API_docs/types/string.html) | Yes|App name| +|app\_version|[string](/API_docs/types/string.html) | Yes|App version| +|date\_created|[int](/API_docs/types/int.html) | Yes|When was the session created| +|date\_active|[int](/API_docs/types/int.html) | Yes|When was the session last active| +|ip|[string](/API_docs/types/string.html) | Yes|Last known IP| +|country|[string](/API_docs/types/string.html) | Yes|Country determined from IP| +|region|[string](/API_docs/types/string.html) | Yes|Region determined from IP| + + + +### Type: [Authorization](/API_docs/types/Authorization.html) + + +### Example: + +``` +$authorization = ['_' => 'authorization', 'current' => Bool, 'official_app' => Bool, 'password_pending' => Bool, 'encrypted_requests_disabled' => Bool, 'call_requests_disabled' => Bool, 'unconfirmed' => Bool, 'hash' => long, 'device_model' => 'string', 'platform' => 'string', 'system_version' => 'string', 'api_id' => int, 'app_name' => 'string', 'app_version' => 'string', 'date_created' => int, 'date_active' => int, 'ip' => 'string', 'country' => 'string', 'region' => 'string']; +``` diff --git a/docs/API_docs/constructors/autoDownloadSettings.md b/docs/API_docs/constructors/autoDownloadSettings.md new file mode 100644 index 0000000000..6b7126744b --- /dev/null +++ b/docs/API_docs/constructors/autoDownloadSettings.md @@ -0,0 +1,39 @@ +--- +title: "autoDownloadSettings" +description: "Autodownload settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: autoDownloadSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Autodownload settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|disabled|[Bool](/API_docs/types/Bool.html) | Optional|Disable automatic media downloads?| +|video\_preload\_large|[Bool](/API_docs/types/Bool.html) | Optional|Whether to preload the first seconds of videos larger than the specified limit| +|audio\_preload\_next|[Bool](/API_docs/types/Bool.html) | Optional|Whether to preload the next audio track when you're listening to music| +|phonecalls\_less\_data|[Bool](/API_docs/types/Bool.html) | Optional|Whether to enable data saving mode in phone calls| +|stories\_preload|[Bool](/API_docs/types/Bool.html) | Optional|Whether to preload [stories](https://core.telegram.org/api/stories); in particular, the first [documentAttributeVideo](../constructors/documentAttributeVideo.html).`preload_prefix_size` bytes of story videos should be preloaded.| +|photo\_size\_max|[int](/API_docs/types/int.html) | Yes|Maximum size of photos to preload| +|video\_size\_max|[long](/API_docs/types/long.html) | Yes|Maximum size of videos to preload| +|file\_size\_max|[long](/API_docs/types/long.html) | Yes|Maximum size of other files to preload| +|video\_upload\_maxbitrate|[int](/API_docs/types/int.html) | Yes|Maximum suggested bitrate for **uploading** videos| +|small\_queue\_active\_operations\_max|[int](/API_docs/types/int.html) | Yes|A limit, specifying the maximum number of files that should be downloaded in parallel from the same DC, for files smaller than 20MB.| +|large\_queue\_active\_operations\_max|[int](/API_docs/types/int.html) | Yes|A limit, specifying the maximum number of files that should be downloaded in parallel from the same DC, for files bigger than 20MB.| + + + +### Type: [AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html) + + +### Example: + +``` +$autoDownloadSettings = ['_' => 'autoDownloadSettings', 'disabled' => Bool, 'video_preload_large' => Bool, 'audio_preload_next' => Bool, 'phonecalls_less_data' => Bool, 'stories_preload' => Bool, 'photo_size_max' => int, 'video_size_max' => long, 'file_size_max' => long, 'video_upload_maxbitrate' => int, 'small_queue_active_operations_max' => int, 'large_queue_active_operations_max' => int]; +``` diff --git a/docs/API_docs/constructors/autoSaveException.md b/docs/API_docs/constructors/autoSaveException.md new file mode 100644 index 0000000000..76e720e24d --- /dev/null +++ b/docs/API_docs/constructors/autoSaveException.md @@ -0,0 +1,30 @@ +--- +title: "autoSaveException" +description: "Peer-specific media autosave settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: autoSaveException +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer-specific media autosave settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer| +|settings|[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) | Yes|Media autosave settings| + + + +### Type: [AutoSaveException](/API_docs/types/AutoSaveException.html) + + +### Example: + +``` +$autoSaveException = ['_' => 'autoSaveException', 'peer' => long, 'settings' => AutoSaveSettings]; +``` diff --git a/docs/API_docs/constructors/autoSaveSettings.md b/docs/API_docs/constructors/autoSaveSettings.md new file mode 100644 index 0000000000..d22b67b553 --- /dev/null +++ b/docs/API_docs/constructors/autoSaveSettings.md @@ -0,0 +1,31 @@ +--- +title: "autoSaveSettings" +description: "Media autosave settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: autoSaveSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Media autosave settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|photos|[Bool](/API_docs/types/Bool.html) | Optional|Whether photos should be autosaved to the gallery.| +|videos|[Bool](/API_docs/types/Bool.html) | Optional|Whether videos should be autosaved to the gallery.| +|video\_max\_size|[long](/API_docs/types/long.html) | Optional|If set, specifies a size limit for autosavable videos| + + + +### Type: [AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) + + +### Example: + +``` +$autoSaveSettings = ['_' => 'autoSaveSettings', 'photos' => Bool, 'videos' => Bool, 'video_max_size' => long]; +``` diff --git a/docs/API_docs/constructors/availableReaction.md b/docs/API_docs/constructors/availableReaction.md new file mode 100644 index 0000000000..b49bdcce9d --- /dev/null +++ b/docs/API_docs/constructors/availableReaction.md @@ -0,0 +1,39 @@ +--- +title: "availableReaction" +description: "Animations associated with a message reaction" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: availableReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Animations associated with a message reaction + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inactive|[Bool](/API_docs/types/Bool.html) | Optional|If not set, the reaction can be added to new messages and enabled in chats.| +|premium|[Bool](/API_docs/types/Bool.html) | Optional|Whether this reaction can only be used by Telegram Premium users| +|reaction|[string](/API_docs/types/string.html) | Yes|Reaction emoji| +|title|[string](/API_docs/types/string.html) | Yes|Reaction description| +|static\_icon|[Document](/API_docs/types/Document.html) | Optional|Static icon for the reaction| +|appear\_animation|[Document](/API_docs/types/Document.html) | Optional|The animated sticker to show when the user opens the reaction dropdown| +|select\_animation|[Document](/API_docs/types/Document.html) | Optional|The animated sticker to show when the user hovers over the reaction| +|activate\_animation|[Document](/API_docs/types/Document.html) | Optional|The animated sticker to show when the reaction is chosen and activated| +|effect\_animation|[Document](/API_docs/types/Document.html) | Optional|The background effect (still an animated sticker) to play under the `activate_animation`, when the reaction is chosen and activated| +|around\_animation|[Document](/API_docs/types/Document.html) | Optional|The animation that plays around the button when you press an existing reaction (played together with `center_icon`).| +|center\_icon|[Document](/API_docs/types/Document.html) | Optional|The animation of the emoji inside the button when you press an existing reaction (played together with `around_animation`).| + + + +### Type: [AvailableReaction](/API_docs/types/AvailableReaction.html) + + +### Example: + +``` +$availableReaction = ['_' => 'availableReaction', 'inactive' => Bool, 'premium' => Bool, 'reaction' => 'string', 'title' => 'string', 'static_icon' => Document, 'appear_animation' => Document, 'select_animation' => Document, 'activate_animation' => Document, 'effect_animation' => Document, 'around_animation' => Document, 'center_icon' => Document]; +``` diff --git a/docs/API_docs/constructors/bankCardOpenUrl.md b/docs/API_docs/constructors/bankCardOpenUrl.md new file mode 100644 index 0000000000..a2c5068cd1 --- /dev/null +++ b/docs/API_docs/constructors/bankCardOpenUrl.md @@ -0,0 +1,30 @@ +--- +title: "bankCardOpenUrl" +description: "Credit card info URL provided by the bank" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: bankCardOpenUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Credit card info URL provided by the bank + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Info URL| +|name|[string](/API_docs/types/string.html) | Yes|Bank name| + + + +### Type: [BankCardOpenUrl](/API_docs/types/BankCardOpenUrl.html) + + +### Example: + +``` +$bankCardOpenUrl = ['_' => 'bankCardOpenUrl', 'url' => 'string', 'name' => 'string']; +``` diff --git a/docs/API_docs/constructors/baseThemeArctic.md b/docs/API_docs/constructors/baseThemeArctic.md new file mode 100644 index 0000000000..11bd29924f --- /dev/null +++ b/docs/API_docs/constructors/baseThemeArctic.md @@ -0,0 +1,24 @@ +--- +title: "baseThemeArctic" +description: "Arctic theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: baseThemeArctic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Arctic theme + + + + +### Type: [BaseTheme](/API_docs/types/BaseTheme.html) + + +### Example: + +``` +$baseThemeArctic = ['_' => 'baseThemeArctic']; +``` diff --git a/docs/API_docs/constructors/baseThemeClassic.md b/docs/API_docs/constructors/baseThemeClassic.md new file mode 100644 index 0000000000..1e88d57bb2 --- /dev/null +++ b/docs/API_docs/constructors/baseThemeClassic.md @@ -0,0 +1,24 @@ +--- +title: "baseThemeClassic" +description: "Classic theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: baseThemeClassic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Classic theme + + + + +### Type: [BaseTheme](/API_docs/types/BaseTheme.html) + + +### Example: + +``` +$baseThemeClassic = ['_' => 'baseThemeClassic']; +``` diff --git a/docs/API_docs/constructors/baseThemeDay.md b/docs/API_docs/constructors/baseThemeDay.md new file mode 100644 index 0000000000..f3b04e20d5 --- /dev/null +++ b/docs/API_docs/constructors/baseThemeDay.md @@ -0,0 +1,24 @@ +--- +title: "baseThemeDay" +description: "Day theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: baseThemeDay +[Back to constructors index](/API_docs/constructors/index.html) + + + +Day theme + + + + +### Type: [BaseTheme](/API_docs/types/BaseTheme.html) + + +### Example: + +``` +$baseThemeDay = ['_' => 'baseThemeDay']; +``` diff --git a/docs/API_docs/constructors/baseThemeNight.md b/docs/API_docs/constructors/baseThemeNight.md new file mode 100644 index 0000000000..695be826d5 --- /dev/null +++ b/docs/API_docs/constructors/baseThemeNight.md @@ -0,0 +1,24 @@ +--- +title: "baseThemeNight" +description: "Night theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: baseThemeNight +[Back to constructors index](/API_docs/constructors/index.html) + + + +Night theme + + + + +### Type: [BaseTheme](/API_docs/types/BaseTheme.html) + + +### Example: + +``` +$baseThemeNight = ['_' => 'baseThemeNight']; +``` diff --git a/docs/API_docs/constructors/baseThemeTinted.md b/docs/API_docs/constructors/baseThemeTinted.md new file mode 100644 index 0000000000..573099e486 --- /dev/null +++ b/docs/API_docs/constructors/baseThemeTinted.md @@ -0,0 +1,24 @@ +--- +title: "baseThemeTinted" +description: "Tinted theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: baseThemeTinted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Tinted theme + + + + +### Type: [BaseTheme](/API_docs/types/BaseTheme.html) + + +### Example: + +``` +$baseThemeTinted = ['_' => 'baseThemeTinted']; +``` diff --git a/docs/API_docs/constructors/birthday.md b/docs/API_docs/constructors/birthday.md new file mode 100644 index 0000000000..47cfc54eef --- /dev/null +++ b/docs/API_docs/constructors/birthday.md @@ -0,0 +1,29 @@ +--- +title: "birthday" +description: "birthday attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: birthday +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|day|[int](/API_docs/types/int.html) | Yes| +|month|[int](/API_docs/types/int.html) | Yes| +|year|[int](/API_docs/types/int.html) | Optional| + + + +### Type: [Birthday](/API_docs/types/Birthday.html) + + +### Example: + +``` +$birthday = ['_' => 'birthday', 'day' => int, 'month' => int, 'year' => int]; +``` diff --git a/docs/API_docs/constructors/boolFalse.md b/docs/API_docs/constructors/boolFalse.md new file mode 100644 index 0000000000..a3fd4f1a87 --- /dev/null +++ b/docs/API_docs/constructors/boolFalse.md @@ -0,0 +1,10 @@ +--- +title: boolFalse +description: Represents a boolean with value equal to false +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# boolFalse +[Back to constructor index](index.html) + +Represents a boolean with value equal to `false`. diff --git a/docs/API_docs/constructors/boolTrue.md b/docs/API_docs/constructors/boolTrue.md new file mode 100644 index 0000000000..3e6866f9b0 --- /dev/null +++ b/docs/API_docs/constructors/boolTrue.md @@ -0,0 +1,10 @@ +--- +title: boolTrue +description: Represents a boolean with value equal to true +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# boolTrue +[Back to constructor index](index.html) + +Represents a boolean with value equal to `true`. diff --git a/docs/API_docs/constructors/boost.md b/docs/API_docs/constructors/boost.md new file mode 100644 index 0000000000..4fecb6ec65 --- /dev/null +++ b/docs/API_docs/constructors/boost.md @@ -0,0 +1,38 @@ +--- +title: "boost" +description: "Info about one or more boosts applied by a specific user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: boost +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about one or more [boosts](https://core.telegram.org/api/boost) applied by a specific user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|gift|[Bool](/API_docs/types/Bool.html) | Optional|Whether this boost was applied because the channel [directly gifted a subscription to the user](https://core.telegram.org/api/giveaways).| +|giveaway|[Bool](/API_docs/types/Bool.html) | Optional|Whether this boost was applied because the user was chosen in a [giveaway started by the channel](https://core.telegram.org/api/giveaways).| +|unclaimed|[Bool](/API_docs/types/Bool.html) | Optional|If set, the user hasn't yet invoked [payments.applyGiftCode](../methods/payments.applyGiftCode.html) to claim a subscription gifted [directly or in a giveaway by the channel](https://core.telegram.org/api/giveaways).| +|id|[string](/API_docs/types/string.html) | Yes|Unique ID for this set of boosts.| +|user\_id|[long](/API_docs/types/long.html) | Optional|ID of the user that applied the boost.| +|giveaway\_msg\_id|[int](/API_docs/types/int.html) | Optional|The message ID of the [giveaway](https://core.telegram.org/api/giveaways)| +|date|[int](/API_docs/types/int.html) | Yes|When was the boost applied| +|expires|[int](/API_docs/types/int.html) | Yes|When does the boost expire| +|used\_gift\_slug|[string](/API_docs/types/string.html) | Optional|The created Telegram Premium gift code, only set if either `gift` or `giveaway` are set AND it is either a gift code for the currently logged in user or if it was already claimed.| +|multiplier|[int](/API_docs/types/int.html) | Optional|If set, this boost counts as `multiplier` boosts, otherwise it counts as a single boost.| + + + +### Type: [Boost](/API_docs/types/Boost.html) + + +### Example: + +``` +$boost = ['_' => 'boost', 'gift' => Bool, 'giveaway' => Bool, 'unclaimed' => Bool, 'id' => 'string', 'user_id' => long, 'giveaway_msg_id' => int, 'date' => int, 'expires' => int, 'used_gift_slug' => 'string', 'multiplier' => int]; +``` diff --git a/docs/API_docs/constructors/botApp.md b/docs/API_docs/constructors/botApp.md new file mode 100644 index 0000000000..4805e5c18c --- /dev/null +++ b/docs/API_docs/constructors/botApp.md @@ -0,0 +1,36 @@ +--- +title: "botApp" +description: "Contains information about a direct link Mini App." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botApp +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains information about a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|bot mini app ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|bot mini app access hash| +|short\_name|[string](/API_docs/types/string.html) | Yes|bot mini app short name, used to generate [Direct Mini App deep links](https://core.telegram.org/api/links#direct-mini-app-links).| +|title|[string](/API_docs/types/string.html) | Yes|bot mini app title.| +|description|[string](/API_docs/types/string.html) | Yes|bot mini app description.| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|bot mini app photo.| +|document|[Document](/API_docs/types/Document.html) | Optional|bot mini app animation.| +|hash|[long](/API_docs/types/long.html) | Yes|Hash to pass to [messages.getBotApp](../methods/messages.getBotApp.html), to avoid refetching bot app info if it hasn't changed.| + + + +### Type: [BotApp](/API_docs/types/BotApp.html) + + +### Example: + +``` +$botApp = ['_' => 'botApp', 'id' => long, 'access_hash' => long, 'short_name' => 'string', 'title' => 'string', 'description' => 'string', 'photo' => Photo, 'document' => Document, 'hash' => long]; +``` diff --git a/docs/API_docs/constructors/botAppNotModified.md b/docs/API_docs/constructors/botAppNotModified.md new file mode 100644 index 0000000000..c4e8eda66b --- /dev/null +++ b/docs/API_docs/constructors/botAppNotModified.md @@ -0,0 +1,24 @@ +--- +title: "botAppNotModified" +description: "Bot app info hasn't changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botAppNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bot app info hasn't changed. + + + + +### Type: [BotApp](/API_docs/types/BotApp.html) + + +### Example: + +``` +$botAppNotModified = ['_' => 'botAppNotModified']; +``` diff --git a/docs/API_docs/constructors/botBusinessConnection.md b/docs/API_docs/constructors/botBusinessConnection.md new file mode 100644 index 0000000000..f96d035008 --- /dev/null +++ b/docs/API_docs/constructors/botBusinessConnection.md @@ -0,0 +1,32 @@ +--- +title: "botBusinessConnection" +description: "botBusinessConnection attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botBusinessConnection +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|can\_reply|[Bool](/API_docs/types/Bool.html) | Optional| +|disabled|[Bool](/API_docs/types/Bool.html) | Optional| +|connection\_id|[string](/API_docs/types/string.html) | Yes| +|user\_id|[long](/API_docs/types/long.html) | Yes| +|dc\_id|[int](/API_docs/types/int.html) | Yes| +|date|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [BotBusinessConnection](/API_docs/types/BotBusinessConnection.html) + + +### Example: + +``` +$botBusinessConnection = ['_' => 'botBusinessConnection', 'can_reply' => Bool, 'disabled' => Bool, 'connection_id' => 'string', 'user_id' => long, 'dc_id' => int, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/botCommand.md b/docs/API_docs/constructors/botCommand.md new file mode 100644 index 0000000000..53ae68d7bb --- /dev/null +++ b/docs/API_docs/constructors/botCommand.md @@ -0,0 +1,30 @@ +--- +title: "botCommand" +description: "Describes a bot command that can be used in a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommand +[Back to constructors index](/API_docs/constructors/index.html) + + + +Describes a bot command that can be used in a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|command|[string](/API_docs/types/string.html) | Yes|`/command` name| +|description|[string](/API_docs/types/string.html) | Yes|Description of the command| + + + +### Type: [BotCommand](/API_docs/types/BotCommand.html) + + +### Example: + +``` +$botCommand = ['_' => 'botCommand', 'command' => 'string', 'description' => 'string']; +``` diff --git a/docs/API_docs/constructors/botCommandScopeChatAdmins.md b/docs/API_docs/constructors/botCommandScopeChatAdmins.md new file mode 100644 index 0000000000..64d5e5cc99 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopeChatAdmins.md @@ -0,0 +1,24 @@ +--- +title: "botCommandScopeChatAdmins" +description: "The specified bot commands will be valid only for chat administrators, in all groups and supergroups." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopeChatAdmins +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified bot commands will be valid only for chat administrators, in all [groups and supergroups](https://core.telegram.org/api/channel). + + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopeChatAdmins = ['_' => 'botCommandScopeChatAdmins']; +``` diff --git a/docs/API_docs/constructors/botCommandScopeChats.md b/docs/API_docs/constructors/botCommandScopeChats.md new file mode 100644 index 0000000000..da3e567431 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopeChats.md @@ -0,0 +1,24 @@ +--- +title: "botCommandScopeChats" +description: "The specified bot commands will be valid in all groups and supergroups." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopeChats +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified bot commands will be valid in all [groups and supergroups](https://core.telegram.org/api/channel). + + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopeChats = ['_' => 'botCommandScopeChats']; +``` diff --git a/docs/API_docs/constructors/botCommandScopeDefault.md b/docs/API_docs/constructors/botCommandScopeDefault.md new file mode 100644 index 0000000000..32a96ce701 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopeDefault.md @@ -0,0 +1,24 @@ +--- +title: "botCommandScopeDefault" +description: "The commands will be valid in all dialogs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopeDefault +[Back to constructors index](/API_docs/constructors/index.html) + + + +The commands will be valid in all dialogs + + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopeDefault = ['_' => 'botCommandScopeDefault']; +``` diff --git a/docs/API_docs/constructors/botCommandScopePeer.md b/docs/API_docs/constructors/botCommandScopePeer.md new file mode 100644 index 0000000000..baa877fe91 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopePeer.md @@ -0,0 +1,29 @@ +--- +title: "botCommandScopePeer" +description: "The specified bot commands will be valid only in a specific dialog." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopePeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified bot commands will be valid only in a specific dialog. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[InputPeer](/API_docs/types/InputPeer.html) | Optional|The dialog| + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopePeer = ['_' => 'botCommandScopePeer', 'peer' => InputPeer]; +``` diff --git a/docs/API_docs/constructors/botCommandScopePeerAdmins.md b/docs/API_docs/constructors/botCommandScopePeerAdmins.md new file mode 100644 index 0000000000..277b4dafd1 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopePeerAdmins.md @@ -0,0 +1,29 @@ +--- +title: "botCommandScopePeerAdmins" +description: "The specified bot commands will be valid for all admins of the specified group or supergroup." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopePeerAdmins +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified bot commands will be valid for all admins of the specified [group or supergroup](https://core.telegram.org/api/channel). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[InputPeer](/API_docs/types/InputPeer.html) | Optional|The chat| + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopePeerAdmins = ['_' => 'botCommandScopePeerAdmins', 'peer' => InputPeer]; +``` diff --git a/docs/API_docs/constructors/botCommandScopePeerUser.md b/docs/API_docs/constructors/botCommandScopePeerUser.md new file mode 100644 index 0000000000..53c34b90e2 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopePeerUser.md @@ -0,0 +1,30 @@ +--- +title: "botCommandScopePeerUser" +description: "The specified bot commands will be valid only for a specific user in the specified group or supergroup." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopePeerUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified bot commands will be valid only for a specific user in the specified [group or supergroup](https://core.telegram.org/api/channel). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[InputPeer](/API_docs/types/InputPeer.html) | Optional|The chat| +|user\_id|[InputUser](/API_docs/types/InputUser.html) | Optional|The user| + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopePeerUser = ['_' => 'botCommandScopePeerUser', 'peer' => InputPeer, 'user_id' => InputUser]; +``` diff --git a/docs/API_docs/constructors/botCommandScopeUsers.md b/docs/API_docs/constructors/botCommandScopeUsers.md new file mode 100644 index 0000000000..be96ec2403 --- /dev/null +++ b/docs/API_docs/constructors/botCommandScopeUsers.md @@ -0,0 +1,24 @@ +--- +title: "botCommandScopeUsers" +description: "The specified bot commands will only be valid in all private chats with users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botCommandScopeUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified bot commands will only be valid in all private chats with users. + + + + +### Type: [BotCommandScope](/API_docs/types/BotCommandScope.html) + + +### Example: + +``` +$botCommandScopeUsers = ['_' => 'botCommandScopeUsers']; +``` diff --git a/docs/API_docs/constructors/botInfo.md b/docs/API_docs/constructors/botInfo.md new file mode 100644 index 0000000000..1785629482 --- /dev/null +++ b/docs/API_docs/constructors/botInfo.md @@ -0,0 +1,34 @@ +--- +title: "botInfo" +description: "Info about bots (available bot commands, etc)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about bots (available bot commands, etc) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Optional|ID of the bot| +|description|[string](/API_docs/types/string.html) | Optional|Description of the bot| +|description\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Description photo| +|description\_document|[Document](/API_docs/types/Document.html) | Optional|Description animation in MPEG4 format| +|commands|Array of [BotCommand](/API_docs/types/BotCommand.html) | Optional|Bot commands that can be used in the chat| +|menu\_button|[BotMenuButton](/API_docs/types/BotMenuButton.html) | Optional|Indicates the action to execute when pressing the in-UI menu button for bots| + + + +### Type: [BotInfo](/API_docs/types/BotInfo.html) + + +### Example: + +``` +$botInfo = ['_' => 'botInfo', 'user_id' => long, 'description' => 'string', 'description_photo' => Photo, 'description_document' => Document, 'commands' => [BotCommand, BotCommand], 'menu_button' => BotMenuButton]; +``` diff --git a/docs/API_docs/constructors/botInlineMediaResult.md b/docs/API_docs/constructors/botInlineMediaResult.md new file mode 100644 index 0000000000..927a2a135e --- /dev/null +++ b/docs/API_docs/constructors/botInlineMediaResult.md @@ -0,0 +1,35 @@ +--- +title: "botInlineMediaResult" +description: "Media result" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMediaResult +[Back to constructors index](/API_docs/constructors/index.html) + + + +Media result + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Result ID| +|type|[string](/API_docs/types/string.html) | Yes|Result type (see [bot API docs](https://core.telegram.org/bots/api#inlinequeryresult))| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|If type is `photo`, the photo to send| +|document|[Document](/API_docs/types/Document.html) | Optional|If type is `document`, the document to send| +|title|[string](/API_docs/types/string.html) | Optional|Result title| +|description|[string](/API_docs/types/string.html) | Optional|Description| +|send\_message|[BotInlineMessage](/API_docs/types/BotInlineMessage.html) | Yes|Depending on the `type` and on the [constructor](../types/BotInlineMessage.html), contains the caption of the media or the content of the message to be sent **instead** of the media| + + + +### Type: [BotInlineResult](/API_docs/types/BotInlineResult.html) + + +### Example: + +``` +$botInlineMediaResult = ['_' => 'botInlineMediaResult', 'id' => 'string', 'type' => 'string', 'photo' => Photo, 'document' => Document, 'title' => 'string', 'description' => 'string', 'send_message' => BotInlineMessage]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageMediaAuto.md b/docs/API_docs/constructors/botInlineMessageMediaAuto.md new file mode 100644 index 0000000000..e743226b8d --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageMediaAuto.md @@ -0,0 +1,93 @@ +--- +title: "botInlineMessageMediaAuto" +description: "Send whatever media is attached to the botInlineMediaResult" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageMediaAuto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send whatever media is attached to the [botInlineMediaResult](../constructors/botInlineMediaResult.html) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|message|[string](/API_docs/types/string.html) | Yes|Caption| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$botInlineMessageMediaAuto = ['_' => 'botInlineMessageMediaAuto', 'invert_media' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageMediaContact.md b/docs/API_docs/constructors/botInlineMessageMediaContact.md new file mode 100644 index 0000000000..ad42af4e95 --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageMediaContact.md @@ -0,0 +1,39 @@ +--- +title: "botInlineMessageMediaContact" +description: "Send a contact" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageMediaContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send a contact + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|First name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Last name| +|vcard|[string](/API_docs/types/string.html) | Yes|VCard info| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$botInlineMessageMediaContact = ['_' => 'botInlineMessageMediaContact', 'phone_number' => 'string', 'first_name' => 'string', 'last_name' => 'string', 'vcard' => 'string', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageMediaGeo.md b/docs/API_docs/constructors/botInlineMessageMediaGeo.md new file mode 100644 index 0000000000..d28b8b8bc0 --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageMediaGeo.md @@ -0,0 +1,39 @@ +--- +title: "botInlineMessageMediaGeo" +description: "Send a geolocation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageMediaGeo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send a geolocation + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Geolocation| +|heading|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a direction in which the location moves, in degrees; 1-360.| +|period|[int](/API_docs/types/int.html) | Optional|Validity period| +|proximity\_notification\_radius|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a maximum distance to another chat member for proximity alerts, in meters (0-100000).| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$botInlineMessageMediaGeo = ['_' => 'botInlineMessageMediaGeo', 'geo' => GeoPoint, 'heading' => int, 'period' => int, 'proximity_notification_radius' => int, 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageMediaInvoice.md b/docs/API_docs/constructors/botInlineMessageMediaInvoice.md new file mode 100644 index 0000000000..59725522f9 --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageMediaInvoice.md @@ -0,0 +1,42 @@ +--- +title: "botInlineMessageMediaInvoice" +description: "Send an invoice" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageMediaInvoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send an invoice + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|shipping\_address\_requested|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if you require the user's shipping address to complete the order| +|test|[Bool](/API_docs/types/Bool.html) | Optional|Test invoice| +|title|[string](/API_docs/types/string.html) | Yes|Product name, 1-32 characters| +|description|[string](/API_docs/types/string.html) | Yes|Product description, 1-255 characters| +|photo|[WebDocument](/API_docs/types/WebDocument.html) | Optional|Product photo| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|total\_amount|[long](/API_docs/types/long.html) | Yes|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$botInlineMessageMediaInvoice = ['_' => 'botInlineMessageMediaInvoice', 'shipping_address_requested' => Bool, 'test' => Bool, 'title' => 'string', 'description' => 'string', 'photo' => WebDocument, 'currency' => 'string', 'total_amount' => long, 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageMediaVenue.md b/docs/API_docs/constructors/botInlineMessageMediaVenue.md new file mode 100644 index 0000000000..71b37e9d4a --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageMediaVenue.md @@ -0,0 +1,41 @@ +--- +title: "botInlineMessageMediaVenue" +description: "Send a venue" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageMediaVenue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send a venue + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Geolocation of venue| +|title|[string](/API_docs/types/string.html) | Yes|Venue name| +|address|[string](/API_docs/types/string.html) | Yes|Address| +|provider|[string](/API_docs/types/string.html) | Yes|Venue provider: currently only "foursquare" and "gplaces" (Google Places) need to be supported| +|venue\_id|[string](/API_docs/types/string.html) | Yes|Venue ID in the provider's database| +|venue\_type|[string](/API_docs/types/string.html) | Yes|Venue type in the provider's database| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$botInlineMessageMediaVenue = ['_' => 'botInlineMessageMediaVenue', 'geo' => GeoPoint, 'title' => 'string', 'address' => 'string', 'provider' => 'string', 'venue_id' => 'string', 'venue_type' => 'string', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageMediaWebPage.md b/docs/API_docs/constructors/botInlineMessageMediaWebPage.md new file mode 100644 index 0000000000..a9ba3ebb3b --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageMediaWebPage.md @@ -0,0 +1,98 @@ +--- +title: "botInlineMessageMediaWebPage" +description: "Specifies options that must be used to generate the link preview for the message, or even a standalone link preview without an attached message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageMediaWebPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Specifies options that must be used to generate the link preview for the message, or even a standalone link preview without an attached message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|force\_large\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a large media preview should be used.| +|force\_small\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a small media preview should be used.| +|manual|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates that the URL used for the webpage preview was specified manually using [inputMediaWebPage](../constructors/inputMediaWebPage.html), and may not be related to any of the URLs specified in the message.| +|safe|[Bool](/API_docs/types/Bool.html) | Optional|If set, the link can be opened directly without user confirmation.| +|message|[string](/API_docs/types/string.html) | Yes|The message, can be empty.| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|url|[string](/API_docs/types/string.html) | Yes|The URL to use for the link preview.| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Reply markup for sending bot buttons| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$botInlineMessageMediaWebPage = ['_' => 'botInlineMessageMediaWebPage', 'invert_media' => Bool, 'force_large_media' => Bool, 'force_small_media' => Bool, 'manual' => Bool, 'safe' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'url' => 'string', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineMessageText.md b/docs/API_docs/constructors/botInlineMessageText.md new file mode 100644 index 0000000000..7ea55cfa18 --- /dev/null +++ b/docs/API_docs/constructors/botInlineMessageText.md @@ -0,0 +1,94 @@ +--- +title: "botInlineMessageText" +description: "Send a simple text message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineMessageText +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send a simple text message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Optional|Disable webpage preview| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|message|[string](/API_docs/types/string.html) | Yes|The message| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [BotInlineMessage](/API_docs/types/BotInlineMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$botInlineMessageText = ['_' => 'botInlineMessageText', 'no_webpage' => Bool, 'invert_media' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/botInlineResult.md b/docs/API_docs/constructors/botInlineResult.md new file mode 100644 index 0000000000..e95d93f95d --- /dev/null +++ b/docs/API_docs/constructors/botInlineResult.md @@ -0,0 +1,36 @@ +--- +title: "botInlineResult" +description: "Generic result" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botInlineResult +[Back to constructors index](/API_docs/constructors/index.html) + + + +Generic result + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Result ID| +|type|[string](/API_docs/types/string.html) | Yes|Result type (see [bot API docs](https://core.telegram.org/bots/api#inlinequeryresult))| +|title|[string](/API_docs/types/string.html) | Optional|Result title| +|description|[string](/API_docs/types/string.html) | Optional|Result description| +|url|[string](/API_docs/types/string.html) | Optional|URL of article or webpage| +|thumb|[WebDocument](/API_docs/types/WebDocument.html) | Optional|Thumbnail for the result| +|content|[WebDocument](/API_docs/types/WebDocument.html) | Optional|Content of the result| +|send\_message|[BotInlineMessage](/API_docs/types/BotInlineMessage.html) | Yes|Message to send| + + + +### Type: [BotInlineResult](/API_docs/types/BotInlineResult.html) + + +### Example: + +``` +$botInlineResult = ['_' => 'botInlineResult', 'id' => 'string', 'type' => 'string', 'title' => 'string', 'description' => 'string', 'url' => 'string', 'thumb' => WebDocument, 'content' => WebDocument, 'send_message' => BotInlineMessage]; +``` diff --git a/docs/API_docs/constructors/botMenuButton.md b/docs/API_docs/constructors/botMenuButton.md new file mode 100644 index 0000000000..df45db1f8e --- /dev/null +++ b/docs/API_docs/constructors/botMenuButton.md @@ -0,0 +1,30 @@ +--- +title: "botMenuButton" +description: "Bot menu button that opens a web app when clicked." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botMenuButton +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Bot menu button](https://core.telegram.org/api/bots/menu) that opens a [web app](https://core.telegram.org/api/bots/webapps) when clicked. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Title to be displayed on the menu button instead of 'Menu'| +|url|[string](/API_docs/types/string.html) | Yes|URL of a [web app](https://core.telegram.org/api/bots/webapps) to open when the user clicks on the button| + + + +### Type: [BotMenuButton](/API_docs/types/BotMenuButton.html) + + +### Example: + +``` +$botMenuButton = ['_' => 'botMenuButton', 'text' => 'string', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/botMenuButtonCommands.md b/docs/API_docs/constructors/botMenuButtonCommands.md new file mode 100644 index 0000000000..69f21dfd04 --- /dev/null +++ b/docs/API_docs/constructors/botMenuButtonCommands.md @@ -0,0 +1,24 @@ +--- +title: "botMenuButtonCommands" +description: "Bot menu button that opens the bot command list when clicked." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botMenuButtonCommands +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Bot menu button](https://core.telegram.org/api/bots/menu) that opens the bot command list when clicked. + + + + +### Type: [BotMenuButton](/API_docs/types/BotMenuButton.html) + + +### Example: + +``` +$botMenuButtonCommands = ['_' => 'botMenuButtonCommands']; +``` diff --git a/docs/API_docs/constructors/botMenuButtonDefault.md b/docs/API_docs/constructors/botMenuButtonDefault.md new file mode 100644 index 0000000000..3ceb4e873e --- /dev/null +++ b/docs/API_docs/constructors/botMenuButtonDefault.md @@ -0,0 +1,24 @@ +--- +title: "botMenuButtonDefault" +description: "Placeholder bot menu button never returned to users: see the docs for more info." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: botMenuButtonDefault +[Back to constructors index](/API_docs/constructors/index.html) + + + +Placeholder [bot menu button](https://core.telegram.org/api/bots/menu) never returned to users: see [the docs for more info](https://core.telegram.org/api/bots/menu). + + + + +### Type: [BotMenuButton](/API_docs/types/BotMenuButton.html) + + +### Example: + +``` +$botMenuButtonDefault = ['_' => 'botMenuButtonDefault']; +``` diff --git a/docs/API_docs/constructors/bots.botInfo.md b/docs/API_docs/constructors/bots.botInfo.md new file mode 100644 index 0000000000..f957085e68 --- /dev/null +++ b/docs/API_docs/constructors/bots.botInfo.md @@ -0,0 +1,32 @@ +--- +title: "bots.botInfo" +description: "Localized information about a bot." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/bots_botInfo.html +--- +# Constructor: bots.botInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Localized information about a bot. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|name|[string](/API_docs/types/string.html) | Yes|Bot name| +|about|[string](/API_docs/types/string.html) | Yes|Bot about text| +|description|[string](/API_docs/types/string.html) | Yes|Bot description| + + + +### Type: [bots.BotInfo](/API_docs/types/bots.BotInfo.html) + + +### Example: + +``` +$bots_botInfo = ['_' => 'bots.botInfo', 'name' => 'string', 'about' => 'string', 'description' => 'string']; +``` diff --git a/docs/API_docs/constructors/broadcastRevenueBalances.md b/docs/API_docs/constructors/broadcastRevenueBalances.md new file mode 100644 index 0000000000..79bb8f081e --- /dev/null +++ b/docs/API_docs/constructors/broadcastRevenueBalances.md @@ -0,0 +1,29 @@ +--- +title: "broadcastRevenueBalances" +description: "broadcastRevenueBalances attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: broadcastRevenueBalances +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|current\_balance|[long](/API_docs/types/long.html) | Yes| +|available\_balance|[long](/API_docs/types/long.html) | Yes| +|overall\_revenue|[long](/API_docs/types/long.html) | Yes| + + + +### Type: [BroadcastRevenueBalances](/API_docs/types/BroadcastRevenueBalances.html) + + +### Example: + +``` +$broadcastRevenueBalances = ['_' => 'broadcastRevenueBalances', 'current_balance' => long, 'available_balance' => long, 'overall_revenue' => long]; +``` diff --git a/docs/API_docs/constructors/broadcastRevenueTransactionProceeds.md b/docs/API_docs/constructors/broadcastRevenueTransactionProceeds.md new file mode 100644 index 0000000000..eec94a1de7 --- /dev/null +++ b/docs/API_docs/constructors/broadcastRevenueTransactionProceeds.md @@ -0,0 +1,29 @@ +--- +title: "broadcastRevenueTransactionProceeds" +description: "broadcastRevenueTransactionProceeds attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: broadcastRevenueTransactionProceeds +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|amount|[long](/API_docs/types/long.html) | Yes| +|from\_date|[int](/API_docs/types/int.html) | Yes| +|to\_date|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [BroadcastRevenueTransaction](/API_docs/types/BroadcastRevenueTransaction.html) + + +### Example: + +``` +$broadcastRevenueTransactionProceeds = ['_' => 'broadcastRevenueTransactionProceeds', 'amount' => long, 'from_date' => int, 'to_date' => int]; +``` diff --git a/docs/API_docs/constructors/broadcastRevenueTransactionRefund.md b/docs/API_docs/constructors/broadcastRevenueTransactionRefund.md new file mode 100644 index 0000000000..f37dd253a5 --- /dev/null +++ b/docs/API_docs/constructors/broadcastRevenueTransactionRefund.md @@ -0,0 +1,29 @@ +--- +title: "broadcastRevenueTransactionRefund" +description: "broadcastRevenueTransactionRefund attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: broadcastRevenueTransactionRefund +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|amount|[long](/API_docs/types/long.html) | Yes| +|date|[int](/API_docs/types/int.html) | Yes| +|provider|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [BroadcastRevenueTransaction](/API_docs/types/BroadcastRevenueTransaction.html) + + +### Example: + +``` +$broadcastRevenueTransactionRefund = ['_' => 'broadcastRevenueTransactionRefund', 'amount' => long, 'date' => int, 'provider' => 'string']; +``` diff --git a/docs/API_docs/constructors/broadcastRevenueTransactionWithdrawal.md b/docs/API_docs/constructors/broadcastRevenueTransactionWithdrawal.md new file mode 100644 index 0000000000..0e79242b45 --- /dev/null +++ b/docs/API_docs/constructors/broadcastRevenueTransactionWithdrawal.md @@ -0,0 +1,33 @@ +--- +title: "broadcastRevenueTransactionWithdrawal" +description: "broadcastRevenueTransactionWithdrawal attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: broadcastRevenueTransactionWithdrawal +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|pending|[Bool](/API_docs/types/Bool.html) | Optional| +|failed|[Bool](/API_docs/types/Bool.html) | Optional| +|amount|[long](/API_docs/types/long.html) | Yes| +|date|[int](/API_docs/types/int.html) | Yes| +|provider|[string](/API_docs/types/string.html) | Yes| +|transaction\_date|[int](/API_docs/types/int.html) | Optional| +|transaction\_url|[string](/API_docs/types/string.html) | Optional| + + + +### Type: [BroadcastRevenueTransaction](/API_docs/types/BroadcastRevenueTransaction.html) + + +### Example: + +``` +$broadcastRevenueTransactionWithdrawal = ['_' => 'broadcastRevenueTransactionWithdrawal', 'pending' => Bool, 'failed' => Bool, 'amount' => long, 'date' => int, 'provider' => 'string', 'transaction_date' => int, 'transaction_url' => 'string']; +``` diff --git a/docs/API_docs/constructors/businessAwayMessage.md b/docs/API_docs/constructors/businessAwayMessage.md new file mode 100644 index 0000000000..6cf265cb33 --- /dev/null +++ b/docs/API_docs/constructors/businessAwayMessage.md @@ -0,0 +1,30 @@ +--- +title: "businessAwayMessage" +description: "businessAwayMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessAwayMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|offline\_only|[Bool](/API_docs/types/Bool.html) | Optional| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| +|schedule|[BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html) | Yes| +|recipients|[BusinessRecipients](/API_docs/types/BusinessRecipients.html) | Yes| + + + +### Type: [BusinessAwayMessage](/API_docs/types/BusinessAwayMessage.html) + + +### Example: + +``` +$businessAwayMessage = ['_' => 'businessAwayMessage', 'offline_only' => Bool, 'shortcut_id' => int, 'schedule' => BusinessAwayMessageSchedule, 'recipients' => BusinessRecipients]; +``` diff --git a/docs/API_docs/constructors/businessAwayMessageScheduleAlways.md b/docs/API_docs/constructors/businessAwayMessageScheduleAlways.md new file mode 100644 index 0000000000..4b80b63d23 --- /dev/null +++ b/docs/API_docs/constructors/businessAwayMessageScheduleAlways.md @@ -0,0 +1,22 @@ +--- +title: "businessAwayMessageScheduleAlways" +description: "businessAwayMessageScheduleAlways attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessAwayMessageScheduleAlways +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html) + + +### Example: + +``` +$businessAwayMessageScheduleAlways = ['_' => 'businessAwayMessageScheduleAlways']; +``` diff --git a/docs/API_docs/constructors/businessAwayMessageScheduleCustom.md b/docs/API_docs/constructors/businessAwayMessageScheduleCustom.md new file mode 100644 index 0000000000..0ebed49fb1 --- /dev/null +++ b/docs/API_docs/constructors/businessAwayMessageScheduleCustom.md @@ -0,0 +1,28 @@ +--- +title: "businessAwayMessageScheduleCustom" +description: "businessAwayMessageScheduleCustom attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessAwayMessageScheduleCustom +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|start\_date|[int](/API_docs/types/int.html) | Yes| +|end\_date|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html) + + +### Example: + +``` +$businessAwayMessageScheduleCustom = ['_' => 'businessAwayMessageScheduleCustom', 'start_date' => int, 'end_date' => int]; +``` diff --git a/docs/API_docs/constructors/businessAwayMessageScheduleOutsideWorkHours.md b/docs/API_docs/constructors/businessAwayMessageScheduleOutsideWorkHours.md new file mode 100644 index 0000000000..18cf9376ea --- /dev/null +++ b/docs/API_docs/constructors/businessAwayMessageScheduleOutsideWorkHours.md @@ -0,0 +1,22 @@ +--- +title: "businessAwayMessageScheduleOutsideWorkHours" +description: "businessAwayMessageScheduleOutsideWorkHours attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessAwayMessageScheduleOutsideWorkHours +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html) + + +### Example: + +``` +$businessAwayMessageScheduleOutsideWorkHours = ['_' => 'businessAwayMessageScheduleOutsideWorkHours']; +``` diff --git a/docs/API_docs/constructors/businessBotRecipients.md b/docs/API_docs/constructors/businessBotRecipients.md new file mode 100644 index 0000000000..0c6e84befd --- /dev/null +++ b/docs/API_docs/constructors/businessBotRecipients.md @@ -0,0 +1,33 @@ +--- +title: "businessBotRecipients" +description: "businessBotRecipients attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessBotRecipients +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|existing\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|new\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|non\_contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|exclude\_selected|[Bool](/API_docs/types/Bool.html) | Optional| +|users|Array of [long](/API_docs/types/long.html) | Optional| +|exclude\_users|Array of [long](/API_docs/types/long.html) | Optional| + + + +### Type: [BusinessBotRecipients](/API_docs/types/BusinessBotRecipients.html) + + +### Example: + +``` +$businessBotRecipients = ['_' => 'businessBotRecipients', 'existing_chats' => Bool, 'new_chats' => Bool, 'contacts' => Bool, 'non_contacts' => Bool, 'exclude_selected' => Bool, 'users' => [long, long], 'exclude_users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/businessChatLink.md b/docs/API_docs/constructors/businessChatLink.md new file mode 100644 index 0000000000..9bb5a872d1 --- /dev/null +++ b/docs/API_docs/constructors/businessChatLink.md @@ -0,0 +1,92 @@ +--- +title: "businessChatLink" +description: "businessChatLink attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessChatLink +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|link|[string](/API_docs/types/string.html) | Yes| +|message|[string](/API_docs/types/string.html) | Yes| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|title|[string](/API_docs/types/string.html) | Optional| +|views|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [BusinessChatLink](/API_docs/types/BusinessChatLink.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$businessChatLink = ['_' => 'businessChatLink', 'link' => 'string', 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'title' => 'string', 'views' => int]; +``` diff --git a/docs/API_docs/constructors/businessGreetingMessage.md b/docs/API_docs/constructors/businessGreetingMessage.md new file mode 100644 index 0000000000..180ce9527d --- /dev/null +++ b/docs/API_docs/constructors/businessGreetingMessage.md @@ -0,0 +1,29 @@ +--- +title: "businessGreetingMessage" +description: "businessGreetingMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessGreetingMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| +|recipients|[BusinessRecipients](/API_docs/types/BusinessRecipients.html) | Yes| +|no\_activity\_days|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [BusinessGreetingMessage](/API_docs/types/BusinessGreetingMessage.html) + + +### Example: + +``` +$businessGreetingMessage = ['_' => 'businessGreetingMessage', 'shortcut_id' => int, 'recipients' => BusinessRecipients, 'no_activity_days' => int]; +``` diff --git a/docs/API_docs/constructors/businessIntro.md b/docs/API_docs/constructors/businessIntro.md new file mode 100644 index 0000000000..4bafc4148c --- /dev/null +++ b/docs/API_docs/constructors/businessIntro.md @@ -0,0 +1,29 @@ +--- +title: "businessIntro" +description: "businessIntro attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessIntro +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|title|[string](/API_docs/types/string.html) | Yes| +|description|[string](/API_docs/types/string.html) | Yes| +|sticker|[Document](/API_docs/types/Document.html) | Optional| + + + +### Type: [BusinessIntro](/API_docs/types/BusinessIntro.html) + + +### Example: + +``` +$businessIntro = ['_' => 'businessIntro', 'title' => 'string', 'description' => 'string', 'sticker' => Document]; +``` diff --git a/docs/API_docs/constructors/businessLocation.md b/docs/API_docs/constructors/businessLocation.md new file mode 100644 index 0000000000..7dbc3e21cc --- /dev/null +++ b/docs/API_docs/constructors/businessLocation.md @@ -0,0 +1,28 @@ +--- +title: "businessLocation" +description: "businessLocation attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|geo\_point|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional| +|address|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [BusinessLocation](/API_docs/types/BusinessLocation.html) + + +### Example: + +``` +$businessLocation = ['_' => 'businessLocation', 'geo_point' => GeoPoint, 'address' => 'string']; +``` diff --git a/docs/API_docs/constructors/businessRecipients.md b/docs/API_docs/constructors/businessRecipients.md new file mode 100644 index 0000000000..0e49ace105 --- /dev/null +++ b/docs/API_docs/constructors/businessRecipients.md @@ -0,0 +1,32 @@ +--- +title: "businessRecipients" +description: "businessRecipients attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessRecipients +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|existing\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|new\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|non\_contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|exclude\_selected|[Bool](/API_docs/types/Bool.html) | Optional| +|users|Array of [long](/API_docs/types/long.html) | Optional| + + + +### Type: [BusinessRecipients](/API_docs/types/BusinessRecipients.html) + + +### Example: + +``` +$businessRecipients = ['_' => 'businessRecipients', 'existing_chats' => Bool, 'new_chats' => Bool, 'contacts' => Bool, 'non_contacts' => Bool, 'exclude_selected' => Bool, 'users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/businessWeeklyOpen.md b/docs/API_docs/constructors/businessWeeklyOpen.md new file mode 100644 index 0000000000..f486e0f4fa --- /dev/null +++ b/docs/API_docs/constructors/businessWeeklyOpen.md @@ -0,0 +1,28 @@ +--- +title: "businessWeeklyOpen" +description: "businessWeeklyOpen attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessWeeklyOpen +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|start\_minute|[int](/API_docs/types/int.html) | Yes| +|end\_minute|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [BusinessWeeklyOpen](/API_docs/types/BusinessWeeklyOpen.html) + + +### Example: + +``` +$businessWeeklyOpen = ['_' => 'businessWeeklyOpen', 'start_minute' => int, 'end_minute' => int]; +``` diff --git a/docs/API_docs/constructors/businessWorkHours.md b/docs/API_docs/constructors/businessWorkHours.md new file mode 100644 index 0000000000..4e1c5abf40 --- /dev/null +++ b/docs/API_docs/constructors/businessWorkHours.md @@ -0,0 +1,29 @@ +--- +title: "businessWorkHours" +description: "businessWorkHours attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: businessWorkHours +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|open\_now|[Bool](/API_docs/types/Bool.html) | Optional| +|timezone\_id|[string](/API_docs/types/string.html) | Yes| +|weekly\_open|Array of [BusinessWeeklyOpen](/API_docs/types/BusinessWeeklyOpen.html) | Yes| + + + +### Type: [BusinessWorkHours](/API_docs/types/BusinessWorkHours.html) + + +### Example: + +``` +$businessWorkHours = ['_' => 'businessWorkHours', 'open_now' => Bool, 'timezone_id' => 'string', 'weekly_open' => [BusinessWeeklyOpen, BusinessWeeklyOpen]]; +``` diff --git a/docs/API_docs/constructors/cdnConfig.md b/docs/API_docs/constructors/cdnConfig.md new file mode 100644 index 0000000000..e500ac21e5 --- /dev/null +++ b/docs/API_docs/constructors/cdnConfig.md @@ -0,0 +1,29 @@ +--- +title: "cdnConfig" +description: "Configuration for CDN file downloads." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: cdnConfig +[Back to constructors index](/API_docs/constructors/index.html) + + + +Configuration for [CDN](https://core.telegram.org/cdn) file downloads. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|public\_keys|Array of [CdnPublicKey](/API_docs/types/CdnPublicKey.html) | Yes|Vector of public keys to use **only** during handshakes to [CDN](https://core.telegram.org/cdn) DCs.| + + + +### Type: [CdnConfig](/API_docs/types/CdnConfig.html) + + +### Example: + +``` +$cdnConfig = ['_' => 'cdnConfig', 'public_keys' => [CdnPublicKey, CdnPublicKey]]; +``` diff --git a/docs/API_docs/constructors/cdnPublicKey.md b/docs/API_docs/constructors/cdnPublicKey.md new file mode 100644 index 0000000000..45faad0a18 --- /dev/null +++ b/docs/API_docs/constructors/cdnPublicKey.md @@ -0,0 +1,30 @@ +--- +title: "cdnPublicKey" +description: "Public key to use only during handshakes to CDN DCs." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: cdnPublicKey +[Back to constructors index](/API_docs/constructors/index.html) + + + +Public key to use **only** during handshakes to [CDN](https://core.telegram.org/cdn) DCs. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dc\_id|[int](/API_docs/types/int.html) | Yes|[CDN DC](https://core.telegram.org/cdn) ID| +|public\_key|[string](/API_docs/types/string.html) | Yes|RSA public key| + + + +### Type: [CdnPublicKey](/API_docs/types/CdnPublicKey.html) + + +### Example: + +``` +$cdnPublicKey = ['_' => 'cdnPublicKey', 'dc_id' => int, 'public_key' => 'string']; +``` diff --git a/docs/API_docs/constructors/channel.md b/docs/API_docs/constructors/channel.md new file mode 100644 index 0000000000..54f4a9f02b --- /dev/null +++ b/docs/API_docs/constructors/channel.md @@ -0,0 +1,68 @@ +--- +title: "channel" +description: "Channel/supergroup info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channel +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel/supergroup info + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|creator|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user is the creator of this channel| +|left|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user has left or is not a member of this channel| +|broadcast|[Bool](/API_docs/types/Bool.html) | Optional|Is this a channel?| +|verified|[Bool](/API_docs/types/Bool.html) | Optional|Is this channel verified by telegram?| +|megagroup|[Bool](/API_docs/types/Bool.html) | Optional|Is this a supergroup?| +|restricted|[Bool](/API_docs/types/Bool.html) | Optional|Whether viewing/writing in this channel for a reason (see `restriction_reason`| +|signatures|[Bool](/API_docs/types/Bool.html) | Optional|Whether signatures are enabled (channels)| +|min|[Bool](/API_docs/types/Bool.html) | Optional|See [min](https://core.telegram.org/api/min)| +|scam|[Bool](/API_docs/types/Bool.html) | Optional|This channel/supergroup is probably a scam| +|has\_link|[Bool](/API_docs/types/Bool.html) | Optional|Whether this channel has a private join link| +|has\_geo|[Bool](/API_docs/types/Bool.html) | Optional|Whether this chanel has a geoposition| +|slowmode\_enabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether slow mode is enabled for groups to prevent flood in chat| +|call\_active|[Bool](/API_docs/types/Bool.html) | Optional|Whether a group call or livestream is currently active| +|call\_not\_empty|[Bool](/API_docs/types/Bool.html) | Optional|Whether there's anyone in the group call or livestream| +|fake|[Bool](/API_docs/types/Bool.html) | Optional|If set, this [supergroup/channel](https://core.telegram.org/api/channel) was reported by many users as a fake or scam: be careful when interacting with it.| +|gigagroup|[Bool](/API_docs/types/Bool.html) | Optional|Whether this [supergroup](https://core.telegram.org/api/channel) is a gigagroup| +|noforwards|[Bool](/API_docs/types/Bool.html) | Optional|Whether this channel or group is [protected](https://telegram.org/blog/protected-content-delete-by-date-and-more), thus does not allow forwarding messages from it| +|join\_to\_send|[Bool](/API_docs/types/Bool.html) | Optional|Whether a user needs to join the supergroup before they can send messages: can be false only for [discussion groups »](https://core.telegram.org/api/discussion), toggle using [channels.toggleJoinToSend](../methods/channels.toggleJoinToSend.html)| +|join\_request|[Bool](/API_docs/types/Bool.html) | Optional|Whether a user's join request will have to be [approved by administrators](https://core.telegram.org/api/invites#join-requests), toggle using [channels.toggleJoinToSend](../methods/channels.toggleJoinRequest.html)| +|forum|[Bool](/API_docs/types/Bool.html) | Optional|Whether this supergroup is a [forum](https://core.telegram.org/api/forum)| +|stories\_hidden|[Bool](/API_docs/types/Bool.html) | Optional| +|stories\_hidden\_min|[Bool](/API_docs/types/Bool.html) | Optional| +|stories\_unavailable|[Bool](/API_docs/types/Bool.html) | Optional| +|id|[long](/API_docs/types/long.html) | Yes|ID of the channel| +|access\_hash|[long](/API_docs/types/long.html) | Optional|Access hash| +|title|[string](/API_docs/types/string.html) | Yes|Title| +|username|[string](/API_docs/types/string.html) | Optional|Username| +|photo|[ChatPhoto](/API_docs/types/ChatPhoto.html) | Optional|Profile photo| +|date|[int](/API_docs/types/int.html) | Yes|Date when the user joined the supergroup/channel, or if the user isn't a member, its creation date| +|restriction\_reason|Array of [RestrictionReason](/API_docs/types/RestrictionReason.html) | Optional|Contains the reason why access to this channel must be restricted.| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|Admin rights of the user in this channel (see [rights](https://core.telegram.org/api/rights))| +|banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Optional|Banned rights of the user in this channel (see [rights](https://core.telegram.org/api/rights))| +|default\_banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Optional|Default chat rights (see [rights](https://core.telegram.org/api/rights))| +|participants\_count|[int](/API_docs/types/int.html) | Optional|Participant count| +|usernames|Array of [Username](/API_docs/types/Username.html) | Optional| +|stories\_max\_id|[int](/API_docs/types/int.html) | Optional| +|color|[PeerColor](/API_docs/types/PeerColor.html) | Optional| +|profile\_color|[PeerColor](/API_docs/types/PeerColor.html) | Optional| +|emoji\_status|[EmojiStatus](/API_docs/types/EmojiStatus.html) | Optional| +|level|[int](/API_docs/types/int.html) | Optional| + + + +### Type: [Chat](/API_docs/types/Chat.html) + + +### Example: + +``` +$channel = ['_' => 'channel', 'creator' => Bool, 'left' => Bool, 'broadcast' => Bool, 'verified' => Bool, 'megagroup' => Bool, 'restricted' => Bool, 'signatures' => Bool, 'min' => Bool, 'scam' => Bool, 'has_link' => Bool, 'has_geo' => Bool, 'slowmode_enabled' => Bool, 'call_active' => Bool, 'call_not_empty' => Bool, 'fake' => Bool, 'gigagroup' => Bool, 'noforwards' => Bool, 'join_to_send' => Bool, 'join_request' => Bool, 'forum' => Bool, 'stories_hidden' => Bool, 'stories_hidden_min' => Bool, 'stories_unavailable' => Bool, 'id' => long, 'access_hash' => long, 'title' => 'string', 'username' => 'string', 'photo' => ChatPhoto, 'date' => int, 'restriction_reason' => [RestrictionReason, RestrictionReason], 'admin_rights' => ChatAdminRights, 'banned_rights' => ChatBannedRights, 'default_banned_rights' => ChatBannedRights, 'participants_count' => int, 'usernames' => [Username, Username], 'stories_max_id' => int, 'color' => PeerColor, 'profile_color' => PeerColor, 'emoji_status' => EmojiStatus, 'level' => int]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEvent.md b/docs/API_docs/constructors/channelAdminLogEvent.md new file mode 100644 index 0000000000..bf150b488f --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEvent.md @@ -0,0 +1,32 @@ +--- +title: "channelAdminLogEvent" +description: "Admin log event" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEvent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Admin log event + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Event ID| +|date|[int](/API_docs/types/int.html) | Yes|Date| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|action|[ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) | Yes|Action| + + + +### Type: [ChannelAdminLogEvent](/API_docs/types/ChannelAdminLogEvent.html) + + +### Example: + +``` +$channelAdminLogEvent = ['_' => 'channelAdminLogEvent', 'id' => long, 'date' => int, 'user_id' => long, 'action' => ChannelAdminLogEventAction]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeAbout.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeAbout.md new file mode 100644 index 0000000000..8a555fccc8 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeAbout.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeAbout" +description: "The description was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeAbout +[Back to constructors index](/API_docs/constructors/index.html) + + + +The description was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[string](/API_docs/types/string.html) | Yes|Previous description| +|new\_value|[string](/API_docs/types/string.html) | Yes|New description| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeAbout = ['_' => 'channelAdminLogEventActionChangeAbout', 'prev_value' => 'string', 'new_value' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeAvailableReactions.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeAvailableReactions.md new file mode 100644 index 0000000000..ed18961078 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeAvailableReactions.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeAvailableReactions" +description: "The set of allowed message reactions » for this channel has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeAvailableReactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +The set of allowed [message reactions »](https://core.telegram.org/api/reactions) for this channel has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[ChatReactions](/API_docs/types/ChatReactions.html) | Yes|Previously allowed reaction emojis| +|new\_value|[ChatReactions](/API_docs/types/ChatReactions.html) | Yes|New allowed reaction emojis| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeAvailableReactions = ['_' => 'channelAdminLogEventActionChangeAvailableReactions', 'prev_value' => ChatReactions, 'new_value' => ChatReactions]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeEmojiStatus.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeEmojiStatus.md new file mode 100644 index 0000000000..7bf43342d0 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeEmojiStatus.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeEmojiStatus" +description: "The emoji status was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeEmojiStatus +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [emoji status](https://core.telegram.org/api/emoji-status) was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[EmojiStatus](/API_docs/types/EmojiStatus.html) | Optional|Previous emoji status| +|new\_value|[EmojiStatus](/API_docs/types/EmojiStatus.html) | Optional|New emoji status| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeEmojiStatus = ['_' => 'channelAdminLogEventActionChangeEmojiStatus', 'prev_value' => EmojiStatus, 'new_value' => EmojiStatus]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeEmojiStickerSet.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeEmojiStickerSet.md new file mode 100644 index 0000000000..145a4186e4 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeEmojiStickerSet.md @@ -0,0 +1,28 @@ +--- +title: "channelAdminLogEventActionChangeEmojiStickerSet" +description: "channelAdminLogEventActionChangeEmojiStickerSet attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeEmojiStickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|prev\_stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional| +|new\_stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeEmojiStickerSet = ['_' => 'channelAdminLogEventActionChangeEmojiStickerSet', 'prev_stickerset' => InputStickerSet, 'new_stickerset' => InputStickerSet]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeHistoryTTL.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeHistoryTTL.md new file mode 100644 index 0000000000..db342eb913 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeHistoryTTL.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeHistoryTTL" +description: "The Time-To-Live of messages in this chat was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeHistoryTTL +[Back to constructors index](/API_docs/constructors/index.html) + + + +The Time-To-Live of messages in this chat was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[int](/API_docs/types/int.html) | Yes|Previous value| +|new\_value|[int](/API_docs/types/int.html) | Yes|New value| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeHistoryTTL = ['_' => 'channelAdminLogEventActionChangeHistoryTTL', 'prev_value' => int, 'new_value' => int]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeLinkedChat.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeLinkedChat.md new file mode 100644 index 0000000000..223463d354 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeLinkedChat.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeLinkedChat" +description: "The linked chat was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeLinkedChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +The linked chat was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[long](/API_docs/types/long.html) | Yes|Previous linked chat| +|new\_value|[long](/API_docs/types/long.html) | Yes|New linked chat| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeLinkedChat = ['_' => 'channelAdminLogEventActionChangeLinkedChat', 'prev_value' => long, 'new_value' => long]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeLocation.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeLocation.md new file mode 100644 index 0000000000..68a3819ae8 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeLocation.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeLocation" +description: "The geogroup location was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +The geogroup location was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[ChannelLocation](/API_docs/types/ChannelLocation.html) | Optional|Previous location| +|new\_value|[ChannelLocation](/API_docs/types/ChannelLocation.html) | Optional|New location| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeLocation = ['_' => 'channelAdminLogEventActionChangeLocation', 'prev_value' => ChannelLocation, 'new_value' => ChannelLocation]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangePeerColor.md b/docs/API_docs/constructors/channelAdminLogEventActionChangePeerColor.md new file mode 100644 index 0000000000..01696b39e7 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangePeerColor.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangePeerColor" +description: "The message accent color was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangePeerColor +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [message accent color](https://core.telegram.org/api/colors) was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[PeerColor](/API_docs/types/PeerColor.html) | Yes|Previous accent palette| +|new\_value|[PeerColor](/API_docs/types/PeerColor.html) | Yes|New accent palette| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangePeerColor = ['_' => 'channelAdminLogEventActionChangePeerColor', 'prev_value' => PeerColor, 'new_value' => PeerColor]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangePhoto.md b/docs/API_docs/constructors/channelAdminLogEventActionChangePhoto.md new file mode 100644 index 0000000000..f6b7f0b07e --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangePhoto.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangePhoto" +description: "The channel/supergroup's picture was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangePhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +The channel/supergroup's picture was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Previous picture| +|new\_photo|[Photo](/API_docs/types/Photo.html) | Optional|New picture| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangePhoto = ['_' => 'channelAdminLogEventActionChangePhoto', 'prev_photo' => Photo, 'new_photo' => Photo]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeProfilePeerColor.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeProfilePeerColor.md new file mode 100644 index 0000000000..1e77a6fb6e --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeProfilePeerColor.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeProfilePeerColor" +description: "The profile accent color was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeProfilePeerColor +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [profile accent color](https://core.telegram.org/api/colors) was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[PeerColor](/API_docs/types/PeerColor.html) | Yes|Previous accent palette| +|new\_value|[PeerColor](/API_docs/types/PeerColor.html) | Yes|New accent palette| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeProfilePeerColor = ['_' => 'channelAdminLogEventActionChangeProfilePeerColor', 'prev_value' => PeerColor, 'new_value' => PeerColor]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeStickerSet.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeStickerSet.md new file mode 100644 index 0000000000..b9415923a4 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeStickerSet.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeStickerSet" +description: "The supergroup's stickerset was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeStickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +The supergroup's stickerset was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|Previous stickerset| +|new\_stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|New stickerset| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeStickerSet = ['_' => 'channelAdminLogEventActionChangeStickerSet', 'prev_stickerset' => InputStickerSet, 'new_stickerset' => InputStickerSet]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeTitle.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeTitle.md new file mode 100644 index 0000000000..f8a2816203 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeTitle.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeTitle" +description: "Channel/supergroup title was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeTitle +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel/supergroup title was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[string](/API_docs/types/string.html) | Yes|Previous title| +|new\_value|[string](/API_docs/types/string.html) | Yes|New title| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeTitle = ['_' => 'channelAdminLogEventActionChangeTitle', 'prev_value' => 'string', 'new_value' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeUsername.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeUsername.md new file mode 100644 index 0000000000..3ed3d3c8ec --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeUsername.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeUsername" +description: "Channel/supergroup username was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeUsername +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel/supergroup username was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[string](/API_docs/types/string.html) | Yes|Old username| +|new\_value|[string](/API_docs/types/string.html) | Yes|New username| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeUsername = ['_' => 'channelAdminLogEventActionChangeUsername', 'prev_value' => 'string', 'new_value' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeUsernames.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeUsernames.md new file mode 100644 index 0000000000..f3b39651be --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeUsernames.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeUsernames" +description: "The list of usernames associated with the channel was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeUsernames +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of usernames associated with the channel was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|Array of [string](/API_docs/types/string.html) | Yes|Previous set of usernames| +|new\_value|Array of [string](/API_docs/types/string.html) | Yes|New set of usernames| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeUsernames = ['_' => 'channelAdminLogEventActionChangeUsernames', 'prev_value' => ['string', 'string'], 'new_value' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionChangeWallpaper.md b/docs/API_docs/constructors/channelAdminLogEventActionChangeWallpaper.md new file mode 100644 index 0000000000..9663c599db --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionChangeWallpaper.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionChangeWallpaper" +description: "The wallpaper was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionChangeWallpaper +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [wallpaper](https://core.telegram.org/api/wallpapers) was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[WallPaper](/API_docs/types/WallPaper.html) | Yes|Previous wallpaper| +|new\_value|[WallPaper](/API_docs/types/WallPaper.html) | Yes|New wallpaper| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionChangeWallpaper = ['_' => 'channelAdminLogEventActionChangeWallpaper', 'prev_value' => WallPaper, 'new_value' => WallPaper]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionCreateTopic.md b/docs/API_docs/constructors/channelAdminLogEventActionCreateTopic.md new file mode 100644 index 0000000000..54faaf2f55 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionCreateTopic.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionCreateTopic" +description: "A forum topic was created" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionCreateTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|topic|[ForumTopic](/API_docs/types/ForumTopic.html) | Yes|The [forum topic](https://core.telegram.org/api/forum#forum-topics) that was created| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionCreateTopic = ['_' => 'channelAdminLogEventActionCreateTopic', 'topic' => ForumTopic]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionDefaultBannedRights.md b/docs/API_docs/constructors/channelAdminLogEventActionDefaultBannedRights.md new file mode 100644 index 0000000000..b1e7e4a572 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionDefaultBannedRights.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionDefaultBannedRights" +description: "The default banned rights were modified" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionDefaultBannedRights +[Back to constructors index](/API_docs/constructors/index.html) + + + +The default banned rights were modified + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Yes|Previous global [banned rights](https://core.telegram.org/api/rights)| +|new\_banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Yes|New global [banned rights](https://core.telegram.org/api/rights).| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionDefaultBannedRights = ['_' => 'channelAdminLogEventActionDefaultBannedRights', 'prev_banned_rights' => ChatBannedRights, 'new_banned_rights' => ChatBannedRights]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionDeleteMessage.md b/docs/API_docs/constructors/channelAdminLogEventActionDeleteMessage.md new file mode 100644 index 0000000000..0c31a06577 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionDeleteMessage.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionDeleteMessage" +description: "A message was deleted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionDeleteMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was deleted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The message that was deleted| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionDeleteMessage = ['_' => 'channelAdminLogEventActionDeleteMessage', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionDeleteTopic.md b/docs/API_docs/constructors/channelAdminLogEventActionDeleteTopic.md new file mode 100644 index 0000000000..2bd2e6f01a --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionDeleteTopic.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionDeleteTopic" +description: "A forum topic was deleted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionDeleteTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [forum topic](https://core.telegram.org/api/forum#forum-topics) was deleted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|topic|[ForumTopic](/API_docs/types/ForumTopic.html) | Yes|The [forum topic](https://core.telegram.org/api/forum#forum-topics) that was deleted| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionDeleteTopic = ['_' => 'channelAdminLogEventActionDeleteTopic', 'topic' => ForumTopic]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionDiscardGroupCall.md b/docs/API_docs/constructors/channelAdminLogEventActionDiscardGroupCall.md new file mode 100644 index 0000000000..120a715e17 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionDiscardGroupCall.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionDiscardGroupCall" +description: "A group call was terminated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionDiscardGroupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +A group call was terminated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|The group call that was terminated| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionDiscardGroupCall = ['_' => 'channelAdminLogEventActionDiscardGroupCall', 'call' => InputGroupCall]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionEditMessage.md b/docs/API_docs/constructors/channelAdminLogEventActionEditMessage.md new file mode 100644 index 0000000000..6c18cf4384 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionEditMessage.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionEditMessage" +description: "A message was edited" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionEditMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was edited + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_message|[Message](/API_docs/types/Message.html) | Optional|Old message| +|new\_message|[Message](/API_docs/types/Message.html) | Optional|New message| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionEditMessage = ['_' => 'channelAdminLogEventActionEditMessage', 'prev_message' => Message, 'new_message' => Message]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionEditTopic.md b/docs/API_docs/constructors/channelAdminLogEventActionEditTopic.md new file mode 100644 index 0000000000..8894437284 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionEditTopic.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionEditTopic" +description: "A forum topic was edited" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionEditTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [forum topic](https://core.telegram.org/api/forum#forum-topics) was edited + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_topic|[ForumTopic](/API_docs/types/ForumTopic.html) | Yes|Previous topic information| +|new\_topic|[ForumTopic](/API_docs/types/ForumTopic.html) | Yes|New topic information| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionEditTopic = ['_' => 'channelAdminLogEventActionEditTopic', 'prev_topic' => ForumTopic, 'new_topic' => ForumTopic]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteDelete.md b/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteDelete.md new file mode 100644 index 0000000000..41afb0a65d --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteDelete.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionExportedInviteDelete" +description: "A chat invite was deleted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionExportedInviteDelete +[Back to constructors index](/API_docs/constructors/index.html) + + + +A chat invite was deleted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|The deleted chat invite| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionExportedInviteDelete = ['_' => 'channelAdminLogEventActionExportedInviteDelete', 'invite' => ExportedChatInvite]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteEdit.md b/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteEdit.md new file mode 100644 index 0000000000..150077220b --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteEdit.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionExportedInviteEdit" +description: "A chat invite was edited" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionExportedInviteEdit +[Back to constructors index](/API_docs/constructors/index.html) + + + +A chat invite was edited + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|Previous chat invite information| +|new\_invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|New chat invite information| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionExportedInviteEdit = ['_' => 'channelAdminLogEventActionExportedInviteEdit', 'prev_invite' => ExportedChatInvite, 'new_invite' => ExportedChatInvite]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteRevoke.md b/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteRevoke.md new file mode 100644 index 0000000000..39ce179393 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionExportedInviteRevoke.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionExportedInviteRevoke" +description: "A specific invite link was revoked" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionExportedInviteRevoke +[Back to constructors index](/API_docs/constructors/index.html) + + + +A specific invite link was revoked + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|The invite link that was revoked| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionExportedInviteRevoke = ['_' => 'channelAdminLogEventActionExportedInviteRevoke', 'invite' => ExportedChatInvite]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantInvite.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantInvite.md new file mode 100644 index 0000000000..40c7b5ced5 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantInvite.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionParticipantInvite" +description: "A user was invited to the group" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user was invited to the group + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|The user that was invited| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantInvite = ['_' => 'channelAdminLogEventActionParticipantInvite', 'participant' => ChannelParticipant]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoin.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoin.md new file mode 100644 index 0000000000..603a5b1ea2 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoin.md @@ -0,0 +1,24 @@ +--- +title: "channelAdminLogEventActionParticipantJoin" +description: "A user has joined the group (in the case of big groups, info of the user that has joined isn't shown)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantJoin +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user has joined the group (in the case of big groups, info of the user that has joined isn't shown) + + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantJoin = ['_' => 'channelAdminLogEventActionParticipantJoin']; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoinByInvite.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoinByInvite.md new file mode 100644 index 0000000000..0746ab6148 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoinByInvite.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionParticipantJoinByInvite" +description: "A user joined the supergroup/channel using a specific invite link" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantJoinByInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user joined the [supergroup/channel](https://core.telegram.org/api/channel) using a specific invite link + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|via\_chatlist|[Bool](/API_docs/types/Bool.html) | Optional|The participant joined by importing a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links).| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|The invite link used to join the [supergroup/channel](https://core.telegram.org/api/channel)| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantJoinByInvite = ['_' => 'channelAdminLogEventActionParticipantJoinByInvite', 'via_chatlist' => Bool, 'invite' => ExportedChatInvite]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoinByRequest.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoinByRequest.md new file mode 100644 index 0000000000..082eb16be8 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantJoinByRequest.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionParticipantJoinByRequest" +description: "A new member was accepted to the chat by an admin" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantJoinByRequest +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new member was accepted to the chat by an admin + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|The invite link that was used to join the chat| +|approved\_by|[long](/API_docs/types/long.html) | Yes|ID of the admin that approved the invite| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantJoinByRequest = ['_' => 'channelAdminLogEventActionParticipantJoinByRequest', 'invite' => ExportedChatInvite, 'approved_by' => long]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantLeave.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantLeave.md new file mode 100644 index 0000000000..a88532845f --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantLeave.md @@ -0,0 +1,24 @@ +--- +title: "channelAdminLogEventActionParticipantLeave" +description: "A user left the channel/supergroup (in the case of big groups, info of the user that has joined isn't shown)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantLeave +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user left the channel/supergroup (in the case of big groups, info of the user that has joined isn't shown) + + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantLeave = ['_' => 'channelAdminLogEventActionParticipantLeave']; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantMute.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantMute.md new file mode 100644 index 0000000000..052c2359e4 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantMute.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionParticipantMute" +description: "A group call participant was muted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantMute +[Back to constructors index](/API_docs/constructors/index.html) + + + +A group call participant was muted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|participant|[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) | Yes|The participant that was muted| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantMute = ['_' => 'channelAdminLogEventActionParticipantMute', 'participant' => GroupCallParticipant]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantToggleAdmin.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantToggleAdmin.md new file mode 100644 index 0000000000..57a62851cb --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantToggleAdmin.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionParticipantToggleAdmin" +description: "The admin rights of a user were changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantToggleAdmin +[Back to constructors index](/API_docs/constructors/index.html) + + + +The admin [rights](https://core.telegram.org/api/rights) of a user were changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|Previous admin rights| +|new\_participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|New admin rights| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantToggleAdmin = ['_' => 'channelAdminLogEventActionParticipantToggleAdmin', 'prev_participant' => ChannelParticipant, 'new_participant' => ChannelParticipant]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantToggleBan.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantToggleBan.md new file mode 100644 index 0000000000..2900e7e74d --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantToggleBan.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionParticipantToggleBan" +description: "The banned rights of a user were changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantToggleBan +[Back to constructors index](/API_docs/constructors/index.html) + + + +The banned [rights](https://core.telegram.org/api/rights) of a user were changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|Old banned rights of user| +|new\_participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|New banned rights of user| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantToggleBan = ['_' => 'channelAdminLogEventActionParticipantToggleBan', 'prev_participant' => ChannelParticipant, 'new_participant' => ChannelParticipant]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantUnmute.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantUnmute.md new file mode 100644 index 0000000000..a14d3ff553 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantUnmute.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionParticipantUnmute" +description: "A group call participant was unmuted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantUnmute +[Back to constructors index](/API_docs/constructors/index.html) + + + +A group call participant was unmuted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|participant|[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) | Yes|The participant that was unmuted| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantUnmute = ['_' => 'channelAdminLogEventActionParticipantUnmute', 'participant' => GroupCallParticipant]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionParticipantVolume.md b/docs/API_docs/constructors/channelAdminLogEventActionParticipantVolume.md new file mode 100644 index 0000000000..48a7a8224b --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionParticipantVolume.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionParticipantVolume" +description: "channelAdminLogEvent.user_id has set the volume of participant.peer to participant.volume" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionParticipantVolume +[Back to constructors index](/API_docs/constructors/index.html) + + + +channelAdminLogEvent.user\_id has set the volume of participant.peer to participant.volume + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|participant|[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) | Yes|The participant whose volume was changed| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionParticipantVolume = ['_' => 'channelAdminLogEventActionParticipantVolume', 'participant' => GroupCallParticipant]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionPinTopic.md b/docs/API_docs/constructors/channelAdminLogEventActionPinTopic.md new file mode 100644 index 0000000000..2373f2a832 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionPinTopic.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionPinTopic" +description: "A forum topic was pinned or unpinned" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionPinTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [forum topic](https://core.telegram.org/api/forum#forum-topics) was pinned or unpinned + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_topic|[ForumTopic](/API_docs/types/ForumTopic.html) | Optional|Previous topic information| +|new\_topic|[ForumTopic](/API_docs/types/ForumTopic.html) | Optional|New topic information| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionPinTopic = ['_' => 'channelAdminLogEventActionPinTopic', 'prev_topic' => ForumTopic, 'new_topic' => ForumTopic]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionSendMessage.md b/docs/API_docs/constructors/channelAdminLogEventActionSendMessage.md new file mode 100644 index 0000000000..3020d81f2e --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionSendMessage.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionSendMessage" +description: "A message was posted in a channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionSendMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was posted in a channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The message that was sent| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionSendMessage = ['_' => 'channelAdminLogEventActionSendMessage', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionStartGroupCall.md b/docs/API_docs/constructors/channelAdminLogEventActionStartGroupCall.md new file mode 100644 index 0000000000..d42874434e --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionStartGroupCall.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionStartGroupCall" +description: "A group call was started" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionStartGroupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +A group call was started + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|Group call| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionStartGroupCall = ['_' => 'channelAdminLogEventActionStartGroupCall', 'call' => InputGroupCall]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionStopPoll.md b/docs/API_docs/constructors/channelAdminLogEventActionStopPoll.md new file mode 100644 index 0000000000..f1e674f2bc --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionStopPoll.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionStopPoll" +description: "A poll was stopped" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionStopPoll +[Back to constructors index](/API_docs/constructors/index.html) + + + +A poll was stopped + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The poll that was stopped| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionStopPoll = ['_' => 'channelAdminLogEventActionStopPoll', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleAntiSpam.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleAntiSpam.md new file mode 100644 index 0000000000..c247d31cd9 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleAntiSpam.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionToggleAntiSpam" +description: "Native antispam functionality was enabled or disabled." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleAntiSpam +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Native antispam](https://core.telegram.org/api/antispam) functionality was enabled or disabled. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_value|[Bool](/API_docs/types/Bool.html) | Yes|Whether antispam functionality was enabled or disabled.| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleAntiSpam = ['_' => 'channelAdminLogEventActionToggleAntiSpam', 'new_value' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleForum.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleForum.md new file mode 100644 index 0000000000..43c3d2ef5f --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleForum.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionToggleForum" +description: "Forum functionality was enabled or disabled." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleForum +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Forum](https://core.telegram.org/api/forum) functionality was enabled or disabled. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_value|[Bool](/API_docs/types/Bool.html) | Yes|Whether [forum](https://core.telegram.org/api/forum) functionality was enabled or disabled.| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleForum = ['_' => 'channelAdminLogEventActionToggleForum', 'new_value' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleGroupCallSetting.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleGroupCallSetting.md new file mode 100644 index 0000000000..b13007a058 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleGroupCallSetting.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionToggleGroupCallSetting" +description: "Group call settings were changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleGroupCallSetting +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group call settings were changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|join\_muted|[Bool](/API_docs/types/Bool.html) | Yes|Whether all users are muted by default upon joining| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleGroupCallSetting = ['_' => 'channelAdminLogEventActionToggleGroupCallSetting', 'join_muted' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleInvites.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleInvites.md new file mode 100644 index 0000000000..26db2ac7de --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleInvites.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionToggleInvites" +description: "Invites were enabled/disabled" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleInvites +[Back to constructors index](/API_docs/constructors/index.html) + + + +Invites were enabled/disabled + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_value|[Bool](/API_docs/types/Bool.html) | Yes|New value| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleInvites = ['_' => 'channelAdminLogEventActionToggleInvites', 'new_value' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleNoForwards.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleNoForwards.md new file mode 100644 index 0000000000..96819a7575 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleNoForwards.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionToggleNoForwards" +description: "Forwards were enabled or disabled" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleNoForwards +[Back to constructors index](/API_docs/constructors/index.html) + + + +Forwards were enabled or disabled + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_value|[Bool](/API_docs/types/Bool.html) | Yes|Old value| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleNoForwards = ['_' => 'channelAdminLogEventActionToggleNoForwards', 'new_value' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionTogglePreHistoryHidden.md b/docs/API_docs/constructors/channelAdminLogEventActionTogglePreHistoryHidden.md new file mode 100644 index 0000000000..4c7e88f9e0 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionTogglePreHistoryHidden.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionTogglePreHistoryHidden" +description: "The hidden prehistory setting was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionTogglePreHistoryHidden +[Back to constructors index](/API_docs/constructors/index.html) + + + +The hidden prehistory setting was [changed](../methods/channels.togglePreHistoryHidden.html) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_value|[Bool](/API_docs/types/Bool.html) | Yes|New value| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionTogglePreHistoryHidden = ['_' => 'channelAdminLogEventActionTogglePreHistoryHidden', 'new_value' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleSignatures.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleSignatures.md new file mode 100644 index 0000000000..4caac5d2a3 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleSignatures.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionToggleSignatures" +description: "Channel signatures were enabled/disabled" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleSignatures +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel signatures were enabled/disabled + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_value|[Bool](/API_docs/types/Bool.html) | Yes|New value| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleSignatures = ['_' => 'channelAdminLogEventActionToggleSignatures', 'new_value' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionToggleSlowMode.md b/docs/API_docs/constructors/channelAdminLogEventActionToggleSlowMode.md new file mode 100644 index 0000000000..7a7e8fb20d --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionToggleSlowMode.md @@ -0,0 +1,30 @@ +--- +title: "channelAdminLogEventActionToggleSlowMode" +description: "Slow mode setting for supergroups was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionToggleSlowMode +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Slow mode setting for supergroups was changed](../methods/channels.toggleSlowMode.html) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|prev\_value|[int](/API_docs/types/int.html) | Yes|Previous slow mode value| +|new\_value|[int](/API_docs/types/int.html) | Yes|New slow mode value| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionToggleSlowMode = ['_' => 'channelAdminLogEventActionToggleSlowMode', 'prev_value' => int, 'new_value' => int]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventActionUpdatePinned.md b/docs/API_docs/constructors/channelAdminLogEventActionUpdatePinned.md new file mode 100644 index 0000000000..b743414f16 --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventActionUpdatePinned.md @@ -0,0 +1,29 @@ +--- +title: "channelAdminLogEventActionUpdatePinned" +description: "A message was pinned" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventActionUpdatePinned +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was pinned + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The message that was pinned| + + + +### Type: [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + + +### Example: + +``` +$channelAdminLogEventActionUpdatePinned = ['_' => 'channelAdminLogEventActionUpdatePinned', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/channelAdminLogEventsFilter.md b/docs/API_docs/constructors/channelAdminLogEventsFilter.md new file mode 100644 index 0000000000..09c671551c --- /dev/null +++ b/docs/API_docs/constructors/channelAdminLogEventsFilter.md @@ -0,0 +1,46 @@ +--- +title: "channelAdminLogEventsFilter" +description: "Filter only certain admin log events" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelAdminLogEventsFilter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter only certain admin log events + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|join|[Bool](/API_docs/types/Bool.html) | Optional|[Join events](../constructors/channelAdminLogEventActionParticipantJoin.html), including [joins using invite links](../constructors/channelAdminLogEventActionParticipantJoinByInvite.html) and [join requests](../constructors/channelAdminLogEventActionParticipantJoinByRequest.html).| +|leave|[Bool](/API_docs/types/Bool.html) | Optional|[Leave events](../constructors/channelAdminLogEventActionParticipantLeave.html)| +|invite|[Bool](/API_docs/types/Bool.html) | Optional|[Invite events](../constructors/channelAdminLogEventActionParticipantInvite.html)| +|ban|[Bool](/API_docs/types/Bool.html) | Optional|[Ban events](../constructors/channelAdminLogEventActionParticipantToggleBan.html)| +|unban|[Bool](/API_docs/types/Bool.html) | Optional|[Unban events](../constructors/channelAdminLogEventActionParticipantToggleBan.html)| +|kick|[Bool](/API_docs/types/Bool.html) | Optional|[Kick events](../constructors/channelAdminLogEventActionParticipantToggleBan.html)| +|unkick|[Bool](/API_docs/types/Bool.html) | Optional|[Unkick events](../constructors/channelAdminLogEventActionParticipantToggleBan.html)| +|promote|[Bool](/API_docs/types/Bool.html) | Optional|[Admin promotion events](../constructors/channelAdminLogEventActionParticipantToggleAdmin.html)| +|demote|[Bool](/API_docs/types/Bool.html) | Optional|[Admin demotion events](../constructors/channelAdminLogEventActionParticipantToggleAdmin.html)| +|info|[Bool](/API_docs/types/Bool.html) | Optional|Info change events (when [about](../constructors/channelAdminLogEventActionChangeAbout.html), [linked chat](../constructors/channelAdminLogEventActionChangeLinkedChat.html), [location](../constructors/channelAdminLogEventActionChangeLocation.html), [photo](../constructors/channelAdminLogEventActionChangePhoto.html), [stickerset](../constructors/channelAdminLogEventActionChangeStickerSet.html), [title](../constructors/channelAdminLogEventActionChangeTitle.html) or [username](../constructors/channelAdminLogEventActionChangeUsername.html), [slowmode](../constructors/channelAdminLogEventActionToggleSlowMode.html), [history TTL](../constructors/channelAdminLogEventActionChangeHistoryTTL.html) settings of a channel gets modified)| +|settings|[Bool](/API_docs/types/Bool.html) | Optional|Settings change events ([invites](../constructors/channelAdminLogEventActionToggleInvites.html), [hidden prehistory](../constructors/channelAdminLogEventActionTogglePreHistoryHidden.html), [signatures](../constructors/channelAdminLogEventActionToggleSignatures.html), [default banned rights](../constructors/channelAdminLogEventActionDefaultBannedRights.html), [forum toggle events](../constructors/channelAdminLogEventActionToggleForum.html))| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|[Message pin events](../constructors/channelAdminLogEventActionUpdatePinned.html)| +|edit|[Bool](/API_docs/types/Bool.html) | Optional|[Message edit events](../constructors/channelAdminLogEventActionEditMessage.html)| +|delete|[Bool](/API_docs/types/Bool.html) | Optional|[Message deletion events](../constructors/channelAdminLogEventActionDeleteMessage.html)| +|group\_call|[Bool](/API_docs/types/Bool.html) | Optional|Group call events| +|invites|[Bool](/API_docs/types/Bool.html) | Optional|Invite events| +|send|[Bool](/API_docs/types/Bool.html) | Optional|A message was posted in a channel| +|forums|[Bool](/API_docs/types/Bool.html) | Optional|[Forum](https://core.telegram.org/api/forum)-related events| + + + +### Type: [ChannelAdminLogEventsFilter](/API_docs/types/ChannelAdminLogEventsFilter.html) + + +### Example: + +``` +$channelAdminLogEventsFilter = ['_' => 'channelAdminLogEventsFilter', 'join' => Bool, 'leave' => Bool, 'invite' => Bool, 'ban' => Bool, 'unban' => Bool, 'kick' => Bool, 'unkick' => Bool, 'promote' => Bool, 'demote' => Bool, 'info' => Bool, 'settings' => Bool, 'pinned' => Bool, 'edit' => Bool, 'delete' => Bool, 'group_call' => Bool, 'invites' => Bool, 'send' => Bool, 'forums' => Bool]; +``` diff --git a/docs/API_docs/constructors/channelForbidden.md b/docs/API_docs/constructors/channelForbidden.md new file mode 100644 index 0000000000..884df81510 --- /dev/null +++ b/docs/API_docs/constructors/channelForbidden.md @@ -0,0 +1,34 @@ +--- +title: "channelForbidden" +description: "Indicates a channel/supergroup we can't access because we were banned, or for some other reason." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelForbidden +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a channel/supergroup we can't access because we were banned, or for some other reason. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|broadcast|[Bool](/API_docs/types/Bool.html) | Optional|Is this a channel| +|megagroup|[Bool](/API_docs/types/Bool.html) | Optional|Is this a supergroup| +|id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|title|[string](/API_docs/types/string.html) | Yes|Title| +|until\_date|[int](/API_docs/types/int.html) | Optional|The ban is valid until the specified date| + + + +### Type: [Chat](/API_docs/types/Chat.html) + + +### Example: + +``` +$channelForbidden = ['_' => 'channelForbidden', 'broadcast' => Bool, 'megagroup' => Bool, 'id' => long, 'access_hash' => long, 'title' => 'string', 'until_date' => int]; +``` diff --git a/docs/API_docs/constructors/channelFull.md b/docs/API_docs/constructors/channelFull.md new file mode 100644 index 0000000000..76e36e1a4e --- /dev/null +++ b/docs/API_docs/constructors/channelFull.md @@ -0,0 +1,85 @@ +--- +title: "channelFull" +description: "Full info about a channel, supergroup or gigagroup." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelFull +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full info about a [channel](https://core.telegram.org/api/channel#channels), [supergroup](https://core.telegram.org/api/channel#supergroups) or [gigagroup](https://core.telegram.org/api/channel#gigagroups). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|can\_view\_participants|[Bool](/API_docs/types/Bool.html) | Optional|Can we view the participant list?| +|can\_set\_username|[Bool](/API_docs/types/Bool.html) | Optional|Can we set the channel's username?| +|can\_set\_stickers|[Bool](/API_docs/types/Bool.html) | Optional|Can we [associate](../methods/channels.setStickers.html) a stickerpack to the supergroup?| +|hidden\_prehistory|[Bool](/API_docs/types/Bool.html) | Optional|Is the history before we joined hidden to us?| +|can\_set\_location|[Bool](/API_docs/types/Bool.html) | Optional|Can we set the geolocation of this group (for geogroups)| +|has\_scheduled|[Bool](/API_docs/types/Bool.html) | Optional|Whether scheduled messages are available| +|can\_view\_stats|[Bool](/API_docs/types/Bool.html) | Optional|Can the user view [channel/supergroup statistics](https://core.telegram.org/api/stats)| +|blocked|[Bool](/API_docs/types/Bool.html) | Optional|Whether any anonymous admin of this supergroup was blocked: if set, you won't receive messages from anonymous group admins in [discussion replies via @replies](https://core.telegram.org/api/discussion)| +|can\_delete\_channel|[Bool](/API_docs/types/Bool.html) | Optional| +|antispam|[Bool](/API_docs/types/Bool.html) | Optional| +|participants\_hidden|[Bool](/API_docs/types/Bool.html) | Optional| +|translations\_disabled|[Bool](/API_docs/types/Bool.html) | Optional| +|stories\_pinned\_available|[Bool](/API_docs/types/Bool.html) | Optional| +|view\_forum\_as\_messages|[Bool](/API_docs/types/Bool.html) | Optional| +|restricted\_sponsored|[Bool](/API_docs/types/Bool.html) | Optional| +|can\_view\_revenue|[Bool](/API_docs/types/Bool.html) | Optional| +|id|[long](/API_docs/types/long.html) | Yes|ID of the channel| +|about|[string](/API_docs/types/string.html) | Yes|Info about the channel| +|participants\_count|[int](/API_docs/types/int.html) | Optional|Number of participants of the channel| +|admins\_count|[int](/API_docs/types/int.html) | Optional|Number of channel admins| +|kicked\_count|[int](/API_docs/types/int.html) | Optional|Number of users [kicked](https://core.telegram.org/api/rights) from the channel| +|banned\_count|[int](/API_docs/types/int.html) | Optional|Number of users [banned](https://core.telegram.org/api/rights) from the channel| +|online\_count|[int](/API_docs/types/int.html) | Optional|Number of users currently online| +|read\_inbox\_max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all incoming messages are read.| +|read\_outbox\_max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all outgoing messages are read.| +|unread\_count|[int](/API_docs/types/int.html) | Yes|Count of unread messages| +|chat\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Channel picture| +|notify\_settings|[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) | Yes|Notification settings| +|exported\_invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Optional|Invite link| +|bot\_info|Array of [BotInfo](/API_docs/types/BotInfo.html) | Yes|Info about bots in the channel/supergroup| +|migrated\_from\_chat\_id|[long](/API_docs/types/long.html) | Optional|The chat ID from which this group was [migrated](https://core.telegram.org/api/channel)| +|migrated\_from\_max\_id|[int](/API_docs/types/int.html) | Optional|The message ID in the original chat at which this group was [migrated](https://core.telegram.org/api/channel)| +|pinned\_msg\_id|[int](/API_docs/types/int.html) | Optional|Message ID of the last [pinned message](https://core.telegram.org/api/pin)| +|stickerset|[StickerSet](/API_docs/types/StickerSet.html) | Optional|Associated stickerset| +|available\_min\_id|[int](/API_docs/types/int.html) | Optional|Identifier of a maximum unavailable message in a channel due to hidden history.| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|linked\_chat\_id|[long](/API_docs/types/long.html) | Optional|ID of the linked [discussion chat](https://core.telegram.org/api/discussion) for channels| +|location|[ChannelLocation](/API_docs/types/ChannelLocation.html) | Optional|Location of the geogroup| +|slowmode\_seconds|[int](/API_docs/types/int.html) | Optional|If specified, users in supergroups will only be able to send one message every `slowmode_seconds` seconds| +|slowmode\_next\_send\_date|[int](/API_docs/types/int.html) | Optional|Indicates when the user will be allowed to send another message in the supergroup (unixtime)| +|stats\_dc|[int](/API_docs/types/int.html) | Optional|If set, specifies the DC to use for fetching channel statistics| +|pts|[int](/API_docs/types/int.html) | Yes|Latest [PTS](https://core.telegram.org/api/updates) for this channel| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Optional|Livestream or group call information| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time-To-Live of messages in this channel or supergroup| +|pending\_suggestions|Array of [string](/API_docs/types/string.html) | Optional|A list of [suggested actions](https://core.telegram.org/api/config#suggestions) for the supergroup admin, [see here for more info »](https://core.telegram.org/api/config#suggestions).| +|groupcall\_default\_join\_as|[Peer](/API_docs/types/Peer.html) | Optional|When using [phone.getGroupCallJoinAs](../methods/phone.getGroupCallJoinAs.html) to get a list of peers that can be used to join a group call, this field indicates the peer that should be selected by default.| +|theme\_emoticon|[string](/API_docs/types/string.html) | Optional|Emoji representing a specific chat theme| +|requests\_pending|[int](/API_docs/types/int.html) | Optional|Pending [join requests »](https://core.telegram.org/api/invites#join-requests)| +|recent\_requesters|Array of [long](/API_docs/types/long.html) | Optional|IDs of users who requested to join recently| +|default\_send\_as|[Peer](/API_docs/types/Peer.html) | Optional|Default peer used for sending messages to this channel| +|available\_reactions|[ChatReactions](/API_docs/types/ChatReactions.html) | Optional|Allowed [message reactions »](https://core.telegram.org/api/reactions)| +|reactions\_limit|[int](/API_docs/types/int.html) | Optional| +|stories|[PeerStories](/API_docs/types/PeerStories.html) | Optional| +|wallpaper|[WallPaper](/API_docs/types/WallPaper.html) | Optional| +|boosts\_applied|[int](/API_docs/types/int.html) | Optional| +|boosts\_unrestrict|[int](/API_docs/types/int.html) | Optional| +|emojiset|[StickerSet](/API_docs/types/StickerSet.html) | Optional| + + + +### Type: [ChatFull](/API_docs/types/ChatFull.html) + + +### Example: + +``` +$channelFull = ['_' => 'channelFull', 'can_view_participants' => Bool, 'can_set_username' => Bool, 'can_set_stickers' => Bool, 'hidden_prehistory' => Bool, 'can_set_location' => Bool, 'has_scheduled' => Bool, 'can_view_stats' => Bool, 'blocked' => Bool, 'can_delete_channel' => Bool, 'antispam' => Bool, 'participants_hidden' => Bool, 'translations_disabled' => Bool, 'stories_pinned_available' => Bool, 'view_forum_as_messages' => Bool, 'restricted_sponsored' => Bool, 'can_view_revenue' => Bool, 'id' => long, 'about' => 'string', 'participants_count' => int, 'admins_count' => int, 'kicked_count' => int, 'banned_count' => int, 'online_count' => int, 'read_inbox_max_id' => int, 'read_outbox_max_id' => int, 'unread_count' => int, 'chat_photo' => Photo, 'notify_settings' => PeerNotifySettings, 'exported_invite' => ExportedChatInvite, 'bot_info' => [BotInfo, BotInfo], 'migrated_from_chat_id' => long, 'migrated_from_max_id' => int, 'pinned_msg_id' => int, 'stickerset' => StickerSet, 'available_min_id' => int, 'folder_id' => int, 'linked_chat_id' => long, 'location' => ChannelLocation, 'slowmode_seconds' => int, 'slowmode_next_send_date' => int, 'stats_dc' => int, 'pts' => int, 'call' => InputGroupCall, 'ttl_period' => int, 'pending_suggestions' => ['string', 'string'], 'groupcall_default_join_as' => Peer, 'theme_emoticon' => 'string', 'requests_pending' => int, 'recent_requesters' => [long, long], 'default_send_as' => Peer, 'available_reactions' => ChatReactions, 'reactions_limit' => int, 'stories' => PeerStories, 'wallpaper' => WallPaper, 'boosts_applied' => int, 'boosts_unrestrict' => int, 'emojiset' => StickerSet]; +``` diff --git a/docs/API_docs/constructors/channelLocation.md b/docs/API_docs/constructors/channelLocation.md new file mode 100644 index 0000000000..0bbbebff25 --- /dev/null +++ b/docs/API_docs/constructors/channelLocation.md @@ -0,0 +1,30 @@ +--- +title: "channelLocation" +description: "Geographical location of supergroup (geogroups)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Geographical location of supergroup (geogroups) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo\_point|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Geographical location of supergroup| +|address|[string](/API_docs/types/string.html) | Yes|Textual description of the address| + + + +### Type: [ChannelLocation](/API_docs/types/ChannelLocation.html) + + +### Example: + +``` +$channelLocation = ['_' => 'channelLocation', 'geo_point' => GeoPoint, 'address' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelLocationEmpty.md b/docs/API_docs/constructors/channelLocationEmpty.md new file mode 100644 index 0000000000..591e9a5ce8 --- /dev/null +++ b/docs/API_docs/constructors/channelLocationEmpty.md @@ -0,0 +1,24 @@ +--- +title: "channelLocationEmpty" +description: "No location (normal supergroup)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelLocationEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No location (normal supergroup) + + + + +### Type: [ChannelLocation](/API_docs/types/ChannelLocation.html) + + +### Example: + +``` +$channelLocationEmpty = ['_' => 'channelLocationEmpty']; +``` diff --git a/docs/API_docs/constructors/channelMessagesFilter.md b/docs/API_docs/constructors/channelMessagesFilter.md new file mode 100644 index 0000000000..54e9c35d12 --- /dev/null +++ b/docs/API_docs/constructors/channelMessagesFilter.md @@ -0,0 +1,30 @@ +--- +title: "channelMessagesFilter" +description: "Filter for getting only certain types of channel messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelMessagesFilter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter for getting only certain types of channel messages + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|exclude\_new\_messages|[Bool](/API_docs/types/Bool.html) | Optional|Whether to exclude new messages from the search| +|ranges|Array of [MessageRange](/API_docs/types/MessageRange.html) | Yes|A range of messages to fetch| + + + +### Type: [ChannelMessagesFilter](/API_docs/types/ChannelMessagesFilter.html) + + +### Example: + +``` +$channelMessagesFilter = ['_' => 'channelMessagesFilter', 'exclude_new_messages' => Bool, 'ranges' => [MessageRange, MessageRange]]; +``` diff --git a/docs/API_docs/constructors/channelMessagesFilterEmpty.md b/docs/API_docs/constructors/channelMessagesFilterEmpty.md new file mode 100644 index 0000000000..d5c9293388 --- /dev/null +++ b/docs/API_docs/constructors/channelMessagesFilterEmpty.md @@ -0,0 +1,24 @@ +--- +title: "channelMessagesFilterEmpty" +description: "No filter" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelMessagesFilterEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No filter + + + + +### Type: [ChannelMessagesFilter](/API_docs/types/ChannelMessagesFilter.html) + + +### Example: + +``` +$channelMessagesFilterEmpty = ['_' => 'channelMessagesFilterEmpty']; +``` diff --git a/docs/API_docs/constructors/channelParticipant.md b/docs/API_docs/constructors/channelParticipant.md new file mode 100644 index 0000000000..cc67f4a805 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipant.md @@ -0,0 +1,30 @@ +--- +title: "channelParticipant" +description: "Channel/supergroup participant" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipant +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel/supergroup participant + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|Participant user ID| +|date|[int](/API_docs/types/int.html) | Yes|Date joined| + + + +### Type: [ChannelParticipant](/API_docs/types/ChannelParticipant.html) + + +### Example: + +``` +$channelParticipant = ['_' => 'channelParticipant', 'user_id' => long, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/channelParticipantAdmin.md b/docs/API_docs/constructors/channelParticipantAdmin.md new file mode 100644 index 0000000000..c63bee14f8 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantAdmin.md @@ -0,0 +1,36 @@ +--- +title: "channelParticipantAdmin" +description: "Admin" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantAdmin +[Back to constructors index](/API_docs/constructors/index.html) + + + +Admin + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|can\_edit|[Bool](/API_docs/types/Bool.html) | Optional|Can this admin promote other admins with the same permissions?| +|self|[Bool](/API_docs/types/Bool.html) | Optional|Is this the current user| +|user\_id|[long](/API_docs/types/long.html) | Yes|Admin user ID| +|inviter\_id|[long](/API_docs/types/long.html) | Optional|User that invited the admin to the channel/group| +|promoted\_by|[long](/API_docs/types/long.html) | Yes|User that promoted the user to admin| +|date|[int](/API_docs/types/int.html) | Yes|When did the user join| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Yes|Admin [rights](https://core.telegram.org/api/rights)| +|rank|[string](/API_docs/types/string.html) | Optional|The role (rank) of the admin in the group: just an arbitrary string, `admin` by default| + + + +### Type: [ChannelParticipant](/API_docs/types/ChannelParticipant.html) + + +### Example: + +``` +$channelParticipantAdmin = ['_' => 'channelParticipantAdmin', 'can_edit' => Bool, 'self' => Bool, 'user_id' => long, 'inviter_id' => long, 'promoted_by' => long, 'date' => int, 'admin_rights' => ChatAdminRights, 'rank' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelParticipantBanned.md b/docs/API_docs/constructors/channelParticipantBanned.md new file mode 100644 index 0000000000..cab810967d --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantBanned.md @@ -0,0 +1,33 @@ +--- +title: "channelParticipantBanned" +description: "Banned/kicked user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantBanned +[Back to constructors index](/API_docs/constructors/index.html) + + + +Banned/kicked user + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|left|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user has left the group| +|peer|[long](/API_docs/types/long.html) | Yes|The banned peer| +|kicked\_by|[long](/API_docs/types/long.html) | Yes|User was kicked by the specified admin| +|date|[int](/API_docs/types/int.html) | Yes|When did the user join the group| +|banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Yes|Banned [rights](https://core.telegram.org/api/rights)| + + + +### Type: [ChannelParticipant](/API_docs/types/ChannelParticipant.html) + + +### Example: + +``` +$channelParticipantBanned = ['_' => 'channelParticipantBanned', 'left' => Bool, 'peer' => long, 'kicked_by' => long, 'date' => int, 'banned_rights' => ChatBannedRights]; +``` diff --git a/docs/API_docs/constructors/channelParticipantCreator.md b/docs/API_docs/constructors/channelParticipantCreator.md new file mode 100644 index 0000000000..40b4d7b101 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantCreator.md @@ -0,0 +1,31 @@ +--- +title: "channelParticipantCreator" +description: "Channel/supergroup creator" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantCreator +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel/supergroup creator + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Yes|Creator admin rights| +|rank|[string](/API_docs/types/string.html) | Optional|The role (rank) of the group creator in the group: just an arbitrary string, `admin` by default| + + + +### Type: [ChannelParticipant](/API_docs/types/ChannelParticipant.html) + + +### Example: + +``` +$channelParticipantCreator = ['_' => 'channelParticipantCreator', 'user_id' => long, 'admin_rights' => ChatAdminRights, 'rank' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelParticipantLeft.md b/docs/API_docs/constructors/channelParticipantLeft.md new file mode 100644 index 0000000000..0e6f3959c0 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantLeft.md @@ -0,0 +1,29 @@ +--- +title: "channelParticipantLeft" +description: "A participant that left the channel/supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantLeft +[Back to constructors index](/API_docs/constructors/index.html) + + + +A participant that left the channel/supergroup + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer that left| + + + +### Type: [ChannelParticipant](/API_docs/types/ChannelParticipant.html) + + +### Example: + +``` +$channelParticipantLeft = ['_' => 'channelParticipantLeft', 'peer' => long]; +``` diff --git a/docs/API_docs/constructors/channelParticipantSelf.md b/docs/API_docs/constructors/channelParticipantSelf.md new file mode 100644 index 0000000000..440ce5dac2 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantSelf.md @@ -0,0 +1,32 @@ +--- +title: "channelParticipantSelf" +description: "Myself" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantSelf +[Back to constructors index](/API_docs/constructors/index.html) + + + +Myself + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|via\_request|[Bool](/API_docs/types/Bool.html) | Optional|Whether I joined upon specific approval of an admin| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|inviter\_id|[long](/API_docs/types/long.html) | Yes|User that invited me to the channel/supergroup| +|date|[int](/API_docs/types/int.html) | Yes|When did I join the channel/supergroup| + + + +### Type: [ChannelParticipant](/API_docs/types/ChannelParticipant.html) + + +### Example: + +``` +$channelParticipantSelf = ['_' => 'channelParticipantSelf', 'via_request' => Bool, 'user_id' => long, 'inviter_id' => long, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/channelParticipantsAdmins.md b/docs/API_docs/constructors/channelParticipantsAdmins.md new file mode 100644 index 0000000000..dd5f98b234 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsAdmins.md @@ -0,0 +1,24 @@ +--- +title: "channelParticipantsAdmins" +description: "Fetch only admin participants" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsAdmins +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only admin participants + + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsAdmins = ['_' => 'channelParticipantsAdmins']; +``` diff --git a/docs/API_docs/constructors/channelParticipantsBanned.md b/docs/API_docs/constructors/channelParticipantsBanned.md new file mode 100644 index 0000000000..1b9370b0f0 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsBanned.md @@ -0,0 +1,29 @@ +--- +title: "channelParticipantsBanned" +description: "Fetch only banned participants" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsBanned +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only banned participants + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|q|[string](/API_docs/types/string.html) | Yes|Optional filter for searching banned participants by name (otherwise empty)| + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsBanned = ['_' => 'channelParticipantsBanned', 'q' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelParticipantsBots.md b/docs/API_docs/constructors/channelParticipantsBots.md new file mode 100644 index 0000000000..e59f2ee9f9 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsBots.md @@ -0,0 +1,24 @@ +--- +title: "channelParticipantsBots" +description: "Fetch only bot participants" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsBots +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only bot participants + + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsBots = ['_' => 'channelParticipantsBots']; +``` diff --git a/docs/API_docs/constructors/channelParticipantsContacts.md b/docs/API_docs/constructors/channelParticipantsContacts.md new file mode 100644 index 0000000000..044420d5fb --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsContacts.md @@ -0,0 +1,29 @@ +--- +title: "channelParticipantsContacts" +description: "Fetch only participants that are also contacts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only participants that are also contacts + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|q|[string](/API_docs/types/string.html) | Yes|Optional search query for searching contact participants by name| + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsContacts = ['_' => 'channelParticipantsContacts', 'q' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelParticipantsKicked.md b/docs/API_docs/constructors/channelParticipantsKicked.md new file mode 100644 index 0000000000..4f2e2c0b11 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsKicked.md @@ -0,0 +1,29 @@ +--- +title: "channelParticipantsKicked" +description: "Fetch only kicked participants" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsKicked +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only kicked participants + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|q|[string](/API_docs/types/string.html) | Yes|Optional filter for searching kicked participants by name (otherwise empty)| + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsKicked = ['_' => 'channelParticipantsKicked', 'q' => 'string']; +``` diff --git a/docs/API_docs/constructors/channelParticipantsMentions.md b/docs/API_docs/constructors/channelParticipantsMentions.md new file mode 100644 index 0000000000..2e3f5cdffe --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsMentions.md @@ -0,0 +1,31 @@ +--- +title: "channelParticipantsMentions" +description: "This filter is used when looking for supergroup members to mention." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsMentions +[Back to constructors index](/API_docs/constructors/index.html) + + + +This filter is used when looking for supergroup members to mention. +This filter will automatically remove anonymous admins, and return even non-participant users that replied to a specific [thread](https://core.telegram.org/api/threads) through the [comment section](https://core.telegram.org/api/threads#channel-comments) of a channel. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|q|[string](/API_docs/types/string.html) | Optional|Filter by user name or username| +|top\_msg\_id|[int](/API_docs/types/int.html) | Optional|Look only for users that posted in this [thread](https://core.telegram.org/api/threads)| + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsMentions = ['_' => 'channelParticipantsMentions', 'q' => 'string', 'top_msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/channelParticipantsRecent.md b/docs/API_docs/constructors/channelParticipantsRecent.md new file mode 100644 index 0000000000..1f229d0eb1 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsRecent.md @@ -0,0 +1,24 @@ +--- +title: "channelParticipantsRecent" +description: "Fetch only recent participants" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsRecent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only recent participants + + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsRecent = ['_' => 'channelParticipantsRecent']; +``` diff --git a/docs/API_docs/constructors/channelParticipantsSearch.md b/docs/API_docs/constructors/channelParticipantsSearch.md new file mode 100644 index 0000000000..68c14d50d6 --- /dev/null +++ b/docs/API_docs/constructors/channelParticipantsSearch.md @@ -0,0 +1,29 @@ +--- +title: "channelParticipantsSearch" +description: "Query participants by name" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: channelParticipantsSearch +[Back to constructors index](/API_docs/constructors/index.html) + + + +Query participants by name + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|q|[string](/API_docs/types/string.html) | Yes|Search query| + + + +### Type: [ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + + +### Example: + +``` +$channelParticipantsSearch = ['_' => 'channelParticipantsSearch', 'q' => 'string']; +``` diff --git a/docs/API_docs/constructors/channels.adminLogResults.md b/docs/API_docs/constructors/channels.adminLogResults.md new file mode 100644 index 0000000000..e7d8ab6bb3 --- /dev/null +++ b/docs/API_docs/constructors/channels.adminLogResults.md @@ -0,0 +1,32 @@ +--- +title: "channels.adminLogResults" +description: "Admin log events" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_adminLogResults.html +--- +# Constructor: channels.adminLogResults +[Back to constructors index](/API_docs/constructors/index.html) + + + +Admin log events + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|events|Array of [ChannelAdminLogEvent](/API_docs/types/ChannelAdminLogEvent.html) | Yes|Admin log events| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in events| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in events| + + + +### Type: [channels.AdminLogResults](/API_docs/types/channels.AdminLogResults.html) + + +### Example: + +``` +$channels_adminLogResults = ['_' => 'channels.adminLogResults', 'events' => [ChannelAdminLogEvent, ChannelAdminLogEvent], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/channels.channelParticipant.md b/docs/API_docs/constructors/channels.channelParticipant.md new file mode 100644 index 0000000000..7aed2416a3 --- /dev/null +++ b/docs/API_docs/constructors/channels.channelParticipant.md @@ -0,0 +1,32 @@ +--- +title: "channels.channelParticipant" +description: "Represents a channel participant" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_channelParticipant.html +--- +# Constructor: channels.channelParticipant +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a channel participant + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|The channel participant| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [channels.ChannelParticipant](/API_docs/types/channels.ChannelParticipant.html) + + +### Example: + +``` +$channels_channelParticipant = ['_' => 'channels.channelParticipant', 'participant' => ChannelParticipant, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/channels.channelParticipants.md b/docs/API_docs/constructors/channels.channelParticipants.md new file mode 100644 index 0000000000..cd3170afec --- /dev/null +++ b/docs/API_docs/constructors/channels.channelParticipants.md @@ -0,0 +1,33 @@ +--- +title: "channels.channelParticipants" +description: "Represents multiple channel participants" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_channelParticipants.html +--- +# Constructor: channels.channelParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents multiple channel participants + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of participants that correspond to the given query| +|participants|Array of [ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Yes|Participants| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in participant info| + + + +### Type: [channels.ChannelParticipants](/API_docs/types/channels.ChannelParticipants.html) + + +### Example: + +``` +$channels_channelParticipants = ['_' => 'channels.channelParticipants', 'count' => int, 'participants' => [ChannelParticipant, ChannelParticipant], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/channels.channelParticipantsNotModified.md b/docs/API_docs/constructors/channels.channelParticipantsNotModified.md new file mode 100644 index 0000000000..06d4360ca4 --- /dev/null +++ b/docs/API_docs/constructors/channels.channelParticipantsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "channels.channelParticipantsNotModified" +description: "No new participant info could be found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_channelParticipantsNotModified.html +--- +# Constructor: channels.channelParticipantsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new participant info could be found + + + + +### Type: [channels.ChannelParticipants](/API_docs/types/channels.ChannelParticipants.html) + + +### Example: + +``` +$channels_channelParticipantsNotModified = ['_' => 'channels.channelParticipantsNotModified']; +``` diff --git a/docs/API_docs/constructors/channels.sendAsPeers.md b/docs/API_docs/constructors/channels.sendAsPeers.md new file mode 100644 index 0000000000..42085cdc64 --- /dev/null +++ b/docs/API_docs/constructors/channels.sendAsPeers.md @@ -0,0 +1,32 @@ +--- +title: "channels.sendAsPeers" +description: "A list of peers that can be used to send messages in a specific group" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_sendAsPeers.html +--- +# Constructor: channels.sendAsPeers +[Back to constructors index](/API_docs/constructors/index.html) + + + +A list of peers that can be used to send messages in a specific group + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peers|Array of [SendAsPeer](/API_docs/types/SendAsPeer.html) | Yes|Peers that can be used to send messages to the group| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [channels.SendAsPeers](/API_docs/types/channels.SendAsPeers.html) + + +### Example: + +``` +$channels_sendAsPeers = ['_' => 'channels.sendAsPeers', 'peers' => [SendAsPeer, SendAsPeer], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/channels.sponsoredMessageReportResultAdsHidden.md b/docs/API_docs/constructors/channels.sponsoredMessageReportResultAdsHidden.md new file mode 100644 index 0000000000..4c8255ae8d --- /dev/null +++ b/docs/API_docs/constructors/channels.sponsoredMessageReportResultAdsHidden.md @@ -0,0 +1,23 @@ +--- +title: "channels.sponsoredMessageReportResultAdsHidden" +description: "channels.sponsoredMessageReportResultAdsHidden attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_sponsoredMessageReportResultAdsHidden.html +--- +# Constructor: channels.sponsoredMessageReportResultAdsHidden +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [channels.SponsoredMessageReportResult](/API_docs/types/channels.SponsoredMessageReportResult.html) + + +### Example: + +``` +$channels_sponsoredMessageReportResultAdsHidden = ['_' => 'channels.sponsoredMessageReportResultAdsHidden']; +``` diff --git a/docs/API_docs/constructors/channels.sponsoredMessageReportResultChooseOption.md b/docs/API_docs/constructors/channels.sponsoredMessageReportResultChooseOption.md new file mode 100644 index 0000000000..b39d0c14e3 --- /dev/null +++ b/docs/API_docs/constructors/channels.sponsoredMessageReportResultChooseOption.md @@ -0,0 +1,29 @@ +--- +title: "channels.sponsoredMessageReportResultChooseOption" +description: "channels.sponsoredMessageReportResultChooseOption attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_sponsoredMessageReportResultChooseOption.html +--- +# Constructor: channels.sponsoredMessageReportResultChooseOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|title|[string](/API_docs/types/string.html) | Yes| +|options|Array of [SponsoredMessageReportOption](/API_docs/types/SponsoredMessageReportOption.html) | Yes| + + + +### Type: [channels.SponsoredMessageReportResult](/API_docs/types/channels.SponsoredMessageReportResult.html) + + +### Example: + +``` +$channels_sponsoredMessageReportResultChooseOption = ['_' => 'channels.sponsoredMessageReportResultChooseOption', 'title' => 'string', 'options' => [SponsoredMessageReportOption, SponsoredMessageReportOption]]; +``` diff --git a/docs/API_docs/constructors/channels.sponsoredMessageReportResultReported.md b/docs/API_docs/constructors/channels.sponsoredMessageReportResultReported.md new file mode 100644 index 0000000000..66be9a2fa0 --- /dev/null +++ b/docs/API_docs/constructors/channels.sponsoredMessageReportResultReported.md @@ -0,0 +1,23 @@ +--- +title: "channels.sponsoredMessageReportResultReported" +description: "channels.sponsoredMessageReportResultReported attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/channels_sponsoredMessageReportResultReported.html +--- +# Constructor: channels.sponsoredMessageReportResultReported +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [channels.SponsoredMessageReportResult](/API_docs/types/channels.SponsoredMessageReportResult.html) + + +### Example: + +``` +$channels_sponsoredMessageReportResultReported = ['_' => 'channels.sponsoredMessageReportResultReported']; +``` diff --git a/docs/API_docs/constructors/chat.md b/docs/API_docs/constructors/chat.md new file mode 100644 index 0000000000..7bb98108a9 --- /dev/null +++ b/docs/API_docs/constructors/chat.md @@ -0,0 +1,43 @@ +--- +title: "chat" +description: "Info about a group" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a group + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|creator|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user is the creator of the group| +|left|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user has left the group| +|deactivated|[Bool](/API_docs/types/Bool.html) | Optional|Whether the group was [migrated](https://core.telegram.org/api/channel)| +|call\_active|[Bool](/API_docs/types/Bool.html) | Optional|Whether a group call is currently active| +|call\_not\_empty|[Bool](/API_docs/types/Bool.html) | Optional|Whether there's anyone in the group call| +|noforwards|[Bool](/API_docs/types/Bool.html) | Optional|Whether this group is [protected](https://telegram.org/blog/protected-content-delete-by-date-and-more), thus does not allow forwarding messages from it| +|id|[long](/API_docs/types/long.html) | Yes|ID of the group| +|title|[string](/API_docs/types/string.html) | Yes|Title| +|photo|[ChatPhoto](/API_docs/types/ChatPhoto.html) | Optional|Chat photo| +|participants\_count|[int](/API_docs/types/int.html) | Yes|Participant count| +|date|[int](/API_docs/types/int.html) | Yes|Date of creation of the group| +|version|[int](/API_docs/types/int.html) | Yes|Used in basic groups to reorder updates and make sure that all of them were received.| +|migrated\_to|[InputChannel](/API_docs/types/InputChannel.html) | Optional|Means this chat was [upgraded](https://core.telegram.org/api/channel) to a supergroup| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|[Admin rights](https://core.telegram.org/api/rights) of the user in the group| +|default\_banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Optional|[Default banned rights](https://core.telegram.org/api/rights) of all users in the group| + + + +### Type: [Chat](/API_docs/types/Chat.html) + + +### Example: + +``` +$chat = ['_' => 'chat', 'creator' => Bool, 'left' => Bool, 'deactivated' => Bool, 'call_active' => Bool, 'call_not_empty' => Bool, 'noforwards' => Bool, 'id' => long, 'title' => 'string', 'photo' => ChatPhoto, 'participants_count' => int, 'date' => int, 'version' => int, 'migrated_to' => InputChannel, 'admin_rights' => ChatAdminRights, 'default_banned_rights' => ChatBannedRights]; +``` diff --git a/docs/API_docs/constructors/chatAdminRights.md b/docs/API_docs/constructors/chatAdminRights.md new file mode 100644 index 0000000000..e18f4beb00 --- /dev/null +++ b/docs/API_docs/constructors/chatAdminRights.md @@ -0,0 +1,43 @@ +--- +title: "chatAdminRights" +description: "Represents the rights of an admin in a channel/supergroup." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatAdminRights +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents the rights of an admin in a [channel/supergroup](https://core.telegram.org/api/channel). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|change\_info|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to modify the description of the [channel/supergroup](https://core.telegram.org/api/channel)| +|post\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to post messages in the [channel](https://core.telegram.org/api/channel)| +|edit\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to also edit messages from other admins in the [channel](https://core.telegram.org/api/channel)| +|delete\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to also delete messages from other admins in the [channel](https://core.telegram.org/api/channel)| +|ban\_users|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to ban users from the [channel/supergroup](https://core.telegram.org/api/channel)| +|invite\_users|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to invite users in the [channel/supergroup](https://core.telegram.org/api/channel)| +|pin\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to pin messages in the [channel/supergroup](https://core.telegram.org/api/channel)| +|add\_admins|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to add other admins with the same (or more limited) permissions in the [channel/supergroup](https://core.telegram.org/api/channel)| +|anonymous|[Bool](/API_docs/types/Bool.html) | Optional|Whether this admin is anonymous| +|manage\_call|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to change group call/livestream settings| +|other|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if none of the other flags are set, but you still want the user to be an admin: if this or any of the other flags are set, the admin can get the chat [admin log](https://core.telegram.org/api/recent-actions), get [chat statistics](https://core.telegram.org/api/stats), get [message statistics in channels](https://core.telegram.org/api/stats), get channel members, see anonymous administrators in supergroups and ignore slow mode.| +|manage\_topics|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to create, delete or modify [forum topics »](https://core.telegram.org/api/forum#forum-topics).| +|post\_stories|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to post [stories](https://core.telegram.org/api/stories) as the [channel](https://core.telegram.org/api/channel).| +|edit\_stories|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to edit [stories](https://core.telegram.org/api/stories) posted by the other admins of the [channel](https://core.telegram.org/api/channel).| +|delete\_stories|[Bool](/API_docs/types/Bool.html) | Optional|If set, allows the admin to delete [stories](https://core.telegram.org/api/stories) posted by the other admins of the [channel](https://core.telegram.org/api/channel).| + + + +### Type: [ChatAdminRights](/API_docs/types/ChatAdminRights.html) + + +### Example: + +``` +$chatAdminRights = ['_' => 'chatAdminRights', 'change_info' => Bool, 'post_messages' => Bool, 'edit_messages' => Bool, 'delete_messages' => Bool, 'ban_users' => Bool, 'invite_users' => Bool, 'pin_messages' => Bool, 'add_admins' => Bool, 'anonymous' => Bool, 'manage_call' => Bool, 'other' => Bool, 'manage_topics' => Bool, 'post_stories' => Bool, 'edit_stories' => Bool, 'delete_stories' => Bool]; +``` diff --git a/docs/API_docs/constructors/chatAdminWithInvites.md b/docs/API_docs/constructors/chatAdminWithInvites.md new file mode 100644 index 0000000000..a5cc67f7eb --- /dev/null +++ b/docs/API_docs/constructors/chatAdminWithInvites.md @@ -0,0 +1,31 @@ +--- +title: "chatAdminWithInvites" +description: "Info about chat invites generated by admins." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatAdminWithInvites +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about chat invites generated by admins. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|admin\_id|[long](/API_docs/types/long.html) | Yes|The admin| +|invites\_count|[int](/API_docs/types/int.html) | Yes|Number of invites generated by the admin| +|revoked\_invites\_count|[int](/API_docs/types/int.html) | Yes|Number of revoked invites| + + + +### Type: [ChatAdminWithInvites](/API_docs/types/ChatAdminWithInvites.html) + + +### Example: + +``` +$chatAdminWithInvites = ['_' => 'chatAdminWithInvites', 'admin_id' => long, 'invites_count' => int, 'revoked_invites_count' => int]; +``` diff --git a/docs/API_docs/constructors/chatBannedRights.md b/docs/API_docs/constructors/chatBannedRights.md new file mode 100644 index 0000000000..8b3b7e658a --- /dev/null +++ b/docs/API_docs/constructors/chatBannedRights.md @@ -0,0 +1,49 @@ +--- +title: "chatBannedRights" +description: "Represents the rights of a normal user in a supergroup/channel/chat. In this case, the flags are inverted: if set, a flag does not allow a user to do X." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatBannedRights +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents the rights of a normal user in a [supergroup/channel/chat](https://core.telegram.org/api/channel). In this case, the flags are inverted: if set, a flag **does not allow** a user to do X. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|view\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to view messages in a [supergroup/channel/chat](https://core.telegram.org/api/channel)| +|send\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send messages in a [supergroup/chat](https://core.telegram.org/api/channel)| +|send\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send any media in a [supergroup/chat](https://core.telegram.org/api/channel)| +|send\_stickers|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send stickers in a [supergroup/chat](https://core.telegram.org/api/channel)| +|send\_gifs|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send gifs in a [supergroup/chat](https://core.telegram.org/api/channel)| +|send\_games|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send games in a [supergroup/chat](https://core.telegram.org/api/channel)| +|send\_inline|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to use inline bots in a [supergroup/chat](https://core.telegram.org/api/channel).| +|embed\_links|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to embed links in the messages of a [supergroup/chat](https://core.telegram.org/api/channel)| +|send\_polls|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send polls in a [supergroup/chat](https://core.telegram.org/api/channel)| +|change\_info|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow any user to change the description of a [supergroup/chat](https://core.telegram.org/api/channel)| +|invite\_users|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow any user to invite users in a [supergroup/chat](https://core.telegram.org/api/channel)| +|pin\_messages|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow any user to pin messages in a [supergroup/chat](https://core.telegram.org/api/channel)| +|manage\_topics|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow any user to create, delete or modify [forum topics »](https://core.telegram.org/api/forum#forum-topics).| +|send\_photos|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send photos in a [supergroup/chat](https://core.telegram.org/api/channel).| +|send\_videos|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send videos in a [supergroup/chat](https://core.telegram.org/api/channel).| +|send\_roundvideos|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send round videos in a [supergroup/chat](https://core.telegram.org/api/channel).| +|send\_audios|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send audio files in a [supergroup/chat](https://core.telegram.org/api/channel).| +|send\_voices|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send voice messages in a [supergroup/chat](https://core.telegram.org/api/channel).| +|send\_docs|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send documents in a [supergroup/chat](https://core.telegram.org/api/channel).| +|send\_plain|[Bool](/API_docs/types/Bool.html) | Optional|If set, does not allow a user to send text messages in a [supergroup/chat](https://core.telegram.org/api/channel).| +|until\_date|[int](/API_docs/types/int.html) | Yes|Validity of said permissions (it is considered forever any value less then 30 seconds or more then 366 days).| + + + +### Type: [ChatBannedRights](/API_docs/types/ChatBannedRights.html) + + +### Example: + +``` +$chatBannedRights = ['_' => 'chatBannedRights', 'view_messages' => Bool, 'send_messages' => Bool, 'send_media' => Bool, 'send_stickers' => Bool, 'send_gifs' => Bool, 'send_games' => Bool, 'send_inline' => Bool, 'embed_links' => Bool, 'send_polls' => Bool, 'change_info' => Bool, 'invite_users' => Bool, 'pin_messages' => Bool, 'manage_topics' => Bool, 'send_photos' => Bool, 'send_videos' => Bool, 'send_roundvideos' => Bool, 'send_audios' => Bool, 'send_voices' => Bool, 'send_docs' => Bool, 'send_plain' => Bool, 'until_date' => int]; +``` diff --git a/docs/API_docs/constructors/chatEmpty.md b/docs/API_docs/constructors/chatEmpty.md new file mode 100644 index 0000000000..59a91acb2c --- /dev/null +++ b/docs/API_docs/constructors/chatEmpty.md @@ -0,0 +1,29 @@ +--- +title: "chatEmpty" +description: "Empty constructor, group doesn't exist" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, group doesn't exist + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Group identifier| + + + +### Type: [Chat](/API_docs/types/Chat.html) + + +### Example: + +``` +$chatEmpty = ['_' => 'chatEmpty', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/chatForbidden.md b/docs/API_docs/constructors/chatForbidden.md new file mode 100644 index 0000000000..3e17f50b96 --- /dev/null +++ b/docs/API_docs/constructors/chatForbidden.md @@ -0,0 +1,30 @@ +--- +title: "chatForbidden" +description: "A group to which the user has no access. E.g., because the user was kicked from the group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatForbidden +[Back to constructors index](/API_docs/constructors/index.html) + + + +A group to which the user has no access. E.g., because the user was kicked from the group. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|User identifier| +|title|[string](/API_docs/types/string.html) | Yes|Group name| + + + +### Type: [Chat](/API_docs/types/Chat.html) + + +### Example: + +``` +$chatForbidden = ['_' => 'chatForbidden', 'id' => long, 'title' => 'string']; +``` diff --git a/docs/API_docs/constructors/chatFull.md b/docs/API_docs/constructors/chatFull.md new file mode 100644 index 0000000000..4497f962c3 --- /dev/null +++ b/docs/API_docs/constructors/chatFull.md @@ -0,0 +1,48 @@ +--- +title: "chatFull" +description: "Full info about a basic group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatFull +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full info about a [basic group](https://core.telegram.org/api/channel#basic-groups). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|can\_set\_username|[Bool](/API_docs/types/Bool.html) | Optional|Can we change the username of this chat| +|has\_scheduled|[Bool](/API_docs/types/Bool.html) | Optional|Whether [scheduled messages](https://core.telegram.org/api/scheduled-messages) are available| +|translations\_disabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether the [real-time chat translation popup](https://core.telegram.org/api/translation) should be hidden.| +|id|[long](/API_docs/types/long.html) | Yes|ID of the chat| +|about|[string](/API_docs/types/string.html) | Yes|About string for this chat| +|participants|[ChatParticipants](/API_docs/types/ChatParticipants.html) | Yes|Participant list| +|chat\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Chat photo| +|notify\_settings|[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) | Yes|Notification settings| +|exported\_invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Optional|Chat invite| +|bot\_info|Array of [BotInfo](/API_docs/types/BotInfo.html) | Optional|Info about bots that are in this chat| +|pinned\_msg\_id|[int](/API_docs/types/int.html) | Optional|Message ID of the last [pinned message](https://core.telegram.org/api/pin)| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Optional|Group call information| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time-To-Live of messages sent by the current user to this chat| +|groupcall\_default\_join\_as|[Peer](/API_docs/types/Peer.html) | Optional|When using [phone.getGroupCallJoinAs](../methods/phone.getGroupCallJoinAs.html) to get a list of peers that can be used to join a group call, this field indicates the peer that should be selected by default.| +|theme\_emoticon|[string](/API_docs/types/string.html) | Optional|Emoji representing a specific chat theme| +|requests\_pending|[int](/API_docs/types/int.html) | Optional|Pending [join requests »](https://core.telegram.org/api/invites#join-requests)| +|recent\_requesters|Array of [long](/API_docs/types/long.html) | Optional|IDs of users who requested to join recently| +|available\_reactions|[ChatReactions](/API_docs/types/ChatReactions.html) | Optional|Allowed [message reactions »](https://core.telegram.org/api/reactions)| +|reactions\_limit|[int](/API_docs/types/int.html) | Optional| + + + +### Type: [ChatFull](/API_docs/types/ChatFull.html) + + +### Example: + +``` +$chatFull = ['_' => 'chatFull', 'can_set_username' => Bool, 'has_scheduled' => Bool, 'translations_disabled' => Bool, 'id' => long, 'about' => 'string', 'participants' => ChatParticipants, 'chat_photo' => Photo, 'notify_settings' => PeerNotifySettings, 'exported_invite' => ExportedChatInvite, 'bot_info' => [BotInfo, BotInfo], 'pinned_msg_id' => int, 'folder_id' => int, 'call' => InputGroupCall, 'ttl_period' => int, 'groupcall_default_join_as' => Peer, 'theme_emoticon' => 'string', 'requests_pending' => int, 'recent_requesters' => [long, long], 'available_reactions' => ChatReactions, 'reactions_limit' => int]; +``` diff --git a/docs/API_docs/constructors/chatInvite.md b/docs/API_docs/constructors/chatInvite.md new file mode 100644 index 0000000000..9772d58e19 --- /dev/null +++ b/docs/API_docs/constructors/chatInvite.md @@ -0,0 +1,42 @@ +--- +title: "chatInvite" +description: "Chat invite info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat invite info + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a [channel/supergroup](https://core.telegram.org/api/channel) or a [normal group](https://core.telegram.org/api/channel)| +|broadcast|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a [channel](https://core.telegram.org/api/channel)| +|public|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a public [channel/supergroup](https://core.telegram.org/api/channel)| +|megagroup|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a [supergroup](https://core.telegram.org/api/channel)| +|request\_needed|[Bool](/API_docs/types/Bool.html) | Optional|Whether the [join request »](https://core.telegram.org/api/invites#join-requests) must be first approved by an administrator| +|verified|[Bool](/API_docs/types/Bool.html) | Optional|Is this chat or channel verified by Telegram?| +|scam|[Bool](/API_docs/types/Bool.html) | Optional|This chat is probably a scam| +|fake|[Bool](/API_docs/types/Bool.html) | Optional|If set, this chat was reported by many users as a fake or scam: be careful when interacting with it.| +|title|[string](/API_docs/types/string.html) | Yes|Chat/supergroup/channel title| +|about|[string](/API_docs/types/string.html) | Optional|Description of the group of channel| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|Chat/supergroup/channel photo| +|participants\_count|[int](/API_docs/types/int.html) | Yes|Participant count| +|participants|Array of [User](/API_docs/types/User.html) | Optional|A few of the participants that are in the group| +|color|[int](/API_docs/types/int.html) | Yes|[Profile color palette ID](https://core.telegram.org/api/colors)| + + + +### Type: [ChatInvite](/API_docs/types/ChatInvite.html) + + +### Example: + +``` +$chatInvite = ['_' => 'chatInvite', 'channel' => Bool, 'broadcast' => Bool, 'public' => Bool, 'megagroup' => Bool, 'request_needed' => Bool, 'verified' => Bool, 'scam' => Bool, 'fake' => Bool, 'title' => 'string', 'about' => 'string', 'photo' => Photo, 'participants_count' => int, 'participants' => [User, User], 'color' => int]; +``` diff --git a/docs/API_docs/constructors/chatInviteAlready.md b/docs/API_docs/constructors/chatInviteAlready.md new file mode 100644 index 0000000000..0f9fc50918 --- /dev/null +++ b/docs/API_docs/constructors/chatInviteAlready.md @@ -0,0 +1,29 @@ +--- +title: "chatInviteAlready" +description: "The user has already joined this chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatInviteAlready +[Back to constructors index](/API_docs/constructors/index.html) + + + +The user has already joined this chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat|[Chat](/API_docs/types/Chat.html) | Optional|The chat connected to the invite| + + + +### Type: [ChatInvite](/API_docs/types/ChatInvite.html) + + +### Example: + +``` +$chatInviteAlready = ['_' => 'chatInviteAlready', 'chat' => Chat]; +``` diff --git a/docs/API_docs/constructors/chatInviteExported.md b/docs/API_docs/constructors/chatInviteExported.md new file mode 100644 index 0000000000..89e83d2b9e --- /dev/null +++ b/docs/API_docs/constructors/chatInviteExported.md @@ -0,0 +1,40 @@ +--- +title: "chatInviteExported" +description: "Exported chat invite" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatInviteExported +[Back to constructors index](/API_docs/constructors/index.html) + + + +Exported chat invite + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|revoked|[Bool](/API_docs/types/Bool.html) | Optional|Whether this chat invite was revoked| +|permanent|[Bool](/API_docs/types/Bool.html) | Optional|Whether this chat invite has no expiration| +|request\_needed|[Bool](/API_docs/types/Bool.html) | Optional|Whether users importing this invite link will have to be approved to join the channel or group| +|link|[string](/API_docs/types/string.html) | Yes|Chat invitation link| +|admin\_id|[long](/API_docs/types/long.html) | Yes|ID of the admin that created this chat invite| +|date|[int](/API_docs/types/int.html) | Yes|When was this chat invite created| +|start\_date|[int](/API_docs/types/int.html) | Optional|When was this chat invite last modified| +|expire\_date|[int](/API_docs/types/int.html) | Optional|When does this chat invite expire| +|usage\_limit|[int](/API_docs/types/int.html) | Optional|Maximum number of users that can join using this link| +|usage|[int](/API_docs/types/int.html) | Optional|How many users joined using this link| +|requested|[int](/API_docs/types/int.html) | Optional|Number of users that have already used this link to join| +|title|[string](/API_docs/types/string.html) | Optional|Custom description for the invite link, visible only to admins| + + + +### Type: [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) + + +### Example: + +``` +$chatInviteExported = ['_' => 'chatInviteExported', 'revoked' => Bool, 'permanent' => Bool, 'request_needed' => Bool, 'link' => 'string', 'admin_id' => long, 'date' => int, 'start_date' => int, 'expire_date' => int, 'usage_limit' => int, 'usage' => int, 'requested' => int, 'title' => 'string']; +``` diff --git a/docs/API_docs/constructors/chatInviteImporter.md b/docs/API_docs/constructors/chatInviteImporter.md new file mode 100644 index 0000000000..b9aba3b846 --- /dev/null +++ b/docs/API_docs/constructors/chatInviteImporter.md @@ -0,0 +1,34 @@ +--- +title: "chatInviteImporter" +description: "When and which user joined the chat using a chat invite" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatInviteImporter +[Back to constructors index](/API_docs/constructors/index.html) + + + +When and which user joined the chat using a chat invite + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|requested|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user currently has a pending [join request »](https://core.telegram.org/api/invites#join-requests)| +|via\_chatlist|[Bool](/API_docs/types/Bool.html) | Optional|The participant joined by importing a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links).| +|user\_id|[long](/API_docs/types/long.html) | Yes|The user| +|date|[int](/API_docs/types/int.html) | Yes|When did the user join| +|about|[string](/API_docs/types/string.html) | Optional|For users with pending requests, contains bio of the user that requested to join| +|approved\_by|[long](/API_docs/types/long.html) | Optional|The administrator that approved the [join request »](https://core.telegram.org/api/invites#join-requests) of the user| + + + +### Type: [ChatInviteImporter](/API_docs/types/ChatInviteImporter.html) + + +### Example: + +``` +$chatInviteImporter = ['_' => 'chatInviteImporter', 'requested' => Bool, 'via_chatlist' => Bool, 'user_id' => long, 'date' => int, 'about' => 'string', 'approved_by' => long]; +``` diff --git a/docs/API_docs/constructors/chatInvitePeek.md b/docs/API_docs/constructors/chatInvitePeek.md new file mode 100644 index 0000000000..ab89bb9748 --- /dev/null +++ b/docs/API_docs/constructors/chatInvitePeek.md @@ -0,0 +1,30 @@ +--- +title: "chatInvitePeek" +description: "A chat invitation that also allows peeking into the group to read messages without joining it." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatInvitePeek +[Back to constructors index](/API_docs/constructors/index.html) + + + +A chat invitation that also allows peeking into the group to read messages without joining it. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat|[Chat](/API_docs/types/Chat.html) | Optional|Chat information| +|expires|[int](/API_docs/types/int.html) | Yes|Read-only anonymous access to this group will be revoked at this date| + + + +### Type: [ChatInvite](/API_docs/types/ChatInvite.html) + + +### Example: + +``` +$chatInvitePeek = ['_' => 'chatInvitePeek', 'chat' => Chat, 'expires' => int]; +``` diff --git a/docs/API_docs/constructors/chatInvitePublicJoinRequests.md b/docs/API_docs/constructors/chatInvitePublicJoinRequests.md new file mode 100644 index 0000000000..44801f7c98 --- /dev/null +++ b/docs/API_docs/constructors/chatInvitePublicJoinRequests.md @@ -0,0 +1,24 @@ +--- +title: "chatInvitePublicJoinRequests" +description: "Used in updates and in the channel log to indicate when a user is requesting to join or has joined a discussion group" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatInvitePublicJoinRequests +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used in updates and in the channel log to indicate when a user is requesting to join or has joined a [discussion group](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group) + + + + +### Type: [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) + + +### Example: + +``` +$chatInvitePublicJoinRequests = ['_' => 'chatInvitePublicJoinRequests']; +``` diff --git a/docs/API_docs/constructors/chatOnlines.md b/docs/API_docs/constructors/chatOnlines.md new file mode 100644 index 0000000000..dd734953ae --- /dev/null +++ b/docs/API_docs/constructors/chatOnlines.md @@ -0,0 +1,29 @@ +--- +title: "chatOnlines" +description: "Number of online users in a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatOnlines +[Back to constructors index](/API_docs/constructors/index.html) + + + +Number of online users in a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|onlines|[int](/API_docs/types/int.html) | Yes|Number of online users| + + + +### Type: [ChatOnlines](/API_docs/types/ChatOnlines.html) + + +### Example: + +``` +$chatOnlines = ['_' => 'chatOnlines', 'onlines' => int]; +``` diff --git a/docs/API_docs/constructors/chatParticipant.md b/docs/API_docs/constructors/chatParticipant.md new file mode 100644 index 0000000000..d9d9e3b561 --- /dev/null +++ b/docs/API_docs/constructors/chatParticipant.md @@ -0,0 +1,31 @@ +--- +title: "chatParticipant" +description: "Group member." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatParticipant +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group member. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|Member user ID| +|inviter\_id|[long](/API_docs/types/long.html) | Yes|ID of the user that added the member to the group| +|date|[int](/API_docs/types/int.html) | Yes|Date added to the group| + + + +### Type: [ChatParticipant](/API_docs/types/ChatParticipant.html) + + +### Example: + +``` +$chatParticipant = ['_' => 'chatParticipant', 'user_id' => long, 'inviter_id' => long, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/chatParticipantAdmin.md b/docs/API_docs/constructors/chatParticipantAdmin.md new file mode 100644 index 0000000000..7219deaa01 --- /dev/null +++ b/docs/API_docs/constructors/chatParticipantAdmin.md @@ -0,0 +1,31 @@ +--- +title: "chatParticipantAdmin" +description: "Chat admin" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatParticipantAdmin +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat admin + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of a group member that is admin| +|inviter\_id|[long](/API_docs/types/long.html) | Yes|ID of the user that added the member to the group| +|date|[int](/API_docs/types/int.html) | Yes|Date when the user was added| + + + +### Type: [ChatParticipant](/API_docs/types/ChatParticipant.html) + + +### Example: + +``` +$chatParticipantAdmin = ['_' => 'chatParticipantAdmin', 'user_id' => long, 'inviter_id' => long, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/chatParticipantCreator.md b/docs/API_docs/constructors/chatParticipantCreator.md new file mode 100644 index 0000000000..b60e0f7f61 --- /dev/null +++ b/docs/API_docs/constructors/chatParticipantCreator.md @@ -0,0 +1,29 @@ +--- +title: "chatParticipantCreator" +description: "Represents the creator of the group" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatParticipantCreator +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents the creator of the group + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of the user that created the group| + + + +### Type: [ChatParticipant](/API_docs/types/ChatParticipant.html) + + +### Example: + +``` +$chatParticipantCreator = ['_' => 'chatParticipantCreator', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/chatParticipants.md b/docs/API_docs/constructors/chatParticipants.md new file mode 100644 index 0000000000..664e7c4d60 --- /dev/null +++ b/docs/API_docs/constructors/chatParticipants.md @@ -0,0 +1,31 @@ +--- +title: "chatParticipants" +description: "Group members." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group members. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Group identifier| +|participants|Array of [ChatParticipant](/API_docs/types/ChatParticipant.html) | Yes|List of group members| +|version|[int](/API_docs/types/int.html) | Yes|Group version number| + + + +### Type: [ChatParticipants](/API_docs/types/ChatParticipants.html) + + +### Example: + +``` +$chatParticipants = ['_' => 'chatParticipants', 'chat_id' => long, 'participants' => [ChatParticipant, ChatParticipant], 'version' => int]; +``` diff --git a/docs/API_docs/constructors/chatParticipantsForbidden.md b/docs/API_docs/constructors/chatParticipantsForbidden.md new file mode 100644 index 0000000000..fde2f7a14a --- /dev/null +++ b/docs/API_docs/constructors/chatParticipantsForbidden.md @@ -0,0 +1,30 @@ +--- +title: "chatParticipantsForbidden" +description: "Info on members is unavailable" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatParticipantsForbidden +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info on members is unavailable + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Group ID| +|self\_participant|[ChatParticipant](/API_docs/types/ChatParticipant.html) | Optional|Info about the group membership of the current user| + + + +### Type: [ChatParticipants](/API_docs/types/ChatParticipants.html) + + +### Example: + +``` +$chatParticipantsForbidden = ['_' => 'chatParticipantsForbidden', 'chat_id' => long, 'self_participant' => ChatParticipant]; +``` diff --git a/docs/API_docs/constructors/chatPhoto.md b/docs/API_docs/constructors/chatPhoto.md new file mode 100644 index 0000000000..e1880dca31 --- /dev/null +++ b/docs/API_docs/constructors/chatPhoto.md @@ -0,0 +1,32 @@ +--- +title: "chatPhoto" +description: "Group profile photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group profile photo. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_video|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user has an animated profile picture| +|photo\_id|[long](/API_docs/types/long.html) | Yes|Photo ID| +|stripped\_thumb|[bytes](/API_docs/types/bytes.html) | Optional|[Stripped thumbnail](https://core.telegram.org/api/files#stripped-thumbnails)| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC where this photo is stored| + + + +### Type: [ChatPhoto](/API_docs/types/ChatPhoto.html) + + +### Example: + +``` +$chatPhoto = ['_' => 'chatPhoto', 'has_video' => Bool, 'photo_id' => long, 'stripped_thumb' => 'bytes', 'dc_id' => int]; +``` diff --git a/docs/API_docs/constructors/chatPhotoEmpty.md b/docs/API_docs/constructors/chatPhotoEmpty.md new file mode 100644 index 0000000000..03bf5994c6 --- /dev/null +++ b/docs/API_docs/constructors/chatPhotoEmpty.md @@ -0,0 +1,24 @@ +--- +title: "chatPhotoEmpty" +description: "Group photo is not set." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatPhotoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group photo is not set. + + + + +### Type: [ChatPhoto](/API_docs/types/ChatPhoto.html) + + +### Example: + +``` +$chatPhotoEmpty = ['_' => 'chatPhotoEmpty']; +``` diff --git a/docs/API_docs/constructors/chatReactionsAll.md b/docs/API_docs/constructors/chatReactionsAll.md new file mode 100644 index 0000000000..35764922e4 --- /dev/null +++ b/docs/API_docs/constructors/chatReactionsAll.md @@ -0,0 +1,29 @@ +--- +title: "chatReactionsAll" +description: "All reactions or all non-custom reactions are allowed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatReactionsAll +[Back to constructors index](/API_docs/constructors/index.html) + + + +All reactions or all non-custom reactions are allowed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|allow\_custom|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow custom reactions| + + + +### Type: [ChatReactions](/API_docs/types/ChatReactions.html) + + +### Example: + +``` +$chatReactionsAll = ['_' => 'chatReactionsAll', 'allow_custom' => Bool]; +``` diff --git a/docs/API_docs/constructors/chatReactionsNone.md b/docs/API_docs/constructors/chatReactionsNone.md new file mode 100644 index 0000000000..7dd57ce0bb --- /dev/null +++ b/docs/API_docs/constructors/chatReactionsNone.md @@ -0,0 +1,24 @@ +--- +title: "chatReactionsNone" +description: "No reactions are allowed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatReactionsNone +[Back to constructors index](/API_docs/constructors/index.html) + + + +No reactions are allowed + + + + +### Type: [ChatReactions](/API_docs/types/ChatReactions.html) + + +### Example: + +``` +$chatReactionsNone = ['_' => 'chatReactionsNone']; +``` diff --git a/docs/API_docs/constructors/chatReactionsSome.md b/docs/API_docs/constructors/chatReactionsSome.md new file mode 100644 index 0000000000..264f7c614e --- /dev/null +++ b/docs/API_docs/constructors/chatReactionsSome.md @@ -0,0 +1,29 @@ +--- +title: "chatReactionsSome" +description: "Some reactions are allowed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: chatReactionsSome +[Back to constructors index](/API_docs/constructors/index.html) + + + +Some reactions are allowed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|reactions|Array of [Reaction](/API_docs/types/Reaction.html) | Yes|Allowed set of reactions: the [reactions\_in\_chat\_max](https://core.telegram.org/api/config#reactions-in-chat-max) configuration field indicates the maximum number of reactions that can be specified in this field.| + + + +### Type: [ChatReactions](/API_docs/types/ChatReactions.html) + + +### Example: + +``` +$chatReactionsSome = ['_' => 'chatReactionsSome', 'reactions' => [Reaction, Reaction]]; +``` diff --git a/docs/API_docs/constructors/chatlists.chatlistInvite.md b/docs/API_docs/constructors/chatlists.chatlistInvite.md new file mode 100644 index 0000000000..b52366d0c4 --- /dev/null +++ b/docs/API_docs/constructors/chatlists.chatlistInvite.md @@ -0,0 +1,34 @@ +--- +title: "chatlists.chatlistInvite" +description: "Info about a chat folder deep link »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/chatlists_chatlistInvite.html +--- +# Constructor: chatlists.chatlistInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Name of the link| +|emoticon|[string](/API_docs/types/string.html) | Optional|Emoji to use as icon for the folder.| +|peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|Supergroups and channels to join| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Related chat information| +|users|Array of [User](/API_docs/types/User.html) | Yes|Related user information| + + + +### Type: [chatlists.ChatlistInvite](/API_docs/types/chatlists.ChatlistInvite.html) + + +### Example: + +``` +$chatlists_chatlistInvite = ['_' => 'chatlists.chatlistInvite', 'title' => 'string', 'emoticon' => 'string', 'peers' => [Peer, Peer], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/chatlists.chatlistInviteAlready.md b/docs/API_docs/constructors/chatlists.chatlistInviteAlready.md new file mode 100644 index 0000000000..6450f2f4e4 --- /dev/null +++ b/docs/API_docs/constructors/chatlists.chatlistInviteAlready.md @@ -0,0 +1,34 @@ +--- +title: "chatlists.chatlistInviteAlready" +description: "Updated info about a chat folder deep link » we already imported." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/chatlists_chatlistInviteAlready.html +--- +# Constructor: chatlists.chatlistInviteAlready +[Back to constructors index](/API_docs/constructors/index.html) + + + +Updated info about a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links) we already imported. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|filter\_id|[int](/API_docs/types/int.html) | Yes|ID of the imported folder| +|missing\_peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|New peers to be imported| +|already\_peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|Peers that were already imported| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Related chat information| +|users|Array of [User](/API_docs/types/User.html) | Yes|Related user information| + + + +### Type: [chatlists.ChatlistInvite](/API_docs/types/chatlists.ChatlistInvite.html) + + +### Example: + +``` +$chatlists_chatlistInviteAlready = ['_' => 'chatlists.chatlistInviteAlready', 'filter_id' => int, 'missing_peers' => [Peer, Peer], 'already_peers' => [Peer, Peer], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/chatlists.chatlistUpdates.md b/docs/API_docs/constructors/chatlists.chatlistUpdates.md new file mode 100644 index 0000000000..21a4879b19 --- /dev/null +++ b/docs/API_docs/constructors/chatlists.chatlistUpdates.md @@ -0,0 +1,32 @@ +--- +title: "chatlists.chatlistUpdates" +description: "Updated information about a chat folder deep link »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/chatlists_chatlistUpdates.html +--- +# Constructor: chatlists.chatlistUpdates +[Back to constructors index](/API_docs/constructors/index.html) + + + +Updated information about a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|missing\_peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|New peers to join| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Related chat information| +|users|Array of [User](/API_docs/types/User.html) | Yes|Related user information| + + + +### Type: [chatlists.ChatlistUpdates](/API_docs/types/chatlists.ChatlistUpdates.html) + + +### Example: + +``` +$chatlists_chatlistUpdates = ['_' => 'chatlists.chatlistUpdates', 'missing_peers' => [Peer, Peer], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/chatlists.exportedChatlistInvite.md b/docs/API_docs/constructors/chatlists.exportedChatlistInvite.md new file mode 100644 index 0000000000..83ce6971a2 --- /dev/null +++ b/docs/API_docs/constructors/chatlists.exportedChatlistInvite.md @@ -0,0 +1,31 @@ +--- +title: "chatlists.exportedChatlistInvite" +description: "Info about an exported chat folder deep link »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/chatlists_exportedChatlistInvite.html +--- +# Constructor: chatlists.exportedChatlistInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about an exported [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|filter|[DialogFilter](/API_docs/types/DialogFilter.html) | Yes|Folder ID| +|invite|[ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html) | Yes|The exported [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links).| + + + +### Type: [chatlists.ExportedChatlistInvite](/API_docs/types/chatlists.ExportedChatlistInvite.html) + + +### Example: + +``` +$chatlists_exportedChatlistInvite = ['_' => 'chatlists.exportedChatlistInvite', 'filter' => DialogFilter, 'invite' => ExportedChatlistInvite]; +``` diff --git a/docs/API_docs/constructors/chatlists.exportedInvites.md b/docs/API_docs/constructors/chatlists.exportedInvites.md new file mode 100644 index 0000000000..0ddd0fdf83 --- /dev/null +++ b/docs/API_docs/constructors/chatlists.exportedInvites.md @@ -0,0 +1,32 @@ +--- +title: "chatlists.exportedInvites" +description: "Info about multiple chat folder deep links »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/chatlists_exportedInvites.html +--- +# Constructor: chatlists.exportedInvites +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about multiple [chat folder deep links »](https://core.telegram.org/api/links#chat-folder-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invites|Array of [ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html) | Yes|The [chat folder deep links »](https://core.telegram.org/api/links#chat-folder-links).| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Related chat information| +|users|Array of [User](/API_docs/types/User.html) | Yes|Related user information| + + + +### Type: [chatlists.ExportedInvites](/API_docs/types/chatlists.ExportedInvites.html) + + +### Example: + +``` +$chatlists_exportedInvites = ['_' => 'chatlists.exportedInvites', 'invites' => [ExportedChatlistInvite, ExportedChatlistInvite], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/codeSettings.md b/docs/API_docs/constructors/codeSettings.md new file mode 100644 index 0000000000..4df2de6eef --- /dev/null +++ b/docs/API_docs/constructors/codeSettings.md @@ -0,0 +1,39 @@ +--- +title: "codeSettings" +description: "Settings used by telegram servers for sending the confirm code." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: codeSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Settings used by telegram servers for sending the confirm code. + +Example implementations: [telegram for android](https://github.com/DrKLO/Telegram/blob/master/TMessagesProj/src/main/java/org/telegram/ui/LoginActivity.java), [tdlib](https://github.com/tdlib/td/tree/master/td/telegram/SendCodeHelper.cpp). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|allow\_flashcall|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow phone verification via [phone calls](https://core.telegram.org/api/auth).| +|current\_number|[Bool](/API_docs/types/Bool.html) | Optional|Pass true if the phone number is used on the current device. Ignored if allow\_flashcall is not set.| +|allow\_app\_hash|[Bool](/API_docs/types/Bool.html) | Optional|If a token that will be included in eventually sent SMSs is required: required in newer versions of android, to use the [android SMS receiver APIs](https://developers.google.com/identity/sms-retriever/overview)| +|allow\_missed\_call|[Bool](/API_docs/types/Bool.html) | Optional|Whether this device supports receiving the code using the [auth.codeTypeMissedCall](../constructors/auth.codeTypeMissedCall.html) method| +|allow\_firebase|[Bool](/API_docs/types/Bool.html) | Optional|Whether Firebase auth is supported| +|unknown\_number|[Bool](/API_docs/types/Bool.html) | Optional| +|logout\_tokens|Array of [bytes](/API_docs/types/bytes.html) | Optional|Previously stored future auth tokens, see [the documentation for more info »](https://core.telegram.org/api/auth#future-auth-tokens)| +|token|[string](/API_docs/types/string.html) | Optional|Used only by official iOS apps for Firebase auth: device token for apple push.| +|app\_sandbox|[Bool](/API_docs/types/Bool.html) | Optional|Used only by official iOS apps for firebase auth: whether a sandbox-certificate will be used during transmission of the push notification.| + + + +### Type: [CodeSettings](/API_docs/types/CodeSettings.html) + + +### Example: + +``` +$codeSettings = ['_' => 'codeSettings', 'allow_flashcall' => Bool, 'current_number' => Bool, 'allow_app_hash' => Bool, 'allow_missed_call' => Bool, 'allow_firebase' => Bool, 'unknown_number' => Bool, 'logout_tokens' => ['bytes', 'bytes'], 'token' => 'string', 'app_sandbox' => Bool]; +``` diff --git a/docs/API_docs/constructors/config.md b/docs/API_docs/constructors/config.md new file mode 100644 index 0000000000..4b9c646408 --- /dev/null +++ b/docs/API_docs/constructors/config.md @@ -0,0 +1,75 @@ +--- +title: "config" +description: "Current configuration" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: config +[Back to constructors index](/API_docs/constructors/index.html) + + + +Current configuration + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|default\_p2p\_contacts|[Bool](/API_docs/types/Bool.html) | Optional|Whether the client should use P2P by default for phone calls with contacts| +|preload\_featured\_stickers|[Bool](/API_docs/types/Bool.html) | Optional|Whether the client should preload featured stickers| +|revoke\_pm\_inbox|[Bool](/API_docs/types/Bool.html) | Optional|Whether incoming private messages can be deleted for both participants| +|blocked\_mode|[Bool](/API_docs/types/Bool.html) | Optional|Indicates that telegram is *probably* censored by governments/ISPs in the current region| +|force\_try\_ipv6|[Bool](/API_docs/types/Bool.html) | Optional|Whether to forcefully connect using IPv6 [dcOptions](../types/DcOption.html), even if the client knows that IPv4 is available.| +|date|[int](/API_docs/types/int.html) | Yes|Current date at the server| +|expires|[int](/API_docs/types/int.html) | Yes|Expiration date of this config: when it expires it'll have to be refetched using [help.getConfig](../methods/help.getConfig.html)| +|test\_mode|[Bool](/API_docs/types/Bool.html) | Yes|Whether we're connected to the test DCs| +|this\_dc|[int](/API_docs/types/int.html) | Yes|ID of the DC that returned the reply| +|dc\_options|Array of [DcOption](/API_docs/types/DcOption.html) | Yes|DC IP list| +|dc\_txt\_domain\_name|[string](/API_docs/types/string.html) | Yes|Domain name for fetching encrypted DC list from DNS TXT record| +|chat\_size\_max|[int](/API_docs/types/int.html) | Yes|Maximum member count for normal [groups](https://core.telegram.org/api/channel)| +|megagroup\_size\_max|[int](/API_docs/types/int.html) | Yes|Maximum member count for [supergroups](https://core.telegram.org/api/channel)| +|forwarded\_count\_max|[int](/API_docs/types/int.html) | Yes|Maximum number of messages that can be forwarded at once using [messages.forwardMessages](../methods/messages.forwardMessages.html).| +|online\_update\_period\_ms|[int](/API_docs/types/int.html) | Yes|The client should [update its online status](../methods/account.updateStatus.html) every N milliseconds| +|offline\_blur\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|Delay before offline status needs to be sent to the server| +|offline\_idle\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|Time without any user activity after which it should be treated offline| +|online\_cloud\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|If we are offline, but were online from some other client in last `online_cloud_timeout_ms` milliseconds after we had gone offline, then delay offline notification for `notify_cloud_delay_ms` milliseconds.| +|notify\_cloud\_delay\_ms|[int](/API_docs/types/int.html) | Yes|If we are offline, but online from some other client then delay sending the offline notification for `notify_cloud_delay_ms` milliseconds.| +|notify\_default\_delay\_ms|[int](/API_docs/types/int.html) | Yes|If some other client is online, then delay notification for `notification_default_delay_ms` milliseconds| +|push\_chat\_period\_ms|[int](/API_docs/types/int.html) | Yes|Not for client use| +|push\_chat\_limit|[int](/API_docs/types/int.html) | Yes|Not for client use| +|edit\_time\_limit|[int](/API_docs/types/int.html) | Yes|Only messages with age smaller than the one specified can be edited| +|revoke\_time\_limit|[int](/API_docs/types/int.html) | Yes|Only channel/supergroup messages with age smaller than the specified can be deleted| +|revoke\_pm\_time\_limit|[int](/API_docs/types/int.html) | Yes|Only private messages with age smaller than the specified can be deleted| +|rating\_e\_decay|[int](/API_docs/types/int.html) | Yes|Exponential decay rate for computing [top peer rating](https://core.telegram.org/api/top-rating)| +|stickers\_recent\_limit|[int](/API_docs/types/int.html) | Yes|Maximum number of recent stickers| +|channels\_read\_media\_period|[int](/API_docs/types/int.html) | Yes|Indicates that round videos (video notes) and voice messages sent in channels and older than the specified period must be marked as read| +|tmp\_sessions|[int](/API_docs/types/int.html) | Optional|Temporary [passport](https://core.telegram.org/passport) sessions| +|call\_receive\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|Maximum allowed outgoing ring time in VoIP calls: if the user we're calling doesn't reply within the specified time (in milliseconds), we should hang up the call| +|call\_ring\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|Maximum allowed incoming ring time in VoIP calls: if the current user doesn't reply within the specified time (in milliseconds), the call will be automatically refused| +|call\_connect\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|VoIP connection timeout: if the instance of libtgvoip on the other side of the call doesn't connect to our instance of libtgvoip within the specified time (in milliseconds), the call must be aborted| +|call\_packet\_timeout\_ms|[int](/API_docs/types/int.html) | Yes|If during a VoIP call a packet isn't received for the specified period of time, the call must be aborted| +|me\_url\_prefix|[string](/API_docs/types/string.html) | Yes|The domain to use to parse [deep links »](https://core.telegram.org/api/links).| +|autoupdate\_url\_prefix|[string](/API_docs/types/string.html) | Optional|URL to use to auto-update the current app| +|gif\_search\_username|[string](/API_docs/types/string.html) | Optional|Username of the bot to use to search for GIFs| +|venue\_search\_username|[string](/API_docs/types/string.html) | Optional|Username of the bot to use to search for venues| +|img\_search\_username|[string](/API_docs/types/string.html) | Optional|Username of the bot to use for image search| +|static\_maps\_provider|[string](/API_docs/types/string.html) | Optional|ID of the map provider to use for venues| +|caption\_length\_max|[int](/API_docs/types/int.html) | Yes|Maximum length of caption (length in utf8 codepoints)| +|message\_length\_max|[int](/API_docs/types/int.html) | Yes|Maximum length of messages (length in utf8 codepoints)| +|webfile\_dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID to use to download [webfiles](https://core.telegram.org/api/files#downloading-webfiles)| +|suggested\_lang\_code|[string](/API_docs/types/string.html) | Optional|Suggested language code| +|lang\_pack\_version|[int](/API_docs/types/int.html) | Optional|Language pack version| +|base\_lang\_pack\_version|[int](/API_docs/types/int.html) | Optional|Basic language pack version| +|reactions\_default|[Reaction](/API_docs/types/Reaction.html) | Optional|Default [message reaction](https://core.telegram.org/api/reactions)| +|autologin\_token|[string](/API_docs/types/string.html) | Optional|Autologin token, [click here for more info on URL authorization »](https://core.telegram.org/api/url-authorization#link-url-authorization).| + + + +### Type: [Config](/API_docs/types/Config.html) + + +### Example: + +``` +$config = ['_' => 'config', 'default_p2p_contacts' => Bool, 'preload_featured_stickers' => Bool, 'revoke_pm_inbox' => Bool, 'blocked_mode' => Bool, 'force_try_ipv6' => Bool, 'date' => int, 'expires' => int, 'test_mode' => Bool, 'this_dc' => int, 'dc_options' => [DcOption, DcOption], 'dc_txt_domain_name' => 'string', 'chat_size_max' => int, 'megagroup_size_max' => int, 'forwarded_count_max' => int, 'online_update_period_ms' => int, 'offline_blur_timeout_ms' => int, 'offline_idle_timeout_ms' => int, 'online_cloud_timeout_ms' => int, 'notify_cloud_delay_ms' => int, 'notify_default_delay_ms' => int, 'push_chat_period_ms' => int, 'push_chat_limit' => int, 'edit_time_limit' => int, 'revoke_time_limit' => int, 'revoke_pm_time_limit' => int, 'rating_e_decay' => int, 'stickers_recent_limit' => int, 'channels_read_media_period' => int, 'tmp_sessions' => int, 'call_receive_timeout_ms' => int, 'call_ring_timeout_ms' => int, 'call_connect_timeout_ms' => int, 'call_packet_timeout_ms' => int, 'me_url_prefix' => 'string', 'autoupdate_url_prefix' => 'string', 'gif_search_username' => 'string', 'venue_search_username' => 'string', 'img_search_username' => 'string', 'static_maps_provider' => 'string', 'caption_length_max' => int, 'message_length_max' => int, 'webfile_dc_id' => int, 'suggested_lang_code' => 'string', 'lang_pack_version' => int, 'base_lang_pack_version' => int, 'reactions_default' => Reaction, 'autologin_token' => 'string']; +``` diff --git a/docs/API_docs/constructors/connectedBot.md b/docs/API_docs/constructors/connectedBot.md new file mode 100644 index 0000000000..e5d964f88d --- /dev/null +++ b/docs/API_docs/constructors/connectedBot.md @@ -0,0 +1,29 @@ +--- +title: "connectedBot" +description: "connectedBot attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: connectedBot +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|can\_reply|[Bool](/API_docs/types/Bool.html) | Optional| +|bot\_id|[long](/API_docs/types/long.html) | Yes| +|recipients|[BusinessBotRecipients](/API_docs/types/BusinessBotRecipients.html) | Yes| + + + +### Type: [ConnectedBot](/API_docs/types/ConnectedBot.html) + + +### Example: + +``` +$connectedBot = ['_' => 'connectedBot', 'can_reply' => Bool, 'bot_id' => long, 'recipients' => BusinessBotRecipients]; +``` diff --git a/docs/API_docs/constructors/contact.md b/docs/API_docs/constructors/contact.md new file mode 100644 index 0000000000..b802e3d508 --- /dev/null +++ b/docs/API_docs/constructors/contact.md @@ -0,0 +1,30 @@ +--- +title: "contact" +description: "A contact of the current user that is registered in the system." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: contact +[Back to constructors index](/API_docs/constructors/index.html) + + + +A contact of the current user that is registered in the system. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|mutual|[Bool](/API_docs/types/Bool.html) | Yes|Current user is in the user's contact list| + + + +### Type: [Contact](/API_docs/types/Contact.html) + + +### Example: + +``` +$contact = ['_' => 'contact', 'user_id' => long, 'mutual' => Bool]; +``` diff --git a/docs/API_docs/constructors/contactBirthday.md b/docs/API_docs/constructors/contactBirthday.md new file mode 100644 index 0000000000..129c383b09 --- /dev/null +++ b/docs/API_docs/constructors/contactBirthday.md @@ -0,0 +1,28 @@ +--- +title: "contactBirthday" +description: "contactBirthday attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: contactBirthday +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|contact\_id|[long](/API_docs/types/long.html) | Yes| +|birthday|[Birthday](/API_docs/types/Birthday.html) | Yes| + + + +### Type: [ContactBirthday](/API_docs/types/ContactBirthday.html) + + +### Example: + +``` +$contactBirthday = ['_' => 'contactBirthday', 'contact_id' => long, 'birthday' => Birthday]; +``` diff --git a/docs/API_docs/constructors/contactStatus.md b/docs/API_docs/constructors/contactStatus.md new file mode 100644 index 0000000000..fbac9eb8cf --- /dev/null +++ b/docs/API_docs/constructors/contactStatus.md @@ -0,0 +1,30 @@ +--- +title: "contactStatus" +description: "Contact status: online / offline." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: contactStatus +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contact status: online / offline. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|status|[UserStatus](/API_docs/types/UserStatus.html) | Optional|Online status| + + + +### Type: [ContactStatus](/API_docs/types/ContactStatus.html) + + +### Example: + +``` +$contactStatus = ['_' => 'contactStatus', 'user_id' => long, 'status' => UserStatus]; +``` diff --git a/docs/API_docs/constructors/contacts.blocked.md b/docs/API_docs/constructors/contacts.blocked.md new file mode 100644 index 0000000000..813a4f990a --- /dev/null +++ b/docs/API_docs/constructors/contacts.blocked.md @@ -0,0 +1,32 @@ +--- +title: "contacts.blocked" +description: "Full list of blocked users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_blocked.html +--- +# Constructor: contacts.blocked +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full list of blocked users. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blocked|Array of [PeerBlocked](/API_docs/types/PeerBlocked.html) | Yes|List of blocked users| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Blocked chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users| + + + +### Type: [contacts.Blocked](/API_docs/types/contacts.Blocked.html) + + +### Example: + +``` +$contacts_blocked = ['_' => 'contacts.blocked', 'blocked' => [PeerBlocked, PeerBlocked], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.blockedSlice.md b/docs/API_docs/constructors/contacts.blockedSlice.md new file mode 100644 index 0000000000..9c2f852249 --- /dev/null +++ b/docs/API_docs/constructors/contacts.blockedSlice.md @@ -0,0 +1,33 @@ +--- +title: "contacts.blockedSlice" +description: "Incomplete list of blocked users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_blockedSlice.html +--- +# Constructor: contacts.blockedSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incomplete list of blocked users. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of elements in the list| +|blocked|Array of [PeerBlocked](/API_docs/types/PeerBlocked.html) | Yes|List of blocked users| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Blocked chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users| + + + +### Type: [contacts.Blocked](/API_docs/types/contacts.Blocked.html) + + +### Example: + +``` +$contacts_blockedSlice = ['_' => 'contacts.blockedSlice', 'count' => int, 'blocked' => [PeerBlocked, PeerBlocked], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.contactBirthdays.md b/docs/API_docs/constructors/contacts.contactBirthdays.md new file mode 100644 index 0000000000..3e7b50beb2 --- /dev/null +++ b/docs/API_docs/constructors/contacts.contactBirthdays.md @@ -0,0 +1,29 @@ +--- +title: "contacts.contactBirthdays" +description: "contacts.contactBirthdays attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_contactBirthdays.html +--- +# Constructor: contacts.contactBirthdays +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|contacts|Array of [ContactBirthday](/API_docs/types/ContactBirthday.html) | Yes| +|users|Array of [User](/API_docs/types/User.html) | Yes| + + + +### Type: [contacts.ContactBirthdays](/API_docs/types/contacts.ContactBirthdays.html) + + +### Example: + +``` +$contacts_contactBirthdays = ['_' => 'contacts.contactBirthdays', 'contacts' => [ContactBirthday, ContactBirthday], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.contacts.md b/docs/API_docs/constructors/contacts.contacts.md new file mode 100644 index 0000000000..4422dae473 --- /dev/null +++ b/docs/API_docs/constructors/contacts.contacts.md @@ -0,0 +1,32 @@ +--- +title: "contacts.contacts" +description: "The current user's contact list and info on users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_contacts.html +--- +# Constructor: contacts.contacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +The current user's contact list and info on users. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|contacts|Array of [Contact](/API_docs/types/Contact.html) | Yes|Contact list| +|saved\_count|[int](/API_docs/types/int.html) | Yes|Number of contacts that were saved successfully| +|users|Array of [User](/API_docs/types/User.html) | Yes|User list| + + + +### Type: [contacts.Contacts](/API_docs/types/contacts.Contacts.html) + + +### Example: + +``` +$contacts_contacts = ['_' => 'contacts.contacts', 'contacts' => [Contact, Contact], 'saved_count' => int, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.contactsNotModified.md b/docs/API_docs/constructors/contacts.contactsNotModified.md new file mode 100644 index 0000000000..90dff4ea78 --- /dev/null +++ b/docs/API_docs/constructors/contacts.contactsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "contacts.contactsNotModified" +description: "Contact list on the server is the same as the list on the client." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_contactsNotModified.html +--- +# Constructor: contacts.contactsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contact list on the server is the same as the list on the client. + + + + +### Type: [contacts.Contacts](/API_docs/types/contacts.Contacts.html) + + +### Example: + +``` +$contacts_contactsNotModified = ['_' => 'contacts.contactsNotModified']; +``` diff --git a/docs/API_docs/constructors/contacts.found.md b/docs/API_docs/constructors/contacts.found.md new file mode 100644 index 0000000000..9e3ca8b5bf --- /dev/null +++ b/docs/API_docs/constructors/contacts.found.md @@ -0,0 +1,33 @@ +--- +title: "contacts.found" +description: "Users found by name substring and auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_found.html +--- +# Constructor: contacts.found +[Back to constructors index](/API_docs/constructors/index.html) + + + +Users found by name substring and auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|my\_results|Array of [Peer](/API_docs/types/Peer.html) | Yes|Personalized results| +|results|Array of [Peer](/API_docs/types/Peer.html) | Yes|List of found user identifiers| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Found chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users| + + + +### Type: [contacts.Found](/API_docs/types/contacts.Found.html) + + +### Example: + +``` +$contacts_found = ['_' => 'contacts.found', 'my_results' => [Peer, Peer], 'results' => [Peer, Peer], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.importedContacts.md b/docs/API_docs/constructors/contacts.importedContacts.md new file mode 100644 index 0000000000..ac7a9524ef --- /dev/null +++ b/docs/API_docs/constructors/contacts.importedContacts.md @@ -0,0 +1,33 @@ +--- +title: "contacts.importedContacts" +description: "Info on successfully imported contacts." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_importedContacts.html +--- +# Constructor: contacts.importedContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info on successfully imported contacts. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|imported|Array of [ImportedContact](/API_docs/types/ImportedContact.html) | Yes|List of successfully imported contacts| +|popular\_invites|Array of [PopularContact](/API_docs/types/PopularContact.html) | Yes|Popular contacts| +|retry\_contacts|Array of [long](/API_docs/types/long.html) | Yes|List of contact ids that could not be imported due to system limitation and will need to be imported at a later date.| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users| + + + +### Type: [contacts.ImportedContacts](/API_docs/types/contacts.ImportedContacts.html) + + +### Example: + +``` +$contacts_importedContacts = ['_' => 'contacts.importedContacts', 'imported' => [ImportedContact, ImportedContact], 'popular_invites' => [PopularContact, PopularContact], 'retry_contacts' => [long, long], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.resolvedPeer.md b/docs/API_docs/constructors/contacts.resolvedPeer.md new file mode 100644 index 0000000000..b2925179e6 --- /dev/null +++ b/docs/API_docs/constructors/contacts.resolvedPeer.md @@ -0,0 +1,32 @@ +--- +title: "contacts.resolvedPeer" +description: "Resolved peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_resolvedPeer.html +--- +# Constructor: contacts.resolvedPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Resolved peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [contacts.ResolvedPeer](/API_docs/types/contacts.ResolvedPeer.html) + + +### Example: + +``` +$contacts_resolvedPeer = ['_' => 'contacts.resolvedPeer', 'peer' => long, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.topPeers.md b/docs/API_docs/constructors/contacts.topPeers.md new file mode 100644 index 0000000000..5badba4c48 --- /dev/null +++ b/docs/API_docs/constructors/contacts.topPeers.md @@ -0,0 +1,32 @@ +--- +title: "contacts.topPeers" +description: "Top peers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_topPeers.html +--- +# Constructor: contacts.topPeers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Top peers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|categories|Array of [TopPeerCategoryPeers](/API_docs/types/TopPeerCategoryPeers.html) | Yes|Top peers by top peer category| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [contacts.TopPeers](/API_docs/types/contacts.TopPeers.html) + + +### Example: + +``` +$contacts_topPeers = ['_' => 'contacts.topPeers', 'categories' => [TopPeerCategoryPeers, TopPeerCategoryPeers], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/contacts.topPeersDisabled.md b/docs/API_docs/constructors/contacts.topPeersDisabled.md new file mode 100644 index 0000000000..c95563d5de --- /dev/null +++ b/docs/API_docs/constructors/contacts.topPeersDisabled.md @@ -0,0 +1,25 @@ +--- +title: "contacts.topPeersDisabled" +description: "Top peers disabled" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_topPeersDisabled.html +--- +# Constructor: contacts.topPeersDisabled +[Back to constructors index](/API_docs/constructors/index.html) + + + +Top peers disabled + + + + +### Type: [contacts.TopPeers](/API_docs/types/contacts.TopPeers.html) + + +### Example: + +``` +$contacts_topPeersDisabled = ['_' => 'contacts.topPeersDisabled']; +``` diff --git a/docs/API_docs/constructors/contacts.topPeersNotModified.md b/docs/API_docs/constructors/contacts.topPeersNotModified.md new file mode 100644 index 0000000000..7413ee6d73 --- /dev/null +++ b/docs/API_docs/constructors/contacts.topPeersNotModified.md @@ -0,0 +1,25 @@ +--- +title: "contacts.topPeersNotModified" +description: "Top peer info hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/contacts_topPeersNotModified.html +--- +# Constructor: contacts.topPeersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Top peer info hasn't changed + + + + +### Type: [contacts.TopPeers](/API_docs/types/contacts.TopPeers.html) + + +### Example: + +``` +$contacts_topPeersNotModified = ['_' => 'contacts.topPeersNotModified']; +``` diff --git a/docs/API_docs/constructors/dataJSON.md b/docs/API_docs/constructors/dataJSON.md new file mode 100644 index 0000000000..f9ac828ffd --- /dev/null +++ b/docs/API_docs/constructors/dataJSON.md @@ -0,0 +1,29 @@ +--- +title: "dataJSON" +description: "Represents a json-encoded object" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dataJSON +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a json-encoded object + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|data|[string](/API_docs/types/string.html) | Yes|JSON-encoded object| + + + +### Type: [DataJSON](/API_docs/types/DataJSON.html) + + +### Example: + +``` +$dataJSON = ['_' => 'dataJSON', 'data' => 'string']; +``` diff --git a/docs/API_docs/constructors/dcOption.md b/docs/API_docs/constructors/dcOption.md new file mode 100644 index 0000000000..1018477992 --- /dev/null +++ b/docs/API_docs/constructors/dcOption.md @@ -0,0 +1,38 @@ +--- +title: "dcOption" +description: "Data center" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dcOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Data center + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|ipv6|[Bool](/API_docs/types/Bool.html) | Optional|Whether the specified IP is an IPv6 address| +|media\_only|[Bool](/API_docs/types/Bool.html) | Optional|Whether this DC should only be used to [download or upload files](https://core.telegram.org/api/files)| +|tcpo\_only|[Bool](/API_docs/types/Bool.html) | Optional|Whether this DC only supports connection with [transport obfuscation](https://core.telegram.org/mtproto/mtproto-transports#transport-obfuscation)| +|cdn|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a [CDN DC](https://core.telegram.org/cdn).| +|static|[Bool](/API_docs/types/Bool.html) | Optional|If set, this IP should be used when connecting through a proxy| +|this\_port\_only|[Bool](/API_docs/types/Bool.html) | Optional|If set, clients must connect using only the specified port, without trying any other port.| +|id|[int](/API_docs/types/int.html) | Yes|DC ID| +|ip\_address|[string](/API_docs/types/string.html) | Yes|IP address of DC| +|port|[int](/API_docs/types/int.html) | Yes|Port| +|secret|[string](/API_docs/types/string.html) | Optional| + + + +### Type: [DcOption](/API_docs/types/DcOption.html) + + +### Example: + +``` +$dcOption = ['_' => 'dcOption', 'ipv6' => Bool, 'media_only' => Bool, 'tcpo_only' => Bool, 'cdn' => Bool, 'static' => Bool, 'this_port_only' => Bool, 'id' => int, 'ip_address' => 'string', 'port' => int, 'secret' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionAbortKey_20.md b/docs/API_docs/constructors/decryptedMessageActionAbortKey_20.md new file mode 100644 index 0000000000..f7c7892d46 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionAbortKey_20.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageActionAbortKey" +description: "Abort rekeying" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionAbortKey\_20 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Abort rekeying + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|exchange\_id|[long](/API_docs/types/long.html) | Yes|Exchange ID| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionAbortKey_20 = ['_' => 'decryptedMessageActionAbortKey', 'exchange_id' => long]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionAcceptKey_20.md b/docs/API_docs/constructors/decryptedMessageActionAcceptKey_20.md new file mode 100644 index 0000000000..3a672a85a6 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionAcceptKey_20.md @@ -0,0 +1,31 @@ +--- +title: "decryptedMessageActionAcceptKey" +description: "Accept new key" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionAcceptKey\_20 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Accept new key + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|exchange\_id|[long](/API_docs/types/long.html) | Yes|Exchange ID| +|g\_b|[bytes](/API_docs/types/bytes.html) | Yes|B parameter, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs)| +|key\_fingerprint|[long](/API_docs/types/long.html) | Yes|Key fingerprint, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs)| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionAcceptKey_20 = ['_' => 'decryptedMessageActionAcceptKey', 'exchange_id' => long, 'g_b' => 'bytes', 'key_fingerprint' => long]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionCommitKey_20.md b/docs/API_docs/constructors/decryptedMessageActionCommitKey_20.md new file mode 100644 index 0000000000..11df1af824 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionCommitKey_20.md @@ -0,0 +1,30 @@ +--- +title: "decryptedMessageActionCommitKey" +description: "Commit new key, see rekeying process" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionCommitKey\_20 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Commit new key, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|exchange\_id|[long](/API_docs/types/long.html) | Yes|Exchange ID, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs)| +|key\_fingerprint|[long](/API_docs/types/long.html) | Yes|Key fingerprint, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs)| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionCommitKey_20 = ['_' => 'decryptedMessageActionCommitKey', 'exchange_id' => long, 'key_fingerprint' => long]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionDeleteMessages_8.md b/docs/API_docs/constructors/decryptedMessageActionDeleteMessages_8.md new file mode 100644 index 0000000000..90834864b8 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionDeleteMessages_8.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageActionDeleteMessages" +description: "Deleted messages." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionDeleteMessages\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Deleted messages. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|random\_ids|Array of [long](/API_docs/types/long.html) | Yes|List of deleted message IDs| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionDeleteMessages_8 = ['_' => 'decryptedMessageActionDeleteMessages', 'random_ids' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionFlushHistory_8.md b/docs/API_docs/constructors/decryptedMessageActionFlushHistory_8.md new file mode 100644 index 0000000000..eeb4633ab0 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionFlushHistory_8.md @@ -0,0 +1,24 @@ +--- +title: "decryptedMessageActionFlushHistory" +description: "The entire message history has been deleted." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionFlushHistory\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +The entire message history has been deleted. + + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionFlushHistory_8 = ['_' => 'decryptedMessageActionFlushHistory']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionNoop_20.md b/docs/API_docs/constructors/decryptedMessageActionNoop_20.md new file mode 100644 index 0000000000..5405c70fb7 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionNoop_20.md @@ -0,0 +1,24 @@ +--- +title: "decryptedMessageActionNoop" +description: "NOOP action" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionNoop\_20 +[Back to constructors index](/API_docs/constructors/index.html) + + + +NOOP action + + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionNoop_20 = ['_' => 'decryptedMessageActionNoop']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionNotifyLayer_17.md b/docs/API_docs/constructors/decryptedMessageActionNotifyLayer_17.md new file mode 100644 index 0000000000..37c511b09c --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionNotifyLayer_17.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageActionNotifyLayer" +description: "A notification stating the API layer that is used by the client. You should use your current layer and take notice of the layer used on the other side of a conversation when sending messages." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionNotifyLayer\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +A notification stating the API layer that is used by the client. You should use your current layer and take notice of the layer used on the other side of a conversation when sending messages. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|layer|[int](/API_docs/types/int.html) | Yes|Layer number, must be **17** or higher (this constructor was introduced in Layer 17.| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionNotifyLayer_17 = ['_' => 'decryptedMessageActionNotifyLayer', 'layer' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionReadMessages_8.md b/docs/API_docs/constructors/decryptedMessageActionReadMessages_8.md new file mode 100644 index 0000000000..56528494e4 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionReadMessages_8.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageActionReadMessages" +description: "Messages marked as read." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionReadMessages\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Messages marked as read. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|random\_ids|Array of [long](/API_docs/types/long.html) | Yes|List of message IDs| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionReadMessages_8 = ['_' => 'decryptedMessageActionReadMessages', 'random_ids' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionRequestKey_20.md b/docs/API_docs/constructors/decryptedMessageActionRequestKey_20.md new file mode 100644 index 0000000000..3748d6eb96 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionRequestKey_20.md @@ -0,0 +1,30 @@ +--- +title: "decryptedMessageActionRequestKey" +description: "Request rekeying, see rekeying process" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionRequestKey\_20 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Request rekeying, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|exchange\_id|[long](/API_docs/types/long.html) | Yes|Exchange ID| +|g\_a|[bytes](/API_docs/types/bytes.html) | Yes|g\_a, see [rekeying process](https://core.telegram.org/api/end-to-end/pfs)| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionRequestKey_20 = ['_' => 'decryptedMessageActionRequestKey', 'exchange_id' => long, 'g_a' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionResend_17.md b/docs/API_docs/constructors/decryptedMessageActionResend_17.md new file mode 100644 index 0000000000..c291d49032 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionResend_17.md @@ -0,0 +1,30 @@ +--- +title: "decryptedMessageActionResend" +description: "Request for the other party in a Secret Chat to automatically resend a contiguous range of previously sent messages, as explained in Sequence number is Secret Chats." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionResend\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Request for the other party in a Secret Chat to automatically resend a contiguous range of previously sent messages, as explained in [Sequence number is Secret Chats](https://core.telegram.org/api/end-to-end/seq_no). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|start\_seq\_no|[int](/API_docs/types/int.html) | Yes|`out_seq_no` of the first message to be resent, with correct parity| +|end\_seq\_no|[int](/API_docs/types/int.html) | Yes|`out_seq_no` of the last message to be resent, with same parity.| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionResend_17 = ['_' => 'decryptedMessageActionResend', 'start_seq_no' => int, 'end_seq_no' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionScreenshotMessages_8.md b/docs/API_docs/constructors/decryptedMessageActionScreenshotMessages_8.md new file mode 100644 index 0000000000..d37a6c1fbb --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionScreenshotMessages_8.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageActionScreenshotMessages" +description: "A screenshot was taken." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionScreenshotMessages\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +A screenshot was taken. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|random\_ids|Array of [long](/API_docs/types/long.html) | Yes|List of affected message ids (that appeared on the screenshot)| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionScreenshotMessages_8 = ['_' => 'decryptedMessageActionScreenshotMessages', 'random_ids' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionSetMessageTTL_8.md b/docs/API_docs/constructors/decryptedMessageActionSetMessageTTL_8.md new file mode 100644 index 0000000000..9bf9241aef --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionSetMessageTTL_8.md @@ -0,0 +1,31 @@ +--- +title: "decryptedMessageActionSetMessageTTL" +description: "Setting of a message lifetime after reading." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionSetMessageTTL\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Setting of a message lifetime after reading. + +Upon receiving such message the client shall start deleting of all messages of an encrypted chat **ttl\_seconds** seconds after the messages were read by user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|ttl\_seconds|[int](/API_docs/types/int.html) | Yes|Lifetime in seconds| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionSetMessageTTL_8 = ['_' => 'decryptedMessageActionSetMessageTTL', 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageActionTyping_17.md b/docs/API_docs/constructors/decryptedMessageActionTyping_17.md new file mode 100644 index 0000000000..876038580b --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageActionTyping_17.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageActionTyping" +description: "User is preparing a message: typing, recording, uploading, etc." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageActionTyping\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is preparing a message: typing, recording, uploading, etc. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|action|[SendMessageAction](/API_docs/types/SendMessageAction.html) | Yes|Type of action| + + + +### Type: [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + + +### Example: + +``` +$decryptedMessageActionTyping_17 = ['_' => 'decryptedMessageActionTyping', 'action' => SendMessageAction]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageLayer_17.md b/docs/API_docs/constructors/decryptedMessageLayer_17.md new file mode 100644 index 0000000000..2c8910bb47 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageLayer_17.md @@ -0,0 +1,32 @@ +--- +title: "decryptedMessageLayer" +description: "Sets the layer number for the contents of an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageLayer\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Sets the layer number for the contents of an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|layer|[int](/API_docs/types/int.html) | Yes|Layer number. Mimimal value - **17** (the layer in which the constructor was added).| +|in\_seq\_no|[int](/API_docs/types/int.html) | Yes|2x the number of messages in the sender's inbox (including deleted and service messages), incremented by 1 if current user was not the chat creator
Parameter added in Layer 17.| +|out\_seq\_no|[int](/API_docs/types/int.html) | Yes|2x the number of messages in the recipient's inbox (including deleted and service messages), incremented by 1 if current user was the chat creator
Parameter added in Layer 17.| +|message|[DecryptedMessage](/API_docs/types/DecryptedMessage.html) | Yes|The content of message itself| + + + +### Type: [DecryptedMessageLayer](/API_docs/types/DecryptedMessageLayer.html) + + +### Example: + +``` +$decryptedMessageLayer_17 = ['_' => 'decryptedMessageLayer', 'layer' => int, 'in_seq_no' => int, 'out_seq_no' => int, 'message' => DecryptedMessage]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaAudio_17.md b/docs/API_docs/constructors/decryptedMessageMediaAudio_17.md new file mode 100644 index 0000000000..fe15160883 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaAudio_17.md @@ -0,0 +1,31 @@ +--- +title: "decryptedMessageMediaAudio" +description: "Audio file attached to a secret chat message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaAudio\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Audio file attached to a secret chat message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|duration|[int](/API_docs/types/int.html) | Yes|Audio duration in seconds| +|mime\_type|[string](/API_docs/types/string.html) | Yes|MIME-type of the audio file
Parameter added in Layer 13.| +|size|[int](/API_docs/types/int.html) | Yes|File size| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaAudio_17 = ['_' => 'decryptedMessageMediaAudio', 'duration' => int, 'mime_type' => 'string', 'size' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaAudio_8.md b/docs/API_docs/constructors/decryptedMessageMediaAudio_8.md new file mode 100644 index 0000000000..24b66043e9 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaAudio_8.md @@ -0,0 +1,30 @@ +--- +title: "decryptedMessageMediaAudio" +description: "Audio file attached to a secret chat message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaAudio\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Audio file attached to a secret chat message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|duration|[int](/API_docs/types/int.html) | Yes|Audio duration in seconds| +|size|[int](/API_docs/types/int.html) | Yes|File size| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaAudio_8 = ['_' => 'decryptedMessageMediaAudio', 'duration' => int, 'size' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaContact_8.md b/docs/API_docs/constructors/decryptedMessageMediaContact_8.md new file mode 100644 index 0000000000..1509a35a6f --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaContact_8.md @@ -0,0 +1,32 @@ +--- +title: "decryptedMessageMediaContact" +description: "Contact attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaContact\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contact attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|Contact's first name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Contact's last name| +|user\_id|[int](/API_docs/types/int.html) | Yes|Telegram User ID of signed-up contact| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaContact_8 = ['_' => 'decryptedMessageMediaContact', 'phone_number' => 'string', 'first_name' => 'string', 'last_name' => 'string', 'user_id' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaDocument_143.md b/docs/API_docs/constructors/decryptedMessageMediaDocument_143.md new file mode 100644 index 0000000000..9fc08612b9 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaDocument_143.md @@ -0,0 +1,35 @@ +--- +title: "decryptedMessageMediaDocument" +description: "Document attached to a message in a secret chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaDocument\_143 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document attached to a message in a secret chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Thumbnail-file contents (JPEG-file, quality 55, set in a 90x90 square)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|mime\_type|[string](/API_docs/types/string.html) | Yes|File MIME-type| +|size|[long](/API_docs/types/long.html) | Yes| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Document attributes for media types| +|caption|[string](/API_docs/types/string.html) | Yes|Caption| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaDocument_143 = ['_' => 'decryptedMessageMediaDocument', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'mime_type' => 'string', 'size' => long, 'attributes' => [DocumentAttribute, DocumentAttribute], 'caption' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaDocument_45.md b/docs/API_docs/constructors/decryptedMessageMediaDocument_45.md new file mode 100644 index 0000000000..f390eb12e1 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaDocument_45.md @@ -0,0 +1,35 @@ +--- +title: "decryptedMessageMediaDocument" +description: "Document attached to a message in a secret chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaDocument\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document attached to a message in a secret chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Thumbnail-file contents (JPEG-file, quality 55, set in a 90x90 square)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|mime\_type|[string](/API_docs/types/string.html) | Yes|File MIME-type| +|size|[int](/API_docs/types/int.html) | Yes| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Document attributes for media types| +|caption|[string](/API_docs/types/string.html) | Yes|Caption| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaDocument_45 = ['_' => 'decryptedMessageMediaDocument', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'mime_type' => 'string', 'size' => int, 'attributes' => [DocumentAttribute, DocumentAttribute], 'caption' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaDocument_8.md b/docs/API_docs/constructors/decryptedMessageMediaDocument_8.md new file mode 100644 index 0000000000..5bd3939854 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaDocument_8.md @@ -0,0 +1,34 @@ +--- +title: "decryptedMessageMediaDocument" +description: "Document attached to a message in a secret chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaDocument\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document attached to a message in a secret chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Thumbnail-file contents (JPEG-file, quality 55, set in a 90x90 square)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|file\_name|[string](/API_docs/types/string.html) | Yes| +|mime\_type|[string](/API_docs/types/string.html) | Yes|File MIME-type| +|size|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaDocument_8 = ['_' => 'decryptedMessageMediaDocument', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'file_name' => 'string', 'mime_type' => 'string', 'size' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaEmpty_8.md b/docs/API_docs/constructors/decryptedMessageMediaEmpty_8.md new file mode 100644 index 0000000000..8e9d61309b --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaEmpty_8.md @@ -0,0 +1,24 @@ +--- +title: "decryptedMessageMediaEmpty" +description: "Empty constructor, no media content." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaEmpty\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, no media content. + + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaEmpty_8 = ['_' => 'decryptedMessageMediaEmpty']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaExternalDocument_23.md b/docs/API_docs/constructors/decryptedMessageMediaExternalDocument_23.md new file mode 100644 index 0000000000..d47ea44e4e --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaExternalDocument_23.md @@ -0,0 +1,36 @@ +--- +title: "decryptedMessageMediaExternalDocument" +description: "Non-e2e documented forwarded from non-secret chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaExternalDocument\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Non-e2e documented forwarded from non-secret chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Document ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|access hash| +|date|[int](/API_docs/types/int.html) | Yes|Date| +|mime\_type|[string](/API_docs/types/string.html) | Yes|Mime type| +|size|[int](/API_docs/types/int.html) | Yes|Size| +|thumb|[PhotoSize](/API_docs/types/PhotoSize.html) | Optional|Thumbnail| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Attributes for media types| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaExternalDocument_23 = ['_' => 'decryptedMessageMediaExternalDocument', 'id' => long, 'access_hash' => long, 'date' => int, 'mime_type' => 'string', 'size' => int, 'thumb' => PhotoSize, 'dc_id' => int, 'attributes' => [DocumentAttribute, DocumentAttribute]]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaGeoPoint_8.md b/docs/API_docs/constructors/decryptedMessageMediaGeoPoint_8.md new file mode 100644 index 0000000000..edf2753227 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaGeoPoint_8.md @@ -0,0 +1,30 @@ +--- +title: "decryptedMessageMediaGeoPoint" +description: "GeoPoint attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaGeoPoint\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +GeoPoint attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lat|[double](/API_docs/types/double.html) | Yes|Latitude of point| +|long|[double](/API_docs/types/double.html) | Yes|Longitude of point| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaGeoPoint_8 = ['_' => 'decryptedMessageMediaGeoPoint', 'lat' => double, 'long' => double]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaPhoto_45.md b/docs/API_docs/constructors/decryptedMessageMediaPhoto_45.md new file mode 100644 index 0000000000..ceee87d35f --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaPhoto_45.md @@ -0,0 +1,35 @@ +--- +title: "decryptedMessageMediaPhoto" +description: "Photo attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaPhoto\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Photo attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|w|[int](/API_docs/types/int.html) | Yes|Photo width| +|h|[int](/API_docs/types/int.html) | Yes|Photo height| +|size|[int](/API_docs/types/int.html) | Yes|Size of the photo in bytes| +|caption|[string](/API_docs/types/string.html) | Yes|Caption| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaPhoto_45 = ['_' => 'decryptedMessageMediaPhoto', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'w' => int, 'h' => int, 'size' => int, 'caption' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaPhoto_8.md b/docs/API_docs/constructors/decryptedMessageMediaPhoto_8.md new file mode 100644 index 0000000000..e1bc208cd5 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaPhoto_8.md @@ -0,0 +1,34 @@ +--- +title: "decryptedMessageMediaPhoto" +description: "Photo attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaPhoto\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Photo attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|w|[int](/API_docs/types/int.html) | Yes|Photo width| +|h|[int](/API_docs/types/int.html) | Yes|Photo height| +|size|[int](/API_docs/types/int.html) | Yes|Size of the photo in bytes| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaPhoto_8 = ['_' => 'decryptedMessageMediaPhoto', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'w' => int, 'h' => int, 'size' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaVenue_45.md b/docs/API_docs/constructors/decryptedMessageMediaVenue_45.md new file mode 100644 index 0000000000..d28f7dcb85 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaVenue_45.md @@ -0,0 +1,34 @@ +--- +title: "decryptedMessageMediaVenue" +description: "Venue" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaVenue\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Venue + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lat|[double](/API_docs/types/double.html) | Yes|Latitude of venue| +|long|[double](/API_docs/types/double.html) | Yes|Longitude of venue| +|title|[string](/API_docs/types/string.html) | Yes|Venue name| +|address|[string](/API_docs/types/string.html) | Yes|Address| +|provider|[string](/API_docs/types/string.html) | Yes|Venue provider: currently only "foursquare" and "gplaces" (Google Places) need to be supported| +|venue\_id|[string](/API_docs/types/string.html) | Yes|Venue ID in the provider's database| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaVenue_45 = ['_' => 'decryptedMessageMediaVenue', 'lat' => double, 'long' => double, 'title' => 'string', 'address' => 'string', 'provider' => 'string', 'venue_id' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaVideo_17.md b/docs/API_docs/constructors/decryptedMessageMediaVideo_17.md new file mode 100644 index 0000000000..fa1b19d05e --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaVideo_17.md @@ -0,0 +1,36 @@ +--- +title: "decryptedMessageMediaVideo" +description: "Video attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaVideo\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Video attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Content of thumbnail file (JPEG file, quality 55, set in a square 90x90)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|duration|[int](/API_docs/types/int.html) | Yes|Duration of video in seconds| +|mime\_type|[string](/API_docs/types/string.html) | Yes|MIME-type of the video file
Parameter added in Layer 17.| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|size|[int](/API_docs/types/int.html) | Yes|File size| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaVideo_17 = ['_' => 'decryptedMessageMediaVideo', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'duration' => int, 'mime_type' => 'string', 'w' => int, 'h' => int, 'size' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaVideo_45.md b/docs/API_docs/constructors/decryptedMessageMediaVideo_45.md new file mode 100644 index 0000000000..534d2ac0d6 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaVideo_45.md @@ -0,0 +1,37 @@ +--- +title: "decryptedMessageMediaVideo" +description: "Video attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaVideo\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Video attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Content of thumbnail file (JPEG file, quality 55, set in a square 90x90)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|duration|[int](/API_docs/types/int.html) | Yes|Duration of video in seconds| +|mime\_type|[string](/API_docs/types/string.html) | Yes|MIME-type of the video file
Parameter added in Layer 17.| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|size|[int](/API_docs/types/int.html) | Yes|File size| +|caption|[string](/API_docs/types/string.html) | Yes|Caption| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaVideo_45 = ['_' => 'decryptedMessageMediaVideo', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'duration' => int, 'mime_type' => 'string', 'w' => int, 'h' => int, 'size' => int, 'caption' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaVideo_8.md b/docs/API_docs/constructors/decryptedMessageMediaVideo_8.md new file mode 100644 index 0000000000..cc0dcee547 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaVideo_8.md @@ -0,0 +1,35 @@ +--- +title: "decryptedMessageMediaVideo" +description: "Video attached to an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaVideo\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Video attached to an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|thumb|[bytes](/API_docs/types/bytes.html) | Yes|Content of thumbnail file (JPEG file, quality 55, set in a square 90x90)| +|thumb\_w|[int](/API_docs/types/int.html) | Yes|Thumbnail width| +|thumb\_h|[int](/API_docs/types/int.html) | Yes|Thumbnail height| +|duration|[int](/API_docs/types/int.html) | Yes|Duration of video in seconds| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|size|[int](/API_docs/types/int.html) | Yes|File size| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaVideo_8 = ['_' => 'decryptedMessageMediaVideo', 'thumb' => 'bytes', 'thumb_w' => int, 'thumb_h' => int, 'duration' => int, 'w' => int, 'h' => int, 'size' => int]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageMediaWebPage_45.md b/docs/API_docs/constructors/decryptedMessageMediaWebPage_45.md new file mode 100644 index 0000000000..d160c62267 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageMediaWebPage_45.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageMediaWebPage" +description: "Webpage preview" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageMediaWebPage\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Webpage preview + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|URL of webpage| + + + +### Type: [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + + +### Example: + +``` +$decryptedMessageMediaWebPage_45 = ['_' => 'decryptedMessageMediaWebPage', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/decryptedMessageService_17.md b/docs/API_docs/constructors/decryptedMessageService_17.md new file mode 100644 index 0000000000..83b4b53068 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageService_17.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageService" +description: "Contents of an encrypted service message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageService\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of an encrypted service message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|action|[DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) | Yes|Action relevant to the service message| + + + +### Type: [DecryptedMessage](/API_docs/types/DecryptedMessage.html) + + +### Example: + +``` +$decryptedMessageService_17 = ['_' => 'decryptedMessageService', 'action' => DecryptedMessageAction]; +``` diff --git a/docs/API_docs/constructors/decryptedMessageService_8.md b/docs/API_docs/constructors/decryptedMessageService_8.md new file mode 100644 index 0000000000..ff46e54e85 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessageService_8.md @@ -0,0 +1,29 @@ +--- +title: "decryptedMessageService" +description: "Contents of an encrypted service message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessageService\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of an encrypted service message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|action|[DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) | Yes|Action relevant to the service message| + + + +### Type: [DecryptedMessage](/API_docs/types/DecryptedMessage.html) + + +### Example: + +``` +$decryptedMessageService_8 = ['_' => 'decryptedMessageService', 'action' => DecryptedMessageAction]; +``` diff --git a/docs/API_docs/constructors/decryptedMessage_17.md b/docs/API_docs/constructors/decryptedMessage_17.md new file mode 100644 index 0000000000..32ccade83f --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessage_17.md @@ -0,0 +1,31 @@ +--- +title: "decryptedMessage" +description: "Contents of an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessage\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|ttl|[int](/API_docs/types/int.html) | Yes|Message lifetime. Has higher priority than [decryptedMessageActionSetMessageTTL](../constructors/decryptedMessageActionSetMessageTTL.html).
Parameter added in Layer 17.| +|message|[string](/API_docs/types/string.html) | Yes|Message text| +|media|[DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) | Yes|Media content| + + + +### Type: [DecryptedMessage](/API_docs/types/DecryptedMessage.html) + + +### Example: + +``` +$decryptedMessage_17 = ['_' => 'decryptedMessage', 'ttl' => int, 'message' => 'string', 'media' => DecryptedMessageMedia]; +``` diff --git a/docs/API_docs/constructors/decryptedMessage_45.md b/docs/API_docs/constructors/decryptedMessage_45.md new file mode 100644 index 0000000000..9d7dfd2dcf --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessage_45.md @@ -0,0 +1,95 @@ +--- +title: "decryptedMessage" +description: "Contents of an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessage\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|ttl|[int](/API_docs/types/int.html) | Yes|Message lifetime. Has higher priority than [decryptedMessageActionSetMessageTTL](../constructors/decryptedMessageActionSetMessageTTL.html).
Parameter added in Layer 17.| +|message|[string](/API_docs/types/string.html) | Yes|Message text| +|media|[DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) | Optional|Media content| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|Message [entities](https://core.telegram.org/api/entities) for styled text (parameter added in layer 45)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|via\_bot\_name|[string](/API_docs/types/string.html) | Optional|Specifies the ID of the inline bot that generated the message (parameter added in layer 45)| +|reply\_to\_random\_id|[long](/API_docs/types/long.html) | Optional|Random message ID of the message this message replies to (parameter added in layer 45)| + + + +### Type: [DecryptedMessage](/API_docs/types/DecryptedMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$decryptedMessage_45 = ['_' => 'decryptedMessage', 'ttl' => int, 'message' => 'string', 'media' => DecryptedMessageMedia, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'via_bot_name' => 'string', 'reply_to_random_id' => long]; +``` diff --git a/docs/API_docs/constructors/decryptedMessage_73.md b/docs/API_docs/constructors/decryptedMessage_73.md new file mode 100644 index 0000000000..127a4c74cb --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessage_73.md @@ -0,0 +1,98 @@ +--- +title: "decryptedMessage" +description: "Contents of an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessage\_73 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Optional|Whether the webpage preview is disabled| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a silent message (no notification triggered)| +|ttl|[int](/API_docs/types/int.html) | Yes|Message lifetime. Has higher priority than [decryptedMessageActionSetMessageTTL](../constructors/decryptedMessageActionSetMessageTTL.html).
Parameter added in Layer 17.| +|message|[string](/API_docs/types/string.html) | Yes|Message text| +|media|[DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) | Optional|Media content| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|Message [entities](https://core.telegram.org/api/entities) for styled text (parameter added in layer 45)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|via\_bot\_name|[string](/API_docs/types/string.html) | Optional|Specifies the ID of the inline bot that generated the message (parameter added in layer 45)| +|reply\_to\_random\_id|[long](/API_docs/types/long.html) | Optional|Random message ID of the message this message replies to (parameter added in layer 45)| +|grouped\_id|[long](/API_docs/types/long.html) | Optional|Random group ID, assigned by the author of message.
Multiple encrypted messages with a photo attached and with the same group ID indicate an [album or grouped media](https://core.telegram.org/api/files#albums-grouped-media) (parameter added in layer 45)| + + + +### Type: [DecryptedMessage](/API_docs/types/DecryptedMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$decryptedMessage_73 = ['_' => 'decryptedMessage', 'no_webpage' => Bool, 'silent' => Bool, 'ttl' => int, 'message' => 'string', 'media' => DecryptedMessageMedia, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'via_bot_name' => 'string', 'reply_to_random_id' => long, 'grouped_id' => long]; +``` diff --git a/docs/API_docs/constructors/decryptedMessage_8.md b/docs/API_docs/constructors/decryptedMessage_8.md new file mode 100644 index 0000000000..4cc0b297a0 --- /dev/null +++ b/docs/API_docs/constructors/decryptedMessage_8.md @@ -0,0 +1,30 @@ +--- +title: "decryptedMessage" +description: "Contents of an encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: decryptedMessage\_8 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of an encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[string](/API_docs/types/string.html) | Yes|Message text| +|media|[DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) | Yes|Media content| + + + +### Type: [DecryptedMessage](/API_docs/types/DecryptedMessage.html) + + +### Example: + +``` +$decryptedMessage_8 = ['_' => 'decryptedMessage', 'message' => 'string', 'media' => DecryptedMessageMedia]; +``` diff --git a/docs/API_docs/constructors/defaultHistoryTTL.md b/docs/API_docs/constructors/defaultHistoryTTL.md new file mode 100644 index 0000000000..c6fc99c049 --- /dev/null +++ b/docs/API_docs/constructors/defaultHistoryTTL.md @@ -0,0 +1,29 @@ +--- +title: "defaultHistoryTTL" +description: "Contains info about the default value of the Time-To-Live setting, applied to all new chats." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: defaultHistoryTTL +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about the default value of the Time-To-Live setting, applied to all new chats. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|period|[int](/API_docs/types/int.html) | Yes|Time-To-Live setting applied to all new chats.| + + + +### Type: [DefaultHistoryTTL](/API_docs/types/DefaultHistoryTTL.html) + + +### Example: + +``` +$defaultHistoryTTL = ['_' => 'defaultHistoryTTL', 'period' => int]; +``` diff --git a/docs/API_docs/constructors/dialog.md b/docs/API_docs/constructors/dialog.md new file mode 100644 index 0000000000..58c87cfdcf --- /dev/null +++ b/docs/API_docs/constructors/dialog.md @@ -0,0 +1,43 @@ +--- +title: "dialog" +description: "Chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialog +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Is the dialog pinned| +|unread\_mark|[Bool](/API_docs/types/Bool.html) | Optional|Whether the chat was manually marked as unread| +|view\_forum\_as\_messages|[Bool](/API_docs/types/Bool.html) | Optional|Users may also choose to display messages from all topics of a [forum](https://core.telegram.org/api/forum) as if they were sent to a normal group, using a "View as messages" setting in the local client.
This setting only affects the current account, and is synced to other logged in sessions using the [channels.toggleViewForumAsMessages](../methods/channels.toggleViewForumAsMessages.html) method; invoking this method will update the value of this flag.| +|peer|[long](/API_docs/types/long.html) | Yes|The chat| +|top\_message|[int](/API_docs/types/int.html) | Yes|The latest message ID| +|read\_inbox\_max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all incoming messages are read.| +|read\_outbox\_max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all outgoing messages are read.| +|unread\_count|[int](/API_docs/types/int.html) | Yes|Number of unread messages| +|unread\_mentions\_count|[int](/API_docs/types/int.html) | Yes|Number of [unread mentions](https://core.telegram.org/api/mentions)| +|unread\_reactions\_count|[int](/API_docs/types/int.html) | Yes|Number of unread reactions to messages you sent| +|notify\_settings|[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) | Yes|Notification settings| +|pts|[int](/API_docs/types/int.html) | Optional|[PTS](https://core.telegram.org/api/updates)| +|draft|[DraftMessage](/API_docs/types/DraftMessage.html) | Optional|Message [draft](https://core.telegram.org/api/drafts)| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time-to-live of all messages sent in this dialog| + + + +### Type: [Dialog](/API_docs/types/Dialog.html) + + +### Example: + +``` +$dialog = ['_' => 'dialog', 'pinned' => Bool, 'unread_mark' => Bool, 'view_forum_as_messages' => Bool, 'peer' => long, 'top_message' => int, 'read_inbox_max_id' => int, 'read_outbox_max_id' => int, 'unread_count' => int, 'unread_mentions_count' => int, 'unread_reactions_count' => int, 'notify_settings' => PeerNotifySettings, 'pts' => int, 'draft' => DraftMessage, 'folder_id' => int, 'ttl_period' => int]; +``` diff --git a/docs/API_docs/constructors/dialogFilter.md b/docs/API_docs/constructors/dialogFilter.md new file mode 100644 index 0000000000..97ce57ee5a --- /dev/null +++ b/docs/API_docs/constructors/dialogFilter.md @@ -0,0 +1,43 @@ +--- +title: "dialogFilter" +description: "Dialog filter AKA folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogFilter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Dialog filter AKA [folder](https://core.telegram.org/api/folders) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|contacts|[Bool](/API_docs/types/Bool.html) | Optional|Whether to include all contacts in this [folder](https://core.telegram.org/api/folders)| +|non\_contacts|[Bool](/API_docs/types/Bool.html) | Optional|Whether to include all non-contacts in this [folder](https://core.telegram.org/api/folders)| +|groups|[Bool](/API_docs/types/Bool.html) | Optional|Whether to include all groups in this [folder](https://core.telegram.org/api/folders)| +|broadcasts|[Bool](/API_docs/types/Bool.html) | Optional|Whether to include all channels in this [folder](https://core.telegram.org/api/folders)| +|bots|[Bool](/API_docs/types/Bool.html) | Optional|Whether to include all bots in this [folder](https://core.telegram.org/api/folders)| +|exclude\_muted|[Bool](/API_docs/types/Bool.html) | Optional|Whether to exclude muted chats from this [folder](https://core.telegram.org/api/folders)| +|exclude\_read|[Bool](/API_docs/types/Bool.html) | Optional|Whether to exclude read chats from this [folder](https://core.telegram.org/api/folders)| +|exclude\_archived|[Bool](/API_docs/types/Bool.html) | Optional|Whether to exclude archived chats from this [folder](https://core.telegram.org/api/folders)| +|id|[int](/API_docs/types/int.html) | Yes|[Folder](https://core.telegram.org/api/folders) ID| +|title|[string](/API_docs/types/string.html) | Yes|[Folder](https://core.telegram.org/api/folders) name| +|emoticon|[string](/API_docs/types/string.html) | Optional|Emoji to use as icon for the folder.| +|color|[int](/API_docs/types/int.html) | Optional| +|pinned\_peers|Array of [InputPeer](/API_docs/types/InputPeer.html) | Yes|Pinned chats, [folders](https://core.telegram.org/api/folders) can have unlimited pinned chats| +|include\_peers|Array of [InputPeer](/API_docs/types/InputPeer.html) | Yes|Include the following chats in this [folder](https://core.telegram.org/api/folders)| +|exclude\_peers|Array of [InputPeer](/API_docs/types/InputPeer.html) | Yes|Exclude the following chats from this [folder](https://core.telegram.org/api/folders)| + + + +### Type: [DialogFilter](/API_docs/types/DialogFilter.html) + + +### Example: + +``` +$dialogFilter = ['_' => 'dialogFilter', 'contacts' => Bool, 'non_contacts' => Bool, 'groups' => Bool, 'broadcasts' => Bool, 'bots' => Bool, 'exclude_muted' => Bool, 'exclude_read' => Bool, 'exclude_archived' => Bool, 'id' => int, 'title' => 'string', 'emoticon' => 'string', 'color' => int, 'pinned_peers' => [InputPeer, InputPeer], 'include_peers' => [InputPeer, InputPeer], 'exclude_peers' => [InputPeer, InputPeer]]; +``` diff --git a/docs/API_docs/constructors/dialogFilterChatlist.md b/docs/API_docs/constructors/dialogFilterChatlist.md new file mode 100644 index 0000000000..65b5e806ca --- /dev/null +++ b/docs/API_docs/constructors/dialogFilterChatlist.md @@ -0,0 +1,35 @@ +--- +title: "dialogFilterChatlist" +description: "A folder imported using a chat folder deep link »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogFilterChatlist +[Back to constructors index](/API_docs/constructors/index.html) + + + +A folder imported using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_my\_invites|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user has created some [chat folder deep links »](https://core.telegram.org/api/links#chat-folder-links) to share the folder as well.| +|id|[int](/API_docs/types/int.html) | Yes|ID of the folder| +|title|[string](/API_docs/types/string.html) | Yes|Name of the folder| +|emoticon|[string](/API_docs/types/string.html) | Optional|Emoji to use as icon for the folder.| +|color|[int](/API_docs/types/int.html) | Optional| +|pinned\_peers|Array of [InputPeer](/API_docs/types/InputPeer.html) | Yes|Pinned chats, [folders](https://core.telegram.org/api/folders) can have unlimited pinned chats| +|include\_peers|Array of [InputPeer](/API_docs/types/InputPeer.html) | Yes|Chats to include in the folder| + + + +### Type: [DialogFilter](/API_docs/types/DialogFilter.html) + + +### Example: + +``` +$dialogFilterChatlist = ['_' => 'dialogFilterChatlist', 'has_my_invites' => Bool, 'id' => int, 'title' => 'string', 'emoticon' => 'string', 'color' => int, 'pinned_peers' => [InputPeer, InputPeer], 'include_peers' => [InputPeer, InputPeer]]; +``` diff --git a/docs/API_docs/constructors/dialogFilterDefault.md b/docs/API_docs/constructors/dialogFilterDefault.md new file mode 100644 index 0000000000..458408f878 --- /dev/null +++ b/docs/API_docs/constructors/dialogFilterDefault.md @@ -0,0 +1,24 @@ +--- +title: "dialogFilterDefault" +description: "Used only when reordering folders to indicate the default (all chats) folder." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogFilterDefault +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used only when reordering folders to indicate the default (all chats) folder. + + + + +### Type: [DialogFilter](/API_docs/types/DialogFilter.html) + + +### Example: + +``` +$dialogFilterDefault = ['_' => 'dialogFilterDefault']; +``` diff --git a/docs/API_docs/constructors/dialogFilterSuggested.md b/docs/API_docs/constructors/dialogFilterSuggested.md new file mode 100644 index 0000000000..ef75f17f51 --- /dev/null +++ b/docs/API_docs/constructors/dialogFilterSuggested.md @@ -0,0 +1,30 @@ +--- +title: "dialogFilterSuggested" +description: "Suggested folders" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogFilterSuggested +[Back to constructors index](/API_docs/constructors/index.html) + + + +Suggested [folders](https://core.telegram.org/api/folders) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|filter|[DialogFilter](/API_docs/types/DialogFilter.html) | Yes|[Folder info](https://core.telegram.org/api/folders)| +|description|[string](/API_docs/types/string.html) | Yes|[Folder](https://core.telegram.org/api/folders) description| + + + +### Type: [DialogFilterSuggested](/API_docs/types/DialogFilterSuggested.html) + + +### Example: + +``` +$dialogFilterSuggested = ['_' => 'dialogFilterSuggested', 'filter' => DialogFilter, 'description' => 'string']; +``` diff --git a/docs/API_docs/constructors/dialogFolder.md b/docs/API_docs/constructors/dialogFolder.md new file mode 100644 index 0000000000..6ee5bc7592 --- /dev/null +++ b/docs/API_docs/constructors/dialogFolder.md @@ -0,0 +1,36 @@ +--- +title: "dialogFolder" +description: "Dialog in folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogFolder +[Back to constructors index](/API_docs/constructors/index.html) + + + +Dialog in folder + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Is this folder pinned| +|folder|[Folder](/API_docs/types/Folder.html) | Yes|The folder| +|peer|[long](/API_docs/types/long.html) | Yes|Peer in folder| +|top\_message|[int](/API_docs/types/int.html) | Yes|Latest message ID of dialog| +|unread\_muted\_peers\_count|[int](/API_docs/types/int.html) | Yes|Number of unread muted peers in folder| +|unread\_unmuted\_peers\_count|[int](/API_docs/types/int.html) | Yes|Number of unread unmuted peers in folder| +|unread\_muted\_messages\_count|[int](/API_docs/types/int.html) | Yes|Number of unread messages from muted peers in folder| +|unread\_unmuted\_messages\_count|[int](/API_docs/types/int.html) | Yes|Number of unread messages from unmuted peers in folder| + + + +### Type: [Dialog](/API_docs/types/Dialog.html) + + +### Example: + +``` +$dialogFolder = ['_' => 'dialogFolder', 'pinned' => Bool, 'folder' => Folder, 'peer' => long, 'top_message' => int, 'unread_muted_peers_count' => int, 'unread_unmuted_peers_count' => int, 'unread_muted_messages_count' => int, 'unread_unmuted_messages_count' => int]; +``` diff --git a/docs/API_docs/constructors/dialogPeer.md b/docs/API_docs/constructors/dialogPeer.md new file mode 100644 index 0000000000..530fcff0e5 --- /dev/null +++ b/docs/API_docs/constructors/dialogPeer.md @@ -0,0 +1,29 @@ +--- +title: "dialogPeer" +description: "Peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| + + + +### Type: [DialogPeer](/API_docs/types/DialogPeer.html) + + +### Example: + +``` +$dialogPeer = ['_' => 'dialogPeer', 'peer' => long]; +``` diff --git a/docs/API_docs/constructors/dialogPeerFolder.md b/docs/API_docs/constructors/dialogPeerFolder.md new file mode 100644 index 0000000000..d82156d7e9 --- /dev/null +++ b/docs/API_docs/constructors/dialogPeerFolder.md @@ -0,0 +1,29 @@ +--- +title: "dialogPeerFolder" +description: "Peer folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: dialogPeerFolder +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Peer folder](https://core.telegram.org/api/folders#peer-folders) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_id|[int](/API_docs/types/int.html) | Yes|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| + + + +### Type: [DialogPeer](/API_docs/types/DialogPeer.html) + + +### Example: + +``` +$dialogPeerFolder = ['_' => 'dialogPeerFolder', 'folder_id' => int]; +``` diff --git a/docs/API_docs/constructors/document.md b/docs/API_docs/constructors/document.md new file mode 100644 index 0000000000..05d5c8aa6e --- /dev/null +++ b/docs/API_docs/constructors/document.md @@ -0,0 +1,38 @@ +--- +title: "document" +description: "Document" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: document +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Document ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Check sum, dependent on document ID| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[File reference](https://core.telegram.org/api/file_reference)| +|date|[int](/API_docs/types/int.html) | Yes|Creation date| +|mime\_type|[string](/API_docs/types/string.html) | Yes|MIME type| +|size|[long](/API_docs/types/long.html) | Yes|Size| +|thumbs|Array of [PhotoSize](/API_docs/types/PhotoSize.html) | Optional|Thumbnails| +|video\_thumbs|Array of [VideoSize](/API_docs/types/VideoSize.html) | Optional|Video thumbnails| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Attributes| + + + +### Type: [Document](/API_docs/types/Document.html) + + +### Example: + +``` +$document = ['_' => 'document', 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes', 'date' => int, 'mime_type' => 'string', 'size' => long, 'thumbs' => [PhotoSize, PhotoSize], 'video_thumbs' => [VideoSize, VideoSize], 'dc_id' => int, 'attributes' => [DocumentAttribute, DocumentAttribute]]; +``` diff --git a/docs/API_docs/constructors/documentAttributeAnimated.md b/docs/API_docs/constructors/documentAttributeAnimated.md new file mode 100644 index 0000000000..d86beea05e --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeAnimated.md @@ -0,0 +1,24 @@ +--- +title: "documentAttributeAnimated" +description: "Defines an animated GIF" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeAnimated +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines an animated GIF + + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeAnimated = ['_' => 'documentAttributeAnimated']; +``` diff --git a/docs/API_docs/constructors/documentAttributeAudio.md b/docs/API_docs/constructors/documentAttributeAudio.md new file mode 100644 index 0000000000..bc5e8fd3b0 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeAudio.md @@ -0,0 +1,33 @@ +--- +title: "documentAttributeAudio" +description: "Represents an audio file" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeAudio +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an audio file + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|voice|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a voice message| +|duration|[int](/API_docs/types/int.html) | Optional|Duration in seconds| +|title|[string](/API_docs/types/string.html) | Optional|Name of song| +|performer|[string](/API_docs/types/string.html) | Optional|Performer| +|waveform|[waveform](/API_docs/constructors/waveform.html) | Optional| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeAudio = ['_' => 'documentAttributeAudio', 'voice' => Bool, 'duration' => int, 'title' => 'string', 'performer' => 'string', 'waveform' => waveform]; +``` diff --git a/docs/API_docs/constructors/documentAttributeAudio_23.md b/docs/API_docs/constructors/documentAttributeAudio_23.md new file mode 100644 index 0000000000..bd08952d25 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeAudio_23.md @@ -0,0 +1,29 @@ +--- +title: "documentAttributeAudio" +description: "Represents an audio file" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeAudio\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an audio file + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|duration|[int](/API_docs/types/int.html) | Optional|Duration in seconds| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeAudio_23 = ['_' => 'documentAttributeAudio', 'duration' => int]; +``` diff --git a/docs/API_docs/constructors/documentAttributeAudio_45.md b/docs/API_docs/constructors/documentAttributeAudio_45.md new file mode 100644 index 0000000000..2ee692bd7a --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeAudio_45.md @@ -0,0 +1,31 @@ +--- +title: "documentAttributeAudio" +description: "Represents an audio file" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeAudio\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an audio file + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|duration|[int](/API_docs/types/int.html) | Optional|Duration in seconds| +|title|[string](/API_docs/types/string.html) | Yes|Name of song| +|performer|[string](/API_docs/types/string.html) | Yes|Performer| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeAudio_45 = ['_' => 'documentAttributeAudio', 'duration' => int, 'title' => 'string', 'performer' => 'string']; +``` diff --git a/docs/API_docs/constructors/documentAttributeCustomEmoji.md b/docs/API_docs/constructors/documentAttributeCustomEmoji.md new file mode 100644 index 0000000000..45983d79ea --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeCustomEmoji.md @@ -0,0 +1,32 @@ +--- +title: "documentAttributeCustomEmoji" +description: "Info about a custom emoji" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeCustomEmoji +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a custom emoji + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|free|[Bool](/API_docs/types/Bool.html) | Optional|Whether this custom emoji can be sent by non-Premium users| +|text\_color|[Bool](/API_docs/types/Bool.html) | Optional|Whether the color of this TGS custom emoji should be changed to the text color when used in messages, the accent color if used as emoji status, white on chat photos, or another appropriate color based on context.| +|alt|[string](/API_docs/types/string.html) | Yes|The actual emoji| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|The emoji stickerset to which this emoji belongs.| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeCustomEmoji = ['_' => 'documentAttributeCustomEmoji', 'free' => Bool, 'text_color' => Bool, 'alt' => 'string', 'stickerset' => InputStickerSet]; +``` diff --git a/docs/API_docs/constructors/documentAttributeFilename.md b/docs/API_docs/constructors/documentAttributeFilename.md new file mode 100644 index 0000000000..28008c5190 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeFilename.md @@ -0,0 +1,29 @@ +--- +title: "documentAttributeFilename" +description: "A simple document with a file name" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeFilename +[Back to constructors index](/API_docs/constructors/index.html) + + + +A simple document with a file name + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|file\_name|[string](/API_docs/types/string.html) | Yes|The file name| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeFilename = ['_' => 'documentAttributeFilename', 'file_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/documentAttributeHasStickers.md b/docs/API_docs/constructors/documentAttributeHasStickers.md new file mode 100644 index 0000000000..b32868f0c7 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeHasStickers.md @@ -0,0 +1,24 @@ +--- +title: "documentAttributeHasStickers" +description: "Whether the current document has stickers attached" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeHasStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether the current document has stickers attached + + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeHasStickers = ['_' => 'documentAttributeHasStickers']; +``` diff --git a/docs/API_docs/constructors/documentAttributeImageSize.md b/docs/API_docs/constructors/documentAttributeImageSize.md new file mode 100644 index 0000000000..29612d997d --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeImageSize.md @@ -0,0 +1,30 @@ +--- +title: "documentAttributeImageSize" +description: "Defines the width and height of an image uploaded as document" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeImageSize +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines the width and height of an image uploaded as document + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|w|[int](/API_docs/types/int.html) | Optional|Width of image| +|h|[int](/API_docs/types/int.html) | Optional|Height of image| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeImageSize = ['_' => 'documentAttributeImageSize', 'w' => int, 'h' => int]; +``` diff --git a/docs/API_docs/constructors/documentAttributeSticker.md b/docs/API_docs/constructors/documentAttributeSticker.md new file mode 100644 index 0000000000..7b74ec2f30 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeSticker.md @@ -0,0 +1,32 @@ +--- +title: "documentAttributeSticker" +description: "Defines a sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeSticker +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a sticker + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|mask|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a mask sticker| +|alt|[string](/API_docs/types/string.html) | Yes|Alternative emoji representation of sticker| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|Associated stickerset| +|mask\_coords|[MaskCoords](/API_docs/types/MaskCoords.html) | Optional|Mask coordinates (if this is a mask sticker, attached to a photo)| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeSticker = ['_' => 'documentAttributeSticker', 'mask' => Bool, 'alt' => 'string', 'stickerset' => InputStickerSet, 'mask_coords' => MaskCoords]; +``` diff --git a/docs/API_docs/constructors/documentAttributeSticker_23.md b/docs/API_docs/constructors/documentAttributeSticker_23.md new file mode 100644 index 0000000000..2fb6106f36 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeSticker_23.md @@ -0,0 +1,24 @@ +--- +title: "documentAttributeSticker" +description: "Defines a sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeSticker\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a sticker + + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeSticker_23 = ['_' => 'documentAttributeSticker']; +``` diff --git a/docs/API_docs/constructors/documentAttributeSticker_45.md b/docs/API_docs/constructors/documentAttributeSticker_45.md new file mode 100644 index 0000000000..daceb4b5e6 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeSticker_45.md @@ -0,0 +1,30 @@ +--- +title: "documentAttributeSticker" +description: "Defines a sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeSticker\_45 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a sticker + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|alt|[string](/API_docs/types/string.html) | Yes|Alternative emoji representation of sticker| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|Associated stickerset| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeSticker_45 = ['_' => 'documentAttributeSticker', 'alt' => 'string', 'stickerset' => InputStickerSet]; +``` diff --git a/docs/API_docs/constructors/documentAttributeVideo.md b/docs/API_docs/constructors/documentAttributeVideo.md new file mode 100644 index 0000000000..0572073e71 --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeVideo.md @@ -0,0 +1,35 @@ +--- +title: "documentAttributeVideo" +description: "Defines a video" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeVideo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a video + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|round\_message|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a round video| +|supports\_streaming|[Bool](/API_docs/types/Bool.html) | Optional|Whether the video supports streaming| +|nosound|[Bool](/API_docs/types/Bool.html) | Optional|Whether the specified document is a video file with no audio tracks (a GIF animation (even as MPEG4), for example)| +|duration|[double](/API_docs/types/double.html) | Optional|Duration in seconds| +|w|[int](/API_docs/types/int.html) | Optional|Video width| +|h|[int](/API_docs/types/int.html) | Optional|Video height| +|preload\_prefix\_size|[int](/API_docs/types/int.html) | Optional|Number of bytes to preload when preloading videos (particularly [video stories](https://core.telegram.org/api/stories)).| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeVideo = ['_' => 'documentAttributeVideo', 'round_message' => Bool, 'supports_streaming' => Bool, 'nosound' => Bool, 'duration' => double, 'w' => int, 'h' => int, 'preload_prefix_size' => int]; +``` diff --git a/docs/API_docs/constructors/documentAttributeVideo_23.md b/docs/API_docs/constructors/documentAttributeVideo_23.md new file mode 100644 index 0000000000..1b83acde7e --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeVideo_23.md @@ -0,0 +1,31 @@ +--- +title: "documentAttributeVideo" +description: "Defines a video" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeVideo\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a video + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|duration|[int](/API_docs/types/int.html) | Optional|Duration in seconds| +|w|[int](/API_docs/types/int.html) | Optional|Video width| +|h|[int](/API_docs/types/int.html) | Optional|Video height| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeVideo_23 = ['_' => 'documentAttributeVideo', 'duration' => int, 'w' => int, 'h' => int]; +``` diff --git a/docs/API_docs/constructors/documentAttributeVideo_66.md b/docs/API_docs/constructors/documentAttributeVideo_66.md new file mode 100644 index 0000000000..2c5259e39c --- /dev/null +++ b/docs/API_docs/constructors/documentAttributeVideo_66.md @@ -0,0 +1,32 @@ +--- +title: "documentAttributeVideo" +description: "Defines a video" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentAttributeVideo\_66 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a video + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|round\_message|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a round video| +|duration|[int](/API_docs/types/int.html) | Optional|Duration in seconds| +|w|[int](/API_docs/types/int.html) | Optional|Video width| +|h|[int](/API_docs/types/int.html) | Optional|Video height| + + + +### Type: [DocumentAttribute](/API_docs/types/DocumentAttribute.html) + + +### Example: + +``` +$documentAttributeVideo_66 = ['_' => 'documentAttributeVideo', 'round_message' => Bool, 'duration' => int, 'w' => int, 'h' => int]; +``` diff --git a/docs/API_docs/constructors/documentEmpty.md b/docs/API_docs/constructors/documentEmpty.md new file mode 100644 index 0000000000..0545458acb --- /dev/null +++ b/docs/API_docs/constructors/documentEmpty.md @@ -0,0 +1,29 @@ +--- +title: "documentEmpty" +description: "Empty constructor, document doesn't exist." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: documentEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, document doesn't exist. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Document ID or `0`| + + + +### Type: [Document](/API_docs/types/Document.html) + + +### Example: + +``` +$documentEmpty = ['_' => 'documentEmpty', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/draftMessage.md b/docs/API_docs/constructors/draftMessage.md new file mode 100644 index 0000000000..507130b818 --- /dev/null +++ b/docs/API_docs/constructors/draftMessage.md @@ -0,0 +1,96 @@ +--- +title: "draftMessage" +description: "Represents a message draft." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: draftMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a message [draft](https://core.telegram.org/api/drafts). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Optional|Whether no webpage preview will be generated| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | Optional|If set, indicates that the message should be sent in reply to the specified message or story.| +|message|[string](/API_docs/types/string.html) | Yes|The draft| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|Message [entities](https://core.telegram.org/api/entities) for styled text.| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|media|[InputMedia](/API_docs/types/InputMedia.html) | Optional|Media.| +|date|[int](/API_docs/types/int.html) | Yes|Date of last update of the draft.| + + + +### Type: [DraftMessage](/API_docs/types/DraftMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$draftMessage = ['_' => 'draftMessage', 'no_webpage' => Bool, 'invert_media' => Bool, 'reply_to' => InputReplyTo, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'media' => InputMedia, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/draftMessageEmpty.md b/docs/API_docs/constructors/draftMessageEmpty.md new file mode 100644 index 0000000000..1bef6db4ed --- /dev/null +++ b/docs/API_docs/constructors/draftMessageEmpty.md @@ -0,0 +1,29 @@ +--- +title: "draftMessageEmpty" +description: "Empty draft" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: draftMessageEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty draft + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|date|[int](/API_docs/types/int.html) | Optional|When was the draft last updated| + + + +### Type: [DraftMessage](/API_docs/types/DraftMessage.html) + + +### Example: + +``` +$draftMessageEmpty = ['_' => 'draftMessageEmpty', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/emailVerificationApple.md b/docs/API_docs/constructors/emailVerificationApple.md new file mode 100644 index 0000000000..0a7551c96e --- /dev/null +++ b/docs/API_docs/constructors/emailVerificationApple.md @@ -0,0 +1,29 @@ +--- +title: "emailVerificationApple" +description: "Apple ID email verification token" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emailVerificationApple +[Back to constructors index](/API_docs/constructors/index.html) + + + +Apple ID email verification token + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|token|[string](/API_docs/types/string.html) | Yes|Token| + + + +### Type: [EmailVerification](/API_docs/types/EmailVerification.html) + + +### Example: + +``` +$emailVerificationApple = ['_' => 'emailVerificationApple', 'token' => 'string']; +``` diff --git a/docs/API_docs/constructors/emailVerificationCode.md b/docs/API_docs/constructors/emailVerificationCode.md new file mode 100644 index 0000000000..b90c33325f --- /dev/null +++ b/docs/API_docs/constructors/emailVerificationCode.md @@ -0,0 +1,29 @@ +--- +title: "emailVerificationCode" +description: "Email verification code" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emailVerificationCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Email verification code + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|code|[string](/API_docs/types/string.html) | Yes|Received verification code| + + + +### Type: [EmailVerification](/API_docs/types/EmailVerification.html) + + +### Example: + +``` +$emailVerificationCode = ['_' => 'emailVerificationCode', 'code' => 'string']; +``` diff --git a/docs/API_docs/constructors/emailVerificationGoogle.md b/docs/API_docs/constructors/emailVerificationGoogle.md new file mode 100644 index 0000000000..c02b32835a --- /dev/null +++ b/docs/API_docs/constructors/emailVerificationGoogle.md @@ -0,0 +1,29 @@ +--- +title: "emailVerificationGoogle" +description: "Google ID email verification token" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emailVerificationGoogle +[Back to constructors index](/API_docs/constructors/index.html) + + + +Google ID email verification token + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|token|[string](/API_docs/types/string.html) | Yes|Token| + + + +### Type: [EmailVerification](/API_docs/types/EmailVerification.html) + + +### Example: + +``` +$emailVerificationGoogle = ['_' => 'emailVerificationGoogle', 'token' => 'string']; +``` diff --git a/docs/API_docs/constructors/emailVerifyPurposeLoginChange.md b/docs/API_docs/constructors/emailVerifyPurposeLoginChange.md new file mode 100644 index 0000000000..1fbd0c80ca --- /dev/null +++ b/docs/API_docs/constructors/emailVerifyPurposeLoginChange.md @@ -0,0 +1,24 @@ +--- +title: "emailVerifyPurposeLoginChange" +description: "Email verification purpose: change login email" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emailVerifyPurposeLoginChange +[Back to constructors index](/API_docs/constructors/index.html) + + + +Email verification purpose: change login email + + + + +### Type: [EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html) + + +### Example: + +``` +$emailVerifyPurposeLoginChange = ['_' => 'emailVerifyPurposeLoginChange']; +``` diff --git a/docs/API_docs/constructors/emailVerifyPurposeLoginSetup.md b/docs/API_docs/constructors/emailVerifyPurposeLoginSetup.md new file mode 100644 index 0000000000..7391818e62 --- /dev/null +++ b/docs/API_docs/constructors/emailVerifyPurposeLoginSetup.md @@ -0,0 +1,30 @@ +--- +title: "emailVerifyPurposeLoginSetup" +description: "Email verification purpose: setup login email" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emailVerifyPurposeLoginSetup +[Back to constructors index](/API_docs/constructors/index.html) + + + +Email verification purpose: setup login email + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Yes|Phone code hash as specified by the [documentation](https://core.telegram.org/api/auth#email-verification)| + + + +### Type: [EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html) + + +### Example: + +``` +$emailVerifyPurposeLoginSetup = ['_' => 'emailVerifyPurposeLoginSetup', 'phone_number' => 'string', 'phone_code_hash' => 'string']; +``` diff --git a/docs/API_docs/constructors/emailVerifyPurposePassport.md b/docs/API_docs/constructors/emailVerifyPurposePassport.md new file mode 100644 index 0000000000..3348ac65f5 --- /dev/null +++ b/docs/API_docs/constructors/emailVerifyPurposePassport.md @@ -0,0 +1,24 @@ +--- +title: "emailVerifyPurposePassport" +description: "Verify an email for use in telegram passport" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emailVerifyPurposePassport +[Back to constructors index](/API_docs/constructors/index.html) + + + +Verify an email for use in [telegram passport](https://core.telegram.org/api/passport) + + + + +### Type: [EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html) + + +### Example: + +``` +$emailVerifyPurposePassport = ['_' => 'emailVerifyPurposePassport']; +``` diff --git a/docs/API_docs/constructors/emojiGroup.md b/docs/API_docs/constructors/emojiGroup.md new file mode 100644 index 0000000000..02335593ed --- /dev/null +++ b/docs/API_docs/constructors/emojiGroup.md @@ -0,0 +1,31 @@ +--- +title: "emojiGroup" +description: "Represents an emoji category." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiGroup +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an [emoji category](https://core.telegram.org/api/custom-emoji#emoji-categories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Category name, i.e. "Animals", "Flags", "Faces" and so on...| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | Yes|A single custom emoji used as preview for the category.| +|emoticons|Array of [string](/API_docs/types/string.html) | Yes|A list of UTF-8 emojis, matching the category.| + + + +### Type: [EmojiGroup](/API_docs/types/EmojiGroup.html) + + +### Example: + +``` +$emojiGroup = ['_' => 'emojiGroup', 'title' => 'string', 'icon_emoji_id' => long, 'emoticons' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/emojiGroupGreeting.md b/docs/API_docs/constructors/emojiGroupGreeting.md new file mode 100644 index 0000000000..3e787883a6 --- /dev/null +++ b/docs/API_docs/constructors/emojiGroupGreeting.md @@ -0,0 +1,29 @@ +--- +title: "emojiGroupGreeting" +description: "emojiGroupGreeting attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiGroupGreeting +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|title|[string](/API_docs/types/string.html) | Yes| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | Yes| +|emoticons|Array of [string](/API_docs/types/string.html) | Yes| + + + +### Type: [EmojiGroup](/API_docs/types/EmojiGroup.html) + + +### Example: + +``` +$emojiGroupGreeting = ['_' => 'emojiGroupGreeting', 'title' => 'string', 'icon_emoji_id' => long, 'emoticons' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/emojiGroupPremium.md b/docs/API_docs/constructors/emojiGroupPremium.md new file mode 100644 index 0000000000..dea724226c --- /dev/null +++ b/docs/API_docs/constructors/emojiGroupPremium.md @@ -0,0 +1,28 @@ +--- +title: "emojiGroupPremium" +description: "emojiGroupPremium attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiGroupPremium +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|title|[string](/API_docs/types/string.html) | Yes| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | Yes| + + + +### Type: [EmojiGroup](/API_docs/types/EmojiGroup.html) + + +### Example: + +``` +$emojiGroupPremium = ['_' => 'emojiGroupPremium', 'title' => 'string', 'icon_emoji_id' => long]; +``` diff --git a/docs/API_docs/constructors/emojiKeyword.md b/docs/API_docs/constructors/emojiKeyword.md new file mode 100644 index 0000000000..3d0a8e5baa --- /dev/null +++ b/docs/API_docs/constructors/emojiKeyword.md @@ -0,0 +1,30 @@ +--- +title: "emojiKeyword" +description: "Emoji keyword" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiKeyword +[Back to constructors index](/API_docs/constructors/index.html) + + + +Emoji keyword + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|keyword|[string](/API_docs/types/string.html) | Yes|Keyword| +|emoticons|Array of [string](/API_docs/types/string.html) | Yes|Emojis associated to keyword| + + + +### Type: [EmojiKeyword](/API_docs/types/EmojiKeyword.html) + + +### Example: + +``` +$emojiKeyword = ['_' => 'emojiKeyword', 'keyword' => 'string', 'emoticons' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/emojiKeywordDeleted.md b/docs/API_docs/constructors/emojiKeywordDeleted.md new file mode 100644 index 0000000000..26e1e38cc7 --- /dev/null +++ b/docs/API_docs/constructors/emojiKeywordDeleted.md @@ -0,0 +1,30 @@ +--- +title: "emojiKeywordDeleted" +description: "Deleted emoji keyword" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiKeywordDeleted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Deleted emoji keyword + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|keyword|[string](/API_docs/types/string.html) | Yes|Keyword| +|emoticons|Array of [string](/API_docs/types/string.html) | Yes|Emojis that were associated to keyword| + + + +### Type: [EmojiKeyword](/API_docs/types/EmojiKeyword.html) + + +### Example: + +``` +$emojiKeywordDeleted = ['_' => 'emojiKeywordDeleted', 'keyword' => 'string', 'emoticons' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/emojiKeywordsDifference.md b/docs/API_docs/constructors/emojiKeywordsDifference.md new file mode 100644 index 0000000000..78474c4346 --- /dev/null +++ b/docs/API_docs/constructors/emojiKeywordsDifference.md @@ -0,0 +1,32 @@ +--- +title: "emojiKeywordsDifference" +description: "Changes to emoji keywords" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiKeywordsDifference +[Back to constructors index](/API_docs/constructors/index.html) + + + +Changes to emoji keywords + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lang\_code|[string](/API_docs/types/string.html) | Yes|Language code for keywords| +|from\_version|[int](/API_docs/types/int.html) | Yes|Previous emoji keyword list version| +|version|[int](/API_docs/types/int.html) | Yes|Current version of emoji keyword list| +|keywords|Array of [EmojiKeyword](/API_docs/types/EmojiKeyword.html) | Yes|Emojis associated to keywords| + + + +### Type: [EmojiKeywordsDifference](/API_docs/types/EmojiKeywordsDifference.html) + + +### Example: + +``` +$emojiKeywordsDifference = ['_' => 'emojiKeywordsDifference', 'lang_code' => 'string', 'from_version' => int, 'version' => int, 'keywords' => [EmojiKeyword, EmojiKeyword]]; +``` diff --git a/docs/API_docs/constructors/emojiLanguage.md b/docs/API_docs/constructors/emojiLanguage.md new file mode 100644 index 0000000000..1d91ad5dd3 --- /dev/null +++ b/docs/API_docs/constructors/emojiLanguage.md @@ -0,0 +1,29 @@ +--- +title: "emojiLanguage" +description: "Emoji language" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiLanguage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Emoji language + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lang\_code|[string](/API_docs/types/string.html) | Yes|Language code| + + + +### Type: [EmojiLanguage](/API_docs/types/EmojiLanguage.html) + + +### Example: + +``` +$emojiLanguage = ['_' => 'emojiLanguage', 'lang_code' => 'string']; +``` diff --git a/docs/API_docs/constructors/emojiList.md b/docs/API_docs/constructors/emojiList.md new file mode 100644 index 0000000000..8433222ebd --- /dev/null +++ b/docs/API_docs/constructors/emojiList.md @@ -0,0 +1,30 @@ +--- +title: "emojiList" +description: "Represents a list of custom emojis." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiList +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a list of [custom emojis](https://core.telegram.org/api/custom-emoji). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|document\_id|Array of [long](/API_docs/types/long.html) | Yes|Custom emoji IDs| + + + +### Type: [EmojiList](/API_docs/types/EmojiList.html) + + +### Example: + +``` +$emojiList = ['_' => 'emojiList', 'hash' => long, 'document_id' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/emojiListNotModified.md b/docs/API_docs/constructors/emojiListNotModified.md new file mode 100644 index 0000000000..94082eee66 --- /dev/null +++ b/docs/API_docs/constructors/emojiListNotModified.md @@ -0,0 +1,24 @@ +--- +title: "emojiListNotModified" +description: "The list of custom emojis hasn't changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiListNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of [custom emojis](https://core.telegram.org/api/custom-emoji) hasn't changed. + + + + +### Type: [EmojiList](/API_docs/types/EmojiList.html) + + +### Example: + +``` +$emojiListNotModified = ['_' => 'emojiListNotModified']; +``` diff --git a/docs/API_docs/constructors/emojiStatus.md b/docs/API_docs/constructors/emojiStatus.md new file mode 100644 index 0000000000..226fa91dac --- /dev/null +++ b/docs/API_docs/constructors/emojiStatus.md @@ -0,0 +1,29 @@ +--- +title: "emojiStatus" +description: "An emoji status" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiStatus +[Back to constructors index](/API_docs/constructors/index.html) + + + +An [emoji status](https://core.telegram.org/api/emoji-status) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document\_id|[long](/API_docs/types/long.html) | Yes|[Custom emoji document ID](https://core.telegram.org/api/custom-emoji)| + + + +### Type: [EmojiStatus](/API_docs/types/EmojiStatus.html) + + +### Example: + +``` +$emojiStatus = ['_' => 'emojiStatus', 'document_id' => long]; +``` diff --git a/docs/API_docs/constructors/emojiStatusEmpty.md b/docs/API_docs/constructors/emojiStatusEmpty.md new file mode 100644 index 0000000000..0d1c97006f --- /dev/null +++ b/docs/API_docs/constructors/emojiStatusEmpty.md @@ -0,0 +1,24 @@ +--- +title: "emojiStatusEmpty" +description: "No emoji status is set" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiStatusEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No emoji status is set + + + + +### Type: [EmojiStatus](/API_docs/types/EmojiStatus.html) + + +### Example: + +``` +$emojiStatusEmpty = ['_' => 'emojiStatusEmpty']; +``` diff --git a/docs/API_docs/constructors/emojiStatusUntil.md b/docs/API_docs/constructors/emojiStatusUntil.md new file mode 100644 index 0000000000..bb5c9f29d4 --- /dev/null +++ b/docs/API_docs/constructors/emojiStatusUntil.md @@ -0,0 +1,30 @@ +--- +title: "emojiStatusUntil" +description: "An emoji status valid until the specified date" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiStatusUntil +[Back to constructors index](/API_docs/constructors/index.html) + + + +An [emoji status](https://core.telegram.org/api/emoji-status) valid until the specified date + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document\_id|[long](/API_docs/types/long.html) | Yes|[Custom emoji document ID](https://core.telegram.org/api/custom-emoji)| +|until|[int](/API_docs/types/int.html) | Yes|This status is valid until this date| + + + +### Type: [EmojiStatus](/API_docs/types/EmojiStatus.html) + + +### Example: + +``` +$emojiStatusUntil = ['_' => 'emojiStatusUntil', 'document_id' => long, 'until' => int]; +``` diff --git a/docs/API_docs/constructors/emojiURL.md b/docs/API_docs/constructors/emojiURL.md new file mode 100644 index 0000000000..63695426e8 --- /dev/null +++ b/docs/API_docs/constructors/emojiURL.md @@ -0,0 +1,29 @@ +--- +title: "emojiURL" +description: "An HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: emojiURL +[Back to constructors index](/API_docs/constructors/index.html) + + + +An HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|An HTTP URL which can be used to automatically log in into translation platform and suggest new emoji replacements. The URL will be valid for 30 seconds after generation| + + + +### Type: [EmojiURL](/API_docs/types/EmojiURL.html) + + +### Example: + +``` +$emojiURL = ['_' => 'emojiURL', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/encryptedChat.md b/docs/API_docs/constructors/encryptedChat.md new file mode 100644 index 0000000000..01c694ffa6 --- /dev/null +++ b/docs/API_docs/constructors/encryptedChat.md @@ -0,0 +1,35 @@ +--- +title: "encryptedChat" +description: "Encrypted chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Encrypted chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Chat ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Check sum dependent on the user ID| +|date|[int](/API_docs/types/int.html) | Yes|Date chat was created| +|admin\_id|[long](/API_docs/types/long.html) | Yes|Chat creator ID| +|participant\_id|[long](/API_docs/types/long.html) | Yes|ID of the second chat participant| +|g\_a\_or\_b|[bytes](/API_docs/types/bytes.html) | Yes|`B = g ^ b mod p`, if the currently authorized user is the chat's creator,
or `A = g ^ a mod p` otherwise
See [Wikipedia](https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange) for more info| +|key\_fingerprint|[long](/API_docs/types/long.html) | Yes|64-bit fingerprint of received key| + + + +### Type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + + +### Example: + +``` +$encryptedChat = ['_' => 'encryptedChat', 'id' => int, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long, 'g_a_or_b' => 'bytes', 'key_fingerprint' => long]; +``` diff --git a/docs/API_docs/constructors/encryptedChatDiscarded.md b/docs/API_docs/constructors/encryptedChatDiscarded.md new file mode 100644 index 0000000000..0adec65030 --- /dev/null +++ b/docs/API_docs/constructors/encryptedChatDiscarded.md @@ -0,0 +1,30 @@ +--- +title: "encryptedChatDiscarded" +description: "Discarded or deleted chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedChatDiscarded +[Back to constructors index](/API_docs/constructors/index.html) + + + +Discarded or deleted chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|history\_deleted|[Bool](/API_docs/types/Bool.html) | Optional|Whether both users of this secret chat should also remove all of its messages| +|id|[int](/API_docs/types/int.html) | Yes|Chat ID| + + + +### Type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + + +### Example: + +``` +$encryptedChatDiscarded = ['_' => 'encryptedChatDiscarded', 'history_deleted' => Bool, 'id' => int]; +``` diff --git a/docs/API_docs/constructors/encryptedChatEmpty.md b/docs/API_docs/constructors/encryptedChatEmpty.md new file mode 100644 index 0000000000..4f3705ca68 --- /dev/null +++ b/docs/API_docs/constructors/encryptedChatEmpty.md @@ -0,0 +1,29 @@ +--- +title: "encryptedChatEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedChatEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Chat ID| + + + +### Type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + + +### Example: + +``` +$encryptedChatEmpty = ['_' => 'encryptedChatEmpty', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/encryptedChatRequested.md b/docs/API_docs/constructors/encryptedChatRequested.md new file mode 100644 index 0000000000..7b6e8552a5 --- /dev/null +++ b/docs/API_docs/constructors/encryptedChatRequested.md @@ -0,0 +1,35 @@ +--- +title: "encryptedChatRequested" +description: "Request to create an encrypted chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedChatRequested +[Back to constructors index](/API_docs/constructors/index.html) + + + +Request to create an encrypted chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|id|[int](/API_docs/types/int.html) | Yes|Chat ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Check sum depending on user ID| +|date|[int](/API_docs/types/int.html) | Yes|Chat creation date| +|admin\_id|[long](/API_docs/types/long.html) | Yes|Chat creator ID| +|participant\_id|[long](/API_docs/types/long.html) | Yes|ID of second chat participant| +|g\_a|[bytes](/API_docs/types/bytes.html) | Yes|`A = g ^ a mod p`, see [Wikipedia](https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange)| + + + +### Type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + + +### Example: + +``` +$encryptedChatRequested = ['_' => 'encryptedChatRequested', 'folder_id' => int, 'id' => int, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long, 'g_a' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/encryptedChatWaiting.md b/docs/API_docs/constructors/encryptedChatWaiting.md new file mode 100644 index 0000000000..e767679ae4 --- /dev/null +++ b/docs/API_docs/constructors/encryptedChatWaiting.md @@ -0,0 +1,33 @@ +--- +title: "encryptedChatWaiting" +description: "Chat waiting for approval of second participant." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedChatWaiting +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat waiting for approval of second participant. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Chat ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Checking sum depending on user ID| +|date|[int](/API_docs/types/int.html) | Yes|Date of chat creation| +|admin\_id|[long](/API_docs/types/long.html) | Yes|Chat creator ID| +|participant\_id|[long](/API_docs/types/long.html) | Yes|ID of second chat participant| + + + +### Type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + + +### Example: + +``` +$encryptedChatWaiting = ['_' => 'encryptedChatWaiting', 'id' => int, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long]; +``` diff --git a/docs/API_docs/constructors/encryptedFile.md b/docs/API_docs/constructors/encryptedFile.md new file mode 100644 index 0000000000..332ef51a8f --- /dev/null +++ b/docs/API_docs/constructors/encryptedFile.md @@ -0,0 +1,33 @@ +--- +title: "encryptedFile" +description: "Encrypted file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Encrypted file. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|File ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Checking sum depending on user ID| +|size|[long](/API_docs/types/long.html) | Yes|File size in bytes| +|dc\_id|[int](/API_docs/types/int.html) | Yes|Number of data center| +|key\_fingerprint|[int](/API_docs/types/int.html) | Yes|32-bit fingerprint of key used for file encryption| + + + +### Type: [EncryptedFile](/API_docs/types/EncryptedFile.html) + + +### Example: + +``` +$encryptedFile = ['_' => 'encryptedFile', 'id' => long, 'access_hash' => long, 'size' => long, 'dc_id' => int, 'key_fingerprint' => int]; +``` diff --git a/docs/API_docs/constructors/encryptedFileEmpty.md b/docs/API_docs/constructors/encryptedFileEmpty.md new file mode 100644 index 0000000000..5bd4233647 --- /dev/null +++ b/docs/API_docs/constructors/encryptedFileEmpty.md @@ -0,0 +1,24 @@ +--- +title: "encryptedFileEmpty" +description: "Empty constructor, non-existing file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedFileEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, non-existing file. + + + + +### Type: [EncryptedFile](/API_docs/types/EncryptedFile.html) + + +### Example: + +``` +$encryptedFileEmpty = ['_' => 'encryptedFileEmpty']; +``` diff --git a/docs/API_docs/constructors/encryptedMessage.md b/docs/API_docs/constructors/encryptedMessage.md new file mode 100644 index 0000000000..d255b6d44f --- /dev/null +++ b/docs/API_docs/constructors/encryptedMessage.md @@ -0,0 +1,32 @@ +--- +title: "encryptedMessage" +description: "Encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[int](/API_docs/types/int.html) | Yes|ID of encrypted chat| +|date|[int](/API_docs/types/int.html) | Yes|Date of sending| +|decrypted\_message|[DecryptedMessage](/API_docs/types/DecryptedMessage.html) | Yes| +|file|[EncryptedFile](/API_docs/types/EncryptedFile.html) | Optional|Attached encrypted file| + + + +### Type: [EncryptedMessage](/API_docs/types/EncryptedMessage.html) + + +### Example: + +``` +$encryptedMessage = ['_' => 'encryptedMessage', 'chat_id' => int, 'date' => int, 'decrypted_message' => DecryptedMessage, 'file' => EncryptedFile]; +``` diff --git a/docs/API_docs/constructors/encryptedMessageService.md b/docs/API_docs/constructors/encryptedMessageService.md new file mode 100644 index 0000000000..1feba76ece --- /dev/null +++ b/docs/API_docs/constructors/encryptedMessageService.md @@ -0,0 +1,31 @@ +--- +title: "encryptedMessageService" +description: "Encrypted service message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: encryptedMessageService +[Back to constructors index](/API_docs/constructors/index.html) + + + +Encrypted service message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[int](/API_docs/types/int.html) | Yes|ID of encrypted chat| +|date|[int](/API_docs/types/int.html) | Yes|Date of sending| +|decrypted\_message|[DecryptedMessage](/API_docs/types/DecryptedMessage.html) | Yes| + + + +### Type: [EncryptedMessage](/API_docs/types/EncryptedMessage.html) + + +### Example: + +``` +$encryptedMessageService = ['_' => 'encryptedMessageService', 'chat_id' => int, 'date' => int, 'decrypted_message' => DecryptedMessage]; +``` diff --git a/docs/API_docs/constructors/error.md b/docs/API_docs/constructors/error.md new file mode 100644 index 0000000000..cdd828be71 --- /dev/null +++ b/docs/API_docs/constructors/error.md @@ -0,0 +1,30 @@ +--- +title: "error" +description: "Error." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: error +[Back to constructors index](/API_docs/constructors/index.html) + + + +Error. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|code|[int](/API_docs/types/int.html) | Yes|Error code| +|text|[string](/API_docs/types/string.html) | Yes|Message| + + + +### Type: [Error](/API_docs/types/Error.html) + + +### Example: + +``` +$error = ['_' => 'error', 'code' => int, 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/exportedChatlistInvite.md b/docs/API_docs/constructors/exportedChatlistInvite.md new file mode 100644 index 0000000000..be24ec047f --- /dev/null +++ b/docs/API_docs/constructors/exportedChatlistInvite.md @@ -0,0 +1,31 @@ +--- +title: "exportedChatlistInvite" +description: "Exported chat folder deep link »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: exportedChatlistInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Exported [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Name of the link| +|url|[string](/API_docs/types/string.html) | Yes|The [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links).| +|peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|Peers to import| + + + +### Type: [ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html) + + +### Example: + +``` +$exportedChatlistInvite = ['_' => 'exportedChatlistInvite', 'title' => 'string', 'url' => 'string', 'peers' => [Peer, Peer]]; +``` diff --git a/docs/API_docs/constructors/exportedContactToken.md b/docs/API_docs/constructors/exportedContactToken.md new file mode 100644 index 0000000000..5974dc5982 --- /dev/null +++ b/docs/API_docs/constructors/exportedContactToken.md @@ -0,0 +1,30 @@ +--- +title: "exportedContactToken" +description: "Describes a temporary profile link." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: exportedContactToken +[Back to constructors index](/API_docs/constructors/index.html) + + + +Describes a [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|The [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links).| +|expires|[int](/API_docs/types/int.html) | Yes|Its expiration date| + + + +### Type: [ExportedContactToken](/API_docs/types/ExportedContactToken.html) + + +### Example: + +``` +$exportedContactToken = ['_' => 'exportedContactToken', 'url' => 'string', 'expires' => int]; +``` diff --git a/docs/API_docs/constructors/exportedMessageLink.md b/docs/API_docs/constructors/exportedMessageLink.md new file mode 100644 index 0000000000..68d4d88d37 --- /dev/null +++ b/docs/API_docs/constructors/exportedMessageLink.md @@ -0,0 +1,30 @@ +--- +title: "exportedMessageLink" +description: "Link to a message in a supergroup/channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: exportedMessageLink +[Back to constructors index](/API_docs/constructors/index.html) + + + +Link to a message in a supergroup/channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|link|[string](/API_docs/types/string.html) | Yes|URL| +|html|[string](/API_docs/types/string.html) | Yes|Embed code| + + + +### Type: [ExportedMessageLink](/API_docs/types/ExportedMessageLink.html) + + +### Example: + +``` +$exportedMessageLink = ['_' => 'exportedMessageLink', 'link' => 'string', 'html' => 'string']; +``` diff --git a/docs/API_docs/constructors/exportedStoryLink.md b/docs/API_docs/constructors/exportedStoryLink.md new file mode 100644 index 0000000000..dac7d3bfc0 --- /dev/null +++ b/docs/API_docs/constructors/exportedStoryLink.md @@ -0,0 +1,29 @@ +--- +title: "exportedStoryLink" +description: "Represents a story deep link." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: exportedStoryLink +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [story deep link](https://core.telegram.org/api/stories#story-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|link|[string](/API_docs/types/string.html) | Yes|The [story deep link](https://core.telegram.org/api/stories#story-links).| + + + +### Type: [ExportedStoryLink](/API_docs/types/ExportedStoryLink.html) + + +### Example: + +``` +$exportedStoryLink = ['_' => 'exportedStoryLink', 'link' => 'string']; +``` diff --git a/docs/API_docs/constructors/fileHash.md b/docs/API_docs/constructors/fileHash.md new file mode 100644 index 0000000000..5179b5d743 --- /dev/null +++ b/docs/API_docs/constructors/fileHash.md @@ -0,0 +1,31 @@ +--- +title: "fileHash" +description: "SHA256 Hash of an uploaded file, to be checked for validity after download" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: fileHash +[Back to constructors index](/API_docs/constructors/index.html) + + + +SHA256 Hash of an uploaded file, to be checked for validity after download + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[long](/API_docs/types/long.html) | Yes|Offset from where to start computing SHA-256 hash| +|limit|[int](/API_docs/types/int.html) | Yes|Length| +|hash|[bytes](/API_docs/types/bytes.html) | Yes|SHA-256 Hash of file chunk, to be checked for validity after download| + + + +### Type: [FileHash](/API_docs/types/FileHash.html) + + +### Example: + +``` +$fileHash = ['_' => 'fileHash', 'offset' => long, 'limit' => int, 'hash' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/fileLocationUnavailable_23.md b/docs/API_docs/constructors/fileLocationUnavailable_23.md new file mode 100644 index 0000000000..b49b0d4459 --- /dev/null +++ b/docs/API_docs/constructors/fileLocationUnavailable_23.md @@ -0,0 +1,29 @@ +--- +title: "fileLocationUnavailable" +description: "fileLocationUnavailable attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: fileLocationUnavailable\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|volume\_id|[long](/API_docs/types/long.html) | Yes| +|local\_id|[int](/API_docs/types/int.html) | Yes| +|secret|[long](/API_docs/types/long.html) | Yes| + + + +### Type: [FileLocation](/API_docs/types/FileLocation.html) + + +### Example: + +``` +$fileLocationUnavailable_23 = ['_' => 'fileLocationUnavailable', 'volume_id' => long, 'local_id' => int, 'secret' => long]; +``` diff --git a/docs/API_docs/constructors/fileLocation_23.md b/docs/API_docs/constructors/fileLocation_23.md new file mode 100644 index 0000000000..3a15234371 --- /dev/null +++ b/docs/API_docs/constructors/fileLocation_23.md @@ -0,0 +1,30 @@ +--- +title: "fileLocation" +description: "fileLocation attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: fileLocation\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|dc\_id|[int](/API_docs/types/int.html) | Yes| +|volume\_id|[long](/API_docs/types/long.html) | Yes| +|local\_id|[int](/API_docs/types/int.html) | Yes| +|secret|[long](/API_docs/types/long.html) | Yes| + + + +### Type: [FileLocation](/API_docs/types/FileLocation.html) + + +### Example: + +``` +$fileLocation_23 = ['_' => 'fileLocation', 'dc_id' => int, 'volume_id' => long, 'local_id' => int, 'secret' => long]; +``` diff --git a/docs/API_docs/constructors/folder.md b/docs/API_docs/constructors/folder.md new file mode 100644 index 0000000000..e36ab3a1c8 --- /dev/null +++ b/docs/API_docs/constructors/folder.md @@ -0,0 +1,34 @@ +--- +title: "folder" +description: "Folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: folder +[Back to constructors index](/API_docs/constructors/index.html) + + + +Folder + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|autofill\_new\_broadcasts|[Bool](/API_docs/types/Bool.html) | Optional|Automatically add new channels to this folder| +|autofill\_public\_groups|[Bool](/API_docs/types/Bool.html) | Optional|Automatically add joined new public supergroups to this folder| +|autofill\_new\_correspondents|[Bool](/API_docs/types/Bool.html) | Optional|Automatically add new private chats to this folder| +|id|[int](/API_docs/types/int.html) | Yes|Folder ID| +|title|[string](/API_docs/types/string.html) | Yes|Folder title| +|photo|[ChatPhoto](/API_docs/types/ChatPhoto.html) | Optional|Folder picture| + + + +### Type: [Folder](/API_docs/types/Folder.html) + + +### Example: + +``` +$folder = ['_' => 'folder', 'autofill_new_broadcasts' => Bool, 'autofill_public_groups' => Bool, 'autofill_new_correspondents' => Bool, 'id' => int, 'title' => 'string', 'photo' => ChatPhoto]; +``` diff --git a/docs/API_docs/constructors/folderPeer.md b/docs/API_docs/constructors/folderPeer.md new file mode 100644 index 0000000000..760fbcc958 --- /dev/null +++ b/docs/API_docs/constructors/folderPeer.md @@ -0,0 +1,30 @@ +--- +title: "folderPeer" +description: "Peer in a folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: folderPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer in a folder + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Folder peer info| +|folder\_id|[int](/API_docs/types/int.html) | Yes|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| + + + +### Type: [FolderPeer](/API_docs/types/FolderPeer.html) + + +### Example: + +``` +$folderPeer = ['_' => 'folderPeer', 'peer' => long, 'folder_id' => int]; +``` diff --git a/docs/API_docs/constructors/forumTopic.md b/docs/API_docs/constructors/forumTopic.md new file mode 100644 index 0000000000..3fdc08e4a4 --- /dev/null +++ b/docs/API_docs/constructors/forumTopic.md @@ -0,0 +1,47 @@ +--- +title: "forumTopic" +description: "Represents a forum topic." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: forumTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [forum topic](https://core.telegram.org/api/forum#forum-topics). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|my|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic was created by the current user| +|closed|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic is closed (no messages can be sent to it)| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic is pinned| +|short|[Bool](/API_docs/types/Bool.html) | Optional|Whether this constructor is a reduced version of the full topic information.
If set, only the `my`, `closed`, `id`, `date`, `title`, `icon_color`, `icon_emoji_id` and `from_id` parameters will contain valid information.
Reduced info is usually only returned in topic-related [admin log events »](https://core.telegram.org/api/recent-actions) and in the [messages.channelMessages](../constructors/messages.channelMessages.html) constructor: if needed, full information can be fetched using [channels.getForumTopicsByID](../methods/channels.getForumTopicsByID.html).| +|hidden|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic is hidden (only valid for the "General" topic, `id=1`)| +|id|[int](/API_docs/types/int.html) | Yes|[Topic ID](https://core.telegram.org/api/forum#forum-topics)| +|date|[int](/API_docs/types/int.html) | Yes|Topic creation date| +|title|[string](/API_docs/types/string.html) | Yes|Topic title| +|icon\_color|[int](/API_docs/types/int.html) | Yes|If no custom emoji icon is specified, specifies the color of the fallback topic icon (RGB), one of `0x6FB9F0`, `0xFFD67E`, `0xCB86DB`, `0x8EEE98`, `0xFF93B2`, or `0xFB6F5F`.| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | Optional|ID of the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon.| +|top\_message|[int](/API_docs/types/int.html) | Yes|ID of the last message that was sent to this topic| +|read\_inbox\_max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all incoming messages are read.| +|read\_outbox\_max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all outgoing messages are read.| +|unread\_count|[int](/API_docs/types/int.html) | Yes|Number of unread messages| +|unread\_mentions\_count|[int](/API_docs/types/int.html) | Yes|Number of [unread mentions](https://core.telegram.org/api/mentions)| +|unread\_reactions\_count|[int](/API_docs/types/int.html) | Yes|Number of unread reactions to messages you sent| +|from\_id|[Peer](/API_docs/types/Peer.html) | Yes|ID of the peer that created the topic| +|notify\_settings|[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) | Yes|Notification settings| +|draft|[DraftMessage](/API_docs/types/DraftMessage.html) | Optional|Message [draft](https://core.telegram.org/api/drafts)| + + + +### Type: [ForumTopic](/API_docs/types/ForumTopic.html) + + +### Example: + +``` +$forumTopic = ['_' => 'forumTopic', 'my' => Bool, 'closed' => Bool, 'pinned' => Bool, 'short' => Bool, 'hidden' => Bool, 'id' => int, 'date' => int, 'title' => 'string', 'icon_color' => int, 'icon_emoji_id' => long, 'top_message' => int, 'read_inbox_max_id' => int, 'read_outbox_max_id' => int, 'unread_count' => int, 'unread_mentions_count' => int, 'unread_reactions_count' => int, 'from_id' => Peer, 'notify_settings' => PeerNotifySettings, 'draft' => DraftMessage]; +``` diff --git a/docs/API_docs/constructors/forumTopicDeleted.md b/docs/API_docs/constructors/forumTopicDeleted.md new file mode 100644 index 0000000000..24593a4290 --- /dev/null +++ b/docs/API_docs/constructors/forumTopicDeleted.md @@ -0,0 +1,29 @@ +--- +title: "forumTopicDeleted" +description: "Represents a deleted forum topic." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: forumTopicDeleted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a deleted forum topic. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|The ID of the deleted forum topic.| + + + +### Type: [ForumTopic](/API_docs/types/ForumTopic.html) + + +### Example: + +``` +$forumTopicDeleted = ['_' => 'forumTopicDeleted', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/fragment.collectibleInfo.md b/docs/API_docs/constructors/fragment.collectibleInfo.md new file mode 100644 index 0000000000..8d1e6008e6 --- /dev/null +++ b/docs/API_docs/constructors/fragment.collectibleInfo.md @@ -0,0 +1,33 @@ +--- +title: "fragment.collectibleInfo" +description: "fragment.collectibleInfo attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/fragment_collectibleInfo.html +--- +# Constructor: fragment.collectibleInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|purchase\_date|[int](/API_docs/types/int.html) | Yes| +|currency|[string](/API_docs/types/string.html) | Yes| +|amount|[long](/API_docs/types/long.html) | Yes| +|crypto\_currency|[string](/API_docs/types/string.html) | Yes| +|crypto\_amount|[long](/API_docs/types/long.html) | Yes| +|url|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [fragment.CollectibleInfo](/API_docs/types/fragment.CollectibleInfo.html) + + +### Example: + +``` +$fragment_collectibleInfo = ['_' => 'fragment.collectibleInfo', 'purchase_date' => int, 'currency' => 'string', 'amount' => long, 'crypto_currency' => 'string', 'crypto_amount' => long, 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/game.md b/docs/API_docs/constructors/game.md new file mode 100644 index 0000000000..1543a18285 --- /dev/null +++ b/docs/API_docs/constructors/game.md @@ -0,0 +1,35 @@ +--- +title: "game" +description: "Indicates an already sent game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: game +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates an already sent game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|ID of the game| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash of the game| +|short\_name|[string](/API_docs/types/string.html) | Yes|Short name for the game| +|title|[string](/API_docs/types/string.html) | Yes|Title of the game| +|description|[string](/API_docs/types/string.html) | Yes|Game description| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|Game preview| +|document|[Document](/API_docs/types/Document.html) | Optional|Optional attached document| + + + +### Type: [Game](/API_docs/types/Game.html) + + +### Example: + +``` +$game = ['_' => 'game', 'id' => long, 'access_hash' => long, 'short_name' => 'string', 'title' => 'string', 'description' => 'string', 'photo' => Photo, 'document' => Document]; +``` diff --git a/docs/API_docs/constructors/geoPoint.md b/docs/API_docs/constructors/geoPoint.md new file mode 100644 index 0000000000..ef8157f41b --- /dev/null +++ b/docs/API_docs/constructors/geoPoint.md @@ -0,0 +1,32 @@ +--- +title: "geoPoint" +description: "GeoPoint." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: geoPoint +[Back to constructors index](/API_docs/constructors/index.html) + + + +GeoPoint. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|long|[double](/API_docs/types/double.html) | Yes|Longitude| +|lat|[double](/API_docs/types/double.html) | Yes|Latitude| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|accuracy\_radius|[int](/API_docs/types/int.html) | Optional|The estimated horizontal accuracy of the location, in meters; as defined by the sender.| + + + +### Type: [GeoPoint](/API_docs/types/GeoPoint.html) + + +### Example: + +``` +$geoPoint = ['_' => 'geoPoint', 'long' => double, 'lat' => double, 'access_hash' => long, 'accuracy_radius' => int]; +``` diff --git a/docs/API_docs/constructors/geoPointEmpty.md b/docs/API_docs/constructors/geoPointEmpty.md new file mode 100644 index 0000000000..a2447e8566 --- /dev/null +++ b/docs/API_docs/constructors/geoPointEmpty.md @@ -0,0 +1,24 @@ +--- +title: "geoPointEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: geoPointEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + + + + +### Type: [GeoPoint](/API_docs/types/GeoPoint.html) + + +### Example: + +``` +$geoPointEmpty = ['_' => 'geoPointEmpty']; +``` diff --git a/docs/API_docs/constructors/globalPrivacySettings.md b/docs/API_docs/constructors/globalPrivacySettings.md new file mode 100644 index 0000000000..e4f9c60998 --- /dev/null +++ b/docs/API_docs/constructors/globalPrivacySettings.md @@ -0,0 +1,33 @@ +--- +title: "globalPrivacySettings" +description: "Global privacy settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: globalPrivacySettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Global privacy settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|archive\_and\_mute\_new\_noncontact\_peers|[Bool](/API_docs/types/Bool.html) | Optional|Whether to archive and mute new chats from non-contacts| +|keep\_archived\_unmuted|[Bool](/API_docs/types/Bool.html) | Optional|Whether unmuted chats will be kept in the Archive chat list when they get a new message.| +|keep\_archived\_folders|[Bool](/API_docs/types/Bool.html) | Optional|Whether unmuted chats that are always included or pinned in a [folder](https://core.telegram.org/api/folders), will be kept in the Archive chat list when they get a new message. Ignored if `keep_archived_unmuted` is set.| +|hide\_read\_marks|[Bool](/API_docs/types/Bool.html) | Optional| +|new\_noncontact\_peers\_require\_premium|[Bool](/API_docs/types/Bool.html) | Optional| + + + +### Type: [GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) + + +### Example: + +``` +$globalPrivacySettings = ['_' => 'globalPrivacySettings', 'archive_and_mute_new_noncontact_peers' => Bool, 'keep_archived_unmuted' => Bool, 'keep_archived_folders' => Bool, 'hide_read_marks' => Bool, 'new_noncontact_peers_require_premium' => Bool]; +``` diff --git a/docs/API_docs/constructors/groupCall.md b/docs/API_docs/constructors/groupCall.md new file mode 100644 index 0000000000..6ba5d9ad28 --- /dev/null +++ b/docs/API_docs/constructors/groupCall.md @@ -0,0 +1,46 @@ +--- +title: "groupCall" +description: "Info about a group call or livestream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: groupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a group call or livestream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|join\_muted|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user should be muted upon joining the call| +|can\_change\_join\_muted|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user can change the value of the `join_muted` flag using [phone.toggleGroupCallSettings](../methods/phone.toggleGroupCallSettings.html)| +|join\_date\_asc|[Bool](/API_docs/types/Bool.html) | Optional|Specifies the ordering to use when locally sorting by date and displaying in the UI group call participants.| +|schedule\_start\_subscribed|[Bool](/API_docs/types/Bool.html) | Optional|Whether we subscribed to the scheduled call| +|can\_start\_video|[Bool](/API_docs/types/Bool.html) | Optional|Whether you can start streaming video into the call| +|record\_video\_active|[Bool](/API_docs/types/Bool.html) | Optional|Whether the group call is currently being recorded| +|rtmp\_stream|[Bool](/API_docs/types/Bool.html) | Optional|Whether RTMP streams are allowed| +|listeners\_hidden|[Bool](/API_docs/types/Bool.html) | Optional|Whether the listeners list is hidden and cannot be fetched using [phone.getGroupParticipants](../methods/phone.getGroupParticipants.html). The `phone.groupParticipants.count` and `groupCall.participants_count` counters will still include listeners.| +|id|[long](/API_docs/types/long.html) | Yes|Group call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Group call access hash| +|participants\_count|[int](/API_docs/types/int.html) | Yes|Participant count| +|title|[string](/API_docs/types/string.html) | Optional|Group call title| +|stream\_dc\_id|[int](/API_docs/types/int.html) | Optional|DC ID to be used for livestream chunks| +|record\_start\_date|[int](/API_docs/types/int.html) | Optional|When was the recording started| +|schedule\_date|[int](/API_docs/types/int.html) | Optional|When is the call scheduled to start| +|unmuted\_video\_count|[int](/API_docs/types/int.html) | Optional|Number of people currently streaming video into the call| +|unmuted\_video\_limit|[int](/API_docs/types/int.html) | Yes|Maximum number of people allowed to stream video into the call| +|version|[int](/API_docs/types/int.html) | Yes|Version| + + + +### Type: [GroupCall](/API_docs/types/GroupCall.html) + + +### Example: + +``` +$groupCall = ['_' => 'groupCall', 'join_muted' => Bool, 'can_change_join_muted' => Bool, 'join_date_asc' => Bool, 'schedule_start_subscribed' => Bool, 'can_start_video' => Bool, 'record_video_active' => Bool, 'rtmp_stream' => Bool, 'listeners_hidden' => Bool, 'id' => long, 'access_hash' => long, 'participants_count' => int, 'title' => 'string', 'stream_dc_id' => int, 'record_start_date' => int, 'schedule_date' => int, 'unmuted_video_count' => int, 'unmuted_video_limit' => int, 'version' => int]; +``` diff --git a/docs/API_docs/constructors/groupCallDiscarded.md b/docs/API_docs/constructors/groupCallDiscarded.md new file mode 100644 index 0000000000..0d74010edf --- /dev/null +++ b/docs/API_docs/constructors/groupCallDiscarded.md @@ -0,0 +1,31 @@ +--- +title: "groupCallDiscarded" +description: "An ended group call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: groupCallDiscarded +[Back to constructors index](/API_docs/constructors/index.html) + + + +An ended group call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Group call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Group call access hash| +|duration|[int](/API_docs/types/int.html) | Yes|Group call duration| + + + +### Type: [GroupCall](/API_docs/types/GroupCall.html) + + +### Example: + +``` +$groupCallDiscarded = ['_' => 'groupCallDiscarded', 'id' => long, 'access_hash' => long, 'duration' => int]; +``` diff --git a/docs/API_docs/constructors/groupCallParticipant.md b/docs/API_docs/constructors/groupCallParticipant.md new file mode 100644 index 0000000000..ee36894dfd --- /dev/null +++ b/docs/API_docs/constructors/groupCallParticipant.md @@ -0,0 +1,47 @@ +--- +title: "groupCallParticipant" +description: "Info about a group call participant" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: groupCallParticipant +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a group call participant + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|muted|[Bool](/API_docs/types/Bool.html) | Optional|Whether the participant is muted| +|left|[Bool](/API_docs/types/Bool.html) | Optional|Whether the participant has left| +|can\_self\_unmute|[Bool](/API_docs/types/Bool.html) | Optional|Whether the participant can unmute themselves| +|just\_joined|[Bool](/API_docs/types/Bool.html) | Optional|Whether the participant has just joined| +|versioned|[Bool](/API_docs/types/Bool.html) | Optional|If set, and [updateGroupCallParticipants](../constructors/updateGroupCallParticipants.html).version < locally stored call.version, info about this participant should be ignored. If (...), and [updateGroupCallParticipants](../constructors/updateGroupCallParticipants.html).version > call.version+1, the participant list should be refetched using [phone.getGroupParticipants](../methods/phone.getGroupParticipants.html).| +|min|[Bool](/API_docs/types/Bool.html) | Optional|If not set, the `volume` and `muted_by_you` fields can be safely used to overwrite locally cached information; otherwise, `volume` will contain valid information only if `volume_by_admin` is set both in the cache and in the received constructor.| +|muted\_by\_you|[Bool](/API_docs/types/Bool.html) | Optional|Whether this participant was muted by the current user| +|volume\_by\_admin|[Bool](/API_docs/types/Bool.html) | Optional|Whether our volume can only changed by an admin| +|self|[Bool](/API_docs/types/Bool.html) | Optional|Whether this participant is the current user| +|video\_joined|[Bool](/API_docs/types/Bool.html) | Optional|Whether this participant is currently broadcasting video| +|peer|[long](/API_docs/types/long.html) | Yes|Peer information| +|date|[int](/API_docs/types/int.html) | Yes|When did this participant join the group call| +|active\_date|[int](/API_docs/types/int.html) | Optional|When was this participant last active in the group call| +|source|[int](/API_docs/types/int.html) | Yes|Source ID| +|volume|[int](/API_docs/types/int.html) | Optional|Volume, if not set the volume is set to 100%.| +|about|[string](/API_docs/types/string.html) | Optional|Info about this participant| +|raise\_hand\_rating|[long](/API_docs/types/long.html) | Optional|Specifies the UI visualization order of peers with raised hands: peers with a higher rating should be showed first in the list.| +|video|[GroupCallParticipantVideo](/API_docs/types/GroupCallParticipantVideo.html) | Optional|Info about the video stream the participant is currently broadcasting| +|presentation|[GroupCallParticipantVideo](/API_docs/types/GroupCallParticipantVideo.html) | Optional|Info about the screen sharing stream the participant is currently broadcasting| + + + +### Type: [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) + + +### Example: + +``` +$groupCallParticipant = ['_' => 'groupCallParticipant', 'muted' => Bool, 'left' => Bool, 'can_self_unmute' => Bool, 'just_joined' => Bool, 'versioned' => Bool, 'min' => Bool, 'muted_by_you' => Bool, 'volume_by_admin' => Bool, 'self' => Bool, 'video_joined' => Bool, 'peer' => long, 'date' => int, 'active_date' => int, 'source' => int, 'volume' => int, 'about' => 'string', 'raise_hand_rating' => long, 'video' => GroupCallParticipantVideo, 'presentation' => GroupCallParticipantVideo]; +``` diff --git a/docs/API_docs/constructors/groupCallParticipantVideo.md b/docs/API_docs/constructors/groupCallParticipantVideo.md new file mode 100644 index 0000000000..ac662fc369 --- /dev/null +++ b/docs/API_docs/constructors/groupCallParticipantVideo.md @@ -0,0 +1,32 @@ +--- +title: "groupCallParticipantVideo" +description: "Info about a video stream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: groupCallParticipantVideo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a video stream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|paused|[Bool](/API_docs/types/Bool.html) | Optional|Whether the stream is currently paused| +|endpoint|[string](/API_docs/types/string.html) | Yes|Endpoint| +|source\_groups|Array of [GroupCallParticipantVideoSourceGroup](/API_docs/types/GroupCallParticipantVideoSourceGroup.html) | Yes|Source groups| +|audio\_source|[int](/API_docs/types/int.html) | Optional|Audio source ID| + + + +### Type: [GroupCallParticipantVideo](/API_docs/types/GroupCallParticipantVideo.html) + + +### Example: + +``` +$groupCallParticipantVideo = ['_' => 'groupCallParticipantVideo', 'paused' => Bool, 'endpoint' => 'string', 'source_groups' => [GroupCallParticipantVideoSourceGroup, GroupCallParticipantVideoSourceGroup], 'audio_source' => int]; +``` diff --git a/docs/API_docs/constructors/groupCallParticipantVideoSourceGroup.md b/docs/API_docs/constructors/groupCallParticipantVideoSourceGroup.md new file mode 100644 index 0000000000..b921542fe0 --- /dev/null +++ b/docs/API_docs/constructors/groupCallParticipantVideoSourceGroup.md @@ -0,0 +1,30 @@ +--- +title: "groupCallParticipantVideoSourceGroup" +description: "Describes a group of video synchronization source identifiers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: groupCallParticipantVideoSourceGroup +[Back to constructors index](/API_docs/constructors/index.html) + + + +Describes a group of video synchronization source identifiers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|semantics|[string](/API_docs/types/string.html) | Yes|SDP semantics| +|sources|Array of [int](/API_docs/types/int.html) | Yes|Source IDs| + + + +### Type: [GroupCallParticipantVideoSourceGroup](/API_docs/types/GroupCallParticipantVideoSourceGroup.html) + + +### Example: + +``` +$groupCallParticipantVideoSourceGroup = ['_' => 'groupCallParticipantVideoSourceGroup', 'semantics' => 'string', 'sources' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/groupCallStreamChannel.md b/docs/API_docs/constructors/groupCallStreamChannel.md new file mode 100644 index 0000000000..cc8c73d3ca --- /dev/null +++ b/docs/API_docs/constructors/groupCallStreamChannel.md @@ -0,0 +1,31 @@ +--- +title: "groupCallStreamChannel" +description: "Info about an RTMP stream in a group call or livestream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: groupCallStreamChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about an RTMP stream in a group call or livestream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel|[int](/API_docs/types/int.html) | Yes|Channel ID| +|scale|[int](/API_docs/types/int.html) | Yes|Specifies the duration of the video segment to fetch in milliseconds, by bitshifting `1000` to the right `scale` times: `duration_ms := 1000 >> scale`.| +|last\_timestamp\_ms|[long](/API_docs/types/long.html) | Yes|Last seen timestamp to easily start fetching livestream chunks using [inputGroupCallStream](../constructors/inputGroupCallStream.html)| + + + +### Type: [GroupCallStreamChannel](/API_docs/types/GroupCallStreamChannel.html) + + +### Example: + +``` +$groupCallStreamChannel = ['_' => 'groupCallStreamChannel', 'channel' => int, 'scale' => int, 'last_timestamp_ms' => long]; +``` diff --git a/docs/API_docs/constructors/help.appConfig.md b/docs/API_docs/constructors/help.appConfig.md new file mode 100644 index 0000000000..232180377b --- /dev/null +++ b/docs/API_docs/constructors/help.appConfig.md @@ -0,0 +1,31 @@ +--- +title: "help.appConfig" +description: "Contains various client configuration parameters" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_appConfig.html +--- +# Constructor: help.appConfig +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains various [client configuration parameters](https://core.telegram.org/api/config#client-configuration) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[int](/API_docs/types/int.html) | Yes| +|config|[JSONValue](/API_docs/types/JSONValue.html) | Yes|[Client configuration parameters](https://core.telegram.org/api/config#client-configuration)| + + + +### Type: [help.AppConfig](/API_docs/types/help.AppConfig.html) + + +### Example: + +``` +$help_appConfig = ['_' => 'help.appConfig', 'hash' => int, 'config' => JSONValue]; +``` diff --git a/docs/API_docs/constructors/help.appConfigNotModified.md b/docs/API_docs/constructors/help.appConfigNotModified.md new file mode 100644 index 0000000000..0f7714424b --- /dev/null +++ b/docs/API_docs/constructors/help.appConfigNotModified.md @@ -0,0 +1,25 @@ +--- +title: "help.appConfigNotModified" +description: "The client configuration parameters haven't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_appConfigNotModified.html +--- +# Constructor: help.appConfigNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The client configuration parameters haven't changed + + + + +### Type: [help.AppConfig](/API_docs/types/help.AppConfig.html) + + +### Example: + +``` +$help_appConfigNotModified = ['_' => 'help.appConfigNotModified']; +``` diff --git a/docs/API_docs/constructors/help.appUpdate.md b/docs/API_docs/constructors/help.appUpdate.md new file mode 100644 index 0000000000..b709346533 --- /dev/null +++ b/docs/API_docs/constructors/help.appUpdate.md @@ -0,0 +1,98 @@ +--- +title: "help.appUpdate" +description: "An update is available for the application." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_appUpdate.html +--- +# Constructor: help.appUpdate +[Back to constructors index](/API_docs/constructors/index.html) + + + +An update is available for the application. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|can\_not\_skip|[Bool](/API_docs/types/Bool.html) | Optional|Unskippable, the new info must be shown to the user (with a popup or something else)| +|id|[int](/API_docs/types/int.html) | Yes|Update ID| +|version|[string](/API_docs/types/string.html) | Yes|New version name| +|text|[string](/API_docs/types/string.html) | Yes|Text description of the update| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Yes|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|document|[Document](/API_docs/types/Document.html) | Optional|Application binary| +|url|[string](/API_docs/types/string.html) | Optional|Application download URL| +|sticker|[Document](/API_docs/types/Document.html) | Optional|Associated sticker| + + + +### Type: [help.AppUpdate](/API_docs/types/help.AppUpdate.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$help_appUpdate = ['_' => 'help.appUpdate', 'can_not_skip' => Bool, 'id' => int, 'version' => 'string', 'text' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'document' => Document, 'url' => 'string', 'sticker' => Document]; +``` diff --git a/docs/API_docs/constructors/help.countriesList.md b/docs/API_docs/constructors/help.countriesList.md new file mode 100644 index 0000000000..d83e199138 --- /dev/null +++ b/docs/API_docs/constructors/help.countriesList.md @@ -0,0 +1,31 @@ +--- +title: "help.countriesList" +description: "Name, ISO code, localized name and phone codes/patterns of all available countries" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_countriesList.html +--- +# Constructor: help.countriesList +[Back to constructors index](/API_docs/constructors/index.html) + + + +Name, ISO code, localized name and phone codes/patterns of all available countries + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|countries|Array of [help.Country](/API_docs/constructors/help.Country.html) | Yes|Name, ISO code, localized name and phone codes/patterns of all available countries| +|hash|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [help.CountriesList](/API_docs/types/help.CountriesList.html) + + +### Example: + +``` +$help_countriesList = ['_' => 'help.countriesList', 'countries' => [help.Country, help.Country], 'hash' => int]; +``` diff --git a/docs/API_docs/constructors/help.countriesListNotModified.md b/docs/API_docs/constructors/help.countriesListNotModified.md new file mode 100644 index 0000000000..9593732ab8 --- /dev/null +++ b/docs/API_docs/constructors/help.countriesListNotModified.md @@ -0,0 +1,25 @@ +--- +title: "help.countriesListNotModified" +description: "The country list has not changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_countriesListNotModified.html +--- +# Constructor: help.countriesListNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The country list has not changed + + + + +### Type: [help.CountriesList](/API_docs/types/help.CountriesList.html) + + +### Example: + +``` +$help_countriesListNotModified = ['_' => 'help.countriesListNotModified']; +``` diff --git a/docs/API_docs/constructors/help.country.md b/docs/API_docs/constructors/help.country.md new file mode 100644 index 0000000000..7db00f6aba --- /dev/null +++ b/docs/API_docs/constructors/help.country.md @@ -0,0 +1,34 @@ +--- +title: "help.country" +description: "Name, ISO code, localized name and phone codes/patterns of a specific country" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_country.html +--- +# Constructor: help.country +[Back to constructors index](/API_docs/constructors/index.html) + + + +Name, ISO code, localized name and phone codes/patterns of a specific country + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hidden|[Bool](/API_docs/types/Bool.html) | Optional|Whether this country should not be shown in the list| +|iso2|[string](/API_docs/types/string.html) | Yes|ISO code of country| +|default\_name|[string](/API_docs/types/string.html) | Yes|Name of the country in the country's language| +|name|[string](/API_docs/types/string.html) | Optional|Name of the country in the user's language, if different from the original name| +|country\_codes|Array of [help.CountryCode](/API_docs/constructors/help.CountryCode.html) | Yes|Phone codes/patterns| + + + +### Type: [help.Country](/API_docs/types/help.Country.html) + + +### Example: + +``` +$help_country = ['_' => 'help.country', 'hidden' => Bool, 'iso2' => 'string', 'default_name' => 'string', 'name' => 'string', 'country_codes' => [help.CountryCode, help.CountryCode]]; +``` diff --git a/docs/API_docs/constructors/help.countryCode.md b/docs/API_docs/constructors/help.countryCode.md new file mode 100644 index 0000000000..de23cd3762 --- /dev/null +++ b/docs/API_docs/constructors/help.countryCode.md @@ -0,0 +1,32 @@ +--- +title: "help.countryCode" +description: "Country code and phone number pattern of a specific country" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_countryCode.html +--- +# Constructor: help.countryCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Country code and phone number pattern of a specific country + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|country\_code|[string](/API_docs/types/string.html) | Yes|ISO country code| +|prefixes|Array of [string](/API_docs/types/string.html) | Optional|Possible phone prefixes| +|patterns|Array of [string](/API_docs/types/string.html) | Optional|Phone patterns: for example, `XXX XXX XXX`| + + + +### Type: [help.CountryCode](/API_docs/types/help.CountryCode.html) + + +### Example: + +``` +$help_countryCode = ['_' => 'help.countryCode', 'country_code' => 'string', 'prefixes' => ['string', 'string'], 'patterns' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/help.deepLinkInfo.md b/docs/API_docs/constructors/help.deepLinkInfo.md new file mode 100644 index 0000000000..ab3d0dae4e --- /dev/null +++ b/docs/API_docs/constructors/help.deepLinkInfo.md @@ -0,0 +1,93 @@ +--- +title: "help.deepLinkInfo" +description: "Deep link info, see the here for more details" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_deepLinkInfo.html +--- +# Constructor: help.deepLinkInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Deep link info, see [the here for more details](https://core.telegram.org/api/links#unsupported-links) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|update\_app|[Bool](/API_docs/types/Bool.html) | Optional|An update of the app is required to parse this link| +|message|[string](/API_docs/types/string.html) | Yes|Message to show to the user| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + + +### Type: [help.DeepLinkInfo](/API_docs/types/help.DeepLinkInfo.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$help_deepLinkInfo = ['_' => 'help.deepLinkInfo', 'update_app' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', ]; +``` diff --git a/docs/API_docs/constructors/help.deepLinkInfoEmpty.md b/docs/API_docs/constructors/help.deepLinkInfoEmpty.md new file mode 100644 index 0000000000..1d032d92bf --- /dev/null +++ b/docs/API_docs/constructors/help.deepLinkInfoEmpty.md @@ -0,0 +1,25 @@ +--- +title: "help.deepLinkInfoEmpty" +description: "Deep link info empty" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_deepLinkInfoEmpty.html +--- +# Constructor: help.deepLinkInfoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Deep link info empty + + + + +### Type: [help.DeepLinkInfo](/API_docs/types/help.DeepLinkInfo.html) + + +### Example: + +``` +$help_deepLinkInfoEmpty = ['_' => 'help.deepLinkInfoEmpty']; +``` diff --git a/docs/API_docs/constructors/help.inviteText.md b/docs/API_docs/constructors/help.inviteText.md new file mode 100644 index 0000000000..813a4a337a --- /dev/null +++ b/docs/API_docs/constructors/help.inviteText.md @@ -0,0 +1,30 @@ +--- +title: "help.inviteText" +description: "Text of a text message with an invitation to install Telegram." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_inviteText.html +--- +# Constructor: help.inviteText +[Back to constructors index](/API_docs/constructors/index.html) + + + +Text of a text message with an invitation to install Telegram. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[string](/API_docs/types/string.html) | Yes|Text of the message| + + + +### Type: [help.InviteText](/API_docs/types/help.InviteText.html) + + +### Example: + +``` +$help_inviteText = ['_' => 'help.inviteText', 'message' => 'string']; +``` diff --git a/docs/API_docs/constructors/help.noAppUpdate.md b/docs/API_docs/constructors/help.noAppUpdate.md new file mode 100644 index 0000000000..4215ae742d --- /dev/null +++ b/docs/API_docs/constructors/help.noAppUpdate.md @@ -0,0 +1,25 @@ +--- +title: "help.noAppUpdate" +description: "No updates are available for the application." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_noAppUpdate.html +--- +# Constructor: help.noAppUpdate +[Back to constructors index](/API_docs/constructors/index.html) + + + +No updates are available for the application. + + + + +### Type: [help.AppUpdate](/API_docs/types/help.AppUpdate.html) + + +### Example: + +``` +$help_noAppUpdate = ['_' => 'help.noAppUpdate']; +``` diff --git a/docs/API_docs/constructors/help.passportConfig.md b/docs/API_docs/constructors/help.passportConfig.md new file mode 100644 index 0000000000..540b1475ee --- /dev/null +++ b/docs/API_docs/constructors/help.passportConfig.md @@ -0,0 +1,31 @@ +--- +title: "help.passportConfig" +description: "Telegram passport configuration" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_passportConfig.html +--- +# Constructor: help.passportConfig +[Back to constructors index](/API_docs/constructors/index.html) + + + +Telegram [passport](https://core.telegram.org/passport) configuration + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[int](/API_docs/types/int.html) | Yes| +|countries\_langs|[DataJSON](/API_docs/types/DataJSON.html) | Yes|Localization| + + + +### Type: [help.PassportConfig](/API_docs/types/help.PassportConfig.html) + + +### Example: + +``` +$help_passportConfig = ['_' => 'help.passportConfig', 'hash' => int, 'countries_langs' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/help.passportConfigNotModified.md b/docs/API_docs/constructors/help.passportConfigNotModified.md new file mode 100644 index 0000000000..3006693180 --- /dev/null +++ b/docs/API_docs/constructors/help.passportConfigNotModified.md @@ -0,0 +1,25 @@ +--- +title: "help.passportConfigNotModified" +description: "Password configuration not modified" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_passportConfigNotModified.html +--- +# Constructor: help.passportConfigNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Password configuration not modified + + + + +### Type: [help.PassportConfig](/API_docs/types/help.PassportConfig.html) + + +### Example: + +``` +$help_passportConfigNotModified = ['_' => 'help.passportConfigNotModified']; +``` diff --git a/docs/API_docs/constructors/help.peerColorOption.md b/docs/API_docs/constructors/help.peerColorOption.md new file mode 100644 index 0000000000..2a13ca9d3b --- /dev/null +++ b/docs/API_docs/constructors/help.peerColorOption.md @@ -0,0 +1,35 @@ +--- +title: "help.peerColorOption" +description: "Contains info about a color palette »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_peerColorOption.html +--- +# Constructor: help.peerColorOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a [color palette »](https://core.telegram.org/api/colors). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hidden|[Bool](/API_docs/types/Bool.html) | Optional|Whether this palette should not be displayed as an option to the user when choosing a palette to apply to profile pages or message accents.| +|color\_id|[int](/API_docs/types/int.html) | Yes|Palette ID.| +|colors|[help.PeerColorSet](/API_docs/constructors/help.PeerColorSet.html) | Optional|Light mode palette.
Will be empty for IDs `0` to `6` inclusive, in which case a palette containing a single color from the following colors should be used: red, orange, violet, green, cyan, blue, pink for indexes 0 to 6.| +|dark\_colors|[help.PeerColorSet](/API_docs/constructors/help.PeerColorSet.html) | Optional|Dark mode palette. Optional, defaults to the palette in `colors` (or the autogenerated palette for IDs `0` to `6`) if absent.| +|channel\_min\_level|[int](/API_docs/types/int.html) | Optional|Channels can use this palette only after reaching at least the [boost level](https://core.telegram.org/api/boost) specified in this field.| +|group\_min\_level|[int](/API_docs/types/int.html) | Optional| + + + +### Type: [help.PeerColorOption](/API_docs/types/help.PeerColorOption.html) + + +### Example: + +``` +$help_peerColorOption = ['_' => 'help.peerColorOption', 'hidden' => Bool, 'color_id' => int, 'colors' => help.PeerColorSet, 'dark_colors' => help.PeerColorSet, 'channel_min_level' => int, 'group_min_level' => int]; +``` diff --git a/docs/API_docs/constructors/help.peerColorProfileSet.md b/docs/API_docs/constructors/help.peerColorProfileSet.md new file mode 100644 index 0000000000..36ffda1832 --- /dev/null +++ b/docs/API_docs/constructors/help.peerColorProfileSet.md @@ -0,0 +1,32 @@ +--- +title: "help.peerColorProfileSet" +description: "Represents a color palette that can be used in profile pages »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_peerColorProfileSet.html +--- +# Constructor: help.peerColorProfileSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [color palette that can be used in profile pages »](https://core.telegram.org/api/colors). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|palette\_colors|Array of [int](/API_docs/types/int.html) | Yes|A list of 1-2 colors in RGB format, shown in the color palette settings to describe the current palette.| +|bg\_colors|Array of [int](/API_docs/types/int.html) | Yes|A list of 1-2 colors in RGB format describing the colors used to generate the actual background used in the profile page.| +|story\_colors|Array of [int](/API_docs/types/int.html) | Yes|A list of 2 colors in RGB format describing the colors of the gradient used for the unread active story indicator around the profile photo.| + + + +### Type: [help.PeerColorSet](/API_docs/types/help.PeerColorSet.html) + + +### Example: + +``` +$help_peerColorProfileSet = ['_' => 'help.peerColorProfileSet', 'palette_colors' => [int, int], 'bg_colors' => [int, int], 'story_colors' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/help.peerColorSet.md b/docs/API_docs/constructors/help.peerColorSet.md new file mode 100644 index 0000000000..d2b406964b --- /dev/null +++ b/docs/API_docs/constructors/help.peerColorSet.md @@ -0,0 +1,30 @@ +--- +title: "help.peerColorSet" +description: "Represents a color palette that can be used in message accents »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_peerColorSet.html +--- +# Constructor: help.peerColorSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [color palette that can be used in message accents »](https://core.telegram.org/api/colors). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|colors|Array of [int](/API_docs/types/int.html) | Yes|A list of 1-3 colors in RGB format, describing the accent color.| + + + +### Type: [help.PeerColorSet](/API_docs/types/help.PeerColorSet.html) + + +### Example: + +``` +$help_peerColorSet = ['_' => 'help.peerColorSet', 'colors' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/help.peerColors.md b/docs/API_docs/constructors/help.peerColors.md new file mode 100644 index 0000000000..f5215fc481 --- /dev/null +++ b/docs/API_docs/constructors/help.peerColors.md @@ -0,0 +1,31 @@ +--- +title: "help.peerColors" +description: "Contains info about multiple color palettes »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_peerColors.html +--- +# Constructor: help.peerColors +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about multiple [color palettes »](https://core.telegram.org/api/colors). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[int](/API_docs/types/int.html) | Yes| +|colors|Array of [help.PeerColorOption](/API_docs/constructors/help.PeerColorOption.html) | Yes|Usable [color palettes](https://core.telegram.org/api/colors).| + + + +### Type: [help.PeerColors](/API_docs/types/help.PeerColors.html) + + +### Example: + +``` +$help_peerColors = ['_' => 'help.peerColors', 'hash' => int, 'colors' => [help.PeerColorOption, help.PeerColorOption]]; +``` diff --git a/docs/API_docs/constructors/help.peerColorsNotModified.md b/docs/API_docs/constructors/help.peerColorsNotModified.md new file mode 100644 index 0000000000..12200aaff6 --- /dev/null +++ b/docs/API_docs/constructors/help.peerColorsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "help.peerColorsNotModified" +description: "The list of color palettes has not changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_peerColorsNotModified.html +--- +# Constructor: help.peerColorsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of color palettes has not changed. + + + + +### Type: [help.PeerColors](/API_docs/types/help.PeerColors.html) + + +### Example: + +``` +$help_peerColorsNotModified = ['_' => 'help.peerColorsNotModified']; +``` diff --git a/docs/API_docs/constructors/help.premiumPromo.md b/docs/API_docs/constructors/help.premiumPromo.md new file mode 100644 index 0000000000..da09f3e11d --- /dev/null +++ b/docs/API_docs/constructors/help.premiumPromo.md @@ -0,0 +1,39 @@ +--- +title: "help.premiumPromo" +description: "Telegram Premium promotion information" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_premiumPromo.html +--- +# Constructor: help.premiumPromo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Telegram Premium promotion information + +Note that the `video_sections`+`videos` fields are a list of videos, and the corresponding premium feature identifiers. +They're equivalent to a section => video dictionary, with keys from `video_section` and values from `videos`. +The keys in `video_sections` correspond to a specific feature identifier, and the associated promotional video should be shown when the associated feature row is clicked. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|status\_text|[string](/API_docs/types/string.html) | Yes|Description of the current state of the user's Telegram Premium subscription| +|status\_entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Yes|[Message entities for styled text](https://core.telegram.org/api/entities)| +|video\_sections|Array of [string](/API_docs/types/string.html) | Yes|A list of [premium feature identifiers »](https://core.telegram.org/api/premium), associated to each video| +|videos|Array of [Document](/API_docs/types/Document.html) | Yes|A list of videos| +|period\_options|Array of [PremiumSubscriptionOption](/API_docs/types/PremiumSubscriptionOption.html) | Yes|Telegram Premium subscription options| +|users|Array of [User](/API_docs/types/User.html) | Yes|Related user information| + + + +### Type: [help.PremiumPromo](/API_docs/types/help.PremiumPromo.html) + + +### Example: + +``` +$help_premiumPromo = ['_' => 'help.premiumPromo', 'status_text' => 'string', 'status_entities' => [MessageEntity, MessageEntity], 'video_sections' => ['string', 'string'], 'videos' => [Document, Document], 'period_options' => [PremiumSubscriptionOption, PremiumSubscriptionOption], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/help.promoData.md b/docs/API_docs/constructors/help.promoData.md new file mode 100644 index 0000000000..54927df867 --- /dev/null +++ b/docs/API_docs/constructors/help.promoData.md @@ -0,0 +1,36 @@ +--- +title: "help.promoData" +description: "MTProxy/Public Service Announcement information" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_promoData.html +--- +# Constructor: help.promoData +[Back to constructors index](/API_docs/constructors/index.html) + + + +MTProxy/Public Service Announcement information + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|proxy|[Bool](/API_docs/types/Bool.html) | Optional|MTProxy-related channel| +|expires|[int](/API_docs/types/int.html) | Yes|Expiry of PSA/MTProxy info| +|peer|[long](/API_docs/types/long.html) | Yes|MTProxy/PSA peer| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chat info| +|users|Array of [User](/API_docs/types/User.html) | Yes|User info| +|psa\_type|[string](/API_docs/types/string.html) | Optional|PSA type| +|psa\_message|[string](/API_docs/types/string.html) | Optional|PSA message| + + + +### Type: [help.PromoData](/API_docs/types/help.PromoData.html) + + +### Example: + +``` +$help_promoData = ['_' => 'help.promoData', 'proxy' => Bool, 'expires' => int, 'peer' => long, 'chats' => [Chat, Chat], 'users' => [User, User], 'psa_type' => 'string', 'psa_message' => 'string']; +``` diff --git a/docs/API_docs/constructors/help.promoDataEmpty.md b/docs/API_docs/constructors/help.promoDataEmpty.md new file mode 100644 index 0000000000..454a8c7e11 --- /dev/null +++ b/docs/API_docs/constructors/help.promoDataEmpty.md @@ -0,0 +1,30 @@ +--- +title: "help.promoDataEmpty" +description: "No PSA/MTProxy info is available" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_promoDataEmpty.html +--- +# Constructor: help.promoDataEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No PSA/MTProxy info is available + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|expires|[int](/API_docs/types/int.html) | Yes|Re-fetch PSA/MTProxy info after the specified number of seconds| + + + +### Type: [help.PromoData](/API_docs/types/help.PromoData.html) + + +### Example: + +``` +$help_promoDataEmpty = ['_' => 'help.promoDataEmpty', 'expires' => int]; +``` diff --git a/docs/API_docs/constructors/help.recentMeUrls.md b/docs/API_docs/constructors/help.recentMeUrls.md new file mode 100644 index 0000000000..ea78246f6c --- /dev/null +++ b/docs/API_docs/constructors/help.recentMeUrls.md @@ -0,0 +1,32 @@ +--- +title: "help.recentMeUrls" +description: "Recent t.me URLs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_recentMeUrls.html +--- +# Constructor: help.recentMeUrls +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recent t.me URLs + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|urls|Array of [RecentMeUrl](/API_docs/types/RecentMeUrl.html) | Yes|URLs| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [help.RecentMeUrls](/API_docs/types/help.RecentMeUrls.html) + + +### Example: + +``` +$help_recentMeUrls = ['_' => 'help.recentMeUrls', 'urls' => [RecentMeUrl, RecentMeUrl], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/help.support.md b/docs/API_docs/constructors/help.support.md new file mode 100644 index 0000000000..1ced4555e7 --- /dev/null +++ b/docs/API_docs/constructors/help.support.md @@ -0,0 +1,31 @@ +--- +title: "help.support" +description: "Info on support user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_support.html +--- +# Constructor: help.support +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info on support user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|user|[User](/API_docs/types/User.html) | Optional|User| + + + +### Type: [help.Support](/API_docs/types/help.Support.html) + + +### Example: + +``` +$help_support = ['_' => 'help.support', 'phone_number' => 'string', 'user' => User]; +``` diff --git a/docs/API_docs/constructors/help.supportName.md b/docs/API_docs/constructors/help.supportName.md new file mode 100644 index 0000000000..2568b7ab64 --- /dev/null +++ b/docs/API_docs/constructors/help.supportName.md @@ -0,0 +1,30 @@ +--- +title: "help.supportName" +description: "Localized name for telegram support" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_supportName.html +--- +# Constructor: help.supportName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Localized name for telegram support + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|name|[string](/API_docs/types/string.html) | Yes|Localized name| + + + +### Type: [help.SupportName](/API_docs/types/help.SupportName.html) + + +### Example: + +``` +$help_supportName = ['_' => 'help.supportName', 'name' => 'string']; +``` diff --git a/docs/API_docs/constructors/help.termsOfService.md b/docs/API_docs/constructors/help.termsOfService.md new file mode 100644 index 0000000000..c62efd7f67 --- /dev/null +++ b/docs/API_docs/constructors/help.termsOfService.md @@ -0,0 +1,95 @@ +--- +title: "help.termsOfService" +description: "Info about the latest telegram Terms Of Service" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_termsOfService.html +--- +# Constructor: help.termsOfService +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about the latest telegram Terms Of Service + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|popup|[Bool](/API_docs/types/Bool.html) | Optional|Whether a prompt must be showed to the user, in order to accept the new terms.| +|id|[DataJSON](/API_docs/types/DataJSON.html) | Yes|ID of the new terms| +|text|[string](/API_docs/types/string.html) | Yes|Text of the new terms| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Yes|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|min\_age\_confirm|[int](/API_docs/types/int.html) | Optional|Minimum age required to sign up to telegram, the user must confirm that they is older than the minimum age.| + + + +### Type: [help.TermsOfService](/API_docs/types/help.TermsOfService.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$help_termsOfService = ['_' => 'help.termsOfService', 'popup' => Bool, 'id' => DataJSON, 'text' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'min_age_confirm' => int]; +``` diff --git a/docs/API_docs/constructors/help.termsOfServiceUpdate.md b/docs/API_docs/constructors/help.termsOfServiceUpdate.md new file mode 100644 index 0000000000..16f6e23eb5 --- /dev/null +++ b/docs/API_docs/constructors/help.termsOfServiceUpdate.md @@ -0,0 +1,31 @@ +--- +title: "help.termsOfServiceUpdate" +description: "Info about an update of telegram's terms of service. If the terms of service are declined, then the account.deleteAccount method should be called with the reason 'Decline ToS update'" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_termsOfServiceUpdate.html +--- +# Constructor: help.termsOfServiceUpdate +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about an update of telegram's terms of service. If the terms of service are declined, then the [account.deleteAccount](../methods/account.deleteAccount.html) method should be called with the reason "Decline ToS update" + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|expires|[int](/API_docs/types/int.html) | Yes|New TOS updates will have to be queried using [help.getTermsOfServiceUpdate](../methods/help.getTermsOfServiceUpdate.html) in `expires` seconds| +|terms\_of\_service|[help.TermsOfService](/API_docs/constructors/help.TermsOfService.html) | Yes|New terms of service| + + + +### Type: [help.TermsOfServiceUpdate](/API_docs/types/help.TermsOfServiceUpdate.html) + + +### Example: + +``` +$help_termsOfServiceUpdate = ['_' => 'help.termsOfServiceUpdate', 'expires' => int, 'terms_of_service' => help.TermsOfService]; +``` diff --git a/docs/API_docs/constructors/help.termsOfServiceUpdateEmpty.md b/docs/API_docs/constructors/help.termsOfServiceUpdateEmpty.md new file mode 100644 index 0000000000..082eeb1fdb --- /dev/null +++ b/docs/API_docs/constructors/help.termsOfServiceUpdateEmpty.md @@ -0,0 +1,30 @@ +--- +title: "help.termsOfServiceUpdateEmpty" +description: "No changes were made to telegram's terms of service" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_termsOfServiceUpdateEmpty.html +--- +# Constructor: help.termsOfServiceUpdateEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No changes were made to telegram's terms of service + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|expires|[int](/API_docs/types/int.html) | Yes|New TOS updates will have to be queried using [help.getTermsOfServiceUpdate](../methods/help.getTermsOfServiceUpdate.html) in `expires` seconds| + + + +### Type: [help.TermsOfServiceUpdate](/API_docs/types/help.TermsOfServiceUpdate.html) + + +### Example: + +``` +$help_termsOfServiceUpdateEmpty = ['_' => 'help.termsOfServiceUpdateEmpty', 'expires' => int]; +``` diff --git a/docs/API_docs/constructors/help.timezonesList.md b/docs/API_docs/constructors/help.timezonesList.md new file mode 100644 index 0000000000..b26afbccbb --- /dev/null +++ b/docs/API_docs/constructors/help.timezonesList.md @@ -0,0 +1,29 @@ +--- +title: "help.timezonesList" +description: "help.timezonesList attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_timezonesList.html +--- +# Constructor: help.timezonesList +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|timezones|Array of [Timezone](/API_docs/types/Timezone.html) | Yes| +|hash|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [help.TimezonesList](/API_docs/types/help.TimezonesList.html) + + +### Example: + +``` +$help_timezonesList = ['_' => 'help.timezonesList', 'timezones' => [Timezone, Timezone], 'hash' => int]; +``` diff --git a/docs/API_docs/constructors/help.timezonesListNotModified.md b/docs/API_docs/constructors/help.timezonesListNotModified.md new file mode 100644 index 0000000000..5e8405ed8b --- /dev/null +++ b/docs/API_docs/constructors/help.timezonesListNotModified.md @@ -0,0 +1,23 @@ +--- +title: "help.timezonesListNotModified" +description: "help.timezonesListNotModified attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_timezonesListNotModified.html +--- +# Constructor: help.timezonesListNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [help.TimezonesList](/API_docs/types/help.TimezonesList.html) + + +### Example: + +``` +$help_timezonesListNotModified = ['_' => 'help.timezonesListNotModified']; +``` diff --git a/docs/API_docs/constructors/help.userInfo.md b/docs/API_docs/constructors/help.userInfo.md new file mode 100644 index 0000000000..fd8a1cee5f --- /dev/null +++ b/docs/API_docs/constructors/help.userInfo.md @@ -0,0 +1,94 @@ +--- +title: "help.userInfo" +description: "Internal use" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_userInfo.html +--- +# Constructor: help.userInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Internal use + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[string](/API_docs/types/string.html) | Yes|Info| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Yes|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|author|[string](/API_docs/types/string.html) | Yes|Author| +|date|[int](/API_docs/types/int.html) | Yes|Date| + + + +### Type: [help.UserInfo](/API_docs/types/help.UserInfo.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$help_userInfo = ['_' => 'help.userInfo', 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'author' => 'string', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/help.userInfoEmpty.md b/docs/API_docs/constructors/help.userInfoEmpty.md new file mode 100644 index 0000000000..233eac7765 --- /dev/null +++ b/docs/API_docs/constructors/help.userInfoEmpty.md @@ -0,0 +1,25 @@ +--- +title: "help.userInfoEmpty" +description: "Internal use" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/help_userInfoEmpty.html +--- +# Constructor: help.userInfoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Internal use + + + + +### Type: [help.UserInfo](/API_docs/types/help.UserInfo.html) + + +### Example: + +``` +$help_userInfoEmpty = ['_' => 'help.userInfoEmpty']; +``` diff --git a/docs/API_docs/constructors/highScore.md b/docs/API_docs/constructors/highScore.md new file mode 100644 index 0000000000..f132e5f654 --- /dev/null +++ b/docs/API_docs/constructors/highScore.md @@ -0,0 +1,31 @@ +--- +title: "highScore" +description: "Game highscore" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: highScore +[Back to constructors index](/API_docs/constructors/index.html) + + + +Game highscore + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pos|[int](/API_docs/types/int.html) | Yes|Position in highscore list| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|score|[int](/API_docs/types/int.html) | Yes|Score| + + + +### Type: [HighScore](/API_docs/types/HighScore.html) + + +### Example: + +``` +$highScore = ['_' => 'highScore', 'pos' => int, 'user_id' => long, 'score' => int]; +``` diff --git a/docs/API_docs/constructors/importedContact.md b/docs/API_docs/constructors/importedContact.md new file mode 100644 index 0000000000..b04be4cbc0 --- /dev/null +++ b/docs/API_docs/constructors/importedContact.md @@ -0,0 +1,30 @@ +--- +title: "importedContact" +description: "Successfully imported contact." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: importedContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Successfully imported contact. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|client\_id|[long](/API_docs/types/long.html) | Yes|The contact's client identifier (passed to one of the [InputContact](../types/InputContact.html) constructors)| + + + +### Type: [ImportedContact](/API_docs/types/ImportedContact.html) + + +### Example: + +``` +$importedContact = ['_' => 'importedContact', 'user_id' => long, 'client_id' => long]; +``` diff --git a/docs/API_docs/constructors/index.md b/docs/API_docs/constructors/index.md new file mode 100644 index 0000000000..bd3373a694 --- /dev/null +++ b/docs/API_docs/constructors/index.md @@ -0,0 +1,3976 @@ +--- +title: Constructors +description: List of constructors +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructors +[Back to API documentation index](..) + +*** +

[$account.authorizationForm](/API_docs/constructors/account.authorizationForm.html) = \['required_types' => \[[SecureRequiredType](/API_docs/types/SecureRequiredType.html)\], 'values' => \[[SecureValue](/API_docs/types/SecureValue.html)\], 'errors' => \[[SecureValueError](/API_docs/types/SecureValueError.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'privacy_policy_url' => [string](/API_docs/types/string.html), \]; + +*** +

[$account.authorizations](/API_docs/constructors/account.authorizations.html) = \['authorization_ttl_days' => [int](/API_docs/types/int.html), 'authorizations' => \[[Authorization](/API_docs/types/Authorization.html)\], \]; + +*** +

[$account.autoDownloadSettings](/API_docs/constructors/account.autoDownloadSettings.html) = \['low' => [AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html), 'medium' => [AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html), 'high' => [AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html), \]; + +*** +

[$account.autoSaveSettings](/API_docs/constructors/account.autoSaveSettings.html) = \['users_settings' => [AutoSaveSettings](/API_docs/types/AutoSaveSettings.html), 'chats_settings' => [AutoSaveSettings](/API_docs/types/AutoSaveSettings.html), 'broadcasts_settings' => [AutoSaveSettings](/API_docs/types/AutoSaveSettings.html), 'exceptions' => \[[AutoSaveException](/API_docs/types/AutoSaveException.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$account.businessChatLinks](/API_docs/constructors/account.businessChatLinks.html) = \['links' => \[[BusinessChatLink](/API_docs/types/BusinessChatLink.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$account.connectedBots](/API_docs/constructors/account.connectedBots.html) = \['connected_bots' => \[[ConnectedBot](/API_docs/types/ConnectedBot.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$account.contentSettings](/API_docs/constructors/account.contentSettings.html) = \['sensitive_enabled' => [Bool](/API_docs/types/Bool.html), 'sensitive_can_change' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$account.emailVerified](/API_docs/constructors/account.emailVerified.html) = \['email' => [string](/API_docs/types/string.html), \]; + +*** +

[$account.emailVerifiedLogin](/API_docs/constructors/account.emailVerifiedLogin.html) = \['email' => [string](/API_docs/types/string.html), 'sent_code' => [auth.SentCode](/API_docs/types/auth.SentCode.html), \]; + +*** +

[$account.emojiStatuses](/API_docs/constructors/account.emojiStatuses.html) = \['hash' => [long](/API_docs/types/long.html), 'statuses' => \[[EmojiStatus](/API_docs/types/EmojiStatus.html)\], \]; + +*** +

[$account.emojiStatusesNotModified](/API_docs/constructors/account.emojiStatusesNotModified.html) = \[\]; + +*** +

[$account.password](/API_docs/constructors/account.password.html) = \['has_recovery' => [Bool](/API_docs/types/Bool.html), 'has_secure_values' => [Bool](/API_docs/types/Bool.html), 'has_password' => [Bool](/API_docs/types/Bool.html), 'current_algo' => [PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html), 'srp_B' => [bytes](/API_docs/types/bytes.html), 'srp_id' => [long](/API_docs/types/long.html), 'hint' => [string](/API_docs/types/string.html), 'email_unconfirmed_pattern' => [string](/API_docs/types/string.html), 'new_algo' => [PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html), 'new_secure_algo' => [SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html), 'secure_random' => [bytes](/API_docs/types/bytes.html), 'pending_reset_date' => [int](/API_docs/types/int.html), 'login_email_pattern' => [string](/API_docs/types/string.html), \]; + +*** +

[$account.passwordInputSettings](/API_docs/constructors/account.passwordInputSettings.html) = \['new_algo' => [PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html), 'new_password_hash' => [bytes](/API_docs/types/bytes.html), 'hint' => [string](/API_docs/types/string.html), 'email' => [string](/API_docs/types/string.html), 'new_secure_settings' => [SecureSecretSettings](/API_docs/types/SecureSecretSettings.html), \]; + +*** +

[$account.passwordSettings](/API_docs/constructors/account.passwordSettings.html) = \['email' => [string](/API_docs/types/string.html), 'secure_settings' => [SecureSecretSettings](/API_docs/types/SecureSecretSettings.html), \]; + +*** +

[$account.privacyRules](/API_docs/constructors/account.privacyRules.html) = \['rules' => \[[PrivacyRule](/API_docs/types/PrivacyRule.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$account.resetPasswordFailedWait](/API_docs/constructors/account.resetPasswordFailedWait.html) = \['retry_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$account.resetPasswordOk](/API_docs/constructors/account.resetPasswordOk.html) = \[\]; + +*** +

[$account.resetPasswordRequestedWait](/API_docs/constructors/account.resetPasswordRequestedWait.html) = \['until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$account.resolvedBusinessChatLinks](/API_docs/constructors/account.resolvedBusinessChatLinks.html) = \['peer' => [long](/API_docs/types/long.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$account.savedRingtone](/API_docs/constructors/account.savedRingtone.html) = \[\]; + +*** +

[$account.savedRingtoneConverted](/API_docs/constructors/account.savedRingtoneConverted.html) = \['document' => [Document](/API_docs/types/Document.html), \]; + +*** +

[$account.savedRingtones](/API_docs/constructors/account.savedRingtones.html) = \['hash' => [long](/API_docs/types/long.html), 'ringtones' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$account.savedRingtonesNotModified](/API_docs/constructors/account.savedRingtonesNotModified.html) = \[\]; + +*** +

[$account.sentEmailCode](/API_docs/constructors/account.sentEmailCode.html) = \['email_pattern' => [string](/API_docs/types/string.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$account.takeout](/API_docs/constructors/account.takeout.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$account.themes](/API_docs/constructors/account.themes.html) = \['hash' => [long](/API_docs/types/long.html), 'themes' => \[[Theme](/API_docs/types/Theme.html)\], \]; + +*** +

[$account.themesNotModified](/API_docs/constructors/account.themesNotModified.html) = \[\]; + +*** +

[$account.tmpPassword](/API_docs/constructors/account.tmpPassword.html) = \['tmp_password' => [bytes](/API_docs/types/bytes.html), 'valid_until' => [int](/API_docs/types/int.html), \]; + +*** +

[$account.wallPapers](/API_docs/constructors/account.wallPapers.html) = \['hash' => [long](/API_docs/types/long.html), 'wallpapers' => \[[WallPaper](/API_docs/types/WallPaper.html)\], \]; + +*** +

[$account.wallPapersNotModified](/API_docs/constructors/account.wallPapersNotModified.html) = \[\]; + +*** +

[$account.webAuthorizations](/API_docs/constructors/account.webAuthorizations.html) = \['authorizations' => \[[WebAuthorization](/API_docs/types/WebAuthorization.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$accountDaysTTL](/API_docs/constructors/accountDaysTTL.html) = \['days' => [int](/API_docs/types/int.html), \]; + +*** +

[$appWebViewResultUrl](/API_docs/constructors/appWebViewResultUrl.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$attachMenuBot](/API_docs/constructors/attachMenuBot.html) = \['inactive' => [Bool](/API_docs/types/Bool.html), 'has_settings' => [Bool](/API_docs/types/Bool.html), 'request_write_access' => [Bool](/API_docs/types/Bool.html), 'show_in_attach_menu' => [Bool](/API_docs/types/Bool.html), 'show_in_side_menu' => [Bool](/API_docs/types/Bool.html), 'side_menu_disclaimer_needed' => [Bool](/API_docs/types/Bool.html), 'bot_id' => [long](/API_docs/types/long.html), 'short_name' => [string](/API_docs/types/string.html), 'peer_types' => \[[AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html)\], 'icons' => \[[AttachMenuBotIcon](/API_docs/types/AttachMenuBotIcon.html)\], \]; + +*** +

[$attachMenuBotIcon](/API_docs/constructors/attachMenuBotIcon.html) = \['name' => [string](/API_docs/types/string.html), 'icon' => [Document](/API_docs/types/Document.html), 'colors' => \[[AttachMenuBotIconColor](/API_docs/types/AttachMenuBotIconColor.html)\], \]; + +*** +

[$attachMenuBotIconColor](/API_docs/constructors/attachMenuBotIconColor.html) = \['name' => [string](/API_docs/types/string.html), 'color' => [int](/API_docs/types/int.html), \]; + +*** +

[$attachMenuBots](/API_docs/constructors/attachMenuBots.html) = \['hash' => [long](/API_docs/types/long.html), 'bots' => \[[AttachMenuBot](/API_docs/types/AttachMenuBot.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$attachMenuBotsBot](/API_docs/constructors/attachMenuBotsBot.html) = \['bot' => [AttachMenuBot](/API_docs/types/AttachMenuBot.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$attachMenuBotsNotModified](/API_docs/constructors/attachMenuBotsNotModified.html) = \[\]; + +*** +

[$attachMenuPeerTypeBotPM](/API_docs/constructors/attachMenuPeerTypeBotPM.html) = \[\]; + +*** +

[$attachMenuPeerTypeBroadcast](/API_docs/constructors/attachMenuPeerTypeBroadcast.html) = \[\]; + +*** +

[$attachMenuPeerTypeChat](/API_docs/constructors/attachMenuPeerTypeChat.html) = \[\]; + +*** +

[$attachMenuPeerTypePM](/API_docs/constructors/attachMenuPeerTypePM.html) = \[\]; + +*** +

[$attachMenuPeerTypeSameBotPM](/API_docs/constructors/attachMenuPeerTypeSameBotPM.html) = \[\]; + +*** +

[$auth.authorization](/API_docs/constructors/auth.authorization.html) = \['setup_password_required' => [Bool](/API_docs/types/Bool.html), 'otherwise_relogin_days' => [int](/API_docs/types/int.html), 'tmp_sessions' => [int](/API_docs/types/int.html), 'future_auth_token' => [bytes](/API_docs/types/bytes.html), 'user' => [User](/API_docs/types/User.html), \]; + +*** +

[$auth.authorizationSignUpRequired](/API_docs/constructors/auth.authorizationSignUpRequired.html) = \['terms_of_service' => [help.TermsOfService](/API_docs/types/help.TermsOfService.html), \]; + +*** +

[$auth.codeTypeCall](/API_docs/constructors/auth.codeTypeCall.html) = \[\]; + +*** +

[$auth.codeTypeFlashCall](/API_docs/constructors/auth.codeTypeFlashCall.html) = \[\]; + +*** +

[$auth.codeTypeFragmentSms](/API_docs/constructors/auth.codeTypeFragmentSms.html) = \[\]; + +*** +

[$auth.codeTypeMissedCall](/API_docs/constructors/auth.codeTypeMissedCall.html) = \[\]; + +*** +

[$auth.codeTypeSms](/API_docs/constructors/auth.codeTypeSms.html) = \[\]; + +*** +

[$auth.exportedAuthorization](/API_docs/constructors/auth.exportedAuthorization.html) = \['id' => [long](/API_docs/types/long.html), 'bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$auth.loggedOut](/API_docs/constructors/auth.loggedOut.html) = \['future_auth_token' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$auth.loginToken](/API_docs/constructors/auth.loginToken.html) = \['expires' => [int](/API_docs/types/int.html), 'token' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$auth.loginTokenMigrateTo](/API_docs/constructors/auth.loginTokenMigrateTo.html) = \['dc_id' => [int](/API_docs/types/int.html), 'token' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$auth.loginTokenSuccess](/API_docs/constructors/auth.loginTokenSuccess.html) = \['authorization' => [auth.Authorization](/API_docs/types/auth.Authorization.html), \]; + +*** +

[$auth.passwordRecovery](/API_docs/constructors/auth.passwordRecovery.html) = \['email_pattern' => [string](/API_docs/types/string.html), \]; + +*** +

[$auth.sentCode](/API_docs/constructors/auth.sentCode.html) = \['type' => [auth.SentCodeType](/API_docs/types/auth.SentCodeType.html), 'phone_code_hash' => [string](/API_docs/types/string.html), 'next_type' => [auth.CodeType](/API_docs/types/auth.CodeType.html), 'timeout' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeSuccess](/API_docs/constructors/auth.sentCodeSuccess.html) = \['authorization' => [auth.Authorization](/API_docs/types/auth.Authorization.html), \]; + +*** +

[$auth.sentCodeTypeApp](/API_docs/constructors/auth.sentCodeTypeApp.html) = \['length' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeCall](/API_docs/constructors/auth.sentCodeTypeCall.html) = \['length' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeEmailCode](/API_docs/constructors/auth.sentCodeTypeEmailCode.html) = \['apple_signin_allowed' => [Bool](/API_docs/types/Bool.html), 'google_signin_allowed' => [Bool](/API_docs/types/Bool.html), 'email_pattern' => [string](/API_docs/types/string.html), 'length' => [int](/API_docs/types/int.html), 'reset_available_period' => [int](/API_docs/types/int.html), 'reset_pending_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeFirebaseSms](/API_docs/constructors/auth.sentCodeTypeFirebaseSms.html) = \['nonce' => [bytes](/API_docs/types/bytes.html), 'receipt' => [string](/API_docs/types/string.html), 'push_timeout' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeFlashCall](/API_docs/constructors/auth.sentCodeTypeFlashCall.html) = \['pattern' => [string](/API_docs/types/string.html), \]; + +*** +

[$auth.sentCodeTypeFragmentSms](/API_docs/constructors/auth.sentCodeTypeFragmentSms.html) = \['url' => [string](/API_docs/types/string.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeMissedCall](/API_docs/constructors/auth.sentCodeTypeMissedCall.html) = \['prefix' => [string](/API_docs/types/string.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeSetUpEmailRequired](/API_docs/constructors/auth.sentCodeTypeSetUpEmailRequired.html) = \['apple_signin_allowed' => [Bool](/API_docs/types/Bool.html), 'google_signin_allowed' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$auth.sentCodeTypeSms](/API_docs/constructors/auth.sentCodeTypeSms.html) = \['length' => [int](/API_docs/types/int.html), \]; + +*** +

[$auth.sentCodeTypeSmsPhrase](/API_docs/constructors/auth.sentCodeTypeSmsPhrase.html) = \['beginning' => [string](/API_docs/types/string.html), \]; + +*** +

[$auth.sentCodeTypeSmsWord](/API_docs/constructors/auth.sentCodeTypeSmsWord.html) = \['beginning' => [string](/API_docs/types/string.html), \]; + +*** +

[$authorization](/API_docs/constructors/authorization.html) = \['current' => [Bool](/API_docs/types/Bool.html), 'official_app' => [Bool](/API_docs/types/Bool.html), 'password_pending' => [Bool](/API_docs/types/Bool.html), 'encrypted_requests_disabled' => [Bool](/API_docs/types/Bool.html), 'call_requests_disabled' => [Bool](/API_docs/types/Bool.html), 'unconfirmed' => [Bool](/API_docs/types/Bool.html), 'hash' => [long](/API_docs/types/long.html), 'device_model' => [string](/API_docs/types/string.html), 'platform' => [string](/API_docs/types/string.html), 'system_version' => [string](/API_docs/types/string.html), 'api_id' => [int](/API_docs/types/int.html), 'app_name' => [string](/API_docs/types/string.html), 'app_version' => [string](/API_docs/types/string.html), 'date_created' => [int](/API_docs/types/int.html), 'date_active' => [int](/API_docs/types/int.html), 'ip' => [string](/API_docs/types/string.html), 'country' => [string](/API_docs/types/string.html), 'region' => [string](/API_docs/types/string.html), \]; + +*** +

[$autoDownloadSettings](/API_docs/constructors/autoDownloadSettings.html) = \['disabled' => [Bool](/API_docs/types/Bool.html), 'video_preload_large' => [Bool](/API_docs/types/Bool.html), 'audio_preload_next' => [Bool](/API_docs/types/Bool.html), 'phonecalls_less_data' => [Bool](/API_docs/types/Bool.html), 'stories_preload' => [Bool](/API_docs/types/Bool.html), 'photo_size_max' => [int](/API_docs/types/int.html), 'video_size_max' => [long](/API_docs/types/long.html), 'file_size_max' => [long](/API_docs/types/long.html), 'video_upload_maxbitrate' => [int](/API_docs/types/int.html), 'small_queue_active_operations_max' => [int](/API_docs/types/int.html), 'large_queue_active_operations_max' => [int](/API_docs/types/int.html), \]; + +*** +

[$autoSaveException](/API_docs/constructors/autoSaveException.html) = \['peer' => [long](/API_docs/types/long.html), 'settings' => [AutoSaveSettings](/API_docs/types/AutoSaveSettings.html), \]; + +*** +

[$autoSaveSettings](/API_docs/constructors/autoSaveSettings.html) = \['photos' => [Bool](/API_docs/types/Bool.html), 'videos' => [Bool](/API_docs/types/Bool.html), 'video_max_size' => [long](/API_docs/types/long.html), \]; + +*** +

[$availableReaction](/API_docs/constructors/availableReaction.html) = \['inactive' => [Bool](/API_docs/types/Bool.html), 'premium' => [Bool](/API_docs/types/Bool.html), 'reaction' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'static_icon' => [Document](/API_docs/types/Document.html), 'appear_animation' => [Document](/API_docs/types/Document.html), 'select_animation' => [Document](/API_docs/types/Document.html), 'activate_animation' => [Document](/API_docs/types/Document.html), 'effect_animation' => [Document](/API_docs/types/Document.html), 'around_animation' => [Document](/API_docs/types/Document.html), 'center_icon' => [Document](/API_docs/types/Document.html), \]; + +*** +

[$bankCardOpenUrl](/API_docs/constructors/bankCardOpenUrl.html) = \['url' => [string](/API_docs/types/string.html), 'name' => [string](/API_docs/types/string.html), \]; + +*** +

[$baseThemeArctic](/API_docs/constructors/baseThemeArctic.html) = \[\]; + +*** +

[$baseThemeClassic](/API_docs/constructors/baseThemeClassic.html) = \[\]; + +*** +

[$baseThemeDay](/API_docs/constructors/baseThemeDay.html) = \[\]; + +*** +

[$baseThemeNight](/API_docs/constructors/baseThemeNight.html) = \[\]; + +*** +

[$baseThemeTinted](/API_docs/constructors/baseThemeTinted.html) = \[\]; + +*** +

[$birthday](/API_docs/constructors/birthday.html) = \['day' => [int](/API_docs/types/int.html), 'month' => [int](/API_docs/types/int.html), 'year' => [int](/API_docs/types/int.html), \]; + +*** +

[$boolFalse](/API_docs/constructors/boolFalse.html) = \[\]; + +*** +

[$boolTrue](/API_docs/constructors/boolTrue.html) = \[\]; + +*** +

[$boost](/API_docs/constructors/boost.html) = \['gift' => [Bool](/API_docs/types/Bool.html), 'giveaway' => [Bool](/API_docs/types/Bool.html), 'unclaimed' => [Bool](/API_docs/types/Bool.html), 'id' => [string](/API_docs/types/string.html), 'user_id' => [long](/API_docs/types/long.html), 'giveaway_msg_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'expires' => [int](/API_docs/types/int.html), 'used_gift_slug' => [string](/API_docs/types/string.html), 'multiplier' => [int](/API_docs/types/int.html), \]; + +*** +

[$botApp](/API_docs/constructors/botApp.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'short_name' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), 'document' => [Document](/API_docs/types/Document.html), 'hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$botAppNotModified](/API_docs/constructors/botAppNotModified.html) = \[\]; + +*** +

[$botBusinessConnection](/API_docs/constructors/botBusinessConnection.html) = \['can_reply' => [Bool](/API_docs/types/Bool.html), 'disabled' => [Bool](/API_docs/types/Bool.html), 'connection_id' => [string](/API_docs/types/string.html), 'user_id' => [long](/API_docs/types/long.html), 'dc_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$botCommand](/API_docs/constructors/botCommand.html) = \['command' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), \]; + +*** +

[$botCommandScopeChatAdmins](/API_docs/constructors/botCommandScopeChatAdmins.html) = \[\]; + +*** +

[$botCommandScopeChats](/API_docs/constructors/botCommandScopeChats.html) = \[\]; + +*** +

[$botCommandScopeDefault](/API_docs/constructors/botCommandScopeDefault.html) = \[\]; + +*** +

[$botCommandScopePeer](/API_docs/constructors/botCommandScopePeer.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), \]; + +*** +

[$botCommandScopePeerAdmins](/API_docs/constructors/botCommandScopePeerAdmins.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), \]; + +*** +

[$botCommandScopePeerUser](/API_docs/constructors/botCommandScopePeerUser.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'user_id' => [InputUser](/API_docs/types/InputUser.html), \]; + +*** +

[$botCommandScopeUsers](/API_docs/constructors/botCommandScopeUsers.html) = \[\]; + +*** +

[$botInfo](/API_docs/constructors/botInfo.html) = \['user_id' => [long](/API_docs/types/long.html), 'description' => [string](/API_docs/types/string.html), 'description_photo' => [Photo](/API_docs/types/Photo.html), 'description_document' => [Document](/API_docs/types/Document.html), 'commands' => \[[BotCommand](/API_docs/types/BotCommand.html)\], 'menu_button' => [BotMenuButton](/API_docs/types/BotMenuButton.html), \]; + +*** +

[$botInlineMediaResult](/API_docs/constructors/botInlineMediaResult.html) = \['id' => [string](/API_docs/types/string.html), 'type' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), 'document' => [Document](/API_docs/types/Document.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'send_message' => [BotInlineMessage](/API_docs/types/BotInlineMessage.html), \]; + +*** +

[$botInlineMessageMediaAuto](/API_docs/constructors/botInlineMessageMediaAuto.html) = \['invert_media' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineMessageMediaContact](/API_docs/constructors/botInlineMessageMediaContact.html) = \['phone_number' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'vcard' => [string](/API_docs/types/string.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineMessageMediaGeo](/API_docs/constructors/botInlineMessageMediaGeo.html) = \['geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'heading' => [int](/API_docs/types/int.html), 'period' => [int](/API_docs/types/int.html), 'proximity_notification_radius' => [int](/API_docs/types/int.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineMessageMediaInvoice](/API_docs/constructors/botInlineMessageMediaInvoice.html) = \['shipping_address_requested' => [Bool](/API_docs/types/Bool.html), 'test' => [Bool](/API_docs/types/Bool.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [WebDocument](/API_docs/types/WebDocument.html), 'currency' => [string](/API_docs/types/string.html), 'total_amount' => [long](/API_docs/types/long.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineMessageMediaVenue](/API_docs/constructors/botInlineMessageMediaVenue.html) = \['geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'title' => [string](/API_docs/types/string.html), 'address' => [string](/API_docs/types/string.html), 'provider' => [string](/API_docs/types/string.html), 'venue_id' => [string](/API_docs/types/string.html), 'venue_type' => [string](/API_docs/types/string.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineMessageMediaWebPage](/API_docs/constructors/botInlineMessageMediaWebPage.html) = \['invert_media' => [Bool](/API_docs/types/Bool.html), 'force_large_media' => [Bool](/API_docs/types/Bool.html), 'force_small_media' => [Bool](/API_docs/types/Bool.html), 'manual' => [Bool](/API_docs/types/Bool.html), 'safe' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'url' => [string](/API_docs/types/string.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineMessageText](/API_docs/constructors/botInlineMessageText.html) = \['no_webpage' => [Bool](/API_docs/types/Bool.html), 'invert_media' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$botInlineResult](/API_docs/constructors/botInlineResult.html) = \['id' => [string](/API_docs/types/string.html), 'type' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), 'thumb' => [WebDocument](/API_docs/types/WebDocument.html), 'content' => [WebDocument](/API_docs/types/WebDocument.html), 'send_message' => [BotInlineMessage](/API_docs/types/BotInlineMessage.html), \]; + +*** +

[$botMenuButton](/API_docs/constructors/botMenuButton.html) = \['text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$botMenuButtonCommands](/API_docs/constructors/botMenuButtonCommands.html) = \[\]; + +*** +

[$botMenuButtonDefault](/API_docs/constructors/botMenuButtonDefault.html) = \[\]; + +*** +

[$bots.botInfo](/API_docs/constructors/bots.botInfo.html) = \['name' => [string](/API_docs/types/string.html), 'about' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), \]; + +*** +

[$broadcastRevenueBalances](/API_docs/constructors/broadcastRevenueBalances.html) = \['current_balance' => [long](/API_docs/types/long.html), 'available_balance' => [long](/API_docs/types/long.html), 'overall_revenue' => [long](/API_docs/types/long.html), \]; + +*** +

[$broadcastRevenueTransactionProceeds](/API_docs/constructors/broadcastRevenueTransactionProceeds.html) = \['amount' => [long](/API_docs/types/long.html), 'from_date' => [int](/API_docs/types/int.html), 'to_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$broadcastRevenueTransactionRefund](/API_docs/constructors/broadcastRevenueTransactionRefund.html) = \['amount' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'provider' => [string](/API_docs/types/string.html), \]; + +*** +

[$broadcastRevenueTransactionWithdrawal](/API_docs/constructors/broadcastRevenueTransactionWithdrawal.html) = \['pending' => [Bool](/API_docs/types/Bool.html), 'failed' => [Bool](/API_docs/types/Bool.html), 'amount' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'provider' => [string](/API_docs/types/string.html), 'transaction_date' => [int](/API_docs/types/int.html), 'transaction_url' => [string](/API_docs/types/string.html), \]; + +*** +

[$businessAwayMessage](/API_docs/constructors/businessAwayMessage.html) = \['offline_only' => [Bool](/API_docs/types/Bool.html), 'shortcut_id' => [int](/API_docs/types/int.html), 'schedule' => [BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html), 'recipients' => [BusinessRecipients](/API_docs/types/BusinessRecipients.html), \]; + +*** +

[$businessAwayMessageScheduleAlways](/API_docs/constructors/businessAwayMessageScheduleAlways.html) = \[\]; + +*** +

[$businessAwayMessageScheduleCustom](/API_docs/constructors/businessAwayMessageScheduleCustom.html) = \['start_date' => [int](/API_docs/types/int.html), 'end_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$businessAwayMessageScheduleOutsideWorkHours](/API_docs/constructors/businessAwayMessageScheduleOutsideWorkHours.html) = \[\]; + +*** +

[$businessBotRecipients](/API_docs/constructors/businessBotRecipients.html) = \['existing_chats' => [Bool](/API_docs/types/Bool.html), 'new_chats' => [Bool](/API_docs/types/Bool.html), 'contacts' => [Bool](/API_docs/types/Bool.html), 'non_contacts' => [Bool](/API_docs/types/Bool.html), 'exclude_selected' => [Bool](/API_docs/types/Bool.html), 'users' => \[[long](/API_docs/types/long.html)\], 'exclude_users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$businessChatLink](/API_docs/constructors/businessChatLink.html) = \['link' => [string](/API_docs/types/string.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'title' => [string](/API_docs/types/string.html), 'views' => [int](/API_docs/types/int.html), \]; + +*** +

[$businessGreetingMessage](/API_docs/constructors/businessGreetingMessage.html) = \['shortcut_id' => [int](/API_docs/types/int.html), 'recipients' => [BusinessRecipients](/API_docs/types/BusinessRecipients.html), 'no_activity_days' => [int](/API_docs/types/int.html), \]; + +*** +

[$businessIntro](/API_docs/constructors/businessIntro.html) = \['title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'sticker' => [Document](/API_docs/types/Document.html), \]; + +*** +

[$businessLocation](/API_docs/constructors/businessLocation.html) = \['geo_point' => [GeoPoint](/API_docs/types/GeoPoint.html), 'address' => [string](/API_docs/types/string.html), \]; + +*** +

[$businessRecipients](/API_docs/constructors/businessRecipients.html) = \['existing_chats' => [Bool](/API_docs/types/Bool.html), 'new_chats' => [Bool](/API_docs/types/Bool.html), 'contacts' => [Bool](/API_docs/types/Bool.html), 'non_contacts' => [Bool](/API_docs/types/Bool.html), 'exclude_selected' => [Bool](/API_docs/types/Bool.html), 'users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$businessWeeklyOpen](/API_docs/constructors/businessWeeklyOpen.html) = \['start_minute' => [int](/API_docs/types/int.html), 'end_minute' => [int](/API_docs/types/int.html), \]; + +*** +

[$businessWorkHours](/API_docs/constructors/businessWorkHours.html) = \['open_now' => [Bool](/API_docs/types/Bool.html), 'timezone_id' => [string](/API_docs/types/string.html), 'weekly_open' => \[[BusinessWeeklyOpen](/API_docs/types/BusinessWeeklyOpen.html)\], \]; + +*** +

[$cdnConfig](/API_docs/constructors/cdnConfig.html) = \['public_keys' => \[[CdnPublicKey](/API_docs/types/CdnPublicKey.html)\], \]; + +*** +

[$cdnPublicKey](/API_docs/constructors/cdnPublicKey.html) = \['dc_id' => [int](/API_docs/types/int.html), 'public_key' => [string](/API_docs/types/string.html), \]; + +*** +

[$channel](/API_docs/constructors/channel.html) = \['creator' => [Bool](/API_docs/types/Bool.html), 'left' => [Bool](/API_docs/types/Bool.html), 'broadcast' => [Bool](/API_docs/types/Bool.html), 'verified' => [Bool](/API_docs/types/Bool.html), 'megagroup' => [Bool](/API_docs/types/Bool.html), 'restricted' => [Bool](/API_docs/types/Bool.html), 'signatures' => [Bool](/API_docs/types/Bool.html), 'min' => [Bool](/API_docs/types/Bool.html), 'scam' => [Bool](/API_docs/types/Bool.html), 'has_link' => [Bool](/API_docs/types/Bool.html), 'has_geo' => [Bool](/API_docs/types/Bool.html), 'slowmode_enabled' => [Bool](/API_docs/types/Bool.html), 'call_active' => [Bool](/API_docs/types/Bool.html), 'call_not_empty' => [Bool](/API_docs/types/Bool.html), 'fake' => [Bool](/API_docs/types/Bool.html), 'gigagroup' => [Bool](/API_docs/types/Bool.html), 'noforwards' => [Bool](/API_docs/types/Bool.html), 'join_to_send' => [Bool](/API_docs/types/Bool.html), 'join_request' => [Bool](/API_docs/types/Bool.html), 'forum' => [Bool](/API_docs/types/Bool.html), 'stories_hidden' => [Bool](/API_docs/types/Bool.html), 'stories_hidden_min' => [Bool](/API_docs/types/Bool.html), 'stories_unavailable' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'username' => [string](/API_docs/types/string.html), 'photo' => [ChatPhoto](/API_docs/types/ChatPhoto.html), 'date' => [int](/API_docs/types/int.html), 'restriction_reason' => \[[RestrictionReason](/API_docs/types/RestrictionReason.html)\], 'admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), 'default_banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), 'participants_count' => [int](/API_docs/types/int.html), 'usernames' => \[[Username](/API_docs/types/Username.html)\], 'stories_max_id' => [int](/API_docs/types/int.html), 'color' => [PeerColor](/API_docs/types/PeerColor.html), 'profile_color' => [PeerColor](/API_docs/types/PeerColor.html), 'emoji_status' => [EmojiStatus](/API_docs/types/EmojiStatus.html), 'level' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelAdminLogEvent](/API_docs/constructors/channelAdminLogEvent.html) = \['id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), 'action' => [ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html), \]; + +*** +

[$channelAdminLogEventActionChangeAbout](/API_docs/constructors/channelAdminLogEventActionChangeAbout.html) = \['prev_value' => [string](/API_docs/types/string.html), 'new_value' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelAdminLogEventActionChangeAvailableReactions](/API_docs/constructors/channelAdminLogEventActionChangeAvailableReactions.html) = \['prev_value' => [ChatReactions](/API_docs/types/ChatReactions.html), 'new_value' => [ChatReactions](/API_docs/types/ChatReactions.html), \]; + +*** +

[$channelAdminLogEventActionChangeEmojiStatus](/API_docs/constructors/channelAdminLogEventActionChangeEmojiStatus.html) = \['prev_value' => [EmojiStatus](/API_docs/types/EmojiStatus.html), 'new_value' => [EmojiStatus](/API_docs/types/EmojiStatus.html), \]; + +*** +

[$channelAdminLogEventActionChangeEmojiStickerSet](/API_docs/constructors/channelAdminLogEventActionChangeEmojiStickerSet.html) = \['prev_stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), 'new_stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), \]; + +*** +

[$channelAdminLogEventActionChangeHistoryTTL](/API_docs/constructors/channelAdminLogEventActionChangeHistoryTTL.html) = \['prev_value' => [int](/API_docs/types/int.html), 'new_value' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelAdminLogEventActionChangeLinkedChat](/API_docs/constructors/channelAdminLogEventActionChangeLinkedChat.html) = \['prev_value' => [long](/API_docs/types/long.html), 'new_value' => [long](/API_docs/types/long.html), \]; + +*** +

[$channelAdminLogEventActionChangeLocation](/API_docs/constructors/channelAdminLogEventActionChangeLocation.html) = \['prev_value' => [ChannelLocation](/API_docs/types/ChannelLocation.html), 'new_value' => [ChannelLocation](/API_docs/types/ChannelLocation.html), \]; + +*** +

[$channelAdminLogEventActionChangePeerColor](/API_docs/constructors/channelAdminLogEventActionChangePeerColor.html) = \['prev_value' => [PeerColor](/API_docs/types/PeerColor.html), 'new_value' => [PeerColor](/API_docs/types/PeerColor.html), \]; + +*** +

[$channelAdminLogEventActionChangePhoto](/API_docs/constructors/channelAdminLogEventActionChangePhoto.html) = \['prev_photo' => [Photo](/API_docs/types/Photo.html), 'new_photo' => [Photo](/API_docs/types/Photo.html), \]; + +*** +

[$channelAdminLogEventActionChangeProfilePeerColor](/API_docs/constructors/channelAdminLogEventActionChangeProfilePeerColor.html) = \['prev_value' => [PeerColor](/API_docs/types/PeerColor.html), 'new_value' => [PeerColor](/API_docs/types/PeerColor.html), \]; + +*** +

[$channelAdminLogEventActionChangeStickerSet](/API_docs/constructors/channelAdminLogEventActionChangeStickerSet.html) = \['prev_stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), 'new_stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), \]; + +*** +

[$channelAdminLogEventActionChangeTitle](/API_docs/constructors/channelAdminLogEventActionChangeTitle.html) = \['prev_value' => [string](/API_docs/types/string.html), 'new_value' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelAdminLogEventActionChangeUsername](/API_docs/constructors/channelAdminLogEventActionChangeUsername.html) = \['prev_value' => [string](/API_docs/types/string.html), 'new_value' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelAdminLogEventActionChangeUsernames](/API_docs/constructors/channelAdminLogEventActionChangeUsernames.html) = \['prev_value' => \[[string](/API_docs/types/string.html)\], 'new_value' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$channelAdminLogEventActionChangeWallpaper](/API_docs/constructors/channelAdminLogEventActionChangeWallpaper.html) = \['prev_value' => [WallPaper](/API_docs/types/WallPaper.html), 'new_value' => [WallPaper](/API_docs/types/WallPaper.html), \]; + +*** +

[$channelAdminLogEventActionCreateTopic](/API_docs/constructors/channelAdminLogEventActionCreateTopic.html) = \['topic' => [ForumTopic](/API_docs/types/ForumTopic.html), \]; + +*** +

[$channelAdminLogEventActionDefaultBannedRights](/API_docs/constructors/channelAdminLogEventActionDefaultBannedRights.html) = \['prev_banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), 'new_banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), \]; + +*** +

[$channelAdminLogEventActionDeleteMessage](/API_docs/constructors/channelAdminLogEventActionDeleteMessage.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$channelAdminLogEventActionDeleteTopic](/API_docs/constructors/channelAdminLogEventActionDeleteTopic.html) = \['topic' => [ForumTopic](/API_docs/types/ForumTopic.html), \]; + +*** +

[$channelAdminLogEventActionDiscardGroupCall](/API_docs/constructors/channelAdminLogEventActionDiscardGroupCall.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), \]; + +*** +

[$channelAdminLogEventActionEditMessage](/API_docs/constructors/channelAdminLogEventActionEditMessage.html) = \['prev_message' => [Message](/API_docs/types/Message.html), 'new_message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$channelAdminLogEventActionEditTopic](/API_docs/constructors/channelAdminLogEventActionEditTopic.html) = \['prev_topic' => [ForumTopic](/API_docs/types/ForumTopic.html), 'new_topic' => [ForumTopic](/API_docs/types/ForumTopic.html), \]; + +*** +

[$channelAdminLogEventActionExportedInviteDelete](/API_docs/constructors/channelAdminLogEventActionExportedInviteDelete.html) = \['invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), \]; + +*** +

[$channelAdminLogEventActionExportedInviteEdit](/API_docs/constructors/channelAdminLogEventActionExportedInviteEdit.html) = \['prev_invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'new_invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), \]; + +*** +

[$channelAdminLogEventActionExportedInviteRevoke](/API_docs/constructors/channelAdminLogEventActionExportedInviteRevoke.html) = \['invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), \]; + +*** +

[$channelAdminLogEventActionParticipantInvite](/API_docs/constructors/channelAdminLogEventActionParticipantInvite.html) = \['participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), \]; + +*** +

[$channelAdminLogEventActionParticipantJoin](/API_docs/constructors/channelAdminLogEventActionParticipantJoin.html) = \[\]; + +*** +

[$channelAdminLogEventActionParticipantJoinByInvite](/API_docs/constructors/channelAdminLogEventActionParticipantJoinByInvite.html) = \['via_chatlist' => [Bool](/API_docs/types/Bool.html), 'invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), \]; + +*** +

[$channelAdminLogEventActionParticipantJoinByRequest](/API_docs/constructors/channelAdminLogEventActionParticipantJoinByRequest.html) = \['invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'approved_by' => [long](/API_docs/types/long.html), \]; + +*** +

[$channelAdminLogEventActionParticipantLeave](/API_docs/constructors/channelAdminLogEventActionParticipantLeave.html) = \[\]; + +*** +

[$channelAdminLogEventActionParticipantMute](/API_docs/constructors/channelAdminLogEventActionParticipantMute.html) = \['participant' => [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html), \]; + +*** +

[$channelAdminLogEventActionParticipantToggleAdmin](/API_docs/constructors/channelAdminLogEventActionParticipantToggleAdmin.html) = \['prev_participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), 'new_participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), \]; + +*** +

[$channelAdminLogEventActionParticipantToggleBan](/API_docs/constructors/channelAdminLogEventActionParticipantToggleBan.html) = \['prev_participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), 'new_participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), \]; + +*** +

[$channelAdminLogEventActionParticipantUnmute](/API_docs/constructors/channelAdminLogEventActionParticipantUnmute.html) = \['participant' => [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html), \]; + +*** +

[$channelAdminLogEventActionParticipantVolume](/API_docs/constructors/channelAdminLogEventActionParticipantVolume.html) = \['participant' => [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html), \]; + +*** +

[$channelAdminLogEventActionPinTopic](/API_docs/constructors/channelAdminLogEventActionPinTopic.html) = \['prev_topic' => [ForumTopic](/API_docs/types/ForumTopic.html), 'new_topic' => [ForumTopic](/API_docs/types/ForumTopic.html), \]; + +*** +

[$channelAdminLogEventActionSendMessage](/API_docs/constructors/channelAdminLogEventActionSendMessage.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$channelAdminLogEventActionStartGroupCall](/API_docs/constructors/channelAdminLogEventActionStartGroupCall.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), \]; + +*** +

[$channelAdminLogEventActionStopPoll](/API_docs/constructors/channelAdminLogEventActionStopPoll.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$channelAdminLogEventActionToggleAntiSpam](/API_docs/constructors/channelAdminLogEventActionToggleAntiSpam.html) = \['new_value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionToggleForum](/API_docs/constructors/channelAdminLogEventActionToggleForum.html) = \['new_value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionToggleGroupCallSetting](/API_docs/constructors/channelAdminLogEventActionToggleGroupCallSetting.html) = \['join_muted' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionToggleInvites](/API_docs/constructors/channelAdminLogEventActionToggleInvites.html) = \['new_value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionToggleNoForwards](/API_docs/constructors/channelAdminLogEventActionToggleNoForwards.html) = \['new_value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionTogglePreHistoryHidden](/API_docs/constructors/channelAdminLogEventActionTogglePreHistoryHidden.html) = \['new_value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionToggleSignatures](/API_docs/constructors/channelAdminLogEventActionToggleSignatures.html) = \['new_value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelAdminLogEventActionToggleSlowMode](/API_docs/constructors/channelAdminLogEventActionToggleSlowMode.html) = \['prev_value' => [int](/API_docs/types/int.html), 'new_value' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelAdminLogEventActionUpdatePinned](/API_docs/constructors/channelAdminLogEventActionUpdatePinned.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$channelAdminLogEventsFilter](/API_docs/constructors/channelAdminLogEventsFilter.html) = \['join' => [Bool](/API_docs/types/Bool.html), 'leave' => [Bool](/API_docs/types/Bool.html), 'invite' => [Bool](/API_docs/types/Bool.html), 'ban' => [Bool](/API_docs/types/Bool.html), 'unban' => [Bool](/API_docs/types/Bool.html), 'kick' => [Bool](/API_docs/types/Bool.html), 'unkick' => [Bool](/API_docs/types/Bool.html), 'promote' => [Bool](/API_docs/types/Bool.html), 'demote' => [Bool](/API_docs/types/Bool.html), 'info' => [Bool](/API_docs/types/Bool.html), 'settings' => [Bool](/API_docs/types/Bool.html), 'pinned' => [Bool](/API_docs/types/Bool.html), 'edit' => [Bool](/API_docs/types/Bool.html), 'delete' => [Bool](/API_docs/types/Bool.html), 'group_call' => [Bool](/API_docs/types/Bool.html), 'invites' => [Bool](/API_docs/types/Bool.html), 'send' => [Bool](/API_docs/types/Bool.html), 'forums' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$channelForbidden](/API_docs/constructors/channelForbidden.html) = \['broadcast' => [Bool](/API_docs/types/Bool.html), 'megagroup' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelFull](/API_docs/constructors/channelFull.html) = \['can_view_participants' => [Bool](/API_docs/types/Bool.html), 'can_set_username' => [Bool](/API_docs/types/Bool.html), 'can_set_stickers' => [Bool](/API_docs/types/Bool.html), 'hidden_prehistory' => [Bool](/API_docs/types/Bool.html), 'can_set_location' => [Bool](/API_docs/types/Bool.html), 'has_scheduled' => [Bool](/API_docs/types/Bool.html), 'can_view_stats' => [Bool](/API_docs/types/Bool.html), 'blocked' => [Bool](/API_docs/types/Bool.html), 'can_delete_channel' => [Bool](/API_docs/types/Bool.html), 'antispam' => [Bool](/API_docs/types/Bool.html), 'participants_hidden' => [Bool](/API_docs/types/Bool.html), 'translations_disabled' => [Bool](/API_docs/types/Bool.html), 'stories_pinned_available' => [Bool](/API_docs/types/Bool.html), 'view_forum_as_messages' => [Bool](/API_docs/types/Bool.html), 'restricted_sponsored' => [Bool](/API_docs/types/Bool.html), 'can_view_revenue' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'about' => [string](/API_docs/types/string.html), 'participants_count' => [int](/API_docs/types/int.html), 'admins_count' => [int](/API_docs/types/int.html), 'kicked_count' => [int](/API_docs/types/int.html), 'banned_count' => [int](/API_docs/types/int.html), 'online_count' => [int](/API_docs/types/int.html), 'read_inbox_max_id' => [int](/API_docs/types/int.html), 'read_outbox_max_id' => [int](/API_docs/types/int.html), 'unread_count' => [int](/API_docs/types/int.html), 'chat_photo' => [Photo](/API_docs/types/Photo.html), 'notify_settings' => [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html), 'exported_invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'bot_info' => \[[BotInfo](/API_docs/types/BotInfo.html)\], 'migrated_from_chat_id' => [long](/API_docs/types/long.html), 'migrated_from_max_id' => [int](/API_docs/types/int.html), 'pinned_msg_id' => [int](/API_docs/types/int.html), 'stickerset' => [StickerSet](/API_docs/types/StickerSet.html), 'available_min_id' => [int](/API_docs/types/int.html), 'folder_id' => [int](/API_docs/types/int.html), 'linked_chat_id' => [long](/API_docs/types/long.html), 'location' => [ChannelLocation](/API_docs/types/ChannelLocation.html), 'slowmode_seconds' => [int](/API_docs/types/int.html), 'slowmode_next_send_date' => [int](/API_docs/types/int.html), 'stats_dc' => [int](/API_docs/types/int.html), 'pts' => [int](/API_docs/types/int.html), 'call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'ttl_period' => [int](/API_docs/types/int.html), 'pending_suggestions' => \[[string](/API_docs/types/string.html)\], 'groupcall_default_join_as' => [Peer](/API_docs/types/Peer.html), 'theme_emoticon' => [string](/API_docs/types/string.html), 'requests_pending' => [int](/API_docs/types/int.html), 'recent_requesters' => \[[long](/API_docs/types/long.html)\], 'default_send_as' => [Peer](/API_docs/types/Peer.html), 'available_reactions' => [ChatReactions](/API_docs/types/ChatReactions.html), 'reactions_limit' => [int](/API_docs/types/int.html), 'stories' => [PeerStories](/API_docs/types/PeerStories.html), 'wallpaper' => [WallPaper](/API_docs/types/WallPaper.html), 'boosts_applied' => [int](/API_docs/types/int.html), 'boosts_unrestrict' => [int](/API_docs/types/int.html), 'emojiset' => [StickerSet](/API_docs/types/StickerSet.html), \]; + +*** +

[$channelLocation](/API_docs/constructors/channelLocation.html) = \['geo_point' => [GeoPoint](/API_docs/types/GeoPoint.html), 'address' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelLocationEmpty](/API_docs/constructors/channelLocationEmpty.html) = \[\]; + +*** +

[$channelMessagesFilter](/API_docs/constructors/channelMessagesFilter.html) = \['exclude_new_messages' => [Bool](/API_docs/types/Bool.html), 'ranges' => \[[MessageRange](/API_docs/types/MessageRange.html)\], \]; + +*** +

[$channelMessagesFilterEmpty](/API_docs/constructors/channelMessagesFilterEmpty.html) = \[\]; + +*** +

[$channelParticipant](/API_docs/constructors/channelParticipant.html) = \['user_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelParticipantAdmin](/API_docs/constructors/channelParticipantAdmin.html) = \['can_edit' => [Bool](/API_docs/types/Bool.html), 'self' => [Bool](/API_docs/types/Bool.html), 'user_id' => [long](/API_docs/types/long.html), 'inviter_id' => [long](/API_docs/types/long.html), 'promoted_by' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'rank' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelParticipantBanned](/API_docs/constructors/channelParticipantBanned.html) = \['left' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'kicked_by' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), \]; + +*** +

[$channelParticipantCreator](/API_docs/constructors/channelParticipantCreator.html) = \['user_id' => [long](/API_docs/types/long.html), 'admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'rank' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelParticipantLeft](/API_docs/constructors/channelParticipantLeft.html) = \['peer' => [long](/API_docs/types/long.html), \]; + +*** +

[$channelParticipantSelf](/API_docs/constructors/channelParticipantSelf.html) = \['via_request' => [Bool](/API_docs/types/Bool.html), 'user_id' => [long](/API_docs/types/long.html), 'inviter_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelParticipantsAdmins](/API_docs/constructors/channelParticipantsAdmins.html) = \[\]; + +*** +

[$channelParticipantsBanned](/API_docs/constructors/channelParticipantsBanned.html) = \['q' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelParticipantsBots](/API_docs/constructors/channelParticipantsBots.html) = \[\]; + +*** +

[$channelParticipantsContacts](/API_docs/constructors/channelParticipantsContacts.html) = \['q' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelParticipantsKicked](/API_docs/constructors/channelParticipantsKicked.html) = \['q' => [string](/API_docs/types/string.html), \]; + +*** +

[$channelParticipantsMentions](/API_docs/constructors/channelParticipantsMentions.html) = \['q' => [string](/API_docs/types/string.html), 'top_msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$channelParticipantsRecent](/API_docs/constructors/channelParticipantsRecent.html) = \[\]; + +*** +

[$channelParticipantsSearch](/API_docs/constructors/channelParticipantsSearch.html) = \['q' => [string](/API_docs/types/string.html), \]; + +*** +

[$channels.adminLogResults](/API_docs/constructors/channels.adminLogResults.html) = \['events' => \[[ChannelAdminLogEvent](/API_docs/types/ChannelAdminLogEvent.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$channels.channelParticipant](/API_docs/constructors/channels.channelParticipant.html) = \['participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$channels.channelParticipants](/API_docs/constructors/channels.channelParticipants.html) = \['count' => [int](/API_docs/types/int.html), 'participants' => \[[ChannelParticipant](/API_docs/types/ChannelParticipant.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$channels.channelParticipantsNotModified](/API_docs/constructors/channels.channelParticipantsNotModified.html) = \[\]; + +*** +

[$channels.sendAsPeers](/API_docs/constructors/channels.sendAsPeers.html) = \['peers' => \[[SendAsPeer](/API_docs/types/SendAsPeer.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$channels.sponsoredMessageReportResultAdsHidden](/API_docs/constructors/channels.sponsoredMessageReportResultAdsHidden.html) = \[\]; + +*** +

[$channels.sponsoredMessageReportResultChooseOption](/API_docs/constructors/channels.sponsoredMessageReportResultChooseOption.html) = \['title' => [string](/API_docs/types/string.html), 'options' => \[[SponsoredMessageReportOption](/API_docs/types/SponsoredMessageReportOption.html)\], \]; + +*** +

[$channels.sponsoredMessageReportResultReported](/API_docs/constructors/channels.sponsoredMessageReportResultReported.html) = \[\]; + +*** +

[$chat](/API_docs/constructors/chat.html) = \['creator' => [Bool](/API_docs/types/Bool.html), 'left' => [Bool](/API_docs/types/Bool.html), 'deactivated' => [Bool](/API_docs/types/Bool.html), 'call_active' => [Bool](/API_docs/types/Bool.html), 'call_not_empty' => [Bool](/API_docs/types/Bool.html), 'noforwards' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'photo' => [ChatPhoto](/API_docs/types/ChatPhoto.html), 'participants_count' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'version' => [int](/API_docs/types/int.html), 'migrated_to' => [InputChannel](/API_docs/types/InputChannel.html), 'admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'default_banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), \]; + +*** +

[$chatAdminRights](/API_docs/constructors/chatAdminRights.html) = \['change_info' => [Bool](/API_docs/types/Bool.html), 'post_messages' => [Bool](/API_docs/types/Bool.html), 'edit_messages' => [Bool](/API_docs/types/Bool.html), 'delete_messages' => [Bool](/API_docs/types/Bool.html), 'ban_users' => [Bool](/API_docs/types/Bool.html), 'invite_users' => [Bool](/API_docs/types/Bool.html), 'pin_messages' => [Bool](/API_docs/types/Bool.html), 'add_admins' => [Bool](/API_docs/types/Bool.html), 'anonymous' => [Bool](/API_docs/types/Bool.html), 'manage_call' => [Bool](/API_docs/types/Bool.html), 'other' => [Bool](/API_docs/types/Bool.html), 'manage_topics' => [Bool](/API_docs/types/Bool.html), 'post_stories' => [Bool](/API_docs/types/Bool.html), 'edit_stories' => [Bool](/API_docs/types/Bool.html), 'delete_stories' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$chatAdminWithInvites](/API_docs/constructors/chatAdminWithInvites.html) = \['admin_id' => [long](/API_docs/types/long.html), 'invites_count' => [int](/API_docs/types/int.html), 'revoked_invites_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatBannedRights](/API_docs/constructors/chatBannedRights.html) = \['view_messages' => [Bool](/API_docs/types/Bool.html), 'send_messages' => [Bool](/API_docs/types/Bool.html), 'send_media' => [Bool](/API_docs/types/Bool.html), 'send_stickers' => [Bool](/API_docs/types/Bool.html), 'send_gifs' => [Bool](/API_docs/types/Bool.html), 'send_games' => [Bool](/API_docs/types/Bool.html), 'send_inline' => [Bool](/API_docs/types/Bool.html), 'embed_links' => [Bool](/API_docs/types/Bool.html), 'send_polls' => [Bool](/API_docs/types/Bool.html), 'change_info' => [Bool](/API_docs/types/Bool.html), 'invite_users' => [Bool](/API_docs/types/Bool.html), 'pin_messages' => [Bool](/API_docs/types/Bool.html), 'manage_topics' => [Bool](/API_docs/types/Bool.html), 'send_photos' => [Bool](/API_docs/types/Bool.html), 'send_videos' => [Bool](/API_docs/types/Bool.html), 'send_roundvideos' => [Bool](/API_docs/types/Bool.html), 'send_audios' => [Bool](/API_docs/types/Bool.html), 'send_voices' => [Bool](/API_docs/types/Bool.html), 'send_docs' => [Bool](/API_docs/types/Bool.html), 'send_plain' => [Bool](/API_docs/types/Bool.html), 'until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatEmpty](/API_docs/constructors/chatEmpty.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$chatForbidden](/API_docs/constructors/chatForbidden.html) = \['id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), \]; + +*** +

[$chatFull](/API_docs/constructors/chatFull.html) = \['can_set_username' => [Bool](/API_docs/types/Bool.html), 'has_scheduled' => [Bool](/API_docs/types/Bool.html), 'translations_disabled' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'about' => [string](/API_docs/types/string.html), 'participants' => [ChatParticipants](/API_docs/types/ChatParticipants.html), 'chat_photo' => [Photo](/API_docs/types/Photo.html), 'notify_settings' => [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html), 'exported_invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'bot_info' => \[[BotInfo](/API_docs/types/BotInfo.html)\], 'pinned_msg_id' => [int](/API_docs/types/int.html), 'folder_id' => [int](/API_docs/types/int.html), 'call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'ttl_period' => [int](/API_docs/types/int.html), 'groupcall_default_join_as' => [Peer](/API_docs/types/Peer.html), 'theme_emoticon' => [string](/API_docs/types/string.html), 'requests_pending' => [int](/API_docs/types/int.html), 'recent_requesters' => \[[long](/API_docs/types/long.html)\], 'available_reactions' => [ChatReactions](/API_docs/types/ChatReactions.html), 'reactions_limit' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatInvite](/API_docs/constructors/chatInvite.html) = \['channel' => [Bool](/API_docs/types/Bool.html), 'broadcast' => [Bool](/API_docs/types/Bool.html), 'public' => [Bool](/API_docs/types/Bool.html), 'megagroup' => [Bool](/API_docs/types/Bool.html), 'request_needed' => [Bool](/API_docs/types/Bool.html), 'verified' => [Bool](/API_docs/types/Bool.html), 'scam' => [Bool](/API_docs/types/Bool.html), 'fake' => [Bool](/API_docs/types/Bool.html), 'title' => [string](/API_docs/types/string.html), 'about' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), 'participants_count' => [int](/API_docs/types/int.html), 'participants' => \[[User](/API_docs/types/User.html)\], 'color' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatInviteAlready](/API_docs/constructors/chatInviteAlready.html) = \['chat' => [Chat](/API_docs/types/Chat.html), \]; + +*** +

[$chatInviteExported](/API_docs/constructors/chatInviteExported.html) = \['revoked' => [Bool](/API_docs/types/Bool.html), 'permanent' => [Bool](/API_docs/types/Bool.html), 'request_needed' => [Bool](/API_docs/types/Bool.html), 'link' => [string](/API_docs/types/string.html), 'admin_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'start_date' => [int](/API_docs/types/int.html), 'expire_date' => [int](/API_docs/types/int.html), 'usage_limit' => [int](/API_docs/types/int.html), 'usage' => [int](/API_docs/types/int.html), 'requested' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), \]; + +*** +

[$chatInviteImporter](/API_docs/constructors/chatInviteImporter.html) = \['requested' => [Bool](/API_docs/types/Bool.html), 'via_chatlist' => [Bool](/API_docs/types/Bool.html), 'user_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'about' => [string](/API_docs/types/string.html), 'approved_by' => [long](/API_docs/types/long.html), \]; + +*** +

[$chatInvitePeek](/API_docs/constructors/chatInvitePeek.html) = \['chat' => [Chat](/API_docs/types/Chat.html), 'expires' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatInvitePublicJoinRequests](/API_docs/constructors/chatInvitePublicJoinRequests.html) = \[\]; + +*** +

[$chatOnlines](/API_docs/constructors/chatOnlines.html) = \['onlines' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatParticipant](/API_docs/constructors/chatParticipant.html) = \['user_id' => [long](/API_docs/types/long.html), 'inviter_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatParticipantAdmin](/API_docs/constructors/chatParticipantAdmin.html) = \['user_id' => [long](/API_docs/types/long.html), 'inviter_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatParticipantCreator](/API_docs/constructors/chatParticipantCreator.html) = \['user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$chatParticipants](/API_docs/constructors/chatParticipants.html) = \['chat_id' => [long](/API_docs/types/long.html), 'participants' => \[[ChatParticipant](/API_docs/types/ChatParticipant.html)\], 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatParticipantsForbidden](/API_docs/constructors/chatParticipantsForbidden.html) = \['chat_id' => [long](/API_docs/types/long.html), 'self_participant' => [ChatParticipant](/API_docs/types/ChatParticipant.html), \]; + +*** +

[$chatPhoto](/API_docs/constructors/chatPhoto.html) = \['has_video' => [Bool](/API_docs/types/Bool.html), 'photo_id' => [long](/API_docs/types/long.html), 'stripped_thumb' => [bytes](/API_docs/types/bytes.html), 'dc_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$chatPhotoEmpty](/API_docs/constructors/chatPhotoEmpty.html) = \[\]; + +*** +

[$chatReactionsAll](/API_docs/constructors/chatReactionsAll.html) = \['allow_custom' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$chatReactionsNone](/API_docs/constructors/chatReactionsNone.html) = \[\]; + +*** +

[$chatReactionsSome](/API_docs/constructors/chatReactionsSome.html) = \['reactions' => \[[Reaction](/API_docs/types/Reaction.html)\], \]; + +*** +

[$chatlists.chatlistInvite](/API_docs/constructors/chatlists.chatlistInvite.html) = \['title' => [string](/API_docs/types/string.html), 'emoticon' => [string](/API_docs/types/string.html), 'peers' => \[[Peer](/API_docs/types/Peer.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$chatlists.chatlistInviteAlready](/API_docs/constructors/chatlists.chatlistInviteAlready.html) = \['filter_id' => [int](/API_docs/types/int.html), 'missing_peers' => \[[Peer](/API_docs/types/Peer.html)\], 'already_peers' => \[[Peer](/API_docs/types/Peer.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$chatlists.chatlistUpdates](/API_docs/constructors/chatlists.chatlistUpdates.html) = \['missing_peers' => \[[Peer](/API_docs/types/Peer.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$chatlists.exportedChatlistInvite](/API_docs/constructors/chatlists.exportedChatlistInvite.html) = \['filter' => [DialogFilter](/API_docs/types/DialogFilter.html), 'invite' => [ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html), \]; + +*** +

[$chatlists.exportedInvites](/API_docs/constructors/chatlists.exportedInvites.html) = \['invites' => \[[ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$codeSettings](/API_docs/constructors/codeSettings.html) = \['allow_flashcall' => [Bool](/API_docs/types/Bool.html), 'current_number' => [Bool](/API_docs/types/Bool.html), 'allow_app_hash' => [Bool](/API_docs/types/Bool.html), 'allow_missed_call' => [Bool](/API_docs/types/Bool.html), 'allow_firebase' => [Bool](/API_docs/types/Bool.html), 'unknown_number' => [Bool](/API_docs/types/Bool.html), 'logout_tokens' => \[[bytes](/API_docs/types/bytes.html)\], 'token' => [string](/API_docs/types/string.html), 'app_sandbox' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$config](/API_docs/constructors/config.html) = \['default_p2p_contacts' => [Bool](/API_docs/types/Bool.html), 'preload_featured_stickers' => [Bool](/API_docs/types/Bool.html), 'revoke_pm_inbox' => [Bool](/API_docs/types/Bool.html), 'blocked_mode' => [Bool](/API_docs/types/Bool.html), 'force_try_ipv6' => [Bool](/API_docs/types/Bool.html), 'date' => [int](/API_docs/types/int.html), 'expires' => [int](/API_docs/types/int.html), 'test_mode' => [Bool](/API_docs/types/Bool.html), 'this_dc' => [int](/API_docs/types/int.html), 'dc_options' => \[[DcOption](/API_docs/types/DcOption.html)\], 'dc_txt_domain_name' => [string](/API_docs/types/string.html), 'chat_size_max' => [int](/API_docs/types/int.html), 'megagroup_size_max' => [int](/API_docs/types/int.html), 'forwarded_count_max' => [int](/API_docs/types/int.html), 'online_update_period_ms' => [int](/API_docs/types/int.html), 'offline_blur_timeout_ms' => [int](/API_docs/types/int.html), 'offline_idle_timeout_ms' => [int](/API_docs/types/int.html), 'online_cloud_timeout_ms' => [int](/API_docs/types/int.html), 'notify_cloud_delay_ms' => [int](/API_docs/types/int.html), 'notify_default_delay_ms' => [int](/API_docs/types/int.html), 'push_chat_period_ms' => [int](/API_docs/types/int.html), 'push_chat_limit' => [int](/API_docs/types/int.html), 'edit_time_limit' => [int](/API_docs/types/int.html), 'revoke_time_limit' => [int](/API_docs/types/int.html), 'revoke_pm_time_limit' => [int](/API_docs/types/int.html), 'rating_e_decay' => [int](/API_docs/types/int.html), 'stickers_recent_limit' => [int](/API_docs/types/int.html), 'channels_read_media_period' => [int](/API_docs/types/int.html), 'tmp_sessions' => [int](/API_docs/types/int.html), 'call_receive_timeout_ms' => [int](/API_docs/types/int.html), 'call_ring_timeout_ms' => [int](/API_docs/types/int.html), 'call_connect_timeout_ms' => [int](/API_docs/types/int.html), 'call_packet_timeout_ms' => [int](/API_docs/types/int.html), 'me_url_prefix' => [string](/API_docs/types/string.html), 'autoupdate_url_prefix' => [string](/API_docs/types/string.html), 'gif_search_username' => [string](/API_docs/types/string.html), 'venue_search_username' => [string](/API_docs/types/string.html), 'img_search_username' => [string](/API_docs/types/string.html), 'static_maps_provider' => [string](/API_docs/types/string.html), 'caption_length_max' => [int](/API_docs/types/int.html), 'message_length_max' => [int](/API_docs/types/int.html), 'webfile_dc_id' => [int](/API_docs/types/int.html), 'suggested_lang_code' => [string](/API_docs/types/string.html), 'lang_pack_version' => [int](/API_docs/types/int.html), 'base_lang_pack_version' => [int](/API_docs/types/int.html), 'reactions_default' => [Reaction](/API_docs/types/Reaction.html), 'autologin_token' => [string](/API_docs/types/string.html), \]; + +*** +

[$connectedBot](/API_docs/constructors/connectedBot.html) = \['can_reply' => [Bool](/API_docs/types/Bool.html), 'bot_id' => [long](/API_docs/types/long.html), 'recipients' => [BusinessBotRecipients](/API_docs/types/BusinessBotRecipients.html), \]; + +*** +

[$contact](/API_docs/constructors/contact.html) = \['user_id' => [long](/API_docs/types/long.html), 'mutual' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$contactBirthday](/API_docs/constructors/contactBirthday.html) = \['contact_id' => [long](/API_docs/types/long.html), 'birthday' => [Birthday](/API_docs/types/Birthday.html), \]; + +*** +

[$contactStatus](/API_docs/constructors/contactStatus.html) = \['user_id' => [long](/API_docs/types/long.html), 'status' => [UserStatus](/API_docs/types/UserStatus.html), \]; + +*** +

[$contacts.blocked](/API_docs/constructors/contacts.blocked.html) = \['blocked' => \[[PeerBlocked](/API_docs/types/PeerBlocked.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.blockedSlice](/API_docs/constructors/contacts.blockedSlice.html) = \['count' => [int](/API_docs/types/int.html), 'blocked' => \[[PeerBlocked](/API_docs/types/PeerBlocked.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.contactBirthdays](/API_docs/constructors/contacts.contactBirthdays.html) = \['contacts' => \[[ContactBirthday](/API_docs/types/ContactBirthday.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.contacts](/API_docs/constructors/contacts.contacts.html) = \['contacts' => \[[Contact](/API_docs/types/Contact.html)\], 'saved_count' => [int](/API_docs/types/int.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.contactsNotModified](/API_docs/constructors/contacts.contactsNotModified.html) = \[\]; + +*** +

[$contacts.found](/API_docs/constructors/contacts.found.html) = \['my_results' => \[[Peer](/API_docs/types/Peer.html)\], 'results' => \[[Peer](/API_docs/types/Peer.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.importedContacts](/API_docs/constructors/contacts.importedContacts.html) = \['imported' => \[[ImportedContact](/API_docs/types/ImportedContact.html)\], 'popular_invites' => \[[PopularContact](/API_docs/types/PopularContact.html)\], 'retry_contacts' => \[[long](/API_docs/types/long.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.resolvedPeer](/API_docs/constructors/contacts.resolvedPeer.html) = \['peer' => [long](/API_docs/types/long.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.topPeers](/API_docs/constructors/contacts.topPeers.html) = \['categories' => \[[TopPeerCategoryPeers](/API_docs/types/TopPeerCategoryPeers.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$contacts.topPeersDisabled](/API_docs/constructors/contacts.topPeersDisabled.html) = \[\]; + +*** +

[$contacts.topPeersNotModified](/API_docs/constructors/contacts.topPeersNotModified.html) = \[\]; + +*** +

[$dataJSON](/API_docs/constructors/dataJSON.html) = \['data' => [string](/API_docs/types/string.html), \]; + +*** +

[$dcOption](/API_docs/constructors/dcOption.html) = \['ipv6' => [Bool](/API_docs/types/Bool.html), 'media_only' => [Bool](/API_docs/types/Bool.html), 'tcpo_only' => [Bool](/API_docs/types/Bool.html), 'cdn' => [Bool](/API_docs/types/Bool.html), 'static' => [Bool](/API_docs/types/Bool.html), 'this_port_only' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'ip_address' => [string](/API_docs/types/string.html), 'port' => [int](/API_docs/types/int.html), 'secret' => [string](/API_docs/types/string.html), \]; + +*** +

[$decryptedMessage\_73](/API_docs/constructors/decryptedMessage_73.html) = \['no_webpage' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'ttl' => [int](/API_docs/types/int.html), 'message' => [string](/API_docs/types/string.html), 'media' => [DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'via_bot_name' => [string](/API_docs/types/string.html), 'reply_to_random_id' => [long](/API_docs/types/long.html), 'grouped_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$decryptedMessageActionAbortKey\_20](/API_docs/constructors/decryptedMessageActionAbortKey_20.html) = \['exchange_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$decryptedMessageActionAcceptKey\_20](/API_docs/constructors/decryptedMessageActionAcceptKey_20.html) = \['exchange_id' => [long](/API_docs/types/long.html), 'g_b' => [bytes](/API_docs/types/bytes.html), 'key_fingerprint' => [long](/API_docs/types/long.html), \]; + +*** +

[$decryptedMessageActionCommitKey\_20](/API_docs/constructors/decryptedMessageActionCommitKey_20.html) = \['exchange_id' => [long](/API_docs/types/long.html), 'key_fingerprint' => [long](/API_docs/types/long.html), \]; + +*** +

[$decryptedMessageActionDeleteMessages\_8](/API_docs/constructors/decryptedMessageActionDeleteMessages_8.html) = \['random_ids' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$decryptedMessageActionFlushHistory\_8](/API_docs/constructors/decryptedMessageActionFlushHistory_8.html) = \[\]; + +*** +

[$decryptedMessageActionNoop\_20](/API_docs/constructors/decryptedMessageActionNoop_20.html) = \[\]; + +*** +

[$decryptedMessageActionNotifyLayer\_17](/API_docs/constructors/decryptedMessageActionNotifyLayer_17.html) = \['layer' => [int](/API_docs/types/int.html), \]; + +*** +

[$decryptedMessageActionReadMessages\_8](/API_docs/constructors/decryptedMessageActionReadMessages_8.html) = \['random_ids' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$decryptedMessageActionRequestKey\_20](/API_docs/constructors/decryptedMessageActionRequestKey_20.html) = \['exchange_id' => [long](/API_docs/types/long.html), 'g_a' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$decryptedMessageActionResend\_17](/API_docs/constructors/decryptedMessageActionResend_17.html) = \['start_seq_no' => [int](/API_docs/types/int.html), 'end_seq_no' => [int](/API_docs/types/int.html), \]; + +*** +

[$decryptedMessageActionScreenshotMessages\_8](/API_docs/constructors/decryptedMessageActionScreenshotMessages_8.html) = \['random_ids' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$decryptedMessageActionSetMessageTTL\_8](/API_docs/constructors/decryptedMessageActionSetMessageTTL_8.html) = \['ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$decryptedMessageActionTyping\_17](/API_docs/constructors/decryptedMessageActionTyping_17.html) = \['action' => [SendMessageAction](/API_docs/types/SendMessageAction.html), \]; + +*** +

[$decryptedMessageLayer\_17](/API_docs/constructors/decryptedMessageLayer_17.html) = \['layer' => [int](/API_docs/types/int.html), 'in_seq_no' => [int](/API_docs/types/int.html), 'out_seq_no' => [int](/API_docs/types/int.html), 'message' => [DecryptedMessage](/API_docs/types/DecryptedMessage.html), \]; + +*** +

[$decryptedMessageMediaAudio\_17](/API_docs/constructors/decryptedMessageMediaAudio_17.html) = \['duration' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'size' => [int](/API_docs/types/int.html), 'key' => [bytes](/API_docs/types/bytes.html), 'iv' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$decryptedMessageMediaContact\_8](/API_docs/constructors/decryptedMessageMediaContact_8.html) = \['phone_number' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'user_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$decryptedMessageMediaDocument\_143](/API_docs/constructors/decryptedMessageMediaDocument_143.html) = \['thumb' => [bytes](/API_docs/types/bytes.html), 'thumb_w' => [int](/API_docs/types/int.html), 'thumb_h' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'size' => [long](/API_docs/types/long.html), 'key' => [bytes](/API_docs/types/bytes.html), 'iv' => [bytes](/API_docs/types/bytes.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], 'caption' => [string](/API_docs/types/string.html), \]; + +*** +

[$decryptedMessageMediaEmpty\_8](/API_docs/constructors/decryptedMessageMediaEmpty_8.html) = \[\]; + +*** +

[$decryptedMessageMediaExternalDocument\_23](/API_docs/constructors/decryptedMessageMediaExternalDocument_23.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'size' => [int](/API_docs/types/int.html), 'thumb' => [PhotoSize](/API_docs/types/PhotoSize.html), 'dc_id' => [int](/API_docs/types/int.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], \]; + +*** +

[$decryptedMessageMediaGeoPoint\_8](/API_docs/constructors/decryptedMessageMediaGeoPoint_8.html) = \['lat' => [double](/API_docs/types/double.html), 'long' => [double](/API_docs/types/double.html), \]; + +*** +

[$decryptedMessageMediaPhoto\_45](/API_docs/constructors/decryptedMessageMediaPhoto_45.html) = \['thumb' => [bytes](/API_docs/types/bytes.html), 'thumb_w' => [int](/API_docs/types/int.html), 'thumb_h' => [int](/API_docs/types/int.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'size' => [int](/API_docs/types/int.html), 'key' => [bytes](/API_docs/types/bytes.html), 'iv' => [bytes](/API_docs/types/bytes.html), 'caption' => [string](/API_docs/types/string.html), \]; + +*** +

[$decryptedMessageMediaVenue\_45](/API_docs/constructors/decryptedMessageMediaVenue_45.html) = \['lat' => [double](/API_docs/types/double.html), 'long' => [double](/API_docs/types/double.html), 'title' => [string](/API_docs/types/string.html), 'address' => [string](/API_docs/types/string.html), 'provider' => [string](/API_docs/types/string.html), 'venue_id' => [string](/API_docs/types/string.html), \]; + +*** +

[$decryptedMessageMediaVideo\_45](/API_docs/constructors/decryptedMessageMediaVideo_45.html) = \['thumb' => [bytes](/API_docs/types/bytes.html), 'thumb_w' => [int](/API_docs/types/int.html), 'thumb_h' => [int](/API_docs/types/int.html), 'duration' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'size' => [int](/API_docs/types/int.html), 'key' => [bytes](/API_docs/types/bytes.html), 'iv' => [bytes](/API_docs/types/bytes.html), 'caption' => [string](/API_docs/types/string.html), \]; + +*** +

[$decryptedMessageMediaWebPage\_45](/API_docs/constructors/decryptedMessageMediaWebPage_45.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$decryptedMessageService\_17](/API_docs/constructors/decryptedMessageService_17.html) = \['action' => [DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html), \]; + +*** +

[$defaultHistoryTTL](/API_docs/constructors/defaultHistoryTTL.html) = \['period' => [int](/API_docs/types/int.html), \]; + +*** +

[$dialog](/API_docs/constructors/dialog.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'unread_mark' => [Bool](/API_docs/types/Bool.html), 'view_forum_as_messages' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'top_message' => [int](/API_docs/types/int.html), 'read_inbox_max_id' => [int](/API_docs/types/int.html), 'read_outbox_max_id' => [int](/API_docs/types/int.html), 'unread_count' => [int](/API_docs/types/int.html), 'unread_mentions_count' => [int](/API_docs/types/int.html), 'unread_reactions_count' => [int](/API_docs/types/int.html), 'notify_settings' => [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html), 'pts' => [int](/API_docs/types/int.html), 'draft' => [DraftMessage](/API_docs/types/DraftMessage.html), 'folder_id' => [int](/API_docs/types/int.html), 'ttl_period' => [int](/API_docs/types/int.html), \]; + +*** +

[$dialogFilter](/API_docs/constructors/dialogFilter.html) = \['contacts' => [Bool](/API_docs/types/Bool.html), 'non_contacts' => [Bool](/API_docs/types/Bool.html), 'groups' => [Bool](/API_docs/types/Bool.html), 'broadcasts' => [Bool](/API_docs/types/Bool.html), 'bots' => [Bool](/API_docs/types/Bool.html), 'exclude_muted' => [Bool](/API_docs/types/Bool.html), 'exclude_read' => [Bool](/API_docs/types/Bool.html), 'exclude_archived' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), 'emoticon' => [string](/API_docs/types/string.html), 'color' => [int](/API_docs/types/int.html), 'pinned_peers' => \[[InputPeer](/API_docs/types/InputPeer.html)\], 'include_peers' => \[[InputPeer](/API_docs/types/InputPeer.html)\], 'exclude_peers' => \[[InputPeer](/API_docs/types/InputPeer.html)\], \]; + +*** +

[$dialogFilterChatlist](/API_docs/constructors/dialogFilterChatlist.html) = \['has_my_invites' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), 'emoticon' => [string](/API_docs/types/string.html), 'color' => [int](/API_docs/types/int.html), 'pinned_peers' => \[[InputPeer](/API_docs/types/InputPeer.html)\], 'include_peers' => \[[InputPeer](/API_docs/types/InputPeer.html)\], \]; + +*** +

[$dialogFilterDefault](/API_docs/constructors/dialogFilterDefault.html) = \[\]; + +*** +

[$dialogFilterSuggested](/API_docs/constructors/dialogFilterSuggested.html) = \['filter' => [DialogFilter](/API_docs/types/DialogFilter.html), 'description' => [string](/API_docs/types/string.html), \]; + +*** +

[$dialogFolder](/API_docs/constructors/dialogFolder.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'folder' => [Folder](/API_docs/types/Folder.html), 'peer' => [long](/API_docs/types/long.html), 'top_message' => [int](/API_docs/types/int.html), 'unread_muted_peers_count' => [int](/API_docs/types/int.html), 'unread_unmuted_peers_count' => [int](/API_docs/types/int.html), 'unread_muted_messages_count' => [int](/API_docs/types/int.html), 'unread_unmuted_messages_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$dialogPeer](/API_docs/constructors/dialogPeer.html) = \['peer' => [long](/API_docs/types/long.html), \]; + +*** +

[$dialogPeerFolder](/API_docs/constructors/dialogPeerFolder.html) = \['folder_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$document](/API_docs/constructors/document.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), 'date' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'size' => [long](/API_docs/types/long.html), 'thumbs' => \[[PhotoSize](/API_docs/types/PhotoSize.html)\], 'video_thumbs' => \[[VideoSize](/API_docs/types/VideoSize.html)\], 'dc_id' => [int](/API_docs/types/int.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], \]; + +*** +

[$documentAttributeAnimated](/API_docs/constructors/documentAttributeAnimated.html) = \[\]; + +*** +

[$documentAttributeAudio\_45](/API_docs/constructors/documentAttributeAudio_45.html) = \['duration' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), 'performer' => [string](/API_docs/types/string.html), \]; + +*** +

[$documentAttributeCustomEmoji](/API_docs/constructors/documentAttributeCustomEmoji.html) = \['free' => [Bool](/API_docs/types/Bool.html), 'text_color' => [Bool](/API_docs/types/Bool.html), 'alt' => [string](/API_docs/types/string.html), 'stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), \]; + +*** +

[$documentAttributeFilename](/API_docs/constructors/documentAttributeFilename.html) = \['file_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$documentAttributeHasStickers](/API_docs/constructors/documentAttributeHasStickers.html) = \[\]; + +*** +

[$documentAttributeImageSize](/API_docs/constructors/documentAttributeImageSize.html) = \['w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), \]; + +*** +

[$documentAttributeSticker\_45](/API_docs/constructors/documentAttributeSticker_45.html) = \['alt' => [string](/API_docs/types/string.html), 'stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), \]; + +*** +

[$documentAttributeVideo\_66](/API_docs/constructors/documentAttributeVideo_66.html) = \['round_message' => [Bool](/API_docs/types/Bool.html), 'duration' => [int](/API_docs/types/int.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), \]; + +*** +

[$documentEmpty](/API_docs/constructors/documentEmpty.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$draftMessage](/API_docs/constructors/draftMessage.html) = \['no_webpage' => [Bool](/API_docs/types/Bool.html), 'invert_media' => [Bool](/API_docs/types/Bool.html), 'reply_to' => [InputReplyTo](/API_docs/types/InputReplyTo.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'media' => [InputMedia](/API_docs/types/InputMedia.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$draftMessageEmpty](/API_docs/constructors/draftMessageEmpty.html) = \['date' => [int](/API_docs/types/int.html), \]; + +*** +

[$emailVerificationApple](/API_docs/constructors/emailVerificationApple.html) = \['token' => [string](/API_docs/types/string.html), \]; + +*** +

[$emailVerificationCode](/API_docs/constructors/emailVerificationCode.html) = \['code' => [string](/API_docs/types/string.html), \]; + +*** +

[$emailVerificationGoogle](/API_docs/constructors/emailVerificationGoogle.html) = \['token' => [string](/API_docs/types/string.html), \]; + +*** +

[$emailVerifyPurposeLoginChange](/API_docs/constructors/emailVerifyPurposeLoginChange.html) = \[\]; + +*** +

[$emailVerifyPurposeLoginSetup](/API_docs/constructors/emailVerifyPurposeLoginSetup.html) = \['phone_number' => [string](/API_docs/types/string.html), 'phone_code_hash' => [string](/API_docs/types/string.html), \]; + +*** +

[$emailVerifyPurposePassport](/API_docs/constructors/emailVerifyPurposePassport.html) = \[\]; + +*** +

[$emojiGroup](/API_docs/constructors/emojiGroup.html) = \['title' => [string](/API_docs/types/string.html), 'icon_emoji_id' => [long](/API_docs/types/long.html), 'emoticons' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$emojiGroupGreeting](/API_docs/constructors/emojiGroupGreeting.html) = \['title' => [string](/API_docs/types/string.html), 'icon_emoji_id' => [long](/API_docs/types/long.html), 'emoticons' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$emojiGroupPremium](/API_docs/constructors/emojiGroupPremium.html) = \['title' => [string](/API_docs/types/string.html), 'icon_emoji_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$emojiKeyword](/API_docs/constructors/emojiKeyword.html) = \['keyword' => [string](/API_docs/types/string.html), 'emoticons' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$emojiKeywordDeleted](/API_docs/constructors/emojiKeywordDeleted.html) = \['keyword' => [string](/API_docs/types/string.html), 'emoticons' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$emojiKeywordsDifference](/API_docs/constructors/emojiKeywordsDifference.html) = \['lang_code' => [string](/API_docs/types/string.html), 'from_version' => [int](/API_docs/types/int.html), 'version' => [int](/API_docs/types/int.html), 'keywords' => \[[EmojiKeyword](/API_docs/types/EmojiKeyword.html)\], \]; + +*** +

[$emojiLanguage](/API_docs/constructors/emojiLanguage.html) = \['lang_code' => [string](/API_docs/types/string.html), \]; + +*** +

[$emojiList](/API_docs/constructors/emojiList.html) = \['hash' => [long](/API_docs/types/long.html), 'document_id' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$emojiListNotModified](/API_docs/constructors/emojiListNotModified.html) = \[\]; + +*** +

[$emojiStatus](/API_docs/constructors/emojiStatus.html) = \['document_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$emojiStatusEmpty](/API_docs/constructors/emojiStatusEmpty.html) = \[\]; + +*** +

[$emojiStatusUntil](/API_docs/constructors/emojiStatusUntil.html) = \['document_id' => [long](/API_docs/types/long.html), 'until' => [int](/API_docs/types/int.html), \]; + +*** +

[$emojiURL](/API_docs/constructors/emojiURL.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$encryptedChat](/API_docs/constructors/encryptedChat.html) = \['id' => [int](/API_docs/types/int.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), 'g_a_or_b' => [bytes](/API_docs/types/bytes.html), 'key_fingerprint' => [long](/API_docs/types/long.html), \]; + +*** +

[$encryptedChatDiscarded](/API_docs/constructors/encryptedChatDiscarded.html) = \['history_deleted' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), \]; + +*** +

[$encryptedChatEmpty](/API_docs/constructors/encryptedChatEmpty.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$encryptedChatRequested](/API_docs/constructors/encryptedChatRequested.html) = \['folder_id' => [int](/API_docs/types/int.html), 'id' => [int](/API_docs/types/int.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), 'g_a' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$encryptedChatWaiting](/API_docs/constructors/encryptedChatWaiting.html) = \['id' => [int](/API_docs/types/int.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$encryptedFile](/API_docs/constructors/encryptedFile.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'size' => [long](/API_docs/types/long.html), 'dc_id' => [int](/API_docs/types/int.html), 'key_fingerprint' => [int](/API_docs/types/int.html), \]; + +*** +

[$encryptedFileEmpty](/API_docs/constructors/encryptedFileEmpty.html) = \[\]; + +*** +

[$encryptedMessage](/API_docs/constructors/encryptedMessage.html) = \['chat_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'decrypted_message' => [DecryptedMessage](/API_docs/types/DecryptedMessage.html), 'file' => [EncryptedFile](/API_docs/types/EncryptedFile.html), \]; + +*** +

[$encryptedMessageService](/API_docs/constructors/encryptedMessageService.html) = \['chat_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'decrypted_message' => [DecryptedMessage](/API_docs/types/DecryptedMessage.html), \]; + +*** +

[$error](/API_docs/constructors/error.html) = \['code' => [int](/API_docs/types/int.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$exportedChatlistInvite](/API_docs/constructors/exportedChatlistInvite.html) = \['title' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), 'peers' => \[[Peer](/API_docs/types/Peer.html)\], \]; + +*** +

[$exportedContactToken](/API_docs/constructors/exportedContactToken.html) = \['url' => [string](/API_docs/types/string.html), 'expires' => [int](/API_docs/types/int.html), \]; + +*** +

[$exportedMessageLink](/API_docs/constructors/exportedMessageLink.html) = \['link' => [string](/API_docs/types/string.html), 'html' => [string](/API_docs/types/string.html), \]; + +*** +

[$exportedStoryLink](/API_docs/constructors/exportedStoryLink.html) = \['link' => [string](/API_docs/types/string.html), \]; + +*** +

[$fileHash](/API_docs/constructors/fileHash.html) = \['offset' => [long](/API_docs/types/long.html), 'limit' => [int](/API_docs/types/int.html), 'hash' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$fileLocation\_23](/API_docs/constructors/fileLocation_23.html) = \['dc_id' => [int](/API_docs/types/int.html), 'volume_id' => [long](/API_docs/types/long.html), 'local_id' => [int](/API_docs/types/int.html), 'secret' => [long](/API_docs/types/long.html), \]; + +*** +

[$fileLocationUnavailable\_23](/API_docs/constructors/fileLocationUnavailable_23.html) = \['volume_id' => [long](/API_docs/types/long.html), 'local_id' => [int](/API_docs/types/int.html), 'secret' => [long](/API_docs/types/long.html), \]; + +*** +

[$folder](/API_docs/constructors/folder.html) = \['autofill_new_broadcasts' => [Bool](/API_docs/types/Bool.html), 'autofill_public_groups' => [Bool](/API_docs/types/Bool.html), 'autofill_new_correspondents' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), 'photo' => [ChatPhoto](/API_docs/types/ChatPhoto.html), \]; + +*** +

[$folderPeer](/API_docs/constructors/folderPeer.html) = \['peer' => [long](/API_docs/types/long.html), 'folder_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$forumTopic](/API_docs/constructors/forumTopic.html) = \['my' => [Bool](/API_docs/types/Bool.html), 'closed' => [Bool](/API_docs/types/Bool.html), 'pinned' => [Bool](/API_docs/types/Bool.html), 'short' => [Bool](/API_docs/types/Bool.html), 'hidden' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), 'icon_color' => [int](/API_docs/types/int.html), 'icon_emoji_id' => [long](/API_docs/types/long.html), 'top_message' => [int](/API_docs/types/int.html), 'read_inbox_max_id' => [int](/API_docs/types/int.html), 'read_outbox_max_id' => [int](/API_docs/types/int.html), 'unread_count' => [int](/API_docs/types/int.html), 'unread_mentions_count' => [int](/API_docs/types/int.html), 'unread_reactions_count' => [int](/API_docs/types/int.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'notify_settings' => [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html), 'draft' => [DraftMessage](/API_docs/types/DraftMessage.html), \]; + +*** +

[$forumTopicDeleted](/API_docs/constructors/forumTopicDeleted.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$fragment.collectibleInfo](/API_docs/constructors/fragment.collectibleInfo.html) = \['purchase_date' => [int](/API_docs/types/int.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), 'crypto_currency' => [string](/API_docs/types/string.html), 'crypto_amount' => [long](/API_docs/types/long.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$game](/API_docs/constructors/game.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'short_name' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), 'document' => [Document](/API_docs/types/Document.html), \]; + +*** +

[$geoPoint](/API_docs/constructors/geoPoint.html) = \['long' => [double](/API_docs/types/double.html), 'lat' => [double](/API_docs/types/double.html), 'access_hash' => [long](/API_docs/types/long.html), 'accuracy_radius' => [int](/API_docs/types/int.html), \]; + +*** +

[$geoPointEmpty](/API_docs/constructors/geoPointEmpty.html) = \[\]; + +*** +

[$globalPrivacySettings](/API_docs/constructors/globalPrivacySettings.html) = \['archive_and_mute_new_noncontact_peers' => [Bool](/API_docs/types/Bool.html), 'keep_archived_unmuted' => [Bool](/API_docs/types/Bool.html), 'keep_archived_folders' => [Bool](/API_docs/types/Bool.html), 'hide_read_marks' => [Bool](/API_docs/types/Bool.html), 'new_noncontact_peers_require_premium' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$groupCall](/API_docs/constructors/groupCall.html) = \['join_muted' => [Bool](/API_docs/types/Bool.html), 'can_change_join_muted' => [Bool](/API_docs/types/Bool.html), 'join_date_asc' => [Bool](/API_docs/types/Bool.html), 'schedule_start_subscribed' => [Bool](/API_docs/types/Bool.html), 'can_start_video' => [Bool](/API_docs/types/Bool.html), 'record_video_active' => [Bool](/API_docs/types/Bool.html), 'rtmp_stream' => [Bool](/API_docs/types/Bool.html), 'listeners_hidden' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'participants_count' => [int](/API_docs/types/int.html), 'title' => [string](/API_docs/types/string.html), 'stream_dc_id' => [int](/API_docs/types/int.html), 'record_start_date' => [int](/API_docs/types/int.html), 'schedule_date' => [int](/API_docs/types/int.html), 'unmuted_video_count' => [int](/API_docs/types/int.html), 'unmuted_video_limit' => [int](/API_docs/types/int.html), 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$groupCallDiscarded](/API_docs/constructors/groupCallDiscarded.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'duration' => [int](/API_docs/types/int.html), \]; + +*** +

[$groupCallParticipant](/API_docs/constructors/groupCallParticipant.html) = \['muted' => [Bool](/API_docs/types/Bool.html), 'left' => [Bool](/API_docs/types/Bool.html), 'can_self_unmute' => [Bool](/API_docs/types/Bool.html), 'just_joined' => [Bool](/API_docs/types/Bool.html), 'versioned' => [Bool](/API_docs/types/Bool.html), 'min' => [Bool](/API_docs/types/Bool.html), 'muted_by_you' => [Bool](/API_docs/types/Bool.html), 'volume_by_admin' => [Bool](/API_docs/types/Bool.html), 'self' => [Bool](/API_docs/types/Bool.html), 'video_joined' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'active_date' => [int](/API_docs/types/int.html), 'source' => [int](/API_docs/types/int.html), 'volume' => [int](/API_docs/types/int.html), 'about' => [string](/API_docs/types/string.html), 'raise_hand_rating' => [long](/API_docs/types/long.html), 'video' => [GroupCallParticipantVideo](/API_docs/types/GroupCallParticipantVideo.html), 'presentation' => [GroupCallParticipantVideo](/API_docs/types/GroupCallParticipantVideo.html), \]; + +*** +

[$groupCallParticipantVideo](/API_docs/constructors/groupCallParticipantVideo.html) = \['paused' => [Bool](/API_docs/types/Bool.html), 'endpoint' => [string](/API_docs/types/string.html), 'source_groups' => \[[GroupCallParticipantVideoSourceGroup](/API_docs/types/GroupCallParticipantVideoSourceGroup.html)\], 'audio_source' => [int](/API_docs/types/int.html), \]; + +*** +

[$groupCallParticipantVideoSourceGroup](/API_docs/constructors/groupCallParticipantVideoSourceGroup.html) = \['semantics' => [string](/API_docs/types/string.html), 'sources' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$groupCallStreamChannel](/API_docs/constructors/groupCallStreamChannel.html) = \['channel' => [int](/API_docs/types/int.html), 'scale' => [int](/API_docs/types/int.html), 'last_timestamp_ms' => [long](/API_docs/types/long.html), \]; + +*** +

[$help.appConfig](/API_docs/constructors/help.appConfig.html) = \['hash' => [int](/API_docs/types/int.html), 'config' => [JSONValue](/API_docs/types/JSONValue.html), \]; + +*** +

[$help.appConfigNotModified](/API_docs/constructors/help.appConfigNotModified.html) = \[\]; + +*** +

[$help.appUpdate](/API_docs/constructors/help.appUpdate.html) = \['can_not_skip' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'version' => [string](/API_docs/types/string.html), 'text' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'document' => [Document](/API_docs/types/Document.html), 'url' => [string](/API_docs/types/string.html), 'sticker' => [Document](/API_docs/types/Document.html), \]; + +*** +

[$help.countriesList](/API_docs/constructors/help.countriesList.html) = \['countries' => \[[help.Country](/API_docs/types/help.Country.html)\], 'hash' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.countriesListNotModified](/API_docs/constructors/help.countriesListNotModified.html) = \[\]; + +*** +

[$help.country](/API_docs/constructors/help.country.html) = \['hidden' => [Bool](/API_docs/types/Bool.html), 'iso2' => [string](/API_docs/types/string.html), 'default_name' => [string](/API_docs/types/string.html), 'name' => [string](/API_docs/types/string.html), 'country_codes' => \[[help.CountryCode](/API_docs/types/help.CountryCode.html)\], \]; + +*** +

[$help.countryCode](/API_docs/constructors/help.countryCode.html) = \['country_code' => [string](/API_docs/types/string.html), 'prefixes' => \[[string](/API_docs/types/string.html)\], 'patterns' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$help.deepLinkInfo](/API_docs/constructors/help.deepLinkInfo.html) = \['update_app' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], \]; + +*** +

[$help.deepLinkInfoEmpty](/API_docs/constructors/help.deepLinkInfoEmpty.html) = \[\]; + +*** +

[$help.inviteText](/API_docs/constructors/help.inviteText.html) = \['message' => [string](/API_docs/types/string.html), \]; + +*** +

[$help.noAppUpdate](/API_docs/constructors/help.noAppUpdate.html) = \[\]; + +*** +

[$help.passportConfig](/API_docs/constructors/help.passportConfig.html) = \['hash' => [int](/API_docs/types/int.html), 'countries_langs' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$help.passportConfigNotModified](/API_docs/constructors/help.passportConfigNotModified.html) = \[\]; + +*** +

[$help.peerColorOption](/API_docs/constructors/help.peerColorOption.html) = \['hidden' => [Bool](/API_docs/types/Bool.html), 'color_id' => [int](/API_docs/types/int.html), 'colors' => [help.PeerColorSet](/API_docs/types/help.PeerColorSet.html), 'dark_colors' => [help.PeerColorSet](/API_docs/types/help.PeerColorSet.html), 'channel_min_level' => [int](/API_docs/types/int.html), 'group_min_level' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.peerColorProfileSet](/API_docs/constructors/help.peerColorProfileSet.html) = \['palette_colors' => \[[int](/API_docs/types/int.html)\], 'bg_colors' => \[[int](/API_docs/types/int.html)\], 'story_colors' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$help.peerColorSet](/API_docs/constructors/help.peerColorSet.html) = \['colors' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$help.peerColors](/API_docs/constructors/help.peerColors.html) = \['hash' => [int](/API_docs/types/int.html), 'colors' => \[[help.PeerColorOption](/API_docs/types/help.PeerColorOption.html)\], \]; + +*** +

[$help.peerColorsNotModified](/API_docs/constructors/help.peerColorsNotModified.html) = \[\]; + +*** +

[$help.premiumPromo](/API_docs/constructors/help.premiumPromo.html) = \['status_text' => [string](/API_docs/types/string.html), 'status_entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'video_sections' => \[[string](/API_docs/types/string.html)\], 'videos' => \[[Document](/API_docs/types/Document.html)\], 'period_options' => \[[PremiumSubscriptionOption](/API_docs/types/PremiumSubscriptionOption.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$help.promoData](/API_docs/constructors/help.promoData.html) = \['proxy' => [Bool](/API_docs/types/Bool.html), 'expires' => [int](/API_docs/types/int.html), 'peer' => [long](/API_docs/types/long.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'psa_type' => [string](/API_docs/types/string.html), 'psa_message' => [string](/API_docs/types/string.html), \]; + +*** +

[$help.promoDataEmpty](/API_docs/constructors/help.promoDataEmpty.html) = \['expires' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.recentMeUrls](/API_docs/constructors/help.recentMeUrls.html) = \['urls' => \[[RecentMeUrl](/API_docs/types/RecentMeUrl.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$help.support](/API_docs/constructors/help.support.html) = \['phone_number' => [string](/API_docs/types/string.html), 'user' => [User](/API_docs/types/User.html), \]; + +*** +

[$help.supportName](/API_docs/constructors/help.supportName.html) = \['name' => [string](/API_docs/types/string.html), \]; + +*** +

[$help.termsOfService](/API_docs/constructors/help.termsOfService.html) = \['popup' => [Bool](/API_docs/types/Bool.html), 'id' => [DataJSON](/API_docs/types/DataJSON.html), 'text' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'min_age_confirm' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.termsOfServiceUpdate](/API_docs/constructors/help.termsOfServiceUpdate.html) = \['expires' => [int](/API_docs/types/int.html), 'terms_of_service' => [help.TermsOfService](/API_docs/types/help.TermsOfService.html), \]; + +*** +

[$help.termsOfServiceUpdateEmpty](/API_docs/constructors/help.termsOfServiceUpdateEmpty.html) = \['expires' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.timezonesList](/API_docs/constructors/help.timezonesList.html) = \['timezones' => \[[Timezone](/API_docs/types/Timezone.html)\], 'hash' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.timezonesListNotModified](/API_docs/constructors/help.timezonesListNotModified.html) = \[\]; + +*** +

[$help.userInfo](/API_docs/constructors/help.userInfo.html) = \['message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'author' => [string](/API_docs/types/string.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$help.userInfoEmpty](/API_docs/constructors/help.userInfoEmpty.html) = \[\]; + +*** +

[$highScore](/API_docs/constructors/highScore.html) = \['pos' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), 'score' => [int](/API_docs/types/int.html), \]; + +*** +

[$importedContact](/API_docs/constructors/importedContact.html) = \['user_id' => [long](/API_docs/types/long.html), 'client_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inlineBotSwitchPM](/API_docs/constructors/inlineBotSwitchPM.html) = \['text' => [string](/API_docs/types/string.html), 'start_param' => [string](/API_docs/types/string.html), \]; + +*** +

[$inlineBotWebView](/API_docs/constructors/inlineBotWebView.html) = \['text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$inlineQueryPeerTypeBotPM](/API_docs/constructors/inlineQueryPeerTypeBotPM.html) = \[\]; + +*** +

[$inlineQueryPeerTypeBroadcast](/API_docs/constructors/inlineQueryPeerTypeBroadcast.html) = \[\]; + +*** +

[$inlineQueryPeerTypeChat](/API_docs/constructors/inlineQueryPeerTypeChat.html) = \[\]; + +*** +

[$inlineQueryPeerTypeMegagroup](/API_docs/constructors/inlineQueryPeerTypeMegagroup.html) = \[\]; + +*** +

[$inlineQueryPeerTypePM](/API_docs/constructors/inlineQueryPeerTypePM.html) = \[\]; + +*** +

[$inlineQueryPeerTypeSameBotPM](/API_docs/constructors/inlineQueryPeerTypeSameBotPM.html) = \[\]; + +*** +

[$inputAppEvent](/API_docs/constructors/inputAppEvent.html) = \['time' => [double](/API_docs/types/double.html), 'type' => [string](/API_docs/types/string.html), 'peer' => [long](/API_docs/types/long.html), 'data' => [JSONValue](/API_docs/types/JSONValue.html), \]; + +*** +

[$inputBotAppID](/API_docs/constructors/inputBotAppID.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputBotAppShortName](/API_docs/constructors/inputBotAppShortName.html) = \['bot_id' => [InputUser](/API_docs/types/InputUser.html), 'short_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputBotInlineMessageGame](/API_docs/constructors/inputBotInlineMessageGame.html) = \['reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageID](/API_docs/constructors/inputBotInlineMessageID.html) = \['dc_id' => [int](/API_docs/types/int.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputBotInlineMessageID64](/API_docs/constructors/inputBotInlineMessageID64.html) = \['dc_id' => [int](/API_docs/types/int.html), 'owner_id' => [long](/API_docs/types/long.html), 'id' => [int](/API_docs/types/int.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputBotInlineMessageMediaAuto](/API_docs/constructors/inputBotInlineMessageMediaAuto.html) = \['invert_media' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageMediaContact](/API_docs/constructors/inputBotInlineMessageMediaContact.html) = \['phone_number' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'vcard' => [string](/API_docs/types/string.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageMediaGeo](/API_docs/constructors/inputBotInlineMessageMediaGeo.html) = \['geo_point' => [InputGeoPoint](/API_docs/types/InputGeoPoint.html), 'heading' => [int](/API_docs/types/int.html), 'period' => [int](/API_docs/types/int.html), 'proximity_notification_radius' => [int](/API_docs/types/int.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageMediaInvoice](/API_docs/constructors/inputBotInlineMessageMediaInvoice.html) = \['title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [InputWebDocument](/API_docs/types/InputWebDocument.html), 'invoice' => [Invoice](/API_docs/types/Invoice.html), 'payload' => [bytes](/API_docs/types/bytes.html), 'provider' => [string](/API_docs/types/string.html), 'provider_data' => [DataJSON](/API_docs/types/DataJSON.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageMediaVenue](/API_docs/constructors/inputBotInlineMessageMediaVenue.html) = \['geo_point' => [InputGeoPoint](/API_docs/types/InputGeoPoint.html), 'title' => [string](/API_docs/types/string.html), 'address' => [string](/API_docs/types/string.html), 'provider' => [string](/API_docs/types/string.html), 'venue_id' => [string](/API_docs/types/string.html), 'venue_type' => [string](/API_docs/types/string.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageMediaWebPage](/API_docs/constructors/inputBotInlineMessageMediaWebPage.html) = \['invert_media' => [Bool](/API_docs/types/Bool.html), 'force_large_media' => [Bool](/API_docs/types/Bool.html), 'force_small_media' => [Bool](/API_docs/types/Bool.html), 'optional' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'url' => [string](/API_docs/types/string.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineMessageText](/API_docs/constructors/inputBotInlineMessageText.html) = \['no_webpage' => [Bool](/API_docs/types/Bool.html), 'invert_media' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), \]; + +*** +

[$inputBotInlineResult](/API_docs/constructors/inputBotInlineResult.html) = \['id' => [string](/API_docs/types/string.html), 'type' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), 'thumb' => [InputWebDocument](/API_docs/types/InputWebDocument.html), 'content' => [InputWebDocument](/API_docs/types/InputWebDocument.html), 'send_message' => [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html), \]; + +*** +

[$inputBotInlineResultDocument](/API_docs/constructors/inputBotInlineResultDocument.html) = \['id' => [string](/API_docs/types/string.html), 'type' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'document' => [InputDocument](/API_docs/types/InputDocument.html), 'send_message' => [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html), \]; + +*** +

[$inputBotInlineResultGame](/API_docs/constructors/inputBotInlineResultGame.html) = \['id' => [string](/API_docs/types/string.html), 'short_name' => [string](/API_docs/types/string.html), 'send_message' => [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html), \]; + +*** +

[$inputBotInlineResultPhoto](/API_docs/constructors/inputBotInlineResultPhoto.html) = \['id' => [string](/API_docs/types/string.html), 'type' => [string](/API_docs/types/string.html), 'photo' => [InputPhoto](/API_docs/types/InputPhoto.html), 'send_message' => [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html), \]; + +*** +

[$inputBusinessAwayMessage](/API_docs/constructors/inputBusinessAwayMessage.html) = \['offline_only' => [Bool](/API_docs/types/Bool.html), 'shortcut_id' => [int](/API_docs/types/int.html), 'schedule' => [BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html), 'recipients' => [InputBusinessRecipients](/API_docs/types/InputBusinessRecipients.html), \]; + +*** +

[$inputBusinessBotRecipients](/API_docs/constructors/inputBusinessBotRecipients.html) = \['existing_chats' => [Bool](/API_docs/types/Bool.html), 'new_chats' => [Bool](/API_docs/types/Bool.html), 'contacts' => [Bool](/API_docs/types/Bool.html), 'non_contacts' => [Bool](/API_docs/types/Bool.html), 'exclude_selected' => [Bool](/API_docs/types/Bool.html), 'users' => \[[InputUser](/API_docs/types/InputUser.html)\], 'exclude_users' => \[[InputUser](/API_docs/types/InputUser.html)\], \]; + +*** +

[$inputBusinessChatLink](/API_docs/constructors/inputBusinessChatLink.html) = \['message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'title' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputBusinessGreetingMessage](/API_docs/constructors/inputBusinessGreetingMessage.html) = \['shortcut_id' => [int](/API_docs/types/int.html), 'recipients' => [InputBusinessRecipients](/API_docs/types/InputBusinessRecipients.html), 'no_activity_days' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputBusinessIntro](/API_docs/constructors/inputBusinessIntro.html) = \['title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'sticker' => [InputDocument](/API_docs/types/InputDocument.html), \]; + +*** +

[$inputBusinessRecipients](/API_docs/constructors/inputBusinessRecipients.html) = \['existing_chats' => [Bool](/API_docs/types/Bool.html), 'new_chats' => [Bool](/API_docs/types/Bool.html), 'contacts' => [Bool](/API_docs/types/Bool.html), 'non_contacts' => [Bool](/API_docs/types/Bool.html), 'exclude_selected' => [Bool](/API_docs/types/Bool.html), 'users' => \[[InputUser](/API_docs/types/InputUser.html)\], \]; + +*** +

[$inputChannel](/API_docs/constructors/inputChannel.html) = \['channel_id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputChannelEmpty](/API_docs/constructors/inputChannelEmpty.html) = \[\]; + +*** +

[$inputChannelFromMessage](/API_docs/constructors/inputChannelFromMessage.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'msg_id' => [int](/API_docs/types/int.html), 'channel_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputChatPhoto](/API_docs/constructors/inputChatPhoto.html) = \['id' => [InputPhoto](/API_docs/types/InputPhoto.html), \]; + +*** +

[$inputChatPhotoEmpty](/API_docs/constructors/inputChatPhotoEmpty.html) = \[\]; + +*** +

[$inputChatUploadedPhoto](/API_docs/constructors/inputChatUploadedPhoto.html) = \['file' => [InputFile](/API_docs/types/InputFile.html), 'video' => [InputFile](/API_docs/types/InputFile.html), 'video_start_ts' => [double](/API_docs/types/double.html), 'video_emoji_markup' => [VideoSize](/API_docs/types/VideoSize.html), \]; + +*** +

[$inputChatlistDialogFilter](/API_docs/constructors/inputChatlistDialogFilter.html) = \['filter_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputCheckPasswordEmpty](/API_docs/constructors/inputCheckPasswordEmpty.html) = \[\]; + +*** +

[$inputCheckPasswordSRP](/API_docs/constructors/inputCheckPasswordSRP.html) = \['srp_id' => [long](/API_docs/types/long.html), 'A' => [bytes](/API_docs/types/bytes.html), 'M1' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$inputClientProxy](/API_docs/constructors/inputClientProxy.html) = \['address' => [string](/API_docs/types/string.html), 'port' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputCollectiblePhone](/API_docs/constructors/inputCollectiblePhone.html) = \['phone' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputCollectibleUsername](/API_docs/constructors/inputCollectibleUsername.html) = \['username' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputDialogPeer](/API_docs/constructors/inputDialogPeer.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), \]; + +*** +

[$inputDialogPeerFolder](/API_docs/constructors/inputDialogPeerFolder.html) = \['folder_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputDocument](/API_docs/constructors/inputDocument.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$inputDocumentEmpty](/API_docs/constructors/inputDocumentEmpty.html) = \[\]; + +*** +

[$inputDocumentFileLocation](/API_docs/constructors/inputDocumentFileLocation.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), 'thumb_size' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputEncryptedChat](/API_docs/constructors/inputEncryptedChat.html) = \['chat_id' => [int](/API_docs/types/int.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputEncryptedFile](/API_docs/constructors/inputEncryptedFile.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputEncryptedFileBigUploaded](/API_docs/constructors/inputEncryptedFileBigUploaded.html) = \['id' => [long](/API_docs/types/long.html), 'parts' => [int](/API_docs/types/int.html), 'key_fingerprint' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputEncryptedFileEmpty](/API_docs/constructors/inputEncryptedFileEmpty.html) = \[\]; + +*** +

[$inputEncryptedFileLocation](/API_docs/constructors/inputEncryptedFileLocation.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputEncryptedFileUploaded](/API_docs/constructors/inputEncryptedFileUploaded.html) = \['id' => [long](/API_docs/types/long.html), 'parts' => [int](/API_docs/types/int.html), 'md5_checksum' => [string](/API_docs/types/string.html), 'key_fingerprint' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputFile](/API_docs/constructors/inputFile.html) = \['id' => [long](/API_docs/types/long.html), 'parts' => [int](/API_docs/types/int.html), 'name' => [string](/API_docs/types/string.html), 'md5_checksum' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputFileBig](/API_docs/constructors/inputFileBig.html) = \['id' => [long](/API_docs/types/long.html), 'parts' => [int](/API_docs/types/int.html), 'name' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputFileLocation](/API_docs/constructors/inputFileLocation.html) = \['volume_id' => [long](/API_docs/types/long.html), 'local_id' => [int](/API_docs/types/int.html), 'secret' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$inputFolderPeer](/API_docs/constructors/inputFolderPeer.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'folder_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputGameID](/API_docs/constructors/inputGameID.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputGameShortName](/API_docs/constructors/inputGameShortName.html) = \['bot_id' => [InputUser](/API_docs/types/InputUser.html), 'short_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputGeoPoint](/API_docs/constructors/inputGeoPoint.html) = \['lat' => [double](/API_docs/types/double.html), 'long' => [double](/API_docs/types/double.html), 'accuracy_radius' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputGeoPointEmpty](/API_docs/constructors/inputGeoPointEmpty.html) = \[\]; + +*** +

[$inputGroupCall](/API_docs/constructors/inputGroupCall.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputGroupCallStream](/API_docs/constructors/inputGroupCallStream.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'time_ms' => [long](/API_docs/types/long.html), 'scale' => [int](/API_docs/types/int.html), 'video_channel' => [int](/API_docs/types/int.html), 'video_quality' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputInvoiceMessage](/API_docs/constructors/inputInvoiceMessage.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputInvoicePremiumGiftCode](/API_docs/constructors/inputInvoicePremiumGiftCode.html) = \['purpose' => [InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html), 'option' => [PremiumGiftCodeOption](/API_docs/types/PremiumGiftCodeOption.html), \]; + +*** +

[$inputInvoiceSlug](/API_docs/constructors/inputInvoiceSlug.html) = \['slug' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputKeyboardButtonRequestPeer](/API_docs/constructors/inputKeyboardButtonRequestPeer.html) = \['name_requested' => [Bool](/API_docs/types/Bool.html), 'username_requested' => [Bool](/API_docs/types/Bool.html), 'photo_requested' => [Bool](/API_docs/types/Bool.html), 'text' => [string](/API_docs/types/string.html), 'button_id' => [int](/API_docs/types/int.html), 'peer_type' => [RequestPeerType](/API_docs/types/RequestPeerType.html), 'max_quantity' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputKeyboardButtonUrlAuth](/API_docs/constructors/inputKeyboardButtonUrlAuth.html) = \['request_write_access' => [Bool](/API_docs/types/Bool.html), 'text' => [string](/API_docs/types/string.html), 'fwd_text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), 'bot' => [InputUser](/API_docs/types/InputUser.html), \]; + +*** +

[$inputKeyboardButtonUserProfile](/API_docs/constructors/inputKeyboardButtonUserProfile.html) = \['text' => [string](/API_docs/types/string.html), 'user_id' => [InputUser](/API_docs/types/InputUser.html), \]; + +*** +

[$inputMediaAreaChannelPost](/API_docs/constructors/inputMediaAreaChannelPost.html) = \['coordinates' => [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html), 'channel' => [InputChannel](/API_docs/types/InputChannel.html), 'msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaAreaVenue](/API_docs/constructors/inputMediaAreaVenue.html) = \['coordinates' => [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html), 'query_id' => [long](/API_docs/types/long.html), 'result_id' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputMediaContact](/API_docs/constructors/inputMediaContact.html) = \['phone_number' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'vcard' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputMediaDice](/API_docs/constructors/inputMediaDice.html) = \['emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputMediaDocument](/API_docs/constructors/inputMediaDocument.html) = \['spoiler' => [Bool](/API_docs/types/Bool.html), 'id' => [InputDocument](/API_docs/types/InputDocument.html), 'ttl_seconds' => [int](/API_docs/types/int.html), 'query' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputMediaDocumentExternal](/API_docs/constructors/inputMediaDocumentExternal.html) = \['spoiler' => [Bool](/API_docs/types/Bool.html), 'url' => [string](/API_docs/types/string.html), 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaEmpty](/API_docs/constructors/inputMediaEmpty.html) = \[\]; + +*** +

[$inputMediaGame](/API_docs/constructors/inputMediaGame.html) = \['id' => [InputGame](/API_docs/types/InputGame.html), \]; + +*** +

[$inputMediaGeoLive](/API_docs/constructors/inputMediaGeoLive.html) = \['stopped' => [Bool](/API_docs/types/Bool.html), 'geo_point' => [InputGeoPoint](/API_docs/types/InputGeoPoint.html), 'heading' => [int](/API_docs/types/int.html), 'period' => [int](/API_docs/types/int.html), 'proximity_notification_radius' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaGeoPoint](/API_docs/constructors/inputMediaGeoPoint.html) = \['geo_point' => [InputGeoPoint](/API_docs/types/InputGeoPoint.html), \]; + +*** +

[$inputMediaInvoice](/API_docs/constructors/inputMediaInvoice.html) = \['title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [InputWebDocument](/API_docs/types/InputWebDocument.html), 'invoice' => [Invoice](/API_docs/types/Invoice.html), 'payload' => [bytes](/API_docs/types/bytes.html), 'provider' => [string](/API_docs/types/string.html), 'provider_data' => [DataJSON](/API_docs/types/DataJSON.html), 'start_param' => [string](/API_docs/types/string.html), 'extended_media' => [InputMedia](/API_docs/types/InputMedia.html), \]; + +*** +

[$inputMediaPhoto](/API_docs/constructors/inputMediaPhoto.html) = \['spoiler' => [Bool](/API_docs/types/Bool.html), 'id' => [InputPhoto](/API_docs/types/InputPhoto.html), 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaPhotoExternal](/API_docs/constructors/inputMediaPhotoExternal.html) = \['spoiler' => [Bool](/API_docs/types/Bool.html), 'url' => [string](/API_docs/types/string.html), 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaPoll](/API_docs/constructors/inputMediaPoll.html) = \['poll' => [Poll](/API_docs/types/Poll.html), 'correct_answers' => \[[bytes](/API_docs/types/bytes.html)\], 'solution' => [string](/API_docs/types/string.html), 'solution_entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], \]; + +*** +

[$inputMediaStory](/API_docs/constructors/inputMediaStory.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaUploadedDocument](/API_docs/constructors/inputMediaUploadedDocument.html) = \['nosound_video' => [Bool](/API_docs/types/Bool.html), 'force_file' => [Bool](/API_docs/types/Bool.html), 'spoiler' => [Bool](/API_docs/types/Bool.html), 'file' => [InputFile](/API_docs/types/InputFile.html), 'thumb' => [InputFile](/API_docs/types/InputFile.html), 'mime_type' => [string](/API_docs/types/string.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], 'stickers' => \[[InputDocument](/API_docs/types/InputDocument.html)\], 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaUploadedPhoto](/API_docs/constructors/inputMediaUploadedPhoto.html) = \['spoiler' => [Bool](/API_docs/types/Bool.html), 'file' => [InputFile](/API_docs/types/InputFile.html), 'stickers' => \[[InputDocument](/API_docs/types/InputDocument.html)\], 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMediaVenue](/API_docs/constructors/inputMediaVenue.html) = \['geo_point' => [InputGeoPoint](/API_docs/types/InputGeoPoint.html), 'title' => [string](/API_docs/types/string.html), 'address' => [string](/API_docs/types/string.html), 'provider' => [string](/API_docs/types/string.html), 'venue_id' => [string](/API_docs/types/string.html), 'venue_type' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputMediaWebPage](/API_docs/constructors/inputMediaWebPage.html) = \['force_large_media' => [Bool](/API_docs/types/Bool.html), 'force_small_media' => [Bool](/API_docs/types/Bool.html), 'optional' => [Bool](/API_docs/types/Bool.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputMessageCallbackQuery](/API_docs/constructors/inputMessageCallbackQuery.html) = \['id' => [int](/API_docs/types/int.html), 'query_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputMessageEntityMentionName](/API_docs/constructors/inputMessageEntityMentionName.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), 'user_id' => [InputUser](/API_docs/types/InputUser.html), \]; + +*** +

[$inputMessageID](/API_docs/constructors/inputMessageID.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMessagePinned](/API_docs/constructors/inputMessagePinned.html) = \[\]; + +*** +

[$inputMessageReplyTo](/API_docs/constructors/inputMessageReplyTo.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputMessagesFilterChatPhotos](/API_docs/constructors/inputMessagesFilterChatPhotos.html) = \[\]; + +*** +

[$inputMessagesFilterContacts](/API_docs/constructors/inputMessagesFilterContacts.html) = \[\]; + +*** +

[$inputMessagesFilterDocument](/API_docs/constructors/inputMessagesFilterDocument.html) = \[\]; + +*** +

[$inputMessagesFilterEmpty](/API_docs/constructors/inputMessagesFilterEmpty.html) = \[\]; + +*** +

[$inputMessagesFilterGeo](/API_docs/constructors/inputMessagesFilterGeo.html) = \[\]; + +*** +

[$inputMessagesFilterGif](/API_docs/constructors/inputMessagesFilterGif.html) = \[\]; + +*** +

[$inputMessagesFilterMusic](/API_docs/constructors/inputMessagesFilterMusic.html) = \[\]; + +*** +

[$inputMessagesFilterMyMentions](/API_docs/constructors/inputMessagesFilterMyMentions.html) = \[\]; + +*** +

[$inputMessagesFilterPhoneCalls](/API_docs/constructors/inputMessagesFilterPhoneCalls.html) = \['missed' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$inputMessagesFilterPhotoVideo](/API_docs/constructors/inputMessagesFilterPhotoVideo.html) = \[\]; + +*** +

[$inputMessagesFilterPhotos](/API_docs/constructors/inputMessagesFilterPhotos.html) = \[\]; + +*** +

[$inputMessagesFilterPinned](/API_docs/constructors/inputMessagesFilterPinned.html) = \[\]; + +*** +

[$inputMessagesFilterRoundVideo](/API_docs/constructors/inputMessagesFilterRoundVideo.html) = \[\]; + +*** +

[$inputMessagesFilterRoundVoice](/API_docs/constructors/inputMessagesFilterRoundVoice.html) = \[\]; + +*** +

[$inputMessagesFilterUrl](/API_docs/constructors/inputMessagesFilterUrl.html) = \[\]; + +*** +

[$inputMessagesFilterVideo](/API_docs/constructors/inputMessagesFilterVideo.html) = \[\]; + +*** +

[$inputMessagesFilterVoice](/API_docs/constructors/inputMessagesFilterVoice.html) = \[\]; + +*** +

[$inputNotifyBroadcasts](/API_docs/constructors/inputNotifyBroadcasts.html) = \[\]; + +*** +

[$inputNotifyChats](/API_docs/constructors/inputNotifyChats.html) = \[\]; + +*** +

[$inputNotifyForumTopic](/API_docs/constructors/inputNotifyForumTopic.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'top_msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputNotifyPeer](/API_docs/constructors/inputNotifyPeer.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), \]; + +*** +

[$inputNotifyUsers](/API_docs/constructors/inputNotifyUsers.html) = \[\]; + +*** +

[$inputPaymentCredentials](/API_docs/constructors/inputPaymentCredentials.html) = \['save' => [Bool](/API_docs/types/Bool.html), 'data' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$inputPaymentCredentialsApplePay](/API_docs/constructors/inputPaymentCredentialsApplePay.html) = \['payment_data' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$inputPaymentCredentialsGooglePay](/API_docs/constructors/inputPaymentCredentialsGooglePay.html) = \['payment_token' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$inputPaymentCredentialsSaved](/API_docs/constructors/inputPaymentCredentialsSaved.html) = \['id' => [string](/API_docs/types/string.html), 'tmp_password' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$inputPeerChannel](/API_docs/constructors/inputPeerChannel.html) = \['channel_id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPeerChannelFromMessage](/API_docs/constructors/inputPeerChannelFromMessage.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'msg_id' => [int](/API_docs/types/int.html), 'channel_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPeerChat](/API_docs/constructors/inputPeerChat.html) = \['chat_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPeerEmpty](/API_docs/constructors/inputPeerEmpty.html) = \[\]; + +*** +

[$inputPeerNotifySettings](/API_docs/constructors/inputPeerNotifySettings.html) = \['show_previews' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'mute_until' => [int](/API_docs/types/int.html), 'sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'stories_muted' => [Bool](/API_docs/types/Bool.html), 'stories_hide_sender' => [Bool](/API_docs/types/Bool.html), 'stories_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), \]; + +*** +

[$inputPeerPhotoFileLocation](/API_docs/constructors/inputPeerPhotoFileLocation.html) = \['big' => [Bool](/API_docs/types/Bool.html), 'peer' => [InputPeer](/API_docs/types/InputPeer.html), 'photo_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPeerSelf](/API_docs/constructors/inputPeerSelf.html) = \[\]; + +*** +

[$inputPeerUser](/API_docs/constructors/inputPeerUser.html) = \['user_id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPeerUserFromMessage](/API_docs/constructors/inputPeerUserFromMessage.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'msg_id' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPhoneCall](/API_docs/constructors/inputPhoneCall.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPhoneContact](/API_docs/constructors/inputPhoneContact.html) = \['client_id' => [long](/API_docs/types/long.html), 'phone' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputPhoto](/API_docs/constructors/inputPhoto.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$inputPhotoEmpty](/API_docs/constructors/inputPhotoEmpty.html) = \[\]; + +*** +

[$inputPhotoFileLocation](/API_docs/constructors/inputPhotoFileLocation.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), 'thumb_size' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputPhotoLegacyFileLocation](/API_docs/constructors/inputPhotoLegacyFileLocation.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), 'volume_id' => [long](/API_docs/types/long.html), 'local_id' => [int](/API_docs/types/int.html), 'secret' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputPrivacyKeyAbout](/API_docs/constructors/inputPrivacyKeyAbout.html) = \[\]; + +*** +

[$inputPrivacyKeyAddedByPhone](/API_docs/constructors/inputPrivacyKeyAddedByPhone.html) = \[\]; + +*** +

[$inputPrivacyKeyBirthday](/API_docs/constructors/inputPrivacyKeyBirthday.html) = \[\]; + +*** +

[$inputPrivacyKeyChatInvite](/API_docs/constructors/inputPrivacyKeyChatInvite.html) = \[\]; + +*** +

[$inputPrivacyKeyForwards](/API_docs/constructors/inputPrivacyKeyForwards.html) = \[\]; + +*** +

[$inputPrivacyKeyPhoneCall](/API_docs/constructors/inputPrivacyKeyPhoneCall.html) = \[\]; + +*** +

[$inputPrivacyKeyPhoneNumber](/API_docs/constructors/inputPrivacyKeyPhoneNumber.html) = \[\]; + +*** +

[$inputPrivacyKeyPhoneP2P](/API_docs/constructors/inputPrivacyKeyPhoneP2P.html) = \[\]; + +*** +

[$inputPrivacyKeyProfilePhoto](/API_docs/constructors/inputPrivacyKeyProfilePhoto.html) = \[\]; + +*** +

[$inputPrivacyKeyStatusTimestamp](/API_docs/constructors/inputPrivacyKeyStatusTimestamp.html) = \[\]; + +*** +

[$inputPrivacyKeyVoiceMessages](/API_docs/constructors/inputPrivacyKeyVoiceMessages.html) = \[\]; + +*** +

[$inputPrivacyValueAllowAll](/API_docs/constructors/inputPrivacyValueAllowAll.html) = \[\]; + +*** +

[$inputPrivacyValueAllowChatParticipants](/API_docs/constructors/inputPrivacyValueAllowChatParticipants.html) = \['chats' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$inputPrivacyValueAllowCloseFriends](/API_docs/constructors/inputPrivacyValueAllowCloseFriends.html) = \[\]; + +*** +

[$inputPrivacyValueAllowContacts](/API_docs/constructors/inputPrivacyValueAllowContacts.html) = \[\]; + +*** +

[$inputPrivacyValueAllowPremium](/API_docs/constructors/inputPrivacyValueAllowPremium.html) = \[\]; + +*** +

[$inputPrivacyValueAllowUsers](/API_docs/constructors/inputPrivacyValueAllowUsers.html) = \['users' => \[[InputUser](/API_docs/types/InputUser.html)\], \]; + +*** +

[$inputPrivacyValueDisallowAll](/API_docs/constructors/inputPrivacyValueDisallowAll.html) = \[\]; + +*** +

[$inputPrivacyValueDisallowChatParticipants](/API_docs/constructors/inputPrivacyValueDisallowChatParticipants.html) = \['chats' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$inputPrivacyValueDisallowContacts](/API_docs/constructors/inputPrivacyValueDisallowContacts.html) = \[\]; + +*** +

[$inputPrivacyValueDisallowUsers](/API_docs/constructors/inputPrivacyValueDisallowUsers.html) = \['users' => \[[InputUser](/API_docs/types/InputUser.html)\], \]; + +*** +

[$inputQuickReplyShortcut](/API_docs/constructors/inputQuickReplyShortcut.html) = \['shortcut' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputQuickReplyShortcutId](/API_docs/constructors/inputQuickReplyShortcutId.html) = \['shortcut_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputReplyToMessage](/API_docs/constructors/inputReplyToMessage.html) = \['reply_to_msg_id' => [int](/API_docs/types/int.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'reply_to_peer_id' => [InputPeer](/API_docs/types/InputPeer.html), 'quote_text' => [string](/API_docs/types/string.html), 'quote_entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'quote_offset' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputReplyToStory](/API_docs/constructors/inputReplyToStory.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'story_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputReportReasonChildAbuse](/API_docs/constructors/inputReportReasonChildAbuse.html) = \[\]; + +*** +

[$inputReportReasonCopyright](/API_docs/constructors/inputReportReasonCopyright.html) = \[\]; + +*** +

[$inputReportReasonFake](/API_docs/constructors/inputReportReasonFake.html) = \[\]; + +*** +

[$inputReportReasonGeoIrrelevant](/API_docs/constructors/inputReportReasonGeoIrrelevant.html) = \[\]; + +*** +

[$inputReportReasonIllegalDrugs](/API_docs/constructors/inputReportReasonIllegalDrugs.html) = \[\]; + +*** +

[$inputReportReasonOther](/API_docs/constructors/inputReportReasonOther.html) = \[\]; + +*** +

[$inputReportReasonPersonalDetails](/API_docs/constructors/inputReportReasonPersonalDetails.html) = \[\]; + +*** +

[$inputReportReasonPornography](/API_docs/constructors/inputReportReasonPornography.html) = \[\]; + +*** +

[$inputReportReasonSpam](/API_docs/constructors/inputReportReasonSpam.html) = \[\]; + +*** +

[$inputReportReasonViolence](/API_docs/constructors/inputReportReasonViolence.html) = \[\]; + +*** +

[$inputSecureFile](/API_docs/constructors/inputSecureFile.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputSecureFileLocation](/API_docs/constructors/inputSecureFileLocation.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputSecureFileUploaded](/API_docs/constructors/inputSecureFileUploaded.html) = \['id' => [long](/API_docs/types/long.html), 'parts' => [int](/API_docs/types/int.html), 'md5_checksum' => [string](/API_docs/types/string.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'secret' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$inputSecureValue](/API_docs/constructors/inputSecureValue.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'data' => [SecureData](/API_docs/types/SecureData.html), 'front_side' => [InputSecureFile](/API_docs/types/InputSecureFile.html), 'reverse_side' => [InputSecureFile](/API_docs/types/InputSecureFile.html), 'selfie' => [InputSecureFile](/API_docs/types/InputSecureFile.html), 'translation' => \[[InputSecureFile](/API_docs/types/InputSecureFile.html)\], 'files' => \[[InputSecureFile](/API_docs/types/InputSecureFile.html)\], 'plain_data' => [SecurePlainData](/API_docs/types/SecurePlainData.html), \]; + +*** +

[$inputSingleMedia](/API_docs/constructors/inputSingleMedia.html) = \['media' => [InputMedia](/API_docs/types/InputMedia.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], \]; + +*** +

[$inputStickerSetAnimatedEmoji](/API_docs/constructors/inputStickerSetAnimatedEmoji.html) = \[\]; + +*** +

[$inputStickerSetAnimatedEmojiAnimations](/API_docs/constructors/inputStickerSetAnimatedEmojiAnimations.html) = \[\]; + +*** +

[$inputStickerSetDice](/API_docs/constructors/inputStickerSetDice.html) = \['emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputStickerSetEmojiChannelDefaultStatuses](/API_docs/constructors/inputStickerSetEmojiChannelDefaultStatuses.html) = \[\]; + +*** +

[$inputStickerSetEmojiDefaultStatuses](/API_docs/constructors/inputStickerSetEmojiDefaultStatuses.html) = \[\]; + +*** +

[$inputStickerSetEmojiDefaultTopicIcons](/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.html) = \[\]; + +*** +

[$inputStickerSetEmojiGenericAnimations](/API_docs/constructors/inputStickerSetEmojiGenericAnimations.html) = \[\]; + +*** +

[$inputStickerSetEmpty](/API_docs/constructors/inputStickerSetEmpty.html) = \[\]; + +*** +

[$inputStickerSetID](/API_docs/constructors/inputStickerSetID.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputStickerSetItem](/API_docs/constructors/inputStickerSetItem.html) = \['document' => [InputDocument](/API_docs/types/InputDocument.html), 'emoji' => [string](/API_docs/types/string.html), 'mask_coords' => [MaskCoords](/API_docs/types/MaskCoords.html), 'keywords' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputStickerSetPremiumGifts](/API_docs/constructors/inputStickerSetPremiumGifts.html) = \[\]; + +*** +

[$inputStickerSetShortName](/API_docs/constructors/inputStickerSetShortName.html) = \['short_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputStickerSetThumb](/API_docs/constructors/inputStickerSetThumb.html) = \['stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), 'thumb_version' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputStickeredMediaDocument](/API_docs/constructors/inputStickeredMediaDocument.html) = \['id' => [InputDocument](/API_docs/types/InputDocument.html), \]; + +*** +

[$inputStickeredMediaPhoto](/API_docs/constructors/inputStickeredMediaPhoto.html) = \['id' => [InputPhoto](/API_docs/types/InputPhoto.html), \]; + +*** +

[$inputStorePaymentGiftPremium](/API_docs/constructors/inputStorePaymentGiftPremium.html) = \['user_id' => [InputUser](/API_docs/types/InputUser.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputStorePaymentPremiumGiftCode](/API_docs/constructors/inputStorePaymentPremiumGiftCode.html) = \['users' => \[[InputUser](/API_docs/types/InputUser.html)\], 'boost_peer' => [InputPeer](/API_docs/types/InputPeer.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputStorePaymentPremiumGiveaway](/API_docs/constructors/inputStorePaymentPremiumGiveaway.html) = \['only_new_subscribers' => [Bool](/API_docs/types/Bool.html), 'winners_are_visible' => [Bool](/API_docs/types/Bool.html), 'boost_peer' => [InputPeer](/API_docs/types/InputPeer.html), 'additional_peers' => \[[InputPeer](/API_docs/types/InputPeer.html)\], 'countries_iso2' => \[[string](/API_docs/types/string.html)\], 'prize_description' => [string](/API_docs/types/string.html), 'until_date' => [int](/API_docs/types/int.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputStorePaymentPremiumSubscription](/API_docs/constructors/inputStorePaymentPremiumSubscription.html) = \['restore' => [Bool](/API_docs/types/Bool.html), 'upgrade' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$inputTakeoutFileLocation](/API_docs/constructors/inputTakeoutFileLocation.html) = \[\]; + +*** +

[$inputTheme](/API_docs/constructors/inputTheme.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputThemeSettings](/API_docs/constructors/inputThemeSettings.html) = \['message_colors_animated' => [Bool](/API_docs/types/Bool.html), 'base_theme' => [BaseTheme](/API_docs/types/BaseTheme.html), 'accent_color' => [int](/API_docs/types/int.html), 'outbox_accent_color' => [int](/API_docs/types/int.html), 'message_colors' => \[[int](/API_docs/types/int.html)\], 'wallpaper' => [InputWallPaper](/API_docs/types/InputWallPaper.html), 'wallpaper_settings' => [WallPaperSettings](/API_docs/types/WallPaperSettings.html), \]; + +*** +

[$inputThemeSlug](/API_docs/constructors/inputThemeSlug.html) = \['slug' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputUser](/API_docs/constructors/inputUser.html) = \['user_id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputUserEmpty](/API_docs/constructors/inputUserEmpty.html) = \[\]; + +*** +

[$inputUserFromMessage](/API_docs/constructors/inputUserFromMessage.html) = \['peer' => [InputPeer](/API_docs/types/InputPeer.html), 'msg_id' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputUserSelf](/API_docs/constructors/inputUserSelf.html) = \[\]; + +*** +

[$inputWallPaper](/API_docs/constructors/inputWallPaper.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputWallPaperNoFile](/API_docs/constructors/inputWallPaperNoFile.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$inputWallPaperSlug](/API_docs/constructors/inputWallPaperSlug.html) = \['slug' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputWebDocument](/API_docs/constructors/inputWebDocument.html) = \['url' => [string](/API_docs/types/string.html), 'size' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], \]; + +*** +

[$inputWebFileAudioAlbumThumbLocation](/API_docs/constructors/inputWebFileAudioAlbumThumbLocation.html) = \['small' => [Bool](/API_docs/types/Bool.html), 'document' => [InputDocument](/API_docs/types/InputDocument.html), 'title' => [string](/API_docs/types/string.html), 'performer' => [string](/API_docs/types/string.html), \]; + +*** +

[$inputWebFileGeoPointLocation](/API_docs/constructors/inputWebFileGeoPointLocation.html) = \['geo_point' => [InputGeoPoint](/API_docs/types/InputGeoPoint.html), 'access_hash' => [long](/API_docs/types/long.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'zoom' => [int](/API_docs/types/int.html), 'scale' => [int](/API_docs/types/int.html), \]; + +*** +

[$inputWebFileLocation](/API_docs/constructors/inputWebFileLocation.html) = \['url' => [string](/API_docs/types/string.html), 'access_hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$invoice](/API_docs/constructors/invoice.html) = \['test' => [Bool](/API_docs/types/Bool.html), 'name_requested' => [Bool](/API_docs/types/Bool.html), 'phone_requested' => [Bool](/API_docs/types/Bool.html), 'email_requested' => [Bool](/API_docs/types/Bool.html), 'shipping_address_requested' => [Bool](/API_docs/types/Bool.html), 'flexible' => [Bool](/API_docs/types/Bool.html), 'phone_to_provider' => [Bool](/API_docs/types/Bool.html), 'email_to_provider' => [Bool](/API_docs/types/Bool.html), 'recurring' => [Bool](/API_docs/types/Bool.html), 'currency' => [string](/API_docs/types/string.html), 'prices' => \[[LabeledPrice](/API_docs/types/LabeledPrice.html)\], 'max_tip_amount' => [long](/API_docs/types/long.html), 'suggested_tip_amounts' => \[[long](/API_docs/types/long.html)\], 'terms_url' => [string](/API_docs/types/string.html), \]; + +*** +

[$jsonArray](/API_docs/constructors/jsonArray.html) = \['value' => \[[JSONValue](/API_docs/types/JSONValue.html)\], \]; + +*** +

[$jsonBool](/API_docs/constructors/jsonBool.html) = \['value' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$jsonNull](/API_docs/constructors/jsonNull.html) = \[\]; + +*** +

[$jsonNumber](/API_docs/constructors/jsonNumber.html) = \['value' => [double](/API_docs/types/double.html), \]; + +*** +

[$jsonObject](/API_docs/constructors/jsonObject.html) = \['value' => \[[JSONObjectValue](/API_docs/types/JSONObjectValue.html)\], \]; + +*** +

[$jsonObjectValue](/API_docs/constructors/jsonObjectValue.html) = \['key' => [string](/API_docs/types/string.html), 'value' => [JSONValue](/API_docs/types/JSONValue.html), \]; + +*** +

[$jsonString](/API_docs/constructors/jsonString.html) = \['value' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButton](/API_docs/constructors/keyboardButton.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonBuy](/API_docs/constructors/keyboardButtonBuy.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonCallback](/API_docs/constructors/keyboardButtonCallback.html) = \['requires_password' => [Bool](/API_docs/types/Bool.html), 'text' => [string](/API_docs/types/string.html), 'data' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$keyboardButtonGame](/API_docs/constructors/keyboardButtonGame.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonRequestGeoLocation](/API_docs/constructors/keyboardButtonRequestGeoLocation.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonRequestPeer](/API_docs/constructors/keyboardButtonRequestPeer.html) = \['text' => [string](/API_docs/types/string.html), 'button_id' => [int](/API_docs/types/int.html), 'peer_type' => [RequestPeerType](/API_docs/types/RequestPeerType.html), 'max_quantity' => [int](/API_docs/types/int.html), \]; + +*** +

[$keyboardButtonRequestPhone](/API_docs/constructors/keyboardButtonRequestPhone.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonRequestPoll](/API_docs/constructors/keyboardButtonRequestPoll.html) = \['quiz' => [Bool](/API_docs/types/Bool.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonRow](/API_docs/constructors/keyboardButtonRow.html) = \['buttons' => \[[KeyboardButton](/API_docs/types/KeyboardButton.html)\], \]; + +*** +

[$keyboardButtonSimpleWebView](/API_docs/constructors/keyboardButtonSimpleWebView.html) = \['text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonSwitchInline](/API_docs/constructors/keyboardButtonSwitchInline.html) = \['same_peer' => [Bool](/API_docs/types/Bool.html), 'text' => [string](/API_docs/types/string.html), 'query' => [string](/API_docs/types/string.html), 'peer_types' => \[[InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html)\], \]; + +*** +

[$keyboardButtonUrl](/API_docs/constructors/keyboardButtonUrl.html) = \['text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$keyboardButtonUrlAuth](/API_docs/constructors/keyboardButtonUrlAuth.html) = \['text' => [string](/API_docs/types/string.html), 'fwd_text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), 'button_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$keyboardButtonUserProfile](/API_docs/constructors/keyboardButtonUserProfile.html) = \['text' => [string](/API_docs/types/string.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$keyboardButtonWebView](/API_docs/constructors/keyboardButtonWebView.html) = \['text' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$labeledPrice](/API_docs/constructors/labeledPrice.html) = \['label' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$langPackDifference](/API_docs/constructors/langPackDifference.html) = \['lang_code' => [string](/API_docs/types/string.html), 'from_version' => [int](/API_docs/types/int.html), 'version' => [int](/API_docs/types/int.html), 'strings' => \[[LangPackString](/API_docs/types/LangPackString.html)\], \]; + +*** +

[$langPackLanguage](/API_docs/constructors/langPackLanguage.html) = \['official' => [Bool](/API_docs/types/Bool.html), 'rtl' => [Bool](/API_docs/types/Bool.html), 'beta' => [Bool](/API_docs/types/Bool.html), 'name' => [string](/API_docs/types/string.html), 'native_name' => [string](/API_docs/types/string.html), 'lang_code' => [string](/API_docs/types/string.html), 'base_lang_code' => [string](/API_docs/types/string.html), 'plural_code' => [string](/API_docs/types/string.html), 'strings_count' => [int](/API_docs/types/int.html), 'translated_count' => [int](/API_docs/types/int.html), 'translations_url' => [string](/API_docs/types/string.html), \]; + +*** +

[$langPackString](/API_docs/constructors/langPackString.html) = \['key' => [string](/API_docs/types/string.html), 'value' => [string](/API_docs/types/string.html), \]; + +*** +

[$langPackStringDeleted](/API_docs/constructors/langPackStringDeleted.html) = \['key' => [string](/API_docs/types/string.html), \]; + +*** +

[$langPackStringPluralized](/API_docs/constructors/langPackStringPluralized.html) = \['key' => [string](/API_docs/types/string.html), 'zero_value' => [string](/API_docs/types/string.html), 'one_value' => [string](/API_docs/types/string.html), 'two_value' => [string](/API_docs/types/string.html), 'few_value' => [string](/API_docs/types/string.html), 'many_value' => [string](/API_docs/types/string.html), 'other_value' => [string](/API_docs/types/string.html), \]; + +*** +

[$maskCoords](/API_docs/constructors/maskCoords.html) = \['n' => [int](/API_docs/types/int.html), 'x' => [double](/API_docs/types/double.html), 'y' => [double](/API_docs/types/double.html), 'zoom' => [double](/API_docs/types/double.html), \]; + +*** +

[$mediaAreaChannelPost](/API_docs/constructors/mediaAreaChannelPost.html) = \['coordinates' => [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html), 'channel_id' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$mediaAreaCoordinates](/API_docs/constructors/mediaAreaCoordinates.html) = \['x' => [double](/API_docs/types/double.html), 'y' => [double](/API_docs/types/double.html), 'w' => [double](/API_docs/types/double.html), 'h' => [double](/API_docs/types/double.html), 'rotation' => [double](/API_docs/types/double.html), \]; + +*** +

[$mediaAreaGeoPoint](/API_docs/constructors/mediaAreaGeoPoint.html) = \['coordinates' => [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html), 'geo' => [GeoPoint](/API_docs/types/GeoPoint.html), \]; + +*** +

[$mediaAreaSuggestedReaction](/API_docs/constructors/mediaAreaSuggestedReaction.html) = \['dark' => [Bool](/API_docs/types/Bool.html), 'flipped' => [Bool](/API_docs/types/Bool.html), 'coordinates' => [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$mediaAreaVenue](/API_docs/constructors/mediaAreaVenue.html) = \['coordinates' => [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html), 'geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'title' => [string](/API_docs/types/string.html), 'address' => [string](/API_docs/types/string.html), 'provider' => [string](/API_docs/types/string.html), 'venue_id' => [string](/API_docs/types/string.html), 'venue_type' => [string](/API_docs/types/string.html), \]; + +*** +

[$message](/API_docs/constructors/message.html) = \['out' => [Bool](/API_docs/types/Bool.html), 'mentioned' => [Bool](/API_docs/types/Bool.html), 'media_unread' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'post' => [Bool](/API_docs/types/Bool.html), 'from_scheduled' => [Bool](/API_docs/types/Bool.html), 'legacy' => [Bool](/API_docs/types/Bool.html), 'edit_hide' => [Bool](/API_docs/types/Bool.html), 'pinned' => [Bool](/API_docs/types/Bool.html), 'noforwards' => [Bool](/API_docs/types/Bool.html), 'invert_media' => [Bool](/API_docs/types/Bool.html), 'offline' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'from_boosts_applied' => [int](/API_docs/types/int.html), 'peer_id' => [Peer](/API_docs/types/Peer.html), 'saved_peer_id' => [Peer](/API_docs/types/Peer.html), 'fwd_from' => [MessageFwdHeader](/API_docs/types/MessageFwdHeader.html), 'via_bot_id' => [long](/API_docs/types/long.html), 'via_business_bot_id' => [long](/API_docs/types/long.html), 'reply_to' => [MessageReplyHeader](/API_docs/types/MessageReplyHeader.html), 'date' => [int](/API_docs/types/int.html), 'message' => [string](/API_docs/types/string.html), 'media' => [MessageMedia](/API_docs/types/MessageMedia.html), 'reply_markup' => [ReplyMarkup](/API_docs/types/ReplyMarkup.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'views' => [int](/API_docs/types/int.html), 'forwards' => [int](/API_docs/types/int.html), 'replies' => [MessageReplies](/API_docs/types/MessageReplies.html), 'edit_date' => [int](/API_docs/types/int.html), 'post_author' => [string](/API_docs/types/string.html), 'grouped_id' => [long](/API_docs/types/long.html), 'reactions' => [MessageReactions](/API_docs/types/MessageReactions.html), 'restriction_reason' => \[[RestrictionReason](/API_docs/types/RestrictionReason.html)\], 'ttl_period' => [int](/API_docs/types/int.html), 'quick_reply_shortcut_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionBoostApply](/API_docs/constructors/messageActionBoostApply.html) = \['boosts' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionBotAllowed](/API_docs/constructors/messageActionBotAllowed.html) = \['attach_menu' => [Bool](/API_docs/types/Bool.html), 'from_request' => [Bool](/API_docs/types/Bool.html), 'domain' => [string](/API_docs/types/string.html), 'app' => [BotApp](/API_docs/types/BotApp.html), \]; + +*** +

[$messageActionChannelCreate](/API_docs/constructors/messageActionChannelCreate.html) = \['title' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageActionChannelMigrateFrom](/API_docs/constructors/messageActionChannelMigrateFrom.html) = \['title' => [string](/API_docs/types/string.html), 'chat_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionChatAddUser](/API_docs/constructors/messageActionChatAddUser.html) = \['users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$messageActionChatCreate](/API_docs/constructors/messageActionChatCreate.html) = \['title' => [string](/API_docs/types/string.html), 'users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$messageActionChatDeletePhoto](/API_docs/constructors/messageActionChatDeletePhoto.html) = \[\]; + +*** +

[$messageActionChatDeleteUser](/API_docs/constructors/messageActionChatDeleteUser.html) = \['user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionChatEditPhoto](/API_docs/constructors/messageActionChatEditPhoto.html) = \['photo' => [Photo](/API_docs/types/Photo.html), \]; + +*** +

[$messageActionChatEditTitle](/API_docs/constructors/messageActionChatEditTitle.html) = \['title' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageActionChatJoinedByLink](/API_docs/constructors/messageActionChatJoinedByLink.html) = \['inviter_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionChatJoinedByRequest](/API_docs/constructors/messageActionChatJoinedByRequest.html) = \[\]; + +*** +

[$messageActionChatMigrateTo](/API_docs/constructors/messageActionChatMigrateTo.html) = \['channel_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionContactSignUp](/API_docs/constructors/messageActionContactSignUp.html) = \[\]; + +*** +

[$messageActionCustomAction](/API_docs/constructors/messageActionCustomAction.html) = \['message' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageActionEmpty](/API_docs/constructors/messageActionEmpty.html) = \[\]; + +*** +

[$messageActionGameScore](/API_docs/constructors/messageActionGameScore.html) = \['game_id' => [long](/API_docs/types/long.html), 'score' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionGeoProximityReached](/API_docs/constructors/messageActionGeoProximityReached.html) = \['from_id' => [Peer](/API_docs/types/Peer.html), 'to_id' => [Peer](/API_docs/types/Peer.html), 'distance' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionGiftCode](/API_docs/constructors/messageActionGiftCode.html) = \['via_giveaway' => [Bool](/API_docs/types/Bool.html), 'unclaimed' => [Bool](/API_docs/types/Bool.html), 'boost_peer' => [Peer](/API_docs/types/Peer.html), 'months' => [int](/API_docs/types/int.html), 'slug' => [string](/API_docs/types/string.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), 'crypto_currency' => [string](/API_docs/types/string.html), 'crypto_amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionGiftPremium](/API_docs/constructors/messageActionGiftPremium.html) = \['currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), 'months' => [int](/API_docs/types/int.html), 'crypto_currency' => [string](/API_docs/types/string.html), 'crypto_amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionGiveawayLaunch](/API_docs/constructors/messageActionGiveawayLaunch.html) = \[\]; + +*** +

[$messageActionGiveawayResults](/API_docs/constructors/messageActionGiveawayResults.html) = \['winners_count' => [int](/API_docs/types/int.html), 'unclaimed_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionGroupCall](/API_docs/constructors/messageActionGroupCall.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'duration' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionGroupCallScheduled](/API_docs/constructors/messageActionGroupCallScheduled.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'schedule_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionHistoryClear](/API_docs/constructors/messageActionHistoryClear.html) = \[\]; + +*** +

[$messageActionInviteToGroupCall](/API_docs/constructors/messageActionInviteToGroupCall.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$messageActionPaymentSent](/API_docs/constructors/messageActionPaymentSent.html) = \['recurring_init' => [Bool](/API_docs/types/Bool.html), 'recurring_used' => [Bool](/API_docs/types/Bool.html), 'currency' => [string](/API_docs/types/string.html), 'total_amount' => [long](/API_docs/types/long.html), 'invoice_slug' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageActionPaymentSentMe](/API_docs/constructors/messageActionPaymentSentMe.html) = \['recurring_init' => [Bool](/API_docs/types/Bool.html), 'recurring_used' => [Bool](/API_docs/types/Bool.html), 'currency' => [string](/API_docs/types/string.html), 'total_amount' => [long](/API_docs/types/long.html), 'payload' => [bytes](/API_docs/types/bytes.html), 'info' => [PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html), 'shipping_option_id' => [string](/API_docs/types/string.html), 'charge' => [PaymentCharge](/API_docs/types/PaymentCharge.html), \]; + +*** +

[$messageActionPhoneCall](/API_docs/constructors/messageActionPhoneCall.html) = \['video' => [Bool](/API_docs/types/Bool.html), 'call_id' => [long](/API_docs/types/long.html), 'reason' => [PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html), 'duration' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageActionPinMessage](/API_docs/constructors/messageActionPinMessage.html) = \[\]; + +*** +

[$messageActionRequestedPeer](/API_docs/constructors/messageActionRequestedPeer.html) = \['button_id' => [int](/API_docs/types/int.html), 'peers' => \[[Peer](/API_docs/types/Peer.html)\], \]; + +*** +

[$messageActionRequestedPeerSentMe](/API_docs/constructors/messageActionRequestedPeerSentMe.html) = \['button_id' => [int](/API_docs/types/int.html), 'peers' => \[[RequestedPeer](/API_docs/types/RequestedPeer.html)\], \]; + +*** +

[$messageActionScreenshotTaken](/API_docs/constructors/messageActionScreenshotTaken.html) = \[\]; + +*** +

[$messageActionSecureValuesSent](/API_docs/constructors/messageActionSecureValuesSent.html) = \['types' => \[[SecureValueType](/API_docs/types/SecureValueType.html)\], \]; + +*** +

[$messageActionSecureValuesSentMe](/API_docs/constructors/messageActionSecureValuesSentMe.html) = \['values' => \[[SecureValue](/API_docs/types/SecureValue.html)\], 'credentials' => [SecureCredentialsEncrypted](/API_docs/types/SecureCredentialsEncrypted.html), \]; + +*** +

[$messageActionSetChatTheme](/API_docs/constructors/messageActionSetChatTheme.html) = \['emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageActionSetChatWallPaper](/API_docs/constructors/messageActionSetChatWallPaper.html) = \['same' => [Bool](/API_docs/types/Bool.html), 'for_both' => [Bool](/API_docs/types/Bool.html), 'wallpaper' => [WallPaper](/API_docs/types/WallPaper.html), \]; + +*** +

[$messageActionSetMessagesTTL](/API_docs/constructors/messageActionSetMessagesTTL.html) = \['period' => [int](/API_docs/types/int.html), 'auto_setting_from' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionSuggestProfilePhoto](/API_docs/constructors/messageActionSuggestProfilePhoto.html) = \['photo' => [Photo](/API_docs/types/Photo.html), \]; + +*** +

[$messageActionTopicCreate](/API_docs/constructors/messageActionTopicCreate.html) = \['title' => [string](/API_docs/types/string.html), 'icon_color' => [int](/API_docs/types/int.html), 'icon_emoji_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageActionTopicEdit](/API_docs/constructors/messageActionTopicEdit.html) = \['title' => [string](/API_docs/types/string.html), 'icon_emoji_id' => [long](/API_docs/types/long.html), 'closed' => [Bool](/API_docs/types/Bool.html), 'hidden' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$messageActionWebViewDataSent](/API_docs/constructors/messageActionWebViewDataSent.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageActionWebViewDataSentMe](/API_docs/constructors/messageActionWebViewDataSentMe.html) = \['text' => [string](/API_docs/types/string.html), 'data' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageEmpty](/API_docs/constructors/messageEmpty.html) = \['id' => [int](/API_docs/types/int.html), 'peer_id' => [Peer](/API_docs/types/Peer.html), \]; + +*** +

[$messageEntityBankCard](/API_docs/constructors/messageEntityBankCard.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityBlockquote](/API_docs/constructors/messageEntityBlockquote.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityBold](/API_docs/constructors/messageEntityBold.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityBotCommand](/API_docs/constructors/messageEntityBotCommand.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityCashtag](/API_docs/constructors/messageEntityCashtag.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityCode](/API_docs/constructors/messageEntityCode.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityCustomEmoji](/API_docs/constructors/messageEntityCustomEmoji.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), 'document_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageEntityEmail](/API_docs/constructors/messageEntityEmail.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityHashtag](/API_docs/constructors/messageEntityHashtag.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityItalic](/API_docs/constructors/messageEntityItalic.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityMention](/API_docs/constructors/messageEntityMention.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityMentionName](/API_docs/constructors/messageEntityMentionName.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageEntityPhone](/API_docs/constructors/messageEntityPhone.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityPre](/API_docs/constructors/messageEntityPre.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), 'language' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageEntitySpoiler](/API_docs/constructors/messageEntitySpoiler.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityStrike](/API_docs/constructors/messageEntityStrike.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityTextUrl](/API_docs/constructors/messageEntityTextUrl.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageEntityUnderline](/API_docs/constructors/messageEntityUnderline.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityUnknown](/API_docs/constructors/messageEntityUnknown.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageEntityUrl](/API_docs/constructors/messageEntityUrl.html) = \['offset' => [int](/API_docs/types/int.html), 'length' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageExtendedMedia](/API_docs/constructors/messageExtendedMedia.html) = \['media' => [MessageMedia](/API_docs/types/MessageMedia.html), \]; + +*** +

[$messageExtendedMediaPreview](/API_docs/constructors/messageExtendedMediaPreview.html) = \['w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'thumb' => [PhotoSize](/API_docs/types/PhotoSize.html), 'video_duration' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageFwdHeader](/API_docs/constructors/messageFwdHeader.html) = \['imported' => [Bool](/API_docs/types/Bool.html), 'saved_out' => [Bool](/API_docs/types/Bool.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'from_name' => [string](/API_docs/types/string.html), 'date' => [int](/API_docs/types/int.html), 'channel_post' => [int](/API_docs/types/int.html), 'post_author' => [string](/API_docs/types/string.html), 'saved_from_peer' => [Peer](/API_docs/types/Peer.html), 'saved_from_msg_id' => [int](/API_docs/types/int.html), 'saved_from_id' => [Peer](/API_docs/types/Peer.html), 'saved_from_name' => [string](/API_docs/types/string.html), 'saved_date' => [int](/API_docs/types/int.html), 'psa_type' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageMediaContact](/API_docs/constructors/messageMediaContact.html) = \['phone_number' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'vcard' => [string](/API_docs/types/string.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messageMediaDice](/API_docs/constructors/messageMediaDice.html) = \['value' => [int](/API_docs/types/int.html), 'emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageMediaDocument](/API_docs/constructors/messageMediaDocument.html) = \['nopremium' => [Bool](/API_docs/types/Bool.html), 'spoiler' => [Bool](/API_docs/types/Bool.html), 'video' => [Bool](/API_docs/types/Bool.html), 'round' => [Bool](/API_docs/types/Bool.html), 'voice' => [Bool](/API_docs/types/Bool.html), 'document' => [Document](/API_docs/types/Document.html), 'alt_document' => [Document](/API_docs/types/Document.html), 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageMediaEmpty](/API_docs/constructors/messageMediaEmpty.html) = \[\]; + +*** +

[$messageMediaGame](/API_docs/constructors/messageMediaGame.html) = \['game' => [Game](/API_docs/types/Game.html), \]; + +*** +

[$messageMediaGeo](/API_docs/constructors/messageMediaGeo.html) = \['geo' => [GeoPoint](/API_docs/types/GeoPoint.html), \]; + +*** +

[$messageMediaGeoLive](/API_docs/constructors/messageMediaGeoLive.html) = \['geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'heading' => [int](/API_docs/types/int.html), 'period' => [int](/API_docs/types/int.html), 'proximity_notification_radius' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageMediaGiveaway](/API_docs/constructors/messageMediaGiveaway.html) = \['only_new_subscribers' => [Bool](/API_docs/types/Bool.html), 'winners_are_visible' => [Bool](/API_docs/types/Bool.html), 'channels' => \[[long](/API_docs/types/long.html)\], 'countries_iso2' => \[[string](/API_docs/types/string.html)\], 'prize_description' => [string](/API_docs/types/string.html), 'quantity' => [int](/API_docs/types/int.html), 'months' => [int](/API_docs/types/int.html), 'until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageMediaGiveawayResults](/API_docs/constructors/messageMediaGiveawayResults.html) = \['only_new_subscribers' => [Bool](/API_docs/types/Bool.html), 'refunded' => [Bool](/API_docs/types/Bool.html), 'channel_id' => [long](/API_docs/types/long.html), 'additional_peers_count' => [int](/API_docs/types/int.html), 'launch_msg_id' => [int](/API_docs/types/int.html), 'winners_count' => [int](/API_docs/types/int.html), 'unclaimed_count' => [int](/API_docs/types/int.html), 'winners' => \[[long](/API_docs/types/long.html)\], 'months' => [int](/API_docs/types/int.html), 'prize_description' => [string](/API_docs/types/string.html), 'until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageMediaInvoice](/API_docs/constructors/messageMediaInvoice.html) = \['shipping_address_requested' => [Bool](/API_docs/types/Bool.html), 'test' => [Bool](/API_docs/types/Bool.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [WebDocument](/API_docs/types/WebDocument.html), 'receipt_msg_id' => [int](/API_docs/types/int.html), 'currency' => [string](/API_docs/types/string.html), 'total_amount' => [long](/API_docs/types/long.html), 'start_param' => [string](/API_docs/types/string.html), 'extended_media' => [MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html), \]; + +*** +

[$messageMediaPhoto](/API_docs/constructors/messageMediaPhoto.html) = \['spoiler' => [Bool](/API_docs/types/Bool.html), 'photo' => [Photo](/API_docs/types/Photo.html), 'ttl_seconds' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageMediaPoll](/API_docs/constructors/messageMediaPoll.html) = \['poll' => [Poll](/API_docs/types/Poll.html), 'results' => [PollResults](/API_docs/types/PollResults.html), \]; + +*** +

[$messageMediaStory](/API_docs/constructors/messageMediaStory.html) = \['via_mention' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'id' => [int](/API_docs/types/int.html), 'story' => [StoryItem](/API_docs/types/StoryItem.html), \]; + +*** +

[$messageMediaUnsupported](/API_docs/constructors/messageMediaUnsupported.html) = \[\]; + +*** +

[$messageMediaVenue](/API_docs/constructors/messageMediaVenue.html) = \['geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'title' => [string](/API_docs/types/string.html), 'address' => [string](/API_docs/types/string.html), 'provider' => [string](/API_docs/types/string.html), 'venue_id' => [string](/API_docs/types/string.html), 'venue_type' => [string](/API_docs/types/string.html), \]; + +*** +

[$messageMediaWebPage](/API_docs/constructors/messageMediaWebPage.html) = \['force_large_media' => [Bool](/API_docs/types/Bool.html), 'force_small_media' => [Bool](/API_docs/types/Bool.html), 'manual' => [Bool](/API_docs/types/Bool.html), 'safe' => [Bool](/API_docs/types/Bool.html), 'webpage' => [WebPage](/API_docs/types/WebPage.html), \]; + +*** +

[$messagePeerReaction](/API_docs/constructors/messagePeerReaction.html) = \['big' => [Bool](/API_docs/types/Bool.html), 'unread' => [Bool](/API_docs/types/Bool.html), 'my' => [Bool](/API_docs/types/Bool.html), 'peer_id' => [Peer](/API_docs/types/Peer.html), 'date' => [int](/API_docs/types/int.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$messagePeerVote](/API_docs/constructors/messagePeerVote.html) = \['peer' => [long](/API_docs/types/long.html), 'option' => [bytes](/API_docs/types/bytes.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messagePeerVoteInputOption](/API_docs/constructors/messagePeerVoteInputOption.html) = \['peer' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messagePeerVoteMultiple](/API_docs/constructors/messagePeerVoteMultiple.html) = \['peer' => [long](/API_docs/types/long.html), 'options' => \[[bytes](/API_docs/types/bytes.html)\], 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageRange](/API_docs/constructors/messageRange.html) = \['min_id' => [int](/API_docs/types/int.html), 'max_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageReactions](/API_docs/constructors/messageReactions.html) = \['min' => [Bool](/API_docs/types/Bool.html), 'can_see_list' => [Bool](/API_docs/types/Bool.html), 'reactions_as_tags' => [Bool](/API_docs/types/Bool.html), 'results' => \[[ReactionCount](/API_docs/types/ReactionCount.html)\], 'recent_reactions' => \[[MessagePeerReaction](/API_docs/types/MessagePeerReaction.html)\], \]; + +*** +

[$messageReplies](/API_docs/constructors/messageReplies.html) = \['comments' => [Bool](/API_docs/types/Bool.html), 'replies' => [int](/API_docs/types/int.html), 'replies_pts' => [int](/API_docs/types/int.html), 'recent_repliers' => \[[Peer](/API_docs/types/Peer.html)\], 'channel_id' => [long](/API_docs/types/long.html), 'max_id' => [int](/API_docs/types/int.html), 'read_max_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageReplyHeader](/API_docs/constructors/messageReplyHeader.html) = \['reply_to_scheduled' => [Bool](/API_docs/types/Bool.html), 'forum_topic' => [Bool](/API_docs/types/Bool.html), 'quote' => [Bool](/API_docs/types/Bool.html), 'reply_to_msg_id' => [int](/API_docs/types/int.html), 'reply_to_peer_id' => [Peer](/API_docs/types/Peer.html), 'reply_from' => [MessageFwdHeader](/API_docs/types/MessageFwdHeader.html), 'reply_media' => [MessageMedia](/API_docs/types/MessageMedia.html), 'reply_to_top_id' => [int](/API_docs/types/int.html), 'quote_text' => [string](/API_docs/types/string.html), 'quote_entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'quote_offset' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageReplyStoryHeader](/API_docs/constructors/messageReplyStoryHeader.html) = \['peer' => [long](/API_docs/types/long.html), 'story_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageService](/API_docs/constructors/messageService.html) = \['out' => [Bool](/API_docs/types/Bool.html), 'mentioned' => [Bool](/API_docs/types/Bool.html), 'media_unread' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'post' => [Bool](/API_docs/types/Bool.html), 'legacy' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'peer_id' => [Peer](/API_docs/types/Peer.html), 'reply_to' => [MessageReplyHeader](/API_docs/types/MessageReplyHeader.html), 'date' => [int](/API_docs/types/int.html), 'action' => [MessageAction](/API_docs/types/MessageAction.html), 'ttl_period' => [int](/API_docs/types/int.html), \]; + +*** +

[$messageViews](/API_docs/constructors/messageViews.html) = \['views' => [int](/API_docs/types/int.html), 'forwards' => [int](/API_docs/types/int.html), 'replies' => [MessageReplies](/API_docs/types/MessageReplies.html), \]; + +*** +

[$messages.affectedFoundMessages](/API_docs/constructors/messages.affectedFoundMessages.html) = \['pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), 'offset' => [int](/API_docs/types/int.html), 'messages' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$messages.affectedHistory](/API_docs/constructors/messages.affectedHistory.html) = \['pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), 'offset' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.affectedMessages](/API_docs/constructors/messages.affectedMessages.html) = \['pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.allStickers](/API_docs/constructors/messages.allStickers.html) = \['hash' => [long](/API_docs/types/long.html), 'sets' => \[[StickerSet](/API_docs/types/StickerSet.html)\], \]; + +*** +

[$messages.allStickersNotModified](/API_docs/constructors/messages.allStickersNotModified.html) = \[\]; + +*** +

[$messages.archivedStickers](/API_docs/constructors/messages.archivedStickers.html) = \['count' => [int](/API_docs/types/int.html), 'sets' => \[[StickerSetCovered](/API_docs/types/StickerSetCovered.html)\], \]; + +*** +

[$messages.availableReactions](/API_docs/constructors/messages.availableReactions.html) = \['hash' => [int](/API_docs/types/int.html), 'reactions' => \[[AvailableReaction](/API_docs/types/AvailableReaction.html)\], \]; + +*** +

[$messages.availableReactionsNotModified](/API_docs/constructors/messages.availableReactionsNotModified.html) = \[\]; + +*** +

[$messages.botApp](/API_docs/constructors/messages.botApp.html) = \['inactive' => [Bool](/API_docs/types/Bool.html), 'request_write_access' => [Bool](/API_docs/types/Bool.html), 'has_settings' => [Bool](/API_docs/types/Bool.html), 'app' => [BotApp](/API_docs/types/BotApp.html), \]; + +*** +

[$messages.botCallbackAnswer](/API_docs/constructors/messages.botCallbackAnswer.html) = \['alert' => [Bool](/API_docs/types/Bool.html), 'has_url' => [Bool](/API_docs/types/Bool.html), 'native_ui' => [Bool](/API_docs/types/Bool.html), 'message' => [string](/API_docs/types/string.html), 'url' => [string](/API_docs/types/string.html), 'cache_time' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.botResults](/API_docs/constructors/messages.botResults.html) = \['gallery' => [Bool](/API_docs/types/Bool.html), 'query_id' => [long](/API_docs/types/long.html), 'next_offset' => [string](/API_docs/types/string.html), 'switch_pm' => [InlineBotSwitchPM](/API_docs/types/InlineBotSwitchPM.html), 'switch_webview' => [InlineBotWebView](/API_docs/types/InlineBotWebView.html), 'results' => \[[BotInlineResult](/API_docs/types/BotInlineResult.html)\], 'cache_time' => [int](/API_docs/types/int.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.channelMessages](/API_docs/constructors/messages.channelMessages.html) = \['inexact' => [Bool](/API_docs/types/Bool.html), 'pts' => [int](/API_docs/types/int.html), 'count' => [int](/API_docs/types/int.html), 'offset_id_offset' => [int](/API_docs/types/int.html), 'messages' => \[[Message](/API_docs/types/Message.html)\], 'topics' => \[[ForumTopic](/API_docs/types/ForumTopic.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.chatAdminsWithInvites](/API_docs/constructors/messages.chatAdminsWithInvites.html) = \['admins' => \[[ChatAdminWithInvites](/API_docs/types/ChatAdminWithInvites.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.chatFull](/API_docs/constructors/messages.chatFull.html) = \['full_chat' => [ChatFull](/API_docs/types/ChatFull.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.chatInviteImporters](/API_docs/constructors/messages.chatInviteImporters.html) = \['count' => [int](/API_docs/types/int.html), 'importers' => \[[ChatInviteImporter](/API_docs/types/ChatInviteImporter.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.chats](/API_docs/constructors/messages.chats.html) = \['chats' => \[[Chat](/API_docs/types/Chat.html)\], \]; + +*** +

[$messages.chatsSlice](/API_docs/constructors/messages.chatsSlice.html) = \['count' => [int](/API_docs/types/int.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], \]; + +*** +

[$messages.checkedHistoryImportPeer](/API_docs/constructors/messages.checkedHistoryImportPeer.html) = \['confirm_text' => [string](/API_docs/types/string.html), \]; + +*** +

[$messages.dhConfig](/API_docs/constructors/messages.dhConfig.html) = \['g' => [int](/API_docs/types/int.html), 'p' => [bytes](/API_docs/types/bytes.html), 'version' => [int](/API_docs/types/int.html), 'random' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$messages.dhConfigNotModified](/API_docs/constructors/messages.dhConfigNotModified.html) = \['random' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$messages.dialogFilters](/API_docs/constructors/messages.dialogFilters.html) = \['tags_enabled' => [Bool](/API_docs/types/Bool.html), 'filters' => \[[DialogFilter](/API_docs/types/DialogFilter.html)\], \]; + +*** +

[$messages.dialogs](/API_docs/constructors/messages.dialogs.html) = \['dialogs' => \[[Dialog](/API_docs/types/Dialog.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.dialogsNotModified](/API_docs/constructors/messages.dialogsNotModified.html) = \['count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.dialogsSlice](/API_docs/constructors/messages.dialogsSlice.html) = \['count' => [int](/API_docs/types/int.html), 'dialogs' => \[[Dialog](/API_docs/types/Dialog.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.discussionMessage](/API_docs/constructors/messages.discussionMessage.html) = \['messages' => \[[Message](/API_docs/types/Message.html)\], 'max_id' => [int](/API_docs/types/int.html), 'read_inbox_max_id' => [int](/API_docs/types/int.html), 'read_outbox_max_id' => [int](/API_docs/types/int.html), 'unread_count' => [int](/API_docs/types/int.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.emojiGroups](/API_docs/constructors/messages.emojiGroups.html) = \['hash' => [int](/API_docs/types/int.html), 'groups' => \[[EmojiGroup](/API_docs/types/EmojiGroup.html)\], \]; + +*** +

[$messages.emojiGroupsNotModified](/API_docs/constructors/messages.emojiGroupsNotModified.html) = \[\]; + +*** +

[$messages.exportedChatInvite](/API_docs/constructors/messages.exportedChatInvite.html) = \['invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.exportedChatInviteReplaced](/API_docs/constructors/messages.exportedChatInviteReplaced.html) = \['invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'new_invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.exportedChatInvites](/API_docs/constructors/messages.exportedChatInvites.html) = \['count' => [int](/API_docs/types/int.html), 'invites' => \[[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.favedStickers](/API_docs/constructors/messages.favedStickers.html) = \['hash' => [long](/API_docs/types/long.html), 'packs' => \[[StickerPack](/API_docs/types/StickerPack.html)\], 'stickers' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$messages.favedStickersNotModified](/API_docs/constructors/messages.favedStickersNotModified.html) = \[\]; + +*** +

[$messages.featuredStickers](/API_docs/constructors/messages.featuredStickers.html) = \['premium' => [Bool](/API_docs/types/Bool.html), 'hash' => [long](/API_docs/types/long.html), 'count' => [int](/API_docs/types/int.html), 'sets' => \[[StickerSetCovered](/API_docs/types/StickerSetCovered.html)\], 'unread' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$messages.featuredStickersNotModified](/API_docs/constructors/messages.featuredStickersNotModified.html) = \['count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.forumTopics](/API_docs/constructors/messages.forumTopics.html) = \['order_by_create_date' => [Bool](/API_docs/types/Bool.html), 'count' => [int](/API_docs/types/int.html), 'topics' => \[[ForumTopic](/API_docs/types/ForumTopic.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'pts' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.foundStickerSets](/API_docs/constructors/messages.foundStickerSets.html) = \['hash' => [long](/API_docs/types/long.html), 'sets' => \[[StickerSetCovered](/API_docs/types/StickerSetCovered.html)\], \]; + +*** +

[$messages.foundStickerSetsNotModified](/API_docs/constructors/messages.foundStickerSetsNotModified.html) = \[\]; + +*** +

[$messages.highScores](/API_docs/constructors/messages.highScores.html) = \['scores' => \[[HighScore](/API_docs/types/HighScore.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.historyImport](/API_docs/constructors/messages.historyImport.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$messages.historyImportParsed](/API_docs/constructors/messages.historyImportParsed.html) = \['pm' => [Bool](/API_docs/types/Bool.html), 'group' => [Bool](/API_docs/types/Bool.html), 'title' => [string](/API_docs/types/string.html), \]; + +*** +

[$messages.inactiveChats](/API_docs/constructors/messages.inactiveChats.html) = \['dates' => \[[int](/API_docs/types/int.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.invitedUsers](/API_docs/constructors/messages.invitedUsers.html) = \['updates' => [Updates](/API_docs/types/Updates.html), 'missing_invitees' => \[[MissingInvitee](/API_docs/types/MissingInvitee.html)\], \]; + +*** +

[$messages.messageEditData](/API_docs/constructors/messages.messageEditData.html) = \['caption' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$messages.messageReactionsList](/API_docs/constructors/messages.messageReactionsList.html) = \['count' => [int](/API_docs/types/int.html), 'reactions' => \[[MessagePeerReaction](/API_docs/types/MessagePeerReaction.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'next_offset' => [string](/API_docs/types/string.html), \]; + +*** +

[$messages.messageViews](/API_docs/constructors/messages.messageViews.html) = \['views' => \[[MessageViews](/API_docs/types/MessageViews.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.messages](/API_docs/constructors/messages.messages.html) = \['messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.messagesNotModified](/API_docs/constructors/messages.messagesNotModified.html) = \['count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.messagesSlice](/API_docs/constructors/messages.messagesSlice.html) = \['inexact' => [Bool](/API_docs/types/Bool.html), 'count' => [int](/API_docs/types/int.html), 'next_rate' => [int](/API_docs/types/int.html), 'offset_id_offset' => [int](/API_docs/types/int.html), 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.myStickers](/API_docs/constructors/messages.myStickers.html) = \['count' => [int](/API_docs/types/int.html), 'sets' => \[[StickerSetCovered](/API_docs/types/StickerSetCovered.html)\], \]; + +*** +

[$messages.peerDialogs](/API_docs/constructors/messages.peerDialogs.html) = \['dialogs' => \[[Dialog](/API_docs/types/Dialog.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'state' => [updates.State](/API_docs/types/updates.State.html), \]; + +*** +

[$messages.peerSettings](/API_docs/constructors/messages.peerSettings.html) = \['settings' => [PeerSettings](/API_docs/types/PeerSettings.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.quickReplies](/API_docs/constructors/messages.quickReplies.html) = \['quick_replies' => \[[QuickReply](/API_docs/types/QuickReply.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.quickRepliesNotModified](/API_docs/constructors/messages.quickRepliesNotModified.html) = \[\]; + +*** +

[$messages.reactions](/API_docs/constructors/messages.reactions.html) = \['hash' => [long](/API_docs/types/long.html), 'reactions' => \[[Reaction](/API_docs/types/Reaction.html)\], \]; + +*** +

[$messages.reactionsNotModified](/API_docs/constructors/messages.reactionsNotModified.html) = \[\]; + +*** +

[$messages.recentStickers](/API_docs/constructors/messages.recentStickers.html) = \['hash' => [long](/API_docs/types/long.html), 'packs' => \[[StickerPack](/API_docs/types/StickerPack.html)\], 'stickers' => \[[Document](/API_docs/types/Document.html)\], 'dates' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$messages.recentStickersNotModified](/API_docs/constructors/messages.recentStickersNotModified.html) = \[\]; + +*** +

[$messages.savedDialogs](/API_docs/constructors/messages.savedDialogs.html) = \['dialogs' => \[[SavedDialog](/API_docs/types/SavedDialog.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.savedDialogsNotModified](/API_docs/constructors/messages.savedDialogsNotModified.html) = \['count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.savedDialogsSlice](/API_docs/constructors/messages.savedDialogsSlice.html) = \['count' => [int](/API_docs/types/int.html), 'dialogs' => \[[SavedDialog](/API_docs/types/SavedDialog.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.savedGifs](/API_docs/constructors/messages.savedGifs.html) = \['hash' => [long](/API_docs/types/long.html), 'gifs' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$messages.savedGifsNotModified](/API_docs/constructors/messages.savedGifsNotModified.html) = \[\]; + +*** +

[$messages.savedReactionTags](/API_docs/constructors/messages.savedReactionTags.html) = \['tags' => \[[SavedReactionTag](/API_docs/types/SavedReactionTag.html)\], 'hash' => [long](/API_docs/types/long.html), \]; + +*** +

[$messages.savedReactionTagsNotModified](/API_docs/constructors/messages.savedReactionTagsNotModified.html) = \[\]; + +*** +

[$messages.searchCounter](/API_docs/constructors/messages.searchCounter.html) = \['inexact' => [Bool](/API_docs/types/Bool.html), 'filter' => [MessagesFilter](/API_docs/types/MessagesFilter.html), 'count' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.searchResultsCalendar](/API_docs/constructors/messages.searchResultsCalendar.html) = \['inexact' => [Bool](/API_docs/types/Bool.html), 'count' => [int](/API_docs/types/int.html), 'min_date' => [int](/API_docs/types/int.html), 'min_msg_id' => [int](/API_docs/types/int.html), 'offset_id_offset' => [int](/API_docs/types/int.html), 'periods' => \[[SearchResultsCalendarPeriod](/API_docs/types/SearchResultsCalendarPeriod.html)\], 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.searchResultsPositions](/API_docs/constructors/messages.searchResultsPositions.html) = \['count' => [int](/API_docs/types/int.html), 'positions' => \[[SearchResultsPosition](/API_docs/types/SearchResultsPosition.html)\], \]; + +*** +

[$messages.sentEncryptedFile](/API_docs/constructors/messages.sentEncryptedFile.html) = \['date' => [int](/API_docs/types/int.html), 'file' => [EncryptedFile](/API_docs/types/EncryptedFile.html), \]; + +*** +

[$messages.sentEncryptedMessage](/API_docs/constructors/messages.sentEncryptedMessage.html) = \['date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.sponsoredMessages](/API_docs/constructors/messages.sponsoredMessages.html) = \['posts_between' => [int](/API_docs/types/int.html), 'messages' => \[[SponsoredMessage](/API_docs/types/SponsoredMessage.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$messages.sponsoredMessagesEmpty](/API_docs/constructors/messages.sponsoredMessagesEmpty.html) = \[\]; + +*** +

[$messages.stickerSet](/API_docs/constructors/messages.stickerSet.html) = \['set' => [StickerSet](/API_docs/types/StickerSet.html), 'packs' => \[[StickerPack](/API_docs/types/StickerPack.html)\], 'keywords' => \[[StickerKeyword](/API_docs/types/StickerKeyword.html)\], 'documents' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$messages.stickerSetInstallResultArchive](/API_docs/constructors/messages.stickerSetInstallResultArchive.html) = \['sets' => \[[StickerSetCovered](/API_docs/types/StickerSetCovered.html)\], \]; + +*** +

[$messages.stickerSetInstallResultSuccess](/API_docs/constructors/messages.stickerSetInstallResultSuccess.html) = \[\]; + +*** +

[$messages.stickerSetNotModified](/API_docs/constructors/messages.stickerSetNotModified.html) = \[\]; + +*** +

[$messages.stickers](/API_docs/constructors/messages.stickers.html) = \['hash' => [long](/API_docs/types/long.html), 'stickers' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$messages.stickersNotModified](/API_docs/constructors/messages.stickersNotModified.html) = \[\]; + +*** +

[$messages.transcribedAudio](/API_docs/constructors/messages.transcribedAudio.html) = \['pending' => [Bool](/API_docs/types/Bool.html), 'transcription_id' => [long](/API_docs/types/long.html), 'text' => [string](/API_docs/types/string.html), 'trial_remains_num' => [int](/API_docs/types/int.html), 'trial_remains_until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$messages.translateResult](/API_docs/constructors/messages.translateResult.html) = \['result' => \[[TextWithEntities](/API_docs/types/TextWithEntities.html)\], \]; + +*** +

[$messages.votesList](/API_docs/constructors/messages.votesList.html) = \['count' => [int](/API_docs/types/int.html), 'votes' => \[[MessagePeerVote](/API_docs/types/MessagePeerVote.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'next_offset' => [string](/API_docs/types/string.html), \]; + +*** +

[$messages.webPage](/API_docs/constructors/messages.webPage.html) = \['webpage' => [WebPage](/API_docs/types/WebPage.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$missingInvitee](/API_docs/constructors/missingInvitee.html) = \['premium_would_allow_invite' => [Bool](/API_docs/types/Bool.html), 'premium_required_for_pm' => [Bool](/API_docs/types/Bool.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$myBoost](/API_docs/constructors/myBoost.html) = \['slot' => [int](/API_docs/types/int.html), 'peer' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'expires' => [int](/API_docs/types/int.html), 'cooldown_until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$nearestDc](/API_docs/constructors/nearestDc.html) = \['country' => [string](/API_docs/types/string.html), 'this_dc' => [int](/API_docs/types/int.html), 'nearest_dc' => [int](/API_docs/types/int.html), \]; + +*** +

[$notificationSoundDefault](/API_docs/constructors/notificationSoundDefault.html) = \[\]; + +*** +

[$notificationSoundLocal](/API_docs/constructors/notificationSoundLocal.html) = \['title' => [string](/API_docs/types/string.html), 'data' => [string](/API_docs/types/string.html), \]; + +*** +

[$notificationSoundNone](/API_docs/constructors/notificationSoundNone.html) = \[\]; + +*** +

[$notificationSoundRingtone](/API_docs/constructors/notificationSoundRingtone.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$notifyBroadcasts](/API_docs/constructors/notifyBroadcasts.html) = \[\]; + +*** +

[$notifyChats](/API_docs/constructors/notifyChats.html) = \[\]; + +*** +

[$notifyForumTopic](/API_docs/constructors/notifyForumTopic.html) = \['peer' => [long](/API_docs/types/long.html), 'top_msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$notifyPeer](/API_docs/constructors/notifyPeer.html) = \['peer' => [long](/API_docs/types/long.html), \]; + +*** +

[$notifyUsers](/API_docs/constructors/notifyUsers.html) = \[\]; + +*** +

[$null](/API_docs/constructors/null.html) = \[\]; + +*** +

[$outboxReadDate](/API_docs/constructors/outboxReadDate.html) = \['date' => [int](/API_docs/types/int.html), \]; + +*** +

[$page](/API_docs/constructors/page.html) = \['part' => [Bool](/API_docs/types/Bool.html), 'rtl' => [Bool](/API_docs/types/Bool.html), 'v2' => [Bool](/API_docs/types/Bool.html), 'url' => [string](/API_docs/types/string.html), 'blocks' => \[[PageBlock](/API_docs/types/PageBlock.html)\], 'photos' => \[[Photo](/API_docs/types/Photo.html)\], 'documents' => \[[Document](/API_docs/types/Document.html)\], 'views' => [int](/API_docs/types/int.html), \]; + +*** +

[$pageBlockAnchor](/API_docs/constructors/pageBlockAnchor.html) = \['name' => [string](/API_docs/types/string.html), \]; + +*** +

[$pageBlockAudio](/API_docs/constructors/pageBlockAudio.html) = \['audio_id' => [long](/API_docs/types/long.html), 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageBlockAuthorDate](/API_docs/constructors/pageBlockAuthorDate.html) = \['author' => [RichText](/API_docs/types/RichText.html), 'published_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$pageBlockBlockquote](/API_docs/constructors/pageBlockBlockquote.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'caption' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockChannel](/API_docs/constructors/pageBlockChannel.html) = \['channel' => [Chat](/API_docs/types/Chat.html), \]; + +*** +

[$pageBlockCollage](/API_docs/constructors/pageBlockCollage.html) = \['items' => \[[PageBlock](/API_docs/types/PageBlock.html)\], 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageBlockCover](/API_docs/constructors/pageBlockCover.html) = \['cover' => [PageBlock](/API_docs/types/PageBlock.html), \]; + +*** +

[$pageBlockDetails](/API_docs/constructors/pageBlockDetails.html) = \['open' => [Bool](/API_docs/types/Bool.html), 'blocks' => \[[PageBlock](/API_docs/types/PageBlock.html)\], 'title' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockDivider](/API_docs/constructors/pageBlockDivider.html) = \[\]; + +*** +

[$pageBlockEmbed](/API_docs/constructors/pageBlockEmbed.html) = \['full_width' => [Bool](/API_docs/types/Bool.html), 'allow_scrolling' => [Bool](/API_docs/types/Bool.html), 'url' => [string](/API_docs/types/string.html), 'html' => [string](/API_docs/types/string.html), 'poster_photo_id' => [long](/API_docs/types/long.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageBlockEmbedPost](/API_docs/constructors/pageBlockEmbedPost.html) = \['url' => [string](/API_docs/types/string.html), 'webpage_id' => [long](/API_docs/types/long.html), 'author_photo_id' => [long](/API_docs/types/long.html), 'author' => [string](/API_docs/types/string.html), 'date' => [int](/API_docs/types/int.html), 'blocks' => \[[PageBlock](/API_docs/types/PageBlock.html)\], 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageBlockFooter](/API_docs/constructors/pageBlockFooter.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockHeader](/API_docs/constructors/pageBlockHeader.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockKicker](/API_docs/constructors/pageBlockKicker.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockList](/API_docs/constructors/pageBlockList.html) = \['items' => \[[PageListItem](/API_docs/types/PageListItem.html)\], \]; + +*** +

[$pageBlockMap](/API_docs/constructors/pageBlockMap.html) = \['geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'zoom' => [int](/API_docs/types/int.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageBlockOrderedList](/API_docs/constructors/pageBlockOrderedList.html) = \['items' => \[[PageListOrderedItem](/API_docs/types/PageListOrderedItem.html)\], \]; + +*** +

[$pageBlockParagraph](/API_docs/constructors/pageBlockParagraph.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockPhoto](/API_docs/constructors/pageBlockPhoto.html) = \['photo_id' => [long](/API_docs/types/long.html), 'caption' => [PageCaption](/API_docs/types/PageCaption.html), 'url' => [string](/API_docs/types/string.html), 'webpage_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$pageBlockPreformatted](/API_docs/constructors/pageBlockPreformatted.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'language' => [string](/API_docs/types/string.html), \]; + +*** +

[$pageBlockPullquote](/API_docs/constructors/pageBlockPullquote.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'caption' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockRelatedArticles](/API_docs/constructors/pageBlockRelatedArticles.html) = \['title' => [RichText](/API_docs/types/RichText.html), 'articles' => \[[PageRelatedArticle](/API_docs/types/PageRelatedArticle.html)\], \]; + +*** +

[$pageBlockSlideshow](/API_docs/constructors/pageBlockSlideshow.html) = \['items' => \[[PageBlock](/API_docs/types/PageBlock.html)\], 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageBlockSubheader](/API_docs/constructors/pageBlockSubheader.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockSubtitle](/API_docs/constructors/pageBlockSubtitle.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockTable](/API_docs/constructors/pageBlockTable.html) = \['bordered' => [Bool](/API_docs/types/Bool.html), 'striped' => [Bool](/API_docs/types/Bool.html), 'title' => [RichText](/API_docs/types/RichText.html), 'rows' => \[[PageTableRow](/API_docs/types/PageTableRow.html)\], \]; + +*** +

[$pageBlockTitle](/API_docs/constructors/pageBlockTitle.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageBlockUnsupported](/API_docs/constructors/pageBlockUnsupported.html) = \[\]; + +*** +

[$pageBlockVideo](/API_docs/constructors/pageBlockVideo.html) = \['autoplay' => [Bool](/API_docs/types/Bool.html), 'loop' => [Bool](/API_docs/types/Bool.html), 'video_id' => [long](/API_docs/types/long.html), 'caption' => [PageCaption](/API_docs/types/PageCaption.html), \]; + +*** +

[$pageCaption](/API_docs/constructors/pageCaption.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'credit' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageListItemBlocks](/API_docs/constructors/pageListItemBlocks.html) = \['blocks' => \[[PageBlock](/API_docs/types/PageBlock.html)\], \]; + +*** +

[$pageListItemText](/API_docs/constructors/pageListItemText.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageListOrderedItemBlocks](/API_docs/constructors/pageListOrderedItemBlocks.html) = \['num' => [string](/API_docs/types/string.html), 'blocks' => \[[PageBlock](/API_docs/types/PageBlock.html)\], \]; + +*** +

[$pageListOrderedItemText](/API_docs/constructors/pageListOrderedItemText.html) = \['num' => [string](/API_docs/types/string.html), 'text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$pageRelatedArticle](/API_docs/constructors/pageRelatedArticle.html) = \['url' => [string](/API_docs/types/string.html), 'webpage_id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo_id' => [long](/API_docs/types/long.html), 'author' => [string](/API_docs/types/string.html), 'published_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$pageTableCell](/API_docs/constructors/pageTableCell.html) = \['header' => [Bool](/API_docs/types/Bool.html), 'align_center' => [Bool](/API_docs/types/Bool.html), 'align_right' => [Bool](/API_docs/types/Bool.html), 'valign_middle' => [Bool](/API_docs/types/Bool.html), 'valign_bottom' => [Bool](/API_docs/types/Bool.html), 'text' => [RichText](/API_docs/types/RichText.html), 'colspan' => [int](/API_docs/types/int.html), 'rowspan' => [int](/API_docs/types/int.html), \]; + +*** +

[$pageTableRow](/API_docs/constructors/pageTableRow.html) = \['cells' => \[[PageTableCell](/API_docs/types/PageTableCell.html)\], \]; + +*** +

[$passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow](/API_docs/constructors/passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow.html) = \['salt1' => [bytes](/API_docs/types/bytes.html), 'salt2' => [bytes](/API_docs/types/bytes.html), 'g' => [int](/API_docs/types/int.html), 'p' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$passwordKdfAlgoUnknown](/API_docs/constructors/passwordKdfAlgoUnknown.html) = \[\]; + +*** +

[$paymentCharge](/API_docs/constructors/paymentCharge.html) = \['id' => [string](/API_docs/types/string.html), 'provider_charge_id' => [string](/API_docs/types/string.html), \]; + +*** +

[$paymentFormMethod](/API_docs/constructors/paymentFormMethod.html) = \['url' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), \]; + +*** +

[$paymentRequestedInfo](/API_docs/constructors/paymentRequestedInfo.html) = \['name' => [string](/API_docs/types/string.html), 'phone' => [string](/API_docs/types/string.html), 'email' => [string](/API_docs/types/string.html), 'shipping_address' => [PostAddress](/API_docs/types/PostAddress.html), \]; + +*** +

[$paymentSavedCredentialsCard](/API_docs/constructors/paymentSavedCredentialsCard.html) = \['id' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), \]; + +*** +

[$payments.bankCardData](/API_docs/constructors/payments.bankCardData.html) = \['title' => [string](/API_docs/types/string.html), 'open_urls' => \[[BankCardOpenUrl](/API_docs/types/BankCardOpenUrl.html)\], \]; + +*** +

[$payments.checkedGiftCode](/API_docs/constructors/payments.checkedGiftCode.html) = \['via_giveaway' => [Bool](/API_docs/types/Bool.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'giveaway_msg_id' => [int](/API_docs/types/int.html), 'to_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'months' => [int](/API_docs/types/int.html), 'used_date' => [int](/API_docs/types/int.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$payments.exportedInvoice](/API_docs/constructors/payments.exportedInvoice.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$payments.giveawayInfo](/API_docs/constructors/payments.giveawayInfo.html) = \['participating' => [Bool](/API_docs/types/Bool.html), 'preparing_results' => [Bool](/API_docs/types/Bool.html), 'start_date' => [int](/API_docs/types/int.html), 'joined_too_early_date' => [int](/API_docs/types/int.html), 'admin_disallowed_chat_id' => [long](/API_docs/types/long.html), 'disallowed_country' => [string](/API_docs/types/string.html), \]; + +*** +

[$payments.giveawayInfoResults](/API_docs/constructors/payments.giveawayInfoResults.html) = \['winner' => [Bool](/API_docs/types/Bool.html), 'refunded' => [Bool](/API_docs/types/Bool.html), 'start_date' => [int](/API_docs/types/int.html), 'gift_code_slug' => [string](/API_docs/types/string.html), 'finish_date' => [int](/API_docs/types/int.html), 'winners_count' => [int](/API_docs/types/int.html), 'activated_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$payments.paymentForm](/API_docs/constructors/payments.paymentForm.html) = \['can_save_credentials' => [Bool](/API_docs/types/Bool.html), 'password_missing' => [Bool](/API_docs/types/Bool.html), 'form_id' => [long](/API_docs/types/long.html), 'bot_id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [WebDocument](/API_docs/types/WebDocument.html), 'invoice' => [Invoice](/API_docs/types/Invoice.html), 'provider_id' => [long](/API_docs/types/long.html), 'url' => [string](/API_docs/types/string.html), 'native_provider' => [string](/API_docs/types/string.html), 'native_params' => [DataJSON](/API_docs/types/DataJSON.html), 'additional_methods' => \[[PaymentFormMethod](/API_docs/types/PaymentFormMethod.html)\], 'saved_info' => [PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html), 'saved_credentials' => \[[PaymentSavedCredentials](/API_docs/types/PaymentSavedCredentials.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$payments.paymentReceipt](/API_docs/constructors/payments.paymentReceipt.html) = \['date' => [int](/API_docs/types/int.html), 'bot_id' => [long](/API_docs/types/long.html), 'provider_id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [WebDocument](/API_docs/types/WebDocument.html), 'invoice' => [Invoice](/API_docs/types/Invoice.html), 'info' => [PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html), 'shipping' => [ShippingOption](/API_docs/types/ShippingOption.html), 'tip_amount' => [long](/API_docs/types/long.html), 'currency' => [string](/API_docs/types/string.html), 'total_amount' => [long](/API_docs/types/long.html), 'credentials_title' => [string](/API_docs/types/string.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$payments.paymentResult](/API_docs/constructors/payments.paymentResult.html) = \['updates' => [Updates](/API_docs/types/Updates.html), \]; + +*** +

[$payments.paymentVerificationNeeded](/API_docs/constructors/payments.paymentVerificationNeeded.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$payments.savedInfo](/API_docs/constructors/payments.savedInfo.html) = \['has_saved_credentials' => [Bool](/API_docs/types/Bool.html), 'saved_info' => [PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html), \]; + +*** +

[$payments.validatedRequestedInfo](/API_docs/constructors/payments.validatedRequestedInfo.html) = \['id' => [string](/API_docs/types/string.html), 'shipping_options' => \[[ShippingOption](/API_docs/types/ShippingOption.html)\], \]; + +*** +

[$peerBlocked](/API_docs/constructors/peerBlocked.html) = \['peer_id' => [Peer](/API_docs/types/Peer.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$peerChannel](/API_docs/constructors/peerChannel.html) = \['channel_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$peerChat](/API_docs/constructors/peerChat.html) = \['chat_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$peerColor](/API_docs/constructors/peerColor.html) = \['color' => [int](/API_docs/types/int.html), 'background_emoji_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$peerLocated](/API_docs/constructors/peerLocated.html) = \['peer' => [long](/API_docs/types/long.html), 'expires' => [int](/API_docs/types/int.html), 'distance' => [int](/API_docs/types/int.html), \]; + +*** +

[$peerNotifySettings](/API_docs/constructors/peerNotifySettings.html) = \['show_previews' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'mute_until' => [int](/API_docs/types/int.html), 'ios_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'android_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'other_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'stories_muted' => [Bool](/API_docs/types/Bool.html), 'stories_hide_sender' => [Bool](/API_docs/types/Bool.html), 'stories_ios_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'stories_android_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'stories_other_sound' => [NotificationSound](/API_docs/types/NotificationSound.html), \]; + +*** +

[$peerSelfLocated](/API_docs/constructors/peerSelfLocated.html) = \['expires' => [int](/API_docs/types/int.html), \]; + +*** +

[$peerSettings](/API_docs/constructors/peerSettings.html) = \['report_spam' => [Bool](/API_docs/types/Bool.html), 'add_contact' => [Bool](/API_docs/types/Bool.html), 'block_contact' => [Bool](/API_docs/types/Bool.html), 'share_contact' => [Bool](/API_docs/types/Bool.html), 'need_contacts_exception' => [Bool](/API_docs/types/Bool.html), 'report_geo' => [Bool](/API_docs/types/Bool.html), 'autoarchived' => [Bool](/API_docs/types/Bool.html), 'invite_members' => [Bool](/API_docs/types/Bool.html), 'request_chat_broadcast' => [Bool](/API_docs/types/Bool.html), 'business_bot_paused' => [Bool](/API_docs/types/Bool.html), 'business_bot_can_reply' => [Bool](/API_docs/types/Bool.html), 'geo_distance' => [int](/API_docs/types/int.html), 'request_chat_title' => [string](/API_docs/types/string.html), 'request_chat_date' => [int](/API_docs/types/int.html), 'business_bot_id' => [long](/API_docs/types/long.html), 'business_bot_manage_url' => [string](/API_docs/types/string.html), \]; + +*** +

[$peerStories](/API_docs/constructors/peerStories.html) = \['peer' => [long](/API_docs/types/long.html), 'max_read_id' => [int](/API_docs/types/int.html), 'stories' => \[[StoryItem](/API_docs/types/StoryItem.html)\], \]; + +*** +

[$peerUser](/API_docs/constructors/peerUser.html) = \['user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$phone.exportedGroupCallInvite](/API_docs/constructors/phone.exportedGroupCallInvite.html) = \['link' => [string](/API_docs/types/string.html), \]; + +*** +

[$phone.groupCall](/API_docs/constructors/phone.groupCall.html) = \['call' => [GroupCall](/API_docs/types/GroupCall.html), 'participants' => \[[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html)\], 'participants_next_offset' => [string](/API_docs/types/string.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$phone.groupCallStreamChannels](/API_docs/constructors/phone.groupCallStreamChannels.html) = \['channels' => \[[GroupCallStreamChannel](/API_docs/types/GroupCallStreamChannel.html)\], \]; + +*** +

[$phone.groupCallStreamRtmpUrl](/API_docs/constructors/phone.groupCallStreamRtmpUrl.html) = \['url' => [string](/API_docs/types/string.html), 'key' => [string](/API_docs/types/string.html), \]; + +*** +

[$phone.groupParticipants](/API_docs/constructors/phone.groupParticipants.html) = \['count' => [int](/API_docs/types/int.html), 'participants' => \[[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html)\], 'next_offset' => [string](/API_docs/types/string.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$phone.joinAsPeers](/API_docs/constructors/phone.joinAsPeers.html) = \['peers' => \[[Peer](/API_docs/types/Peer.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$phone.phoneCall](/API_docs/constructors/phone.phoneCall.html) = \['phone_call' => [PhoneCall](/API_docs/types/PhoneCall.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$phoneCall](/API_docs/constructors/phoneCall.html) = \['p2p_allowed' => [Bool](/API_docs/types/Bool.html), 'video' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), 'g_a_or_b' => [bytes](/API_docs/types/bytes.html), 'key_fingerprint' => [long](/API_docs/types/long.html), 'protocol' => [PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), 'connections' => \[[PhoneConnection](/API_docs/types/PhoneConnection.html)\], 'start_date' => [int](/API_docs/types/int.html), 'custom_parameters' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$phoneCallAccepted](/API_docs/constructors/phoneCallAccepted.html) = \['video' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), 'g_b' => [bytes](/API_docs/types/bytes.html), 'protocol' => [PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), \]; + +*** +

[$phoneCallDiscardReasonBusy](/API_docs/constructors/phoneCallDiscardReasonBusy.html) = \[\]; + +*** +

[$phoneCallDiscardReasonDisconnect](/API_docs/constructors/phoneCallDiscardReasonDisconnect.html) = \[\]; + +*** +

[$phoneCallDiscardReasonHangup](/API_docs/constructors/phoneCallDiscardReasonHangup.html) = \[\]; + +*** +

[$phoneCallDiscardReasonMissed](/API_docs/constructors/phoneCallDiscardReasonMissed.html) = \[\]; + +*** +

[$phoneCallDiscarded](/API_docs/constructors/phoneCallDiscarded.html) = \['need_rating' => [Bool](/API_docs/types/Bool.html), 'need_debug' => [Bool](/API_docs/types/Bool.html), 'video' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'reason' => [PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html), 'duration' => [int](/API_docs/types/int.html), \]; + +*** +

[$phoneCallEmpty](/API_docs/constructors/phoneCallEmpty.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$phoneCallProtocol](/API_docs/constructors/phoneCallProtocol.html) = \['udp_p2p' => [Bool](/API_docs/types/Bool.html), 'udp_reflector' => [Bool](/API_docs/types/Bool.html), 'min_layer' => [int](/API_docs/types/int.html), 'max_layer' => [int](/API_docs/types/int.html), 'library_versions' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$phoneCallRequested](/API_docs/constructors/phoneCallRequested.html) = \['video' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), 'g_a_hash' => [bytes](/API_docs/types/bytes.html), 'protocol' => [PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), \]; + +*** +

[$phoneCallWaiting](/API_docs/constructors/phoneCallWaiting.html) = \['video' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'admin_id' => [long](/API_docs/types/long.html), 'participant_id' => [long](/API_docs/types/long.html), 'protocol' => [PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), 'receive_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$phoneConnection](/API_docs/constructors/phoneConnection.html) = \['tcp' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'ip' => [string](/API_docs/types/string.html), 'ipv6' => [string](/API_docs/types/string.html), 'port' => [int](/API_docs/types/int.html), 'peer_tag' => [string](/API_docs/types/string.html), \]; + +*** +

[$phoneConnectionWebrtc](/API_docs/constructors/phoneConnectionWebrtc.html) = \['turn' => [Bool](/API_docs/types/Bool.html), 'stun' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'ip' => [string](/API_docs/types/string.html), 'ipv6' => [string](/API_docs/types/string.html), 'port' => [int](/API_docs/types/int.html), 'username' => [string](/API_docs/types/string.html), 'password' => [string](/API_docs/types/string.html), \]; + +*** +

[$photo](/API_docs/constructors/photo.html) = \['has_stickers' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'file_reference' => [bytes](/API_docs/types/bytes.html), 'date' => [int](/API_docs/types/int.html), 'sizes' => \[[PhotoSize](/API_docs/types/PhotoSize.html)\], 'video_sizes' => \[[VideoSize](/API_docs/types/VideoSize.html)\], 'dc_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$photoCachedSize\_23](/API_docs/constructors/photoCachedSize_23.html) = \['type' => [string](/API_docs/types/string.html), 'location' => [FileLocation](/API_docs/types/FileLocation.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$photoEmpty](/API_docs/constructors/photoEmpty.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$photoPathSize](/API_docs/constructors/photoPathSize.html) = \['type' => [string](/API_docs/types/string.html), 'bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$photoSize\_23](/API_docs/constructors/photoSize_23.html) = \['type' => [string](/API_docs/types/string.html), 'location' => [FileLocation](/API_docs/types/FileLocation.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'size' => [int](/API_docs/types/int.html), \]; + +*** +

[$photoSizeEmpty](/API_docs/constructors/photoSizeEmpty.html) = \['type' => [string](/API_docs/types/string.html), \]; + +*** +

[$photoSizeProgressive](/API_docs/constructors/photoSizeProgressive.html) = \['type' => [string](/API_docs/types/string.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'sizes' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$photoStrippedSize](/API_docs/constructors/photoStrippedSize.html) = \['type' => [string](/API_docs/types/string.html), 'bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$photos.photo](/API_docs/constructors/photos.photo.html) = \['photo' => [Photo](/API_docs/types/Photo.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$photos.photos](/API_docs/constructors/photos.photos.html) = \['photos' => \[[Photo](/API_docs/types/Photo.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$photos.photosSlice](/API_docs/constructors/photos.photosSlice.html) = \['count' => [int](/API_docs/types/int.html), 'photos' => \[[Photo](/API_docs/types/Photo.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$poll](/API_docs/constructors/poll.html) = \['id' => [long](/API_docs/types/long.html), 'closed' => [Bool](/API_docs/types/Bool.html), 'public_voters' => [Bool](/API_docs/types/Bool.html), 'multiple_choice' => [Bool](/API_docs/types/Bool.html), 'quiz' => [Bool](/API_docs/types/Bool.html), 'question' => [TextWithEntities](/API_docs/types/TextWithEntities.html), 'answers' => \[[PollAnswer](/API_docs/types/PollAnswer.html)\], 'close_period' => [int](/API_docs/types/int.html), 'close_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$pollAnswer](/API_docs/constructors/pollAnswer.html) = \['text' => [TextWithEntities](/API_docs/types/TextWithEntities.html), 'option' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$pollAnswerVoters](/API_docs/constructors/pollAnswerVoters.html) = \['chosen' => [Bool](/API_docs/types/Bool.html), 'correct' => [Bool](/API_docs/types/Bool.html), 'option' => [bytes](/API_docs/types/bytes.html), 'voters' => [int](/API_docs/types/int.html), \]; + +*** +

[$pollResults](/API_docs/constructors/pollResults.html) = \['min' => [Bool](/API_docs/types/Bool.html), 'results' => \[[PollAnswerVoters](/API_docs/types/PollAnswerVoters.html)\], 'total_voters' => [int](/API_docs/types/int.html), 'recent_voters' => \[[Peer](/API_docs/types/Peer.html)\], 'solution' => [string](/API_docs/types/string.html), 'solution_entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], \]; + +*** +

[$popularContact](/API_docs/constructors/popularContact.html) = \['client_id' => [long](/API_docs/types/long.html), 'importers' => [int](/API_docs/types/int.html), \]; + +*** +

[$postAddress](/API_docs/constructors/postAddress.html) = \['street_line1' => [string](/API_docs/types/string.html), 'street_line2' => [string](/API_docs/types/string.html), 'city' => [string](/API_docs/types/string.html), 'state' => [string](/API_docs/types/string.html), 'country_iso2' => [string](/API_docs/types/string.html), 'post_code' => [string](/API_docs/types/string.html), \]; + +*** +

[$postInteractionCountersMessage](/API_docs/constructors/postInteractionCountersMessage.html) = \['msg_id' => [int](/API_docs/types/int.html), 'views' => [int](/API_docs/types/int.html), 'forwards' => [int](/API_docs/types/int.html), 'reactions' => [int](/API_docs/types/int.html), \]; + +*** +

[$postInteractionCountersStory](/API_docs/constructors/postInteractionCountersStory.html) = \['story_id' => [int](/API_docs/types/int.html), 'views' => [int](/API_docs/types/int.html), 'forwards' => [int](/API_docs/types/int.html), 'reactions' => [int](/API_docs/types/int.html), \]; + +*** +

[$premium.boostsList](/API_docs/constructors/premium.boostsList.html) = \['count' => [int](/API_docs/types/int.html), 'boosts' => \[[Boost](/API_docs/types/Boost.html)\], 'next_offset' => [string](/API_docs/types/string.html), 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$premium.boostsStatus](/API_docs/constructors/premium.boostsStatus.html) = \['my_boost' => [Bool](/API_docs/types/Bool.html), 'level' => [int](/API_docs/types/int.html), 'current_level_boosts' => [int](/API_docs/types/int.html), 'boosts' => [int](/API_docs/types/int.html), 'gift_boosts' => [int](/API_docs/types/int.html), 'next_level_boosts' => [int](/API_docs/types/int.html), 'premium_audience' => [StatsPercentValue](/API_docs/types/StatsPercentValue.html), 'boost_url' => [string](/API_docs/types/string.html), 'prepaid_giveaways' => \[[PrepaidGiveaway](/API_docs/types/PrepaidGiveaway.html)\], 'my_boost_slots' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$premium.myBoosts](/API_docs/constructors/premium.myBoosts.html) = \['my_boosts' => \[[MyBoost](/API_docs/types/MyBoost.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$premiumGiftCodeOption](/API_docs/constructors/premiumGiftCodeOption.html) = \['users' => [int](/API_docs/types/int.html), 'months' => [int](/API_docs/types/int.html), 'store_product' => [string](/API_docs/types/string.html), 'store_quantity' => [int](/API_docs/types/int.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$premiumGiftOption](/API_docs/constructors/premiumGiftOption.html) = \['months' => [int](/API_docs/types/int.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), 'bot_url' => [string](/API_docs/types/string.html), 'store_product' => [string](/API_docs/types/string.html), \]; + +*** +

[$premiumSubscriptionOption](/API_docs/constructors/premiumSubscriptionOption.html) = \['current' => [Bool](/API_docs/types/Bool.html), 'can_purchase_upgrade' => [Bool](/API_docs/types/Bool.html), 'transaction' => [string](/API_docs/types/string.html), 'months' => [int](/API_docs/types/int.html), 'currency' => [string](/API_docs/types/string.html), 'amount' => [long](/API_docs/types/long.html), 'bot_url' => [string](/API_docs/types/string.html), 'store_product' => [string](/API_docs/types/string.html), \]; + +*** +

[$prepaidGiveaway](/API_docs/constructors/prepaidGiveaway.html) = \['id' => [long](/API_docs/types/long.html), 'months' => [int](/API_docs/types/int.html), 'quantity' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$privacyKeyAbout](/API_docs/constructors/privacyKeyAbout.html) = \[\]; + +*** +

[$privacyKeyAddedByPhone](/API_docs/constructors/privacyKeyAddedByPhone.html) = \[\]; + +*** +

[$privacyKeyBirthday](/API_docs/constructors/privacyKeyBirthday.html) = \[\]; + +*** +

[$privacyKeyChatInvite](/API_docs/constructors/privacyKeyChatInvite.html) = \[\]; + +*** +

[$privacyKeyForwards](/API_docs/constructors/privacyKeyForwards.html) = \[\]; + +*** +

[$privacyKeyPhoneCall](/API_docs/constructors/privacyKeyPhoneCall.html) = \[\]; + +*** +

[$privacyKeyPhoneNumber](/API_docs/constructors/privacyKeyPhoneNumber.html) = \[\]; + +*** +

[$privacyKeyPhoneP2P](/API_docs/constructors/privacyKeyPhoneP2P.html) = \[\]; + +*** +

[$privacyKeyProfilePhoto](/API_docs/constructors/privacyKeyProfilePhoto.html) = \[\]; + +*** +

[$privacyKeyStatusTimestamp](/API_docs/constructors/privacyKeyStatusTimestamp.html) = \[\]; + +*** +

[$privacyKeyVoiceMessages](/API_docs/constructors/privacyKeyVoiceMessages.html) = \[\]; + +*** +

[$privacyValueAllowAll](/API_docs/constructors/privacyValueAllowAll.html) = \[\]; + +*** +

[$privacyValueAllowChatParticipants](/API_docs/constructors/privacyValueAllowChatParticipants.html) = \['chats' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$privacyValueAllowCloseFriends](/API_docs/constructors/privacyValueAllowCloseFriends.html) = \[\]; + +*** +

[$privacyValueAllowContacts](/API_docs/constructors/privacyValueAllowContacts.html) = \[\]; + +*** +

[$privacyValueAllowPremium](/API_docs/constructors/privacyValueAllowPremium.html) = \[\]; + +*** +

[$privacyValueAllowUsers](/API_docs/constructors/privacyValueAllowUsers.html) = \['users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$privacyValueDisallowAll](/API_docs/constructors/privacyValueDisallowAll.html) = \[\]; + +*** +

[$privacyValueDisallowChatParticipants](/API_docs/constructors/privacyValueDisallowChatParticipants.html) = \['chats' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$privacyValueDisallowContacts](/API_docs/constructors/privacyValueDisallowContacts.html) = \[\]; + +*** +

[$privacyValueDisallowUsers](/API_docs/constructors/privacyValueDisallowUsers.html) = \['users' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$publicForwardMessage](/API_docs/constructors/publicForwardMessage.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$publicForwardStory](/API_docs/constructors/publicForwardStory.html) = \['peer' => [long](/API_docs/types/long.html), 'story' => [StoryItem](/API_docs/types/StoryItem.html), \]; + +*** +

[$quickReply](/API_docs/constructors/quickReply.html) = \['shortcut_id' => [int](/API_docs/types/int.html), 'shortcut' => [string](/API_docs/types/string.html), 'top_message' => [int](/API_docs/types/int.html), 'count' => [int](/API_docs/types/int.html), \]; + +*** +

[$reactionCount](/API_docs/constructors/reactionCount.html) = \['chosen_order' => [int](/API_docs/types/int.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), 'count' => [int](/API_docs/types/int.html), \]; + +*** +

[$reactionCustomEmoji](/API_docs/constructors/reactionCustomEmoji.html) = \['document_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$reactionEmoji](/API_docs/constructors/reactionEmoji.html) = \['emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$reactionEmpty](/API_docs/constructors/reactionEmpty.html) = \[\]; + +*** +

[$reactionNotificationsFromAll](/API_docs/constructors/reactionNotificationsFromAll.html) = \[\]; + +*** +

[$reactionNotificationsFromContacts](/API_docs/constructors/reactionNotificationsFromContacts.html) = \[\]; + +*** +

[$reactionsNotifySettings](/API_docs/constructors/reactionsNotifySettings.html) = \['messages_notify_from' => [ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html), 'stories_notify_from' => [ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html), 'sound' => [NotificationSound](/API_docs/types/NotificationSound.html), 'show_previews' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$readParticipantDate](/API_docs/constructors/readParticipantDate.html) = \['user_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$receivedNotifyMessage](/API_docs/constructors/receivedNotifyMessage.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$recentMeUrlChat](/API_docs/constructors/recentMeUrlChat.html) = \['url' => [string](/API_docs/types/string.html), 'chat_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$recentMeUrlChatInvite](/API_docs/constructors/recentMeUrlChatInvite.html) = \['url' => [string](/API_docs/types/string.html), 'chat_invite' => [ChatInvite](/API_docs/types/ChatInvite.html), \]; + +*** +

[$recentMeUrlStickerSet](/API_docs/constructors/recentMeUrlStickerSet.html) = \['url' => [string](/API_docs/types/string.html), 'set' => [StickerSetCovered](/API_docs/types/StickerSetCovered.html), \]; + +*** +

[$recentMeUrlUnknown](/API_docs/constructors/recentMeUrlUnknown.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$recentMeUrlUser](/API_docs/constructors/recentMeUrlUser.html) = \['url' => [string](/API_docs/types/string.html), 'user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$replyInlineMarkup](/API_docs/constructors/replyInlineMarkup.html) = \['rows' => \[[KeyboardButtonRow](/API_docs/types/KeyboardButtonRow.html)\], \]; + +*** +

[$replyKeyboardForceReply](/API_docs/constructors/replyKeyboardForceReply.html) = \['single_use' => [Bool](/API_docs/types/Bool.html), 'selective' => [Bool](/API_docs/types/Bool.html), 'placeholder' => [string](/API_docs/types/string.html), \]; + +*** +

[$replyKeyboardHide](/API_docs/constructors/replyKeyboardHide.html) = \['selective' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$replyKeyboardMarkup](/API_docs/constructors/replyKeyboardMarkup.html) = \['resize' => [Bool](/API_docs/types/Bool.html), 'single_use' => [Bool](/API_docs/types/Bool.html), 'selective' => [Bool](/API_docs/types/Bool.html), 'persistent' => [Bool](/API_docs/types/Bool.html), 'rows' => \[[KeyboardButtonRow](/API_docs/types/KeyboardButtonRow.html)\], 'placeholder' => [string](/API_docs/types/string.html), \]; + +*** +

[$requestPeerTypeBroadcast](/API_docs/constructors/requestPeerTypeBroadcast.html) = \['creator' => [Bool](/API_docs/types/Bool.html), 'has_username' => [Bool](/API_docs/types/Bool.html), 'user_admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'bot_admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), \]; + +*** +

[$requestPeerTypeChat](/API_docs/constructors/requestPeerTypeChat.html) = \['creator' => [Bool](/API_docs/types/Bool.html), 'bot_participant' => [Bool](/API_docs/types/Bool.html), 'has_username' => [Bool](/API_docs/types/Bool.html), 'forum' => [Bool](/API_docs/types/Bool.html), 'user_admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'bot_admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), \]; + +*** +

[$requestPeerTypeUser](/API_docs/constructors/requestPeerTypeUser.html) = \['bot' => [Bool](/API_docs/types/Bool.html), 'premium' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$requestedPeerChannel](/API_docs/constructors/requestedPeerChannel.html) = \['channel_id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'username' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), \]; + +*** +

[$requestedPeerChat](/API_docs/constructors/requestedPeerChat.html) = \['chat_id' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), \]; + +*** +

[$requestedPeerUser](/API_docs/constructors/requestedPeerUser.html) = \['user_id' => [long](/API_docs/types/long.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'username' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), \]; + +*** +

[$restrictionReason](/API_docs/constructors/restrictionReason.html) = \['platform' => [string](/API_docs/types/string.html), 'reason' => [string](/API_docs/types/string.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$savedDialog](/API_docs/constructors/savedDialog.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'top_message' => [int](/API_docs/types/int.html), \]; + +*** +

[$savedPhoneContact](/API_docs/constructors/savedPhoneContact.html) = \['phone' => [string](/API_docs/types/string.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$savedReactionTag](/API_docs/constructors/savedReactionTag.html) = \['reaction' => [Reaction](/API_docs/types/Reaction.html), 'title' => [string](/API_docs/types/string.html), 'count' => [int](/API_docs/types/int.html), \]; + +*** +

[$searchResultPosition](/API_docs/constructors/searchResultPosition.html) = \['msg_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'offset' => [int](/API_docs/types/int.html), \]; + +*** +

[$searchResultsCalendarPeriod](/API_docs/constructors/searchResultsCalendarPeriod.html) = \['date' => [int](/API_docs/types/int.html), 'min_msg_id' => [int](/API_docs/types/int.html), 'max_msg_id' => [int](/API_docs/types/int.html), 'count' => [int](/API_docs/types/int.html), \]; + +*** +

[$secureCredentialsEncrypted](/API_docs/constructors/secureCredentialsEncrypted.html) = \['data' => [bytes](/API_docs/types/bytes.html), 'hash' => [bytes](/API_docs/types/bytes.html), 'secret' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$secureData](/API_docs/constructors/secureData.html) = \['data' => [bytes](/API_docs/types/bytes.html), 'data_hash' => [bytes](/API_docs/types/bytes.html), 'secret' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$secureFile](/API_docs/constructors/secureFile.html) = \['id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'size' => [long](/API_docs/types/long.html), 'dc_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'secret' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$secureFileEmpty](/API_docs/constructors/secureFileEmpty.html) = \[\]; + +*** +

[$securePasswordKdfAlgoPBKDF2HMACSHA512iter100000](/API_docs/constructors/securePasswordKdfAlgoPBKDF2HMACSHA512iter100000.html) = \['salt' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$securePasswordKdfAlgoSHA512](/API_docs/constructors/securePasswordKdfAlgoSHA512.html) = \['salt' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$securePasswordKdfAlgoUnknown](/API_docs/constructors/securePasswordKdfAlgoUnknown.html) = \[\]; + +*** +

[$securePlainEmail](/API_docs/constructors/securePlainEmail.html) = \['email' => [string](/API_docs/types/string.html), \]; + +*** +

[$securePlainPhone](/API_docs/constructors/securePlainPhone.html) = \['phone' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureRequiredType](/API_docs/constructors/secureRequiredType.html) = \['native_names' => [Bool](/API_docs/types/Bool.html), 'selfie_required' => [Bool](/API_docs/types/Bool.html), 'translation_required' => [Bool](/API_docs/types/Bool.html), 'type' => [SecureValueType](/API_docs/types/SecureValueType.html), \]; + +*** +

[$secureRequiredTypeOneOf](/API_docs/constructors/secureRequiredTypeOneOf.html) = \['types' => \[[SecureRequiredType](/API_docs/types/SecureRequiredType.html)\], \]; + +*** +

[$secureSecretSettings](/API_docs/constructors/secureSecretSettings.html) = \['secure_algo' => [SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html), 'secure_secret' => [bytes](/API_docs/types/bytes.html), 'secure_secret_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$secureValue](/API_docs/constructors/secureValue.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'data' => [SecureData](/API_docs/types/SecureData.html), 'front_side' => [SecureFile](/API_docs/types/SecureFile.html), 'reverse_side' => [SecureFile](/API_docs/types/SecureFile.html), 'selfie' => [SecureFile](/API_docs/types/SecureFile.html), 'translation' => \[[SecureFile](/API_docs/types/SecureFile.html)\], 'files' => \[[SecureFile](/API_docs/types/SecureFile.html)\], 'plain_data' => [SecurePlainData](/API_docs/types/SecurePlainData.html), 'hash' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$secureValueError](/API_docs/constructors/secureValueError.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'hash' => [bytes](/API_docs/types/bytes.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorData](/API_docs/constructors/secureValueErrorData.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'data_hash' => [bytes](/API_docs/types/bytes.html), 'field' => [string](/API_docs/types/string.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorFile](/API_docs/constructors/secureValueErrorFile.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorFiles](/API_docs/constructors/secureValueErrorFiles.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => \[[bytes](/API_docs/types/bytes.html)\], 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorFrontSide](/API_docs/constructors/secureValueErrorFrontSide.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorReverseSide](/API_docs/constructors/secureValueErrorReverseSide.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorSelfie](/API_docs/constructors/secureValueErrorSelfie.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorTranslationFile](/API_docs/constructors/secureValueErrorTranslationFile.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => [bytes](/API_docs/types/bytes.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueErrorTranslationFiles](/API_docs/constructors/secureValueErrorTranslationFiles.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'file_hash' => \[[bytes](/API_docs/types/bytes.html)\], 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$secureValueHash](/API_docs/constructors/secureValueHash.html) = \['type' => [SecureValueType](/API_docs/types/SecureValueType.html), 'hash' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$secureValueTypeAddress](/API_docs/constructors/secureValueTypeAddress.html) = \[\]; + +*** +

[$secureValueTypeBankStatement](/API_docs/constructors/secureValueTypeBankStatement.html) = \[\]; + +*** +

[$secureValueTypeDriverLicense](/API_docs/constructors/secureValueTypeDriverLicense.html) = \[\]; + +*** +

[$secureValueTypeEmail](/API_docs/constructors/secureValueTypeEmail.html) = \[\]; + +*** +

[$secureValueTypeIdentityCard](/API_docs/constructors/secureValueTypeIdentityCard.html) = \[\]; + +*** +

[$secureValueTypeInternalPassport](/API_docs/constructors/secureValueTypeInternalPassport.html) = \[\]; + +*** +

[$secureValueTypePassport](/API_docs/constructors/secureValueTypePassport.html) = \[\]; + +*** +

[$secureValueTypePassportRegistration](/API_docs/constructors/secureValueTypePassportRegistration.html) = \[\]; + +*** +

[$secureValueTypePersonalDetails](/API_docs/constructors/secureValueTypePersonalDetails.html) = \[\]; + +*** +

[$secureValueTypePhone](/API_docs/constructors/secureValueTypePhone.html) = \[\]; + +*** +

[$secureValueTypeRentalAgreement](/API_docs/constructors/secureValueTypeRentalAgreement.html) = \[\]; + +*** +

[$secureValueTypeTemporaryRegistration](/API_docs/constructors/secureValueTypeTemporaryRegistration.html) = \[\]; + +*** +

[$secureValueTypeUtilityBill](/API_docs/constructors/secureValueTypeUtilityBill.html) = \[\]; + +*** +

[$sendAsPeer](/API_docs/constructors/sendAsPeer.html) = \['premium_required' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), \]; + +*** +

[$sendMessageCancelAction](/API_docs/constructors/sendMessageCancelAction.html) = \[\]; + +*** +

[$sendMessageChooseContactAction](/API_docs/constructors/sendMessageChooseContactAction.html) = \[\]; + +*** +

[$sendMessageChooseStickerAction](/API_docs/constructors/sendMessageChooseStickerAction.html) = \[\]; + +*** +

[$sendMessageEmojiInteraction](/API_docs/constructors/sendMessageEmojiInteraction.html) = \['emoticon' => [string](/API_docs/types/string.html), 'msg_id' => [int](/API_docs/types/int.html), 'interaction' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$sendMessageEmojiInteractionSeen](/API_docs/constructors/sendMessageEmojiInteractionSeen.html) = \['emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$sendMessageGamePlayAction](/API_docs/constructors/sendMessageGamePlayAction.html) = \[\]; + +*** +

[$sendMessageGeoLocationAction](/API_docs/constructors/sendMessageGeoLocationAction.html) = \[\]; + +*** +

[$sendMessageHistoryImportAction](/API_docs/constructors/sendMessageHistoryImportAction.html) = \['progress' => [int](/API_docs/types/int.html), \]; + +*** +

[$sendMessageRecordAudioAction](/API_docs/constructors/sendMessageRecordAudioAction.html) = \[\]; + +*** +

[$sendMessageRecordRoundAction](/API_docs/constructors/sendMessageRecordRoundAction.html) = \[\]; + +*** +

[$sendMessageRecordVideoAction](/API_docs/constructors/sendMessageRecordVideoAction.html) = \[\]; + +*** +

[$sendMessageTypingAction](/API_docs/constructors/sendMessageTypingAction.html) = \[\]; + +*** +

[$sendMessageUploadAudioAction\_17](/API_docs/constructors/sendMessageUploadAudioAction_17.html) = \[\]; + +*** +

[$sendMessageUploadDocumentAction\_17](/API_docs/constructors/sendMessageUploadDocumentAction_17.html) = \[\]; + +*** +

[$sendMessageUploadPhotoAction\_17](/API_docs/constructors/sendMessageUploadPhotoAction_17.html) = \[\]; + +*** +

[$sendMessageUploadRoundAction\_66](/API_docs/constructors/sendMessageUploadRoundAction_66.html) = \[\]; + +*** +

[$sendMessageUploadVideoAction\_17](/API_docs/constructors/sendMessageUploadVideoAction_17.html) = \[\]; + +*** +

[$shippingOption](/API_docs/constructors/shippingOption.html) = \['id' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'prices' => \[[LabeledPrice](/API_docs/types/LabeledPrice.html)\], \]; + +*** +

[$simpleWebViewResultUrl](/API_docs/constructors/simpleWebViewResultUrl.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$smsJob](/API_docs/constructors/smsJob.html) = \['job_id' => [string](/API_docs/types/string.html), 'phone_number' => [string](/API_docs/types/string.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$smsjobs.eligibleToJoin](/API_docs/constructors/smsjobs.eligibleToJoin.html) = \['terms_url' => [string](/API_docs/types/string.html), 'monthly_sent_sms' => [int](/API_docs/types/int.html), \]; + +*** +

[$smsjobs.status](/API_docs/constructors/smsjobs.status.html) = \['allow_international' => [Bool](/API_docs/types/Bool.html), 'recent_sent' => [int](/API_docs/types/int.html), 'recent_since' => [int](/API_docs/types/int.html), 'recent_remains' => [int](/API_docs/types/int.html), 'total_sent' => [int](/API_docs/types/int.html), 'total_since' => [int](/API_docs/types/int.html), 'last_gift_slug' => [string](/API_docs/types/string.html), 'terms_url' => [string](/API_docs/types/string.html), \]; + +*** +

[$speakingInGroupCallAction](/API_docs/constructors/speakingInGroupCallAction.html) = \[\]; + +*** +

[$sponsoredMessage](/API_docs/constructors/sponsoredMessage.html) = \['recommended' => [Bool](/API_docs/types/Bool.html), 'can_report' => [Bool](/API_docs/types/Bool.html), 'url' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'message' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'photo' => [Photo](/API_docs/types/Photo.html), 'color' => [PeerColor](/API_docs/types/PeerColor.html), 'button_text' => [string](/API_docs/types/string.html), 'sponsor_info' => [string](/API_docs/types/string.html), 'additional_info' => [string](/API_docs/types/string.html), \]; + +*** +

[$sponsoredMessageReportOption](/API_docs/constructors/sponsoredMessageReportOption.html) = \['text' => [string](/API_docs/types/string.html), 'option' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$stats.broadcastRevenueStats](/API_docs/constructors/stats.broadcastRevenueStats.html) = \['top_hours_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'revenue_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'balances' => [BroadcastRevenueBalances](/API_docs/types/BroadcastRevenueBalances.html), 'usd_rate' => [double](/API_docs/types/double.html), \]; + +*** +

[$stats.broadcastRevenueTransactions](/API_docs/constructors/stats.broadcastRevenueTransactions.html) = \['count' => [int](/API_docs/types/int.html), 'transactions' => \[[BroadcastRevenueTransaction](/API_docs/types/BroadcastRevenueTransaction.html)\], \]; + +*** +

[$stats.broadcastRevenueWithdrawalUrl](/API_docs/constructors/stats.broadcastRevenueWithdrawalUrl.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$stats.broadcastStats](/API_docs/constructors/stats.broadcastStats.html) = \['period' => [StatsDateRangeDays](/API_docs/types/StatsDateRangeDays.html), 'followers' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'views_per_post' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'shares_per_post' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'reactions_per_post' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'views_per_story' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'shares_per_story' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'reactions_per_story' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'enabled_notifications' => [StatsPercentValue](/API_docs/types/StatsPercentValue.html), 'growth_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'followers_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'mute_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'top_hours_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'interactions_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'iv_interactions_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'views_by_source_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'new_followers_by_source_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'languages_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'reactions_by_emotion_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'story_interactions_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'story_reactions_by_emotion_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'recent_posts_interactions' => \[[PostInteractionCounters](/API_docs/types/PostInteractionCounters.html)\], \]; + +*** +

[$stats.megagroupStats](/API_docs/constructors/stats.megagroupStats.html) = \['period' => [StatsDateRangeDays](/API_docs/types/StatsDateRangeDays.html), 'members' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'messages' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'viewers' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'posters' => [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html), 'growth_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'members_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'new_members_by_source_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'languages_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'messages_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'actions_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'top_hours_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'weekdays_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'top_posters' => \[[StatsGroupTopPoster](/API_docs/types/StatsGroupTopPoster.html)\], 'top_admins' => \[[StatsGroupTopAdmin](/API_docs/types/StatsGroupTopAdmin.html)\], 'top_inviters' => \[[StatsGroupTopInviter](/API_docs/types/StatsGroupTopInviter.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$stats.messageStats](/API_docs/constructors/stats.messageStats.html) = \['views_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'reactions_by_emotion_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), \]; + +*** +

[$stats.publicForwards](/API_docs/constructors/stats.publicForwards.html) = \['count' => [int](/API_docs/types/int.html), 'forwards' => \[[PublicForward](/API_docs/types/PublicForward.html)\], 'next_offset' => [string](/API_docs/types/string.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$stats.storyStats](/API_docs/constructors/stats.storyStats.html) = \['views_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), 'reactions_by_emotion_graph' => [StatsGraph](/API_docs/types/StatsGraph.html), \]; + +*** +

[$statsAbsValueAndPrev](/API_docs/constructors/statsAbsValueAndPrev.html) = \['current' => [double](/API_docs/types/double.html), 'previous' => [double](/API_docs/types/double.html), \]; + +*** +

[$statsDateRangeDays](/API_docs/constructors/statsDateRangeDays.html) = \['min_date' => [int](/API_docs/types/int.html), 'max_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$statsGraph](/API_docs/constructors/statsGraph.html) = \['json' => [DataJSON](/API_docs/types/DataJSON.html), 'zoom_token' => [string](/API_docs/types/string.html), \]; + +*** +

[$statsGraphAsync](/API_docs/constructors/statsGraphAsync.html) = \['token' => [string](/API_docs/types/string.html), \]; + +*** +

[$statsGraphError](/API_docs/constructors/statsGraphError.html) = \['error' => [string](/API_docs/types/string.html), \]; + +*** +

[$statsGroupTopAdmin](/API_docs/constructors/statsGroupTopAdmin.html) = \['user_id' => [long](/API_docs/types/long.html), 'deleted' => [int](/API_docs/types/int.html), 'kicked' => [int](/API_docs/types/int.html), 'banned' => [int](/API_docs/types/int.html), \]; + +*** +

[$statsGroupTopInviter](/API_docs/constructors/statsGroupTopInviter.html) = \['user_id' => [long](/API_docs/types/long.html), 'invitations' => [int](/API_docs/types/int.html), \]; + +*** +

[$statsGroupTopPoster](/API_docs/constructors/statsGroupTopPoster.html) = \['user_id' => [long](/API_docs/types/long.html), 'messages' => [int](/API_docs/types/int.html), 'avg_chars' => [int](/API_docs/types/int.html), \]; + +*** +

[$statsPercentValue](/API_docs/constructors/statsPercentValue.html) = \['part' => [double](/API_docs/types/double.html), 'total' => [double](/API_docs/types/double.html), \]; + +*** +

[$statsURL](/API_docs/constructors/statsURL.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$stickerKeyword](/API_docs/constructors/stickerKeyword.html) = \['document_id' => [long](/API_docs/types/long.html), 'keyword' => \[[string](/API_docs/types/string.html)\], \]; + +*** +

[$stickerPack](/API_docs/constructors/stickerPack.html) = \['emoticon' => [string](/API_docs/types/string.html), 'documents' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$stickerSet](/API_docs/constructors/stickerSet.html) = \['archived' => [Bool](/API_docs/types/Bool.html), 'official' => [Bool](/API_docs/types/Bool.html), 'masks' => [Bool](/API_docs/types/Bool.html), 'emojis' => [Bool](/API_docs/types/Bool.html), 'text_color' => [Bool](/API_docs/types/Bool.html), 'channel_emoji_status' => [Bool](/API_docs/types/Bool.html), 'creator' => [Bool](/API_docs/types/Bool.html), 'installed_date' => [int](/API_docs/types/int.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'title' => [string](/API_docs/types/string.html), 'short_name' => [string](/API_docs/types/string.html), 'thumbs' => \[[PhotoSize](/API_docs/types/PhotoSize.html)\], 'thumb_dc_id' => [int](/API_docs/types/int.html), 'thumb_version' => [int](/API_docs/types/int.html), 'thumb_document_id' => [long](/API_docs/types/long.html), 'count' => [int](/API_docs/types/int.html), 'hash' => [int](/API_docs/types/int.html), \]; + +*** +

[$stickerSetCovered](/API_docs/constructors/stickerSetCovered.html) = \['set' => [StickerSet](/API_docs/types/StickerSet.html), 'cover' => [Document](/API_docs/types/Document.html), \]; + +*** +

[$stickerSetFullCovered](/API_docs/constructors/stickerSetFullCovered.html) = \['set' => [StickerSet](/API_docs/types/StickerSet.html), 'packs' => \[[StickerPack](/API_docs/types/StickerPack.html)\], 'keywords' => \[[StickerKeyword](/API_docs/types/StickerKeyword.html)\], 'documents' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$stickerSetMultiCovered](/API_docs/constructors/stickerSetMultiCovered.html) = \['set' => [StickerSet](/API_docs/types/StickerSet.html), 'covers' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$stickerSetNoCovered](/API_docs/constructors/stickerSetNoCovered.html) = \['set' => [StickerSet](/API_docs/types/StickerSet.html), \]; + +*** +

[$stickers.suggestedShortName](/API_docs/constructors/stickers.suggestedShortName.html) = \['short_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$storage.fileGif](/API_docs/constructors/storage.fileGif.html) = \[\]; + +*** +

[$storage.fileJpeg](/API_docs/constructors/storage.fileJpeg.html) = \[\]; + +*** +

[$storage.fileMov](/API_docs/constructors/storage.fileMov.html) = \[\]; + +*** +

[$storage.fileMp3](/API_docs/constructors/storage.fileMp3.html) = \[\]; + +*** +

[$storage.fileMp4](/API_docs/constructors/storage.fileMp4.html) = \[\]; + +*** +

[$storage.filePartial](/API_docs/constructors/storage.filePartial.html) = \[\]; + +*** +

[$storage.filePdf](/API_docs/constructors/storage.filePdf.html) = \[\]; + +*** +

[$storage.filePng](/API_docs/constructors/storage.filePng.html) = \[\]; + +*** +

[$storage.fileUnknown](/API_docs/constructors/storage.fileUnknown.html) = \[\]; + +*** +

[$storage.fileWebp](/API_docs/constructors/storage.fileWebp.html) = \[\]; + +*** +

[$stories.allStories](/API_docs/constructors/stories.allStories.html) = \['has_more' => [Bool](/API_docs/types/Bool.html), 'count' => [int](/API_docs/types/int.html), 'state' => [string](/API_docs/types/string.html), 'peer_stories' => \[[PeerStories](/API_docs/types/PeerStories.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'stealth_mode' => [StoriesStealthMode](/API_docs/types/StoriesStealthMode.html), \]; + +*** +

[$stories.allStoriesNotModified](/API_docs/constructors/stories.allStoriesNotModified.html) = \['state' => [string](/API_docs/types/string.html), 'stealth_mode' => [StoriesStealthMode](/API_docs/types/StoriesStealthMode.html), \]; + +*** +

[$stories.peerStories](/API_docs/constructors/stories.peerStories.html) = \['stories' => [PeerStories](/API_docs/types/PeerStories.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$stories.stories](/API_docs/constructors/stories.stories.html) = \['count' => [int](/API_docs/types/int.html), 'stories' => \[[StoryItem](/API_docs/types/StoryItem.html)\], 'pinned_to_top' => \[[int](/API_docs/types/int.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$stories.storyReactionsList](/API_docs/constructors/stories.storyReactionsList.html) = \['count' => [int](/API_docs/types/int.html), 'reactions' => \[[StoryReaction](/API_docs/types/StoryReaction.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'next_offset' => [string](/API_docs/types/string.html), \]; + +*** +

[$stories.storyViews](/API_docs/constructors/stories.storyViews.html) = \['views' => \[[StoryViews](/API_docs/types/StoryViews.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$stories.storyViewsList](/API_docs/constructors/stories.storyViewsList.html) = \['count' => [int](/API_docs/types/int.html), 'views_count' => [int](/API_docs/types/int.html), 'forwards_count' => [int](/API_docs/types/int.html), 'reactions_count' => [int](/API_docs/types/int.html), 'views' => \[[StoryView](/API_docs/types/StoryView.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'next_offset' => [string](/API_docs/types/string.html), \]; + +*** +

[$storiesStealthMode](/API_docs/constructors/storiesStealthMode.html) = \['active_until_date' => [int](/API_docs/types/int.html), 'cooldown_until_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$storyFwdHeader](/API_docs/constructors/storyFwdHeader.html) = \['modified' => [Bool](/API_docs/types/Bool.html), 'from' => [Peer](/API_docs/types/Peer.html), 'from_name' => [string](/API_docs/types/string.html), 'story_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$storyItem](/API_docs/constructors/storyItem.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'public' => [Bool](/API_docs/types/Bool.html), 'close_friends' => [Bool](/API_docs/types/Bool.html), 'min' => [Bool](/API_docs/types/Bool.html), 'noforwards' => [Bool](/API_docs/types/Bool.html), 'edited' => [Bool](/API_docs/types/Bool.html), 'contacts' => [Bool](/API_docs/types/Bool.html), 'selected_contacts' => [Bool](/API_docs/types/Bool.html), 'out' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'fwd_from' => [StoryFwdHeader](/API_docs/types/StoryFwdHeader.html), 'expire_date' => [int](/API_docs/types/int.html), 'caption' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'media' => [MessageMedia](/API_docs/types/MessageMedia.html), 'media_areas' => \[[MediaArea](/API_docs/types/MediaArea.html)\], 'privacy' => \[[PrivacyRule](/API_docs/types/PrivacyRule.html)\], 'views' => [StoryViews](/API_docs/types/StoryViews.html), 'sent_reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$storyItemDeleted](/API_docs/constructors/storyItemDeleted.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$storyItemSkipped](/API_docs/constructors/storyItemSkipped.html) = \['close_friends' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'expire_date' => [int](/API_docs/types/int.html), \]; + +*** +

[$storyReaction](/API_docs/constructors/storyReaction.html) = \['peer_id' => [Peer](/API_docs/types/Peer.html), 'date' => [int](/API_docs/types/int.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$storyReactionPublicForward](/API_docs/constructors/storyReactionPublicForward.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$storyReactionPublicRepost](/API_docs/constructors/storyReactionPublicRepost.html) = \['peer_id' => [Peer](/API_docs/types/Peer.html), 'story' => [StoryItem](/API_docs/types/StoryItem.html), \]; + +*** +

[$storyView](/API_docs/constructors/storyView.html) = \['blocked' => [Bool](/API_docs/types/Bool.html), 'blocked_my_stories_from' => [Bool](/API_docs/types/Bool.html), 'user_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$storyViewPublicForward](/API_docs/constructors/storyViewPublicForward.html) = \['blocked' => [Bool](/API_docs/types/Bool.html), 'blocked_my_stories_from' => [Bool](/API_docs/types/Bool.html), 'message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$storyViewPublicRepost](/API_docs/constructors/storyViewPublicRepost.html) = \['blocked' => [Bool](/API_docs/types/Bool.html), 'blocked_my_stories_from' => [Bool](/API_docs/types/Bool.html), 'peer_id' => [Peer](/API_docs/types/Peer.html), 'story' => [StoryItem](/API_docs/types/StoryItem.html), \]; + +*** +

[$storyViews](/API_docs/constructors/storyViews.html) = \['has_viewers' => [Bool](/API_docs/types/Bool.html), 'views_count' => [int](/API_docs/types/int.html), 'forwards_count' => [int](/API_docs/types/int.html), 'reactions' => \[[ReactionCount](/API_docs/types/ReactionCount.html)\], 'reactions_count' => [int](/API_docs/types/int.html), 'recent_viewers' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$textAnchor](/API_docs/constructors/textAnchor.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'name' => [string](/API_docs/types/string.html), \]; + +*** +

[$textBold](/API_docs/constructors/textBold.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textConcat](/API_docs/constructors/textConcat.html) = \['texts' => \[[RichText](/API_docs/types/RichText.html)\], \]; + +*** +

[$textEmail](/API_docs/constructors/textEmail.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'email' => [string](/API_docs/types/string.html), \]; + +*** +

[$textEmpty](/API_docs/constructors/textEmpty.html) = \[\]; + +*** +

[$textFixed](/API_docs/constructors/textFixed.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textImage](/API_docs/constructors/textImage.html) = \['document_id' => [long](/API_docs/types/long.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), \]; + +*** +

[$textItalic](/API_docs/constructors/textItalic.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textMarked](/API_docs/constructors/textMarked.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textPhone](/API_docs/constructors/textPhone.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'phone' => [string](/API_docs/types/string.html), \]; + +*** +

[$textPlain](/API_docs/constructors/textPlain.html) = \['text' => [string](/API_docs/types/string.html), \]; + +*** +

[$textStrike](/API_docs/constructors/textStrike.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textSubscript](/API_docs/constructors/textSubscript.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textSuperscript](/API_docs/constructors/textSuperscript.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textUnderline](/API_docs/constructors/textUnderline.html) = \['text' => [RichText](/API_docs/types/RichText.html), \]; + +*** +

[$textUrl](/API_docs/constructors/textUrl.html) = \['text' => [RichText](/API_docs/types/RichText.html), 'url' => [string](/API_docs/types/string.html), 'webpage_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$textWithEntities](/API_docs/constructors/textWithEntities.html) = \['text' => [string](/API_docs/types/string.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], \]; + +*** +

[$theme](/API_docs/constructors/theme.html) = \['creator' => [Bool](/API_docs/types/Bool.html), 'default' => [Bool](/API_docs/types/Bool.html), 'for_chat' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'slug' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'document' => [Document](/API_docs/types/Document.html), 'settings' => \[[ThemeSettings](/API_docs/types/ThemeSettings.html)\], 'emoticon' => [string](/API_docs/types/string.html), 'installs_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$themeSettings](/API_docs/constructors/themeSettings.html) = \['message_colors_animated' => [Bool](/API_docs/types/Bool.html), 'base_theme' => [BaseTheme](/API_docs/types/BaseTheme.html), 'accent_color' => [int](/API_docs/types/int.html), 'outbox_accent_color' => [int](/API_docs/types/int.html), 'message_colors' => \[[int](/API_docs/types/int.html)\], 'wallpaper' => [WallPaper](/API_docs/types/WallPaper.html), \]; + +*** +

[$timezone](/API_docs/constructors/timezone.html) = \['id' => [string](/API_docs/types/string.html), 'name' => [string](/API_docs/types/string.html), 'utc_offset' => [int](/API_docs/types/int.html), \]; + +*** +

[$topPeer](/API_docs/constructors/topPeer.html) = \['peer' => [long](/API_docs/types/long.html), 'rating' => [double](/API_docs/types/double.html), \]; + +*** +

[$topPeerCategoryBotsInline](/API_docs/constructors/topPeerCategoryBotsInline.html) = \[\]; + +*** +

[$topPeerCategoryBotsPM](/API_docs/constructors/topPeerCategoryBotsPM.html) = \[\]; + +*** +

[$topPeerCategoryChannels](/API_docs/constructors/topPeerCategoryChannels.html) = \[\]; + +*** +

[$topPeerCategoryCorrespondents](/API_docs/constructors/topPeerCategoryCorrespondents.html) = \[\]; + +*** +

[$topPeerCategoryForwardChats](/API_docs/constructors/topPeerCategoryForwardChats.html) = \[\]; + +*** +

[$topPeerCategoryForwardUsers](/API_docs/constructors/topPeerCategoryForwardUsers.html) = \[\]; + +*** +

[$topPeerCategoryGroups](/API_docs/constructors/topPeerCategoryGroups.html) = \[\]; + +*** +

[$topPeerCategoryPeers](/API_docs/constructors/topPeerCategoryPeers.html) = \['category' => [TopPeerCategory](/API_docs/types/TopPeerCategory.html), 'count' => [int](/API_docs/types/int.html), 'peers' => \[[TopPeer](/API_docs/types/TopPeer.html)\], \]; + +*** +

[$topPeerCategoryPhoneCalls](/API_docs/constructors/topPeerCategoryPhoneCalls.html) = \[\]; + +*** +

[$true](/API_docs/constructors/true.html) = \[\]; + +*** +

[$updateAttachMenuBots](/API_docs/constructors/updateAttachMenuBots.html) = \[\]; + +*** +

[$updateAutoSaveSettings](/API_docs/constructors/updateAutoSaveSettings.html) = \[\]; + +*** +

[$updateBotBusinessConnect](/API_docs/constructors/updateBotBusinessConnect.html) = \['connection' => [BotBusinessConnection](/API_docs/types/BotBusinessConnection.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotCallbackQuery](/API_docs/constructors/updateBotCallbackQuery.html) = \['query_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), 'chat_instance' => [long](/API_docs/types/long.html), 'data' => [bytes](/API_docs/types/bytes.html), 'game_short_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateBotChatBoost](/API_docs/constructors/updateBotChatBoost.html) = \['peer' => [long](/API_docs/types/long.html), 'boost' => [Boost](/API_docs/types/Boost.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotChatInviteRequester](/API_docs/constructors/updateBotChatInviteRequester.html) = \['peer' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), 'about' => [string](/API_docs/types/string.html), 'invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotCommands](/API_docs/constructors/updateBotCommands.html) = \['peer' => [long](/API_docs/types/long.html), 'bot_id' => [long](/API_docs/types/long.html), 'commands' => \[[BotCommand](/API_docs/types/BotCommand.html)\], \]; + +*** +

[$updateBotDeleteBusinessMessage](/API_docs/constructors/updateBotDeleteBusinessMessage.html) = \['connection_id' => [string](/API_docs/types/string.html), 'peer' => [long](/API_docs/types/long.html), 'messages' => \[[int](/API_docs/types/int.html)\], 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotEditBusinessMessage](/API_docs/constructors/updateBotEditBusinessMessage.html) = \['connection_id' => [string](/API_docs/types/string.html), 'message' => [Message](/API_docs/types/Message.html), 'reply_to_message' => [Message](/API_docs/types/Message.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotInlineQuery](/API_docs/constructors/updateBotInlineQuery.html) = \['query_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'query' => [string](/API_docs/types/string.html), 'geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'peer_type' => [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html), 'offset' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateBotInlineSend](/API_docs/constructors/updateBotInlineSend.html) = \['user_id' => [long](/API_docs/types/long.html), 'query' => [string](/API_docs/types/string.html), 'geo' => [GeoPoint](/API_docs/types/GeoPoint.html), 'id' => [string](/API_docs/types/string.html), 'msg_id' => [InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html), \]; + +*** +

[$updateBotMenuButton](/API_docs/constructors/updateBotMenuButton.html) = \['bot_id' => [long](/API_docs/types/long.html), 'button' => [BotMenuButton](/API_docs/types/BotMenuButton.html), \]; + +*** +

[$updateBotMessageReaction](/API_docs/constructors/updateBotMessageReaction.html) = \['peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'actor' => [Peer](/API_docs/types/Peer.html), 'old_reactions' => \[[Reaction](/API_docs/types/Reaction.html)\], 'new_reactions' => \[[Reaction](/API_docs/types/Reaction.html)\], 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotMessageReactions](/API_docs/constructors/updateBotMessageReactions.html) = \['peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'reactions' => \[[ReactionCount](/API_docs/types/ReactionCount.html)\], 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotNewBusinessMessage](/API_docs/constructors/updateBotNewBusinessMessage.html) = \['connection_id' => [string](/API_docs/types/string.html), 'message' => [Message](/API_docs/types/Message.html), 'reply_to_message' => [Message](/API_docs/types/Message.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotPrecheckoutQuery](/API_docs/constructors/updateBotPrecheckoutQuery.html) = \['query_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'payload' => [bytes](/API_docs/types/bytes.html), 'info' => [PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html), 'shipping_option_id' => [string](/API_docs/types/string.html), 'currency' => [string](/API_docs/types/string.html), 'total_amount' => [long](/API_docs/types/long.html), \]; + +*** +

[$updateBotShippingQuery](/API_docs/constructors/updateBotShippingQuery.html) = \['query_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'payload' => [bytes](/API_docs/types/bytes.html), 'shipping_address' => [PostAddress](/API_docs/types/PostAddress.html), \]; + +*** +

[$updateBotStopped](/API_docs/constructors/updateBotStopped.html) = \['user_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'stopped' => [Bool](/API_docs/types/Bool.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateBotWebhookJSON](/API_docs/constructors/updateBotWebhookJSON.html) = \['data' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$updateBotWebhookJSONQuery](/API_docs/constructors/updateBotWebhookJSONQuery.html) = \['query_id' => [long](/API_docs/types/long.html), 'data' => [DataJSON](/API_docs/types/DataJSON.html), 'timeout' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannel](/API_docs/constructors/updateChannel.html) = \['channel_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$updateChannelAvailableMessages](/API_docs/constructors/updateChannelAvailableMessages.html) = \['channel_id' => [long](/API_docs/types/long.html), 'available_min_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannelMessageForwards](/API_docs/constructors/updateChannelMessageForwards.html) = \['channel_id' => [long](/API_docs/types/long.html), 'id' => [int](/API_docs/types/int.html), 'forwards' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannelMessageViews](/API_docs/constructors/updateChannelMessageViews.html) = \['channel_id' => [long](/API_docs/types/long.html), 'id' => [int](/API_docs/types/int.html), 'views' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannelParticipant](/API_docs/constructors/updateChannelParticipant.html) = \['via_chatlist' => [Bool](/API_docs/types/Bool.html), 'channel_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'actor_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'prev_participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), 'new_participant' => [ChannelParticipant](/API_docs/types/ChannelParticipant.html), 'invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannelPinnedTopic](/API_docs/constructors/updateChannelPinnedTopic.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'channel_id' => [long](/API_docs/types/long.html), 'topic_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannelPinnedTopics](/API_docs/constructors/updateChannelPinnedTopics.html) = \['channel_id' => [long](/API_docs/types/long.html), 'order' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$updateChannelReadMessagesContents](/API_docs/constructors/updateChannelReadMessagesContents.html) = \['channel_id' => [long](/API_docs/types/long.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'messages' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$updateChannelTooLong](/API_docs/constructors/updateChannelTooLong.html) = \['channel_id' => [long](/API_docs/types/long.html), 'pts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChannelUserTyping](/API_docs/constructors/updateChannelUserTyping.html) = \['channel_id' => [long](/API_docs/types/long.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'action' => [SendMessageAction](/API_docs/types/SendMessageAction.html), \]; + +*** +

[$updateChannelViewForumAsMessages](/API_docs/constructors/updateChannelViewForumAsMessages.html) = \['channel_id' => [long](/API_docs/types/long.html), 'enabled' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$updateChannelWebPage](/API_docs/constructors/updateChannelWebPage.html) = \['channel_id' => [long](/API_docs/types/long.html), 'webpage' => [WebPage](/API_docs/types/WebPage.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChat](/API_docs/constructors/updateChat.html) = \['chat_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$updateChatDefaultBannedRights](/API_docs/constructors/updateChatDefaultBannedRights.html) = \['peer' => [long](/API_docs/types/long.html), 'default_banned_rights' => [ChatBannedRights](/API_docs/types/ChatBannedRights.html), 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChatParticipant](/API_docs/constructors/updateChatParticipant.html) = \['chat_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'actor_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'prev_participant' => [ChatParticipant](/API_docs/types/ChatParticipant.html), 'new_participant' => [ChatParticipant](/API_docs/types/ChatParticipant.html), 'invite' => [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChatParticipantAdd](/API_docs/constructors/updateChatParticipantAdd.html) = \['chat_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'inviter_id' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChatParticipantAdmin](/API_docs/constructors/updateChatParticipantAdmin.html) = \['chat_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'is_admin' => [Bool](/API_docs/types/Bool.html), 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChatParticipantDelete](/API_docs/constructors/updateChatParticipantDelete.html) = \['chat_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateChatParticipants](/API_docs/constructors/updateChatParticipants.html) = \['participants' => [ChatParticipants](/API_docs/types/ChatParticipants.html), \]; + +*** +

[$updateChatUserTyping](/API_docs/constructors/updateChatUserTyping.html) = \['chat_id' => [long](/API_docs/types/long.html), 'from_id' => [Peer](/API_docs/types/Peer.html), 'action' => [SendMessageAction](/API_docs/types/SendMessageAction.html), \]; + +*** +

[$updateConfig](/API_docs/constructors/updateConfig.html) = \[\]; + +*** +

[$updateContactsReset](/API_docs/constructors/updateContactsReset.html) = \[\]; + +*** +

[$updateDcOptions](/API_docs/constructors/updateDcOptions.html) = \['dc_options' => \[[DcOption](/API_docs/types/DcOption.html)\], \]; + +*** +

[$updateDeleteChannelMessages](/API_docs/constructors/updateDeleteChannelMessages.html) = \['channel_id' => [long](/API_docs/types/long.html), 'messages' => \[[int](/API_docs/types/int.html)\], 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateDeleteMessages](/API_docs/constructors/updateDeleteMessages.html) = \['messages' => \[[int](/API_docs/types/int.html)\], 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateDeleteQuickReply](/API_docs/constructors/updateDeleteQuickReply.html) = \['shortcut_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateDeleteQuickReplyMessages](/API_docs/constructors/updateDeleteQuickReplyMessages.html) = \['shortcut_id' => [int](/API_docs/types/int.html), 'messages' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$updateDeleteScheduledMessages](/API_docs/constructors/updateDeleteScheduledMessages.html) = \['peer' => [long](/API_docs/types/long.html), 'messages' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$updateDialogFilter](/API_docs/constructors/updateDialogFilter.html) = \['id' => [int](/API_docs/types/int.html), 'filter' => [DialogFilter](/API_docs/types/DialogFilter.html), \]; + +*** +

[$updateDialogFilterOrder](/API_docs/constructors/updateDialogFilterOrder.html) = \['order' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$updateDialogFilters](/API_docs/constructors/updateDialogFilters.html) = \[\]; + +*** +

[$updateDialogPinned](/API_docs/constructors/updateDialogPinned.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'folder_id' => [int](/API_docs/types/int.html), 'peer' => [DialogPeer](/API_docs/types/DialogPeer.html), \]; + +*** +

[$updateDialogUnreadMark](/API_docs/constructors/updateDialogUnreadMark.html) = \['unread' => [Bool](/API_docs/types/Bool.html), 'peer' => [DialogPeer](/API_docs/types/DialogPeer.html), \]; + +*** +

[$updateDraftMessage](/API_docs/constructors/updateDraftMessage.html) = \['peer' => [long](/API_docs/types/long.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'draft' => [DraftMessage](/API_docs/types/DraftMessage.html), \]; + +*** +

[$updateEditChannelMessage](/API_docs/constructors/updateEditChannelMessage.html) = \['message' => [Message](/API_docs/types/Message.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateEditMessage](/API_docs/constructors/updateEditMessage.html) = \['message' => [Message](/API_docs/types/Message.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateEncryptedChatTyping](/API_docs/constructors/updateEncryptedChatTyping.html) = \['chat_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateEncryptedMessagesRead](/API_docs/constructors/updateEncryptedMessagesRead.html) = \['chat_id' => [int](/API_docs/types/int.html), 'max_date' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateEncryption](/API_docs/constructors/updateEncryption.html) = \['chat' => [EncryptedChat](/API_docs/types/EncryptedChat.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateFavedStickers](/API_docs/constructors/updateFavedStickers.html) = \[\]; + +*** +

[$updateFolderPeers](/API_docs/constructors/updateFolderPeers.html) = \['folder_peers' => \[[FolderPeer](/API_docs/types/FolderPeer.html)\], 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateGeoLiveViewed](/API_docs/constructors/updateGeoLiveViewed.html) = \['peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateGroupCall](/API_docs/constructors/updateGroupCall.html) = \['chat_id' => [long](/API_docs/types/long.html), 'call' => [GroupCall](/API_docs/types/GroupCall.html), \]; + +*** +

[$updateGroupCallConnection](/API_docs/constructors/updateGroupCallConnection.html) = \['presentation' => [Bool](/API_docs/types/Bool.html), 'params' => [DataJSON](/API_docs/types/DataJSON.html), \]; + +*** +

[$updateGroupCallParticipants](/API_docs/constructors/updateGroupCallParticipants.html) = \['call' => [InputGroupCall](/API_docs/types/InputGroupCall.html), 'participants' => \[[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html)\], 'version' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateInlineBotCallbackQuery](/API_docs/constructors/updateInlineBotCallbackQuery.html) = \['query_id' => [long](/API_docs/types/long.html), 'user_id' => [long](/API_docs/types/long.html), 'msg_id' => [InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html), 'chat_instance' => [long](/API_docs/types/long.html), 'data' => [bytes](/API_docs/types/bytes.html), 'game_short_name' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateLangPack](/API_docs/constructors/updateLangPack.html) = \['difference' => [LangPackDifference](/API_docs/types/LangPackDifference.html), \]; + +*** +

[$updateLangPackTooLong](/API_docs/constructors/updateLangPackTooLong.html) = \['lang_code' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateLoginToken](/API_docs/constructors/updateLoginToken.html) = \[\]; + +*** +

[$updateMessageExtendedMedia](/API_docs/constructors/updateMessageExtendedMedia.html) = \['peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), 'extended_media' => [MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html), \]; + +*** +

[$updateMessageID](/API_docs/constructors/updateMessageID.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateMessagePoll](/API_docs/constructors/updateMessagePoll.html) = \['poll_id' => [long](/API_docs/types/long.html), 'poll' => [Poll](/API_docs/types/Poll.html), 'results' => [PollResults](/API_docs/types/PollResults.html), \]; + +*** +

[$updateMessagePollVote](/API_docs/constructors/updateMessagePollVote.html) = \['poll_id' => [long](/API_docs/types/long.html), 'peer' => [long](/API_docs/types/long.html), 'options' => \[[bytes](/API_docs/types/bytes.html)\], 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateMessageReactions](/API_docs/constructors/updateMessageReactions.html) = \['peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'reactions' => [MessageReactions](/API_docs/types/MessageReactions.html), \]; + +*** +

[$updateMoveStickerSetToTop](/API_docs/constructors/updateMoveStickerSetToTop.html) = \['masks' => [Bool](/API_docs/types/Bool.html), 'emojis' => [Bool](/API_docs/types/Bool.html), 'stickerset' => [long](/API_docs/types/long.html), \]; + +*** +

[$updateNewAuthorization](/API_docs/constructors/updateNewAuthorization.html) = \['unconfirmed' => [Bool](/API_docs/types/Bool.html), 'hash' => [long](/API_docs/types/long.html), 'date' => [int](/API_docs/types/int.html), 'device' => [string](/API_docs/types/string.html), 'location' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateNewChannelMessage](/API_docs/constructors/updateNewChannelMessage.html) = \['message' => [Message](/API_docs/types/Message.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateNewEncryptedMessage](/API_docs/constructors/updateNewEncryptedMessage.html) = \['message' => [EncryptedMessage](/API_docs/types/EncryptedMessage.html), 'qts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateNewMessage](/API_docs/constructors/updateNewMessage.html) = \['message' => [Message](/API_docs/types/Message.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateNewQuickReply](/API_docs/constructors/updateNewQuickReply.html) = \['quick_reply' => [QuickReply](/API_docs/types/QuickReply.html), \]; + +*** +

[$updateNewScheduledMessage](/API_docs/constructors/updateNewScheduledMessage.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$updateNewStickerSet](/API_docs/constructors/updateNewStickerSet.html) = \['stickerset' => [messages.StickerSet](/API_docs/types/messages.StickerSet.html), \]; + +*** +

[$updateNewStoryReaction](/API_docs/constructors/updateNewStoryReaction.html) = \['story_id' => [int](/API_docs/types/int.html), 'peer' => [long](/API_docs/types/long.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$updateNotifySettings](/API_docs/constructors/updateNotifySettings.html) = \['peer' => [NotifyPeer](/API_docs/types/NotifyPeer.html), 'notify_settings' => [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html), \]; + +*** +

[$updatePeerBlocked](/API_docs/constructors/updatePeerBlocked.html) = \['blocked' => [Bool](/API_docs/types/Bool.html), 'blocked_my_stories_from' => [Bool](/API_docs/types/Bool.html), 'peer_id' => [Peer](/API_docs/types/Peer.html), \]; + +*** +

[$updatePeerHistoryTTL](/API_docs/constructors/updatePeerHistoryTTL.html) = \['peer' => [long](/API_docs/types/long.html), 'ttl_period' => [int](/API_docs/types/int.html), \]; + +*** +

[$updatePeerLocated](/API_docs/constructors/updatePeerLocated.html) = \['peers' => \[[PeerLocated](/API_docs/types/PeerLocated.html)\], \]; + +*** +

[$updatePeerSettings](/API_docs/constructors/updatePeerSettings.html) = \['peer' => [long](/API_docs/types/long.html), 'settings' => [PeerSettings](/API_docs/types/PeerSettings.html), \]; + +*** +

[$updatePeerWallpaper](/API_docs/constructors/updatePeerWallpaper.html) = \['wallpaper_overridden' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'wallpaper' => [WallPaper](/API_docs/types/WallPaper.html), \]; + +*** +

[$updatePendingJoinRequests](/API_docs/constructors/updatePendingJoinRequests.html) = \['peer' => [long](/API_docs/types/long.html), 'requests_pending' => [int](/API_docs/types/int.html), 'recent_requesters' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$updatePhoneCall](/API_docs/constructors/updatePhoneCall.html) = \['phone_call' => [PhoneCall](/API_docs/types/PhoneCall.html), \]; + +*** +

[$updatePhoneCallSignalingData](/API_docs/constructors/updatePhoneCallSignalingData.html) = \['phone_call_id' => [long](/API_docs/types/long.html), 'data' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$updatePinnedChannelMessages](/API_docs/constructors/updatePinnedChannelMessages.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'channel_id' => [long](/API_docs/types/long.html), 'messages' => \[[int](/API_docs/types/int.html)\], 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updatePinnedDialogs](/API_docs/constructors/updatePinnedDialogs.html) = \['folder_id' => [int](/API_docs/types/int.html), 'order' => \[[DialogPeer](/API_docs/types/DialogPeer.html)\], \]; + +*** +

[$updatePinnedMessages](/API_docs/constructors/updatePinnedMessages.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'messages' => \[[int](/API_docs/types/int.html)\], 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updatePinnedSavedDialogs](/API_docs/constructors/updatePinnedSavedDialogs.html) = \['order' => \[[DialogPeer](/API_docs/types/DialogPeer.html)\], \]; + +*** +

[$updatePrivacy](/API_docs/constructors/updatePrivacy.html) = \['key' => [PrivacyKey](/API_docs/types/PrivacyKey.html), 'rules' => \[[PrivacyRule](/API_docs/types/PrivacyRule.html)\], \]; + +*** +

[$updatePtsChanged](/API_docs/constructors/updatePtsChanged.html) = \[\]; + +*** +

[$updateQuickReplies](/API_docs/constructors/updateQuickReplies.html) = \['quick_replies' => \[[QuickReply](/API_docs/types/QuickReply.html)\], \]; + +*** +

[$updateQuickReplyMessage](/API_docs/constructors/updateQuickReplyMessage.html) = \['message' => [Message](/API_docs/types/Message.html), \]; + +*** +

[$updateReadChannelDiscussionInbox](/API_docs/constructors/updateReadChannelDiscussionInbox.html) = \['channel_id' => [long](/API_docs/types/long.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'read_max_id' => [int](/API_docs/types/int.html), 'broadcast_id' => [long](/API_docs/types/long.html), 'broadcast_post' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadChannelDiscussionOutbox](/API_docs/constructors/updateReadChannelDiscussionOutbox.html) = \['channel_id' => [long](/API_docs/types/long.html), 'top_msg_id' => [int](/API_docs/types/int.html), 'read_max_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadChannelInbox](/API_docs/constructors/updateReadChannelInbox.html) = \['folder_id' => [int](/API_docs/types/int.html), 'channel_id' => [long](/API_docs/types/long.html), 'max_id' => [int](/API_docs/types/int.html), 'still_unread_count' => [int](/API_docs/types/int.html), 'pts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadChannelOutbox](/API_docs/constructors/updateReadChannelOutbox.html) = \['channel_id' => [long](/API_docs/types/long.html), 'max_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadFeaturedEmojiStickers](/API_docs/constructors/updateReadFeaturedEmojiStickers.html) = \[\]; + +*** +

[$updateReadFeaturedStickers](/API_docs/constructors/updateReadFeaturedStickers.html) = \[\]; + +*** +

[$updateReadHistoryInbox](/API_docs/constructors/updateReadHistoryInbox.html) = \['folder_id' => [int](/API_docs/types/int.html), 'peer' => [long](/API_docs/types/long.html), 'max_id' => [int](/API_docs/types/int.html), 'still_unread_count' => [int](/API_docs/types/int.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadHistoryOutbox](/API_docs/constructors/updateReadHistoryOutbox.html) = \['peer' => [long](/API_docs/types/long.html), 'max_id' => [int](/API_docs/types/int.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadMessagesContents](/API_docs/constructors/updateReadMessagesContents.html) = \['messages' => \[[int](/API_docs/types/int.html)\], 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateReadStories](/API_docs/constructors/updateReadStories.html) = \['peer' => [long](/API_docs/types/long.html), 'max_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateRecentEmojiStatuses](/API_docs/constructors/updateRecentEmojiStatuses.html) = \[\]; + +*** +

[$updateRecentReactions](/API_docs/constructors/updateRecentReactions.html) = \[\]; + +*** +

[$updateRecentStickers](/API_docs/constructors/updateRecentStickers.html) = \[\]; + +*** +

[$updateSavedDialogPinned](/API_docs/constructors/updateSavedDialogPinned.html) = \['pinned' => [Bool](/API_docs/types/Bool.html), 'peer' => [DialogPeer](/API_docs/types/DialogPeer.html), \]; + +*** +

[$updateSavedGifs](/API_docs/constructors/updateSavedGifs.html) = \[\]; + +*** +

[$updateSavedReactionTags](/API_docs/constructors/updateSavedReactionTags.html) = \[\]; + +*** +

[$updateSavedRingtones](/API_docs/constructors/updateSavedRingtones.html) = \[\]; + +*** +

[$updateSentStoryReaction](/API_docs/constructors/updateSentStoryReaction.html) = \['peer' => [long](/API_docs/types/long.html), 'story_id' => [int](/API_docs/types/int.html), 'reaction' => [Reaction](/API_docs/types/Reaction.html), \]; + +*** +

[$updateServiceNotification](/API_docs/constructors/updateServiceNotification.html) = \['popup' => [Bool](/API_docs/types/Bool.html), 'invert_media' => [Bool](/API_docs/types/Bool.html), 'inbox_date' => [int](/API_docs/types/int.html), 'type' => [string](/API_docs/types/string.html), 'message' => [string](/API_docs/types/string.html), 'media' => [MessageMedia](/API_docs/types/MessageMedia.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], \]; + +*** +

[$updateShort](/API_docs/constructors/updateShort.html) = \['update' => [Update](/API_docs/types/Update.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateShortChatMessage](/API_docs/constructors/updateShortChatMessage.html) = \['out' => [Bool](/API_docs/types/Bool.html), 'mentioned' => [Bool](/API_docs/types/Bool.html), 'media_unread' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'from_id' => [long](/API_docs/types/long.html), 'chat_id' => [long](/API_docs/types/long.html), 'message' => [string](/API_docs/types/string.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'fwd_from' => [MessageFwdHeader](/API_docs/types/MessageFwdHeader.html), 'via_bot_id' => [long](/API_docs/types/long.html), 'reply_to' => [MessageReplyHeader](/API_docs/types/MessageReplyHeader.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'ttl_period' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateShortMessage](/API_docs/constructors/updateShortMessage.html) = \['out' => [Bool](/API_docs/types/Bool.html), 'mentioned' => [Bool](/API_docs/types/Bool.html), 'media_unread' => [Bool](/API_docs/types/Bool.html), 'silent' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'user_id' => [long](/API_docs/types/long.html), 'message' => [string](/API_docs/types/string.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'fwd_from' => [MessageFwdHeader](/API_docs/types/MessageFwdHeader.html), 'via_bot_id' => [long](/API_docs/types/long.html), 'reply_to' => [MessageReplyHeader](/API_docs/types/MessageReplyHeader.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'ttl_period' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateShortSentMessage](/API_docs/constructors/updateShortSentMessage.html) = \['out' => [Bool](/API_docs/types/Bool.html), 'id' => [int](/API_docs/types/int.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'media' => [MessageMedia](/API_docs/types/MessageMedia.html), 'entities' => \[[MessageEntity](/API_docs/types/MessageEntity.html)\], 'ttl_period' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateSmsJob](/API_docs/constructors/updateSmsJob.html) = \['job_id' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateStickerSets](/API_docs/constructors/updateStickerSets.html) = \['masks' => [Bool](/API_docs/types/Bool.html), 'emojis' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$updateStickerSetsOrder](/API_docs/constructors/updateStickerSetsOrder.html) = \['masks' => [Bool](/API_docs/types/Bool.html), 'emojis' => [Bool](/API_docs/types/Bool.html), 'order' => \[[long](/API_docs/types/long.html)\], \]; + +*** +

[$updateStoriesStealthMode](/API_docs/constructors/updateStoriesStealthMode.html) = \['stealth_mode' => [StoriesStealthMode](/API_docs/types/StoriesStealthMode.html), \]; + +*** +

[$updateStory](/API_docs/constructors/updateStory.html) = \['peer' => [long](/API_docs/types/long.html), 'story' => [StoryItem](/API_docs/types/StoryItem.html), \]; + +*** +

[$updateStoryID](/API_docs/constructors/updateStoryID.html) = \['id' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateTheme](/API_docs/constructors/updateTheme.html) = \['theme' => [Theme](/API_docs/types/Theme.html), \]; + +*** +

[$updateTranscribedAudio](/API_docs/constructors/updateTranscribedAudio.html) = \['pending' => [Bool](/API_docs/types/Bool.html), 'peer' => [long](/API_docs/types/long.html), 'msg_id' => [int](/API_docs/types/int.html), 'transcription_id' => [long](/API_docs/types/long.html), 'text' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateUser](/API_docs/constructors/updateUser.html) = \['user_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$updateUserEmojiStatus](/API_docs/constructors/updateUserEmojiStatus.html) = \['user_id' => [long](/API_docs/types/long.html), 'emoji_status' => [EmojiStatus](/API_docs/types/EmojiStatus.html), \]; + +*** +

[$updateUserName](/API_docs/constructors/updateUserName.html) = \['user_id' => [long](/API_docs/types/long.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'usernames' => \[[Username](/API_docs/types/Username.html)\], \]; + +*** +

[$updateUserPhone](/API_docs/constructors/updateUserPhone.html) = \['user_id' => [long](/API_docs/types/long.html), 'phone' => [string](/API_docs/types/string.html), \]; + +*** +

[$updateUserStatus](/API_docs/constructors/updateUserStatus.html) = \['user_id' => [long](/API_docs/types/long.html), 'status' => [UserStatus](/API_docs/types/UserStatus.html), \]; + +*** +

[$updateUserTyping](/API_docs/constructors/updateUserTyping.html) = \['user_id' => [long](/API_docs/types/long.html), 'action' => [SendMessageAction](/API_docs/types/SendMessageAction.html), \]; + +*** +

[$updateWebPage](/API_docs/constructors/updateWebPage.html) = \['webpage' => [WebPage](/API_docs/types/WebPage.html), 'pts' => [int](/API_docs/types/int.html), 'pts_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updateWebViewResultSent](/API_docs/constructors/updateWebViewResultSent.html) = \['query_id' => [long](/API_docs/types/long.html), \]; + +*** +

[$updates](/API_docs/constructors/updates.html) = \['updates' => \[[Update](/API_docs/types/Update.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'date' => [int](/API_docs/types/int.html), 'seq' => [int](/API_docs/types/int.html), \]; + +*** +

[$updates.channelDifference](/API_docs/constructors/updates.channelDifference.html) = \['final' => [Bool](/API_docs/types/Bool.html), 'pts' => [int](/API_docs/types/int.html), 'timeout' => [int](/API_docs/types/int.html), 'new_messages' => \[[Message](/API_docs/types/Message.html)\], 'other_updates' => \[[Update](/API_docs/types/Update.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$updates.channelDifferenceEmpty](/API_docs/constructors/updates.channelDifferenceEmpty.html) = \['final' => [Bool](/API_docs/types/Bool.html), 'pts' => [int](/API_docs/types/int.html), 'timeout' => [int](/API_docs/types/int.html), \]; + +*** +

[$updates.channelDifferenceTooLong](/API_docs/constructors/updates.channelDifferenceTooLong.html) = \['final' => [Bool](/API_docs/types/Bool.html), 'timeout' => [int](/API_docs/types/int.html), 'dialog' => [Dialog](/API_docs/types/Dialog.html), 'messages' => \[[Message](/API_docs/types/Message.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$updates.difference](/API_docs/constructors/updates.difference.html) = \['new_messages' => \[[Message](/API_docs/types/Message.html)\], 'new_encrypted_messages' => \[[EncryptedMessage](/API_docs/types/EncryptedMessage.html)\], 'other_updates' => \[[Update](/API_docs/types/Update.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'state' => [updates.State](/API_docs/types/updates.State.html), \]; + +*** +

[$updates.differenceEmpty](/API_docs/constructors/updates.differenceEmpty.html) = \['date' => [int](/API_docs/types/int.html), 'seq' => [int](/API_docs/types/int.html), \]; + +*** +

[$updates.differenceSlice](/API_docs/constructors/updates.differenceSlice.html) = \['new_messages' => \[[Message](/API_docs/types/Message.html)\], 'new_encrypted_messages' => \[[EncryptedMessage](/API_docs/types/EncryptedMessage.html)\], 'other_updates' => \[[Update](/API_docs/types/Update.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'intermediate_state' => [updates.State](/API_docs/types/updates.State.html), \]; + +*** +

[$updates.differenceTooLong](/API_docs/constructors/updates.differenceTooLong.html) = \['pts' => [int](/API_docs/types/int.html), \]; + +*** +

[$updates.state](/API_docs/constructors/updates.state.html) = \['pts' => [int](/API_docs/types/int.html), 'qts' => [int](/API_docs/types/int.html), 'date' => [int](/API_docs/types/int.html), 'seq' => [int](/API_docs/types/int.html), 'unread_count' => [int](/API_docs/types/int.html), \]; + +*** +

[$updatesCombined](/API_docs/constructors/updatesCombined.html) = \['updates' => \[[Update](/API_docs/types/Update.html)\], 'users' => \[[User](/API_docs/types/User.html)\], 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'date' => [int](/API_docs/types/int.html), 'seq_start' => [int](/API_docs/types/int.html), 'seq' => [int](/API_docs/types/int.html), \]; + +*** +

[$updatesTooLong](/API_docs/constructors/updatesTooLong.html) = \[\]; + +*** +

[$upload.cdnFile](/API_docs/constructors/upload.cdnFile.html) = \['bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$upload.cdnFileReuploadNeeded](/API_docs/constructors/upload.cdnFileReuploadNeeded.html) = \['request_token' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$upload.file](/API_docs/constructors/upload.file.html) = \['type' => [storage.FileType](/API_docs/types/storage.FileType.html), 'mtime' => [int](/API_docs/types/int.html), 'bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$upload.fileCdnRedirect](/API_docs/constructors/upload.fileCdnRedirect.html) = \['dc_id' => [int](/API_docs/types/int.html), 'file_token' => [string](/API_docs/types/string.html), 'encryption_key' => [string](/API_docs/types/string.html), 'encryption_iv' => [string](/API_docs/types/string.html), 'file_hashes' => \[[FileHash](/API_docs/types/FileHash.html)\], \]; + +*** +

[$upload.webFile](/API_docs/constructors/upload.webFile.html) = \['size' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'file_type' => [storage.FileType](/API_docs/types/storage.FileType.html), 'mtime' => [int](/API_docs/types/int.html), 'bytes' => [bytes](/API_docs/types/bytes.html), \]; + +*** +

[$urlAuthResultAccepted](/API_docs/constructors/urlAuthResultAccepted.html) = \['url' => [string](/API_docs/types/string.html), \]; + +*** +

[$urlAuthResultDefault](/API_docs/constructors/urlAuthResultDefault.html) = \[\]; + +*** +

[$urlAuthResultRequest](/API_docs/constructors/urlAuthResultRequest.html) = \['request_write_access' => [Bool](/API_docs/types/Bool.html), 'bot' => [User](/API_docs/types/User.html), 'domain' => [string](/API_docs/types/string.html), \]; + +*** +

[$user](/API_docs/constructors/user.html) = \['self' => [Bool](/API_docs/types/Bool.html), 'contact' => [Bool](/API_docs/types/Bool.html), 'mutual_contact' => [Bool](/API_docs/types/Bool.html), 'deleted' => [Bool](/API_docs/types/Bool.html), 'bot' => [Bool](/API_docs/types/Bool.html), 'bot_chat_history' => [Bool](/API_docs/types/Bool.html), 'bot_nochats' => [Bool](/API_docs/types/Bool.html), 'verified' => [Bool](/API_docs/types/Bool.html), 'restricted' => [Bool](/API_docs/types/Bool.html), 'min' => [Bool](/API_docs/types/Bool.html), 'bot_inline_geo' => [Bool](/API_docs/types/Bool.html), 'support' => [Bool](/API_docs/types/Bool.html), 'scam' => [Bool](/API_docs/types/Bool.html), 'apply_min_photo' => [Bool](/API_docs/types/Bool.html), 'fake' => [Bool](/API_docs/types/Bool.html), 'bot_attach_menu' => [Bool](/API_docs/types/Bool.html), 'premium' => [Bool](/API_docs/types/Bool.html), 'attach_menu_enabled' => [Bool](/API_docs/types/Bool.html), 'bot_can_edit' => [Bool](/API_docs/types/Bool.html), 'close_friend' => [Bool](/API_docs/types/Bool.html), 'stories_hidden' => [Bool](/API_docs/types/Bool.html), 'stories_unavailable' => [Bool](/API_docs/types/Bool.html), 'contact_require_premium' => [Bool](/API_docs/types/Bool.html), 'bot_business' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'access_hash' => [long](/API_docs/types/long.html), 'first_name' => [string](/API_docs/types/string.html), 'last_name' => [string](/API_docs/types/string.html), 'username' => [string](/API_docs/types/string.html), 'phone' => [string](/API_docs/types/string.html), 'photo' => [UserProfilePhoto](/API_docs/types/UserProfilePhoto.html), 'status' => [UserStatus](/API_docs/types/UserStatus.html), 'bot_info_version' => [int](/API_docs/types/int.html), 'restriction_reason' => \[[RestrictionReason](/API_docs/types/RestrictionReason.html)\], 'bot_inline_placeholder' => [string](/API_docs/types/string.html), 'lang_code' => [string](/API_docs/types/string.html), 'emoji_status' => [EmojiStatus](/API_docs/types/EmojiStatus.html), 'usernames' => \[[Username](/API_docs/types/Username.html)\], 'stories_max_id' => [int](/API_docs/types/int.html), 'color' => [PeerColor](/API_docs/types/PeerColor.html), 'profile_color' => [PeerColor](/API_docs/types/PeerColor.html), \]; + +*** +

[$userEmpty](/API_docs/constructors/userEmpty.html) = \['id' => [long](/API_docs/types/long.html), \]; + +*** +

[$userFull](/API_docs/constructors/userFull.html) = \['blocked' => [Bool](/API_docs/types/Bool.html), 'phone_calls_available' => [Bool](/API_docs/types/Bool.html), 'phone_calls_private' => [Bool](/API_docs/types/Bool.html), 'can_pin_message' => [Bool](/API_docs/types/Bool.html), 'has_scheduled' => [Bool](/API_docs/types/Bool.html), 'video_calls_available' => [Bool](/API_docs/types/Bool.html), 'voice_messages_forbidden' => [Bool](/API_docs/types/Bool.html), 'translations_disabled' => [Bool](/API_docs/types/Bool.html), 'stories_pinned_available' => [Bool](/API_docs/types/Bool.html), 'blocked_my_stories_from' => [Bool](/API_docs/types/Bool.html), 'wallpaper_overridden' => [Bool](/API_docs/types/Bool.html), 'contact_require_premium' => [Bool](/API_docs/types/Bool.html), 'read_dates_private' => [Bool](/API_docs/types/Bool.html), 'sponsored_enabled' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'about' => [string](/API_docs/types/string.html), 'settings' => [PeerSettings](/API_docs/types/PeerSettings.html), 'personal_photo' => [Photo](/API_docs/types/Photo.html), 'profile_photo' => [Photo](/API_docs/types/Photo.html), 'fallback_photo' => [Photo](/API_docs/types/Photo.html), 'notify_settings' => [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html), 'bot_info' => [BotInfo](/API_docs/types/BotInfo.html), 'pinned_msg_id' => [int](/API_docs/types/int.html), 'common_chats_count' => [int](/API_docs/types/int.html), 'folder_id' => [int](/API_docs/types/int.html), 'ttl_period' => [int](/API_docs/types/int.html), 'theme_emoticon' => [string](/API_docs/types/string.html), 'private_forward_name' => [string](/API_docs/types/string.html), 'bot_group_admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'bot_broadcast_admin_rights' => [ChatAdminRights](/API_docs/types/ChatAdminRights.html), 'premium_gifts' => \[[PremiumGiftOption](/API_docs/types/PremiumGiftOption.html)\], 'wallpaper' => [WallPaper](/API_docs/types/WallPaper.html), 'stories' => [PeerStories](/API_docs/types/PeerStories.html), 'business_work_hours' => [BusinessWorkHours](/API_docs/types/BusinessWorkHours.html), 'business_location' => [BusinessLocation](/API_docs/types/BusinessLocation.html), 'business_greeting_message' => [BusinessGreetingMessage](/API_docs/types/BusinessGreetingMessage.html), 'business_away_message' => [BusinessAwayMessage](/API_docs/types/BusinessAwayMessage.html), 'business_intro' => [BusinessIntro](/API_docs/types/BusinessIntro.html), 'birthday' => [Birthday](/API_docs/types/Birthday.html), 'personal_channel_id' => [long](/API_docs/types/long.html), 'personal_channel_message' => [int](/API_docs/types/int.html), \]; + +*** +

[$userProfilePhoto](/API_docs/constructors/userProfilePhoto.html) = \['has_video' => [Bool](/API_docs/types/Bool.html), 'personal' => [Bool](/API_docs/types/Bool.html), 'photo_id' => [long](/API_docs/types/long.html), 'stripped_thumb' => [bytes](/API_docs/types/bytes.html), 'dc_id' => [int](/API_docs/types/int.html), \]; + +*** +

[$userProfilePhotoEmpty](/API_docs/constructors/userProfilePhotoEmpty.html) = \[\]; + +*** +

[$userStatusEmpty](/API_docs/constructors/userStatusEmpty.html) = \[\]; + +*** +

[$userStatusLastMonth](/API_docs/constructors/userStatusLastMonth.html) = \['by_me' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$userStatusLastWeek](/API_docs/constructors/userStatusLastWeek.html) = \['by_me' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$userStatusOffline](/API_docs/constructors/userStatusOffline.html) = \['was_online' => [int](/API_docs/types/int.html), \]; + +*** +

[$userStatusOnline](/API_docs/constructors/userStatusOnline.html) = \['expires' => [int](/API_docs/types/int.html), \]; + +*** +

[$userStatusRecently](/API_docs/constructors/userStatusRecently.html) = \['by_me' => [Bool](/API_docs/types/Bool.html), \]; + +*** +

[$username](/API_docs/constructors/username.html) = \['editable' => [Bool](/API_docs/types/Bool.html), 'active' => [Bool](/API_docs/types/Bool.html), 'username' => [string](/API_docs/types/string.html), \]; + +*** +

[$users.userFull](/API_docs/constructors/users.userFull.html) = \['full_user' => [UserFull](/API_docs/types/UserFull.html), 'chats' => \[[Chat](/API_docs/types/Chat.html)\], 'users' => \[[User](/API_docs/types/User.html)\], \]; + +*** +

[$videoSize](/API_docs/constructors/videoSize.html) = \['type' => [string](/API_docs/types/string.html), 'w' => [int](/API_docs/types/int.html), 'h' => [int](/API_docs/types/int.html), 'size' => [int](/API_docs/types/int.html), 'video_start_ts' => [double](/API_docs/types/double.html), \]; + +*** +

[$videoSizeEmojiMarkup](/API_docs/constructors/videoSizeEmojiMarkup.html) = \['emoji_id' => [long](/API_docs/types/long.html), 'background_colors' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$videoSizeStickerMarkup](/API_docs/constructors/videoSizeStickerMarkup.html) = \['stickerset' => [InputStickerSet](/API_docs/types/InputStickerSet.html), 'sticker_id' => [long](/API_docs/types/long.html), 'background_colors' => \[[int](/API_docs/types/int.html)\], \]; + +*** +

[$wallPaper](/API_docs/constructors/wallPaper.html) = \['id' => [long](/API_docs/types/long.html), 'creator' => [Bool](/API_docs/types/Bool.html), 'default' => [Bool](/API_docs/types/Bool.html), 'pattern' => [Bool](/API_docs/types/Bool.html), 'dark' => [Bool](/API_docs/types/Bool.html), 'access_hash' => [long](/API_docs/types/long.html), 'slug' => [string](/API_docs/types/string.html), 'document' => [Document](/API_docs/types/Document.html), 'settings' => [WallPaperSettings](/API_docs/types/WallPaperSettings.html), \]; + +*** +

[$wallPaperNoFile](/API_docs/constructors/wallPaperNoFile.html) = \['id' => [long](/API_docs/types/long.html), 'default' => [Bool](/API_docs/types/Bool.html), 'dark' => [Bool](/API_docs/types/Bool.html), 'settings' => [WallPaperSettings](/API_docs/types/WallPaperSettings.html), \]; + +*** +

[$wallPaperSettings](/API_docs/constructors/wallPaperSettings.html) = \['blur' => [Bool](/API_docs/types/Bool.html), 'motion' => [Bool](/API_docs/types/Bool.html), 'background_color' => [int](/API_docs/types/int.html), 'second_background_color' => [int](/API_docs/types/int.html), 'third_background_color' => [int](/API_docs/types/int.html), 'fourth_background_color' => [int](/API_docs/types/int.html), 'intensity' => [int](/API_docs/types/int.html), 'rotation' => [int](/API_docs/types/int.html), 'emoticon' => [string](/API_docs/types/string.html), \]; + +*** +

[$webAuthorization](/API_docs/constructors/webAuthorization.html) = \['hash' => [long](/API_docs/types/long.html), 'bot_id' => [long](/API_docs/types/long.html), 'domain' => [string](/API_docs/types/string.html), 'browser' => [string](/API_docs/types/string.html), 'platform' => [string](/API_docs/types/string.html), 'date_created' => [int](/API_docs/types/int.html), 'date_active' => [int](/API_docs/types/int.html), 'ip' => [string](/API_docs/types/string.html), 'region' => [string](/API_docs/types/string.html), \]; + +*** +

[$webDocument](/API_docs/constructors/webDocument.html) = \['url' => [string](/API_docs/types/string.html), 'access_hash' => [long](/API_docs/types/long.html), 'size' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], \]; + +*** +

[$webDocumentNoProxy](/API_docs/constructors/webDocumentNoProxy.html) = \['url' => [string](/API_docs/types/string.html), 'size' => [int](/API_docs/types/int.html), 'mime_type' => [string](/API_docs/types/string.html), 'attributes' => \[[DocumentAttribute](/API_docs/types/DocumentAttribute.html)\], \]; + +*** +

[$webPage](/API_docs/constructors/webPage.html) = \['has_large_media' => [Bool](/API_docs/types/Bool.html), 'id' => [long](/API_docs/types/long.html), 'url' => [string](/API_docs/types/string.html), 'display_url' => [string](/API_docs/types/string.html), 'hash' => [int](/API_docs/types/int.html), 'type' => [string](/API_docs/types/string.html), 'site_name' => [string](/API_docs/types/string.html), 'title' => [string](/API_docs/types/string.html), 'description' => [string](/API_docs/types/string.html), 'photo' => [Photo](/API_docs/types/Photo.html), 'embed_url' => [string](/API_docs/types/string.html), 'embed_type' => [string](/API_docs/types/string.html), 'embed_width' => [int](/API_docs/types/int.html), 'embed_height' => [int](/API_docs/types/int.html), 'duration' => [int](/API_docs/types/int.html), 'author' => [string](/API_docs/types/string.html), 'document' => [Document](/API_docs/types/Document.html), 'cached_page' => [Page](/API_docs/types/Page.html), 'attributes' => \[[WebPageAttribute](/API_docs/types/WebPageAttribute.html)\], \]; + +*** +

[$webPageAttributeStickerSet](/API_docs/constructors/webPageAttributeStickerSet.html) = \['emojis' => [Bool](/API_docs/types/Bool.html), 'text_color' => [Bool](/API_docs/types/Bool.html), 'stickers' => \[[Document](/API_docs/types/Document.html)\], \]; + +*** +

[$webPageAttributeStory](/API_docs/constructors/webPageAttributeStory.html) = \['peer' => [long](/API_docs/types/long.html), 'id' => [int](/API_docs/types/int.html), 'story' => [StoryItem](/API_docs/types/StoryItem.html), \]; + +*** +

[$webPageAttributeTheme](/API_docs/constructors/webPageAttributeTheme.html) = \['documents' => \[[Document](/API_docs/types/Document.html)\], 'settings' => [ThemeSettings](/API_docs/types/ThemeSettings.html), \]; + +*** +

[$webPageEmpty](/API_docs/constructors/webPageEmpty.html) = \['id' => [long](/API_docs/types/long.html), 'url' => [string](/API_docs/types/string.html), \]; + +*** +

[$webPageNotModified](/API_docs/constructors/webPageNotModified.html) = \['cached_page_views' => [int](/API_docs/types/int.html), \]; + +*** +

[$webPagePending](/API_docs/constructors/webPagePending.html) = \['id' => [long](/API_docs/types/long.html), 'url' => [string](/API_docs/types/string.html), 'date' => [int](/API_docs/types/int.html), \]; + +*** +

[$webViewMessageSent](/API_docs/constructors/webViewMessageSent.html) = \['msg_id' => [InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html), \]; + +*** +

[$webViewResultUrl](/API_docs/constructors/webViewResultUrl.html) = \['query_id' => [long](/API_docs/types/long.html), 'url' => [string](/API_docs/types/string.html), \]; + + diff --git a/docs/API_docs/constructors/inlineBotSwitchPM.md b/docs/API_docs/constructors/inlineBotSwitchPM.md new file mode 100644 index 0000000000..720bf921f1 --- /dev/null +++ b/docs/API_docs/constructors/inlineBotSwitchPM.md @@ -0,0 +1,30 @@ +--- +title: "inlineBotSwitchPM" +description: "The bot requested the user to message them in private" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineBotSwitchPM +[Back to constructors index](/API_docs/constructors/index.html) + + + +The bot requested the user to message them in private + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Text for the button that switches the user to a private chat with the bot and sends the bot a start message with the parameter `start_parameter` (can be empty)| +|start\_param|[string](/API_docs/types/string.html) | Yes|The parameter for the `/start parameter`| + + + +### Type: [InlineBotSwitchPM](/API_docs/types/InlineBotSwitchPM.html) + + +### Example: + +``` +$inlineBotSwitchPM = ['_' => 'inlineBotSwitchPM', 'text' => 'string', 'start_param' => 'string']; +``` diff --git a/docs/API_docs/constructors/inlineBotWebView.md b/docs/API_docs/constructors/inlineBotWebView.md new file mode 100644 index 0000000000..b4c874ca6e --- /dev/null +++ b/docs/API_docs/constructors/inlineBotWebView.md @@ -0,0 +1,30 @@ +--- +title: "inlineBotWebView" +description: "Specifies an inline mode mini app button, shown on top of the inline query results list." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineBotWebView +[Back to constructors index](/API_docs/constructors/index.html) + + + +Specifies an [inline mode mini app](https://core.telegram.org/api/bots/webapps#inline-mode-mini-apps) button, shown on top of the inline query results list. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Text of the button| +|url|[string](/API_docs/types/string.html) | Yes|Webapp URL| + + + +### Type: [InlineBotWebView](/API_docs/types/InlineBotWebView.html) + + +### Example: + +``` +$inlineBotWebView = ['_' => 'inlineBotWebView', 'text' => 'string', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/inlineQueryPeerTypeBotPM.md b/docs/API_docs/constructors/inlineQueryPeerTypeBotPM.md new file mode 100644 index 0000000000..9dc44b1817 --- /dev/null +++ b/docs/API_docs/constructors/inlineQueryPeerTypeBotPM.md @@ -0,0 +1,24 @@ +--- +title: "inlineQueryPeerTypeBotPM" +description: "Peer type: private chat with a bot." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineQueryPeerTypeBotPM +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer type: private chat with a bot. + + + + +### Type: [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + + +### Example: + +``` +$inlineQueryPeerTypeBotPM = ['_' => 'inlineQueryPeerTypeBotPM']; +``` diff --git a/docs/API_docs/constructors/inlineQueryPeerTypeBroadcast.md b/docs/API_docs/constructors/inlineQueryPeerTypeBroadcast.md new file mode 100644 index 0000000000..8ca800c7ba --- /dev/null +++ b/docs/API_docs/constructors/inlineQueryPeerTypeBroadcast.md @@ -0,0 +1,24 @@ +--- +title: "inlineQueryPeerTypeBroadcast" +description: "Peer type: channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineQueryPeerTypeBroadcast +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer type: [channel](https://core.telegram.org/api/channel) + + + + +### Type: [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + + +### Example: + +``` +$inlineQueryPeerTypeBroadcast = ['_' => 'inlineQueryPeerTypeBroadcast']; +``` diff --git a/docs/API_docs/constructors/inlineQueryPeerTypeChat.md b/docs/API_docs/constructors/inlineQueryPeerTypeChat.md new file mode 100644 index 0000000000..bdb07e511f --- /dev/null +++ b/docs/API_docs/constructors/inlineQueryPeerTypeChat.md @@ -0,0 +1,24 @@ +--- +title: "inlineQueryPeerTypeChat" +description: "Peer type: chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineQueryPeerTypeChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer type: [chat](https://core.telegram.org/api/channel) + + + + +### Type: [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + + +### Example: + +``` +$inlineQueryPeerTypeChat = ['_' => 'inlineQueryPeerTypeChat']; +``` diff --git a/docs/API_docs/constructors/inlineQueryPeerTypeMegagroup.md b/docs/API_docs/constructors/inlineQueryPeerTypeMegagroup.md new file mode 100644 index 0000000000..5f3a6cfcd2 --- /dev/null +++ b/docs/API_docs/constructors/inlineQueryPeerTypeMegagroup.md @@ -0,0 +1,24 @@ +--- +title: "inlineQueryPeerTypeMegagroup" +description: "Peer type: supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineQueryPeerTypeMegagroup +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer type: [supergroup](https://core.telegram.org/api/channel) + + + + +### Type: [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + + +### Example: + +``` +$inlineQueryPeerTypeMegagroup = ['_' => 'inlineQueryPeerTypeMegagroup']; +``` diff --git a/docs/API_docs/constructors/inlineQueryPeerTypePM.md b/docs/API_docs/constructors/inlineQueryPeerTypePM.md new file mode 100644 index 0000000000..e55a4f7a0a --- /dev/null +++ b/docs/API_docs/constructors/inlineQueryPeerTypePM.md @@ -0,0 +1,24 @@ +--- +title: "inlineQueryPeerTypePM" +description: "Peer type: private chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineQueryPeerTypePM +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer type: private chat + + + + +### Type: [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + + +### Example: + +``` +$inlineQueryPeerTypePM = ['_' => 'inlineQueryPeerTypePM']; +``` diff --git a/docs/API_docs/constructors/inlineQueryPeerTypeSameBotPM.md b/docs/API_docs/constructors/inlineQueryPeerTypeSameBotPM.md new file mode 100644 index 0000000000..5d4868fe35 --- /dev/null +++ b/docs/API_docs/constructors/inlineQueryPeerTypeSameBotPM.md @@ -0,0 +1,24 @@ +--- +title: "inlineQueryPeerTypeSameBotPM" +description: "Peer type: private chat with the bot itself" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inlineQueryPeerTypeSameBotPM +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer type: private chat with the bot itself + + + + +### Type: [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + + +### Example: + +``` +$inlineQueryPeerTypeSameBotPM = ['_' => 'inlineQueryPeerTypeSameBotPM']; +``` diff --git a/docs/API_docs/constructors/inputAppEvent.md b/docs/API_docs/constructors/inputAppEvent.md new file mode 100644 index 0000000000..990792664a --- /dev/null +++ b/docs/API_docs/constructors/inputAppEvent.md @@ -0,0 +1,32 @@ +--- +title: "inputAppEvent" +description: "Event that occurred in the application." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputAppEvent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Event that occurred in the application. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|time|[double](/API_docs/types/double.html) | Yes|Client's exact timestamp for the event| +|type|[string](/API_docs/types/string.html) | Yes|Type of event| +|peer|[long](/API_docs/types/long.html) | Yes|Arbitrary numeric value for more convenient selection of certain event types, or events referring to a certain object| +|data|[JSONValue](/API_docs/types/JSONValue.html) | Yes|Details of the event| + + + +### Type: [InputAppEvent](/API_docs/types/InputAppEvent.html) + + +### Example: + +``` +$inputAppEvent = ['_' => 'inputAppEvent', 'time' => double, 'type' => 'string', 'peer' => long, 'data' => JSONValue]; +``` diff --git a/docs/API_docs/constructors/inputBotAppID.md b/docs/API_docs/constructors/inputBotAppID.md new file mode 100644 index 0000000000..c9b5389f57 --- /dev/null +++ b/docs/API_docs/constructors/inputBotAppID.md @@ -0,0 +1,30 @@ +--- +title: "inputBotAppID" +description: "Used to fetch information about a direct link Mini App by its ID" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotAppID +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to fetch information about a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps) by its ID + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|[direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps) ID.| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash, obtained from the [botApp](../constructors/botApp.html) constructor.| + + + +### Type: [InputBotApp](/API_docs/types/InputBotApp.html) + + +### Example: + +``` +$inputBotAppID = ['_' => 'inputBotAppID', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputBotAppShortName.md b/docs/API_docs/constructors/inputBotAppShortName.md new file mode 100644 index 0000000000..5fbd5683cb --- /dev/null +++ b/docs/API_docs/constructors/inputBotAppShortName.md @@ -0,0 +1,30 @@ +--- +title: "inputBotAppShortName" +description: "Used to fetch information about a direct link Mini App by its short name" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotAppShortName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to fetch information about a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps) by its short name + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|bot\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional|ID of the bot that owns the bot mini app| +|short\_name|[string](/API_docs/types/string.html) | Yes|Short name, obtained from a [Direct Mini App deep link](https://core.telegram.org/api/links#direct-mini-app-links)| + + + +### Type: [InputBotApp](/API_docs/types/InputBotApp.html) + + +### Example: + +``` +$inputBotAppShortName = ['_' => 'inputBotAppShortName', 'bot_id' => InputUser, 'short_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageGame.md b/docs/API_docs/constructors/inputBotInlineMessageGame.md new file mode 100644 index 0000000000..bc8a62da23 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageGame.md @@ -0,0 +1,35 @@ +--- +title: "inputBotInlineMessageGame" +description: "A game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageGame +[Back to constructors index](/API_docs/constructors/index.html) + + + +A game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$inputBotInlineMessageGame = ['_' => 'inputBotInlineMessageGame', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageID.md b/docs/API_docs/constructors/inputBotInlineMessageID.md new file mode 100644 index 0000000000..1f1985d383 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageID.md @@ -0,0 +1,31 @@ +--- +title: "inputBotInlineMessageID" +description: "Represents a sent inline message from the perspective of a bot (legacy constructor)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageID +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a sent inline message from the perspective of a bot (legacy constructor) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID to use when working with this inline message| +|id|[long](/API_docs/types/long.html) | Yes|ID of message, contains both the (32-bit, legacy) owner ID and the message ID, used only for Bot API backwards compatibility with 32-bit user ID.| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash of message| + + + +### Type: [InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) + + +### Example: + +``` +$inputBotInlineMessageID = ['_' => 'inputBotInlineMessageID', 'dc_id' => int, 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageID64.md b/docs/API_docs/constructors/inputBotInlineMessageID64.md new file mode 100644 index 0000000000..efaef7a72d --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageID64.md @@ -0,0 +1,32 @@ +--- +title: "inputBotInlineMessageID64" +description: "Represents a sent inline message from the perspective of a bot" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageID64 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a sent inline message from the perspective of a bot + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID to use when working with this inline message| +|owner\_id|[long](/API_docs/types/long.html) | Yes|ID of the owner of this message| +|id|[int](/API_docs/types/int.html) | Yes|ID of message| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash of message| + + + +### Type: [InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) + + +### Example: + +``` +$inputBotInlineMessageID64 = ['_' => 'inputBotInlineMessageID64', 'dc_id' => int, 'owner_id' => long, 'id' => int, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageMediaAuto.md b/docs/API_docs/constructors/inputBotInlineMessageMediaAuto.md new file mode 100644 index 0000000000..11caf76fd6 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageMediaAuto.md @@ -0,0 +1,93 @@ +--- +title: "inputBotInlineMessageMediaAuto" +description: "A media" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageMediaAuto +[Back to constructors index](/API_docs/constructors/index.html) + + + +A media + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|message|[string](/API_docs/types/string.html) | Yes|Caption| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$inputBotInlineMessageMediaAuto = ['_' => 'inputBotInlineMessageMediaAuto', 'invert_media' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageMediaContact.md b/docs/API_docs/constructors/inputBotInlineMessageMediaContact.md new file mode 100644 index 0000000000..b68c6e517b --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageMediaContact.md @@ -0,0 +1,39 @@ +--- +title: "inputBotInlineMessageMediaContact" +description: "A contact" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageMediaContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +A contact + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|First name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Last name| +|vcard|[string](/API_docs/types/string.html) | Yes|VCard info| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$inputBotInlineMessageMediaContact = ['_' => 'inputBotInlineMessageMediaContact', 'phone_number' => 'string', 'first_name' => 'string', 'last_name' => 'string', 'vcard' => 'string', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageMediaGeo.md b/docs/API_docs/constructors/inputBotInlineMessageMediaGeo.md new file mode 100644 index 0000000000..0f7bdbec29 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageMediaGeo.md @@ -0,0 +1,39 @@ +--- +title: "inputBotInlineMessageMediaGeo" +description: "Geolocation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageMediaGeo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Geolocation + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional|Geolocation| +|heading|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a direction in which the location moves, in degrees; 1-360| +|period|[int](/API_docs/types/int.html) | Optional|Validity period| +|proximity\_notification\_radius|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a maximum distance to another chat member for proximity alerts, in meters (0-100000)| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Reply markup for bot/inline keyboards| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$inputBotInlineMessageMediaGeo = ['_' => 'inputBotInlineMessageMediaGeo', 'geo_point' => InputGeoPoint, 'heading' => int, 'period' => int, 'proximity_notification_radius' => int, 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageMediaInvoice.md b/docs/API_docs/constructors/inputBotInlineMessageMediaInvoice.md new file mode 100644 index 0000000000..79eb378d1d --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageMediaInvoice.md @@ -0,0 +1,42 @@ +--- +title: "inputBotInlineMessageMediaInvoice" +description: "An invoice" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageMediaInvoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +An invoice + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Product name, 1-32 characters| +|description|[string](/API_docs/types/string.html) | Yes|Product description, 1-255 characters| +|photo|[InputWebDocument](/API_docs/types/InputWebDocument.html) | Optional|Invoice photo| +|invoice|[Invoice](/API_docs/types/Invoice.html) | Yes|The invoice| +|payload|[bytes](/API_docs/types/bytes.html) | Yes|Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes.| +|provider|[string](/API_docs/types/string.html) | Yes|Payments provider token, obtained via [Botfather](https://t.me/botfather)| +|provider\_data|[DataJSON](/API_docs/types/DataJSON.html) | Yes|A JSON-serialized object for data about the invoice, which will be shared with the payment provider. A detailed description of the required fields should be provided by the payment provider.| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$inputBotInlineMessageMediaInvoice = ['_' => 'inputBotInlineMessageMediaInvoice', 'title' => 'string', 'description' => 'string', 'photo' => InputWebDocument, 'invoice' => Invoice, 'payload' => 'bytes', 'provider' => 'string', 'provider_data' => DataJSON, 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageMediaVenue.md b/docs/API_docs/constructors/inputBotInlineMessageMediaVenue.md new file mode 100644 index 0000000000..aa5c3e72e3 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageMediaVenue.md @@ -0,0 +1,41 @@ +--- +title: "inputBotInlineMessageMediaVenue" +description: "Venue" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageMediaVenue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Venue + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional|Geolocation| +|title|[string](/API_docs/types/string.html) | Yes|Venue name| +|address|[string](/API_docs/types/string.html) | Yes|Address| +|provider|[string](/API_docs/types/string.html) | Yes|Venue provider: currently only "foursquare" and "gplaces" (Google Places) need to be supported| +|venue\_id|[string](/API_docs/types/string.html) | Yes|Venue ID in the provider's database| +|venue\_type|[string](/API_docs/types/string.html) | Yes|Venue type in the provider's database| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + +### Example: + +``` +$inputBotInlineMessageMediaVenue = ['_' => 'inputBotInlineMessageMediaVenue', 'geo_point' => InputGeoPoint, 'title' => 'string', 'address' => 'string', 'provider' => 'string', 'venue_id' => 'string', 'venue_type' => 'string', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageMediaWebPage.md b/docs/API_docs/constructors/inputBotInlineMessageMediaWebPage.md new file mode 100644 index 0000000000..896d59ec6b --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageMediaWebPage.md @@ -0,0 +1,97 @@ +--- +title: "inputBotInlineMessageMediaWebPage" +description: "Specifies options that will be used to generate the link preview for the message, or even a standalone link preview without an attached message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageMediaWebPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Specifies options that will be used to generate the link preview for the message, or even a standalone link preview without an attached message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|force\_large\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a large media preview should be used.| +|force\_small\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a small media preview should be used.| +|optional|[Bool](/API_docs/types/Bool.html) | Optional|If **not** set, a `WEBPAGE_NOT_FOUND` RPC error will be emitted if a webpage preview cannot be generated for the specified `url`; otherwise, no error will be emitted (unless the provided message is also empty, in which case a `MESSAGE_EMPTY` will be emitted, instead).| +|message|[string](/API_docs/types/string.html) | Yes|The message, can be empty.| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|url|[string](/API_docs/types/string.html) | Yes|The URL to use for the link preview.| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$inputBotInlineMessageMediaWebPage = ['_' => 'inputBotInlineMessageMediaWebPage', 'invert_media' => Bool, 'force_large_media' => Bool, 'force_small_media' => Bool, 'optional' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'url' => 'string', 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineMessageText.md b/docs/API_docs/constructors/inputBotInlineMessageText.md new file mode 100644 index 0000000000..7e467cc774 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineMessageText.md @@ -0,0 +1,94 @@ +--- +title: "inputBotInlineMessageText" +description: "Simple text message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineMessageText +[Back to constructors index](/API_docs/constructors/index.html) + + + +Simple text message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Optional|Disable webpage preview| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|message|[string](/API_docs/types/string.html) | Yes|Message| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Inline keyboard| + + + +### Type: [InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$inputBotInlineMessageText = ['_' => 'inputBotInlineMessageText', 'no_webpage' => Bool, 'invert_media' => Bool, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'reply_markup' => ReplyMarkup]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineResult.md b/docs/API_docs/constructors/inputBotInlineResult.md new file mode 100644 index 0000000000..475dcc5596 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineResult.md @@ -0,0 +1,36 @@ +--- +title: "inputBotInlineResult" +description: "An inline bot result" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineResult +[Back to constructors index](/API_docs/constructors/index.html) + + + +An inline bot result + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|ID of result| +|type|[string](/API_docs/types/string.html) | Yes|Result type (see [bot API docs](https://core.telegram.org/bots/api#inlinequeryresult))| +|title|[string](/API_docs/types/string.html) | Optional|Result title| +|description|[string](/API_docs/types/string.html) | Optional|Result description| +|url|[string](/API_docs/types/string.html) | Optional|URL of result| +|thumb|[InputWebDocument](/API_docs/types/InputWebDocument.html) | Optional|Thumbnail for result| +|content|[InputWebDocument](/API_docs/types/InputWebDocument.html) | Optional|Result contents| +|send\_message|[InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) | Yes|Message to send when the result is selected| + + + +### Type: [InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) + + +### Example: + +``` +$inputBotInlineResult = ['_' => 'inputBotInlineResult', 'id' => 'string', 'type' => 'string', 'title' => 'string', 'description' => 'string', 'url' => 'string', 'thumb' => InputWebDocument, 'content' => InputWebDocument, 'send_message' => InputBotInlineMessage]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineResultDocument.md b/docs/API_docs/constructors/inputBotInlineResultDocument.md new file mode 100644 index 0000000000..4a98ae56cd --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineResultDocument.md @@ -0,0 +1,34 @@ +--- +title: "inputBotInlineResultDocument" +description: "Document (media of any type except for photos)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineResultDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document (media of any type except for photos) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Result ID| +|type|[string](/API_docs/types/string.html) | Yes|Result type (see [bot API docs](https://core.telegram.org/bots/api#inlinequeryresult))| +|title|[string](/API_docs/types/string.html) | Optional|Result title| +|description|[string](/API_docs/types/string.html) | Optional|Result description| +|document|[MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|Document to send| +|send\_message|[InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) | Yes|Message to send when the result is selected| + + + +### Type: [InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) + + +### Example: + +``` +$inputBotInlineResultDocument = ['_' => 'inputBotInlineResultDocument', 'id' => 'string', 'type' => 'string', 'title' => 'string', 'description' => 'string', 'document' => InputDocument, 'send_message' => InputBotInlineMessage]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineResultGame.md b/docs/API_docs/constructors/inputBotInlineResultGame.md new file mode 100644 index 0000000000..1800c80628 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineResultGame.md @@ -0,0 +1,31 @@ +--- +title: "inputBotInlineResultGame" +description: "Game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineResultGame +[Back to constructors index](/API_docs/constructors/index.html) + + + +Game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Result ID| +|short\_name|[string](/API_docs/types/string.html) | Yes|Game short name| +|send\_message|[InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) | Yes|Message to send when the result is selected| + + + +### Type: [InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) + + +### Example: + +``` +$inputBotInlineResultGame = ['_' => 'inputBotInlineResultGame', 'id' => 'string', 'short_name' => 'string', 'send_message' => InputBotInlineMessage]; +``` diff --git a/docs/API_docs/constructors/inputBotInlineResultPhoto.md b/docs/API_docs/constructors/inputBotInlineResultPhoto.md new file mode 100644 index 0000000000..65117e7661 --- /dev/null +++ b/docs/API_docs/constructors/inputBotInlineResultPhoto.md @@ -0,0 +1,32 @@ +--- +title: "inputBotInlineResultPhoto" +description: "Photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBotInlineResultPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Result ID| +|type|[string](/API_docs/types/string.html) | Yes|Result type (see [bot API docs](https://core.telegram.org/bots/api#inlinequeryresult))| +|photo|[MessageMedia, Message, Update or InputPhoto](/API_docs/types/InputPhoto.html) | Optional|Photo to send| +|send\_message|[InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) | Yes|Message to send when the result is selected| + + + +### Type: [InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) + + +### Example: + +``` +$inputBotInlineResultPhoto = ['_' => 'inputBotInlineResultPhoto', 'id' => 'string', 'type' => 'string', 'photo' => InputPhoto, 'send_message' => InputBotInlineMessage]; +``` diff --git a/docs/API_docs/constructors/inputBusinessAwayMessage.md b/docs/API_docs/constructors/inputBusinessAwayMessage.md new file mode 100644 index 0000000000..c86a3b5587 --- /dev/null +++ b/docs/API_docs/constructors/inputBusinessAwayMessage.md @@ -0,0 +1,30 @@ +--- +title: "inputBusinessAwayMessage" +description: "inputBusinessAwayMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBusinessAwayMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|offline\_only|[Bool](/API_docs/types/Bool.html) | Optional| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| +|schedule|[BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html) | Yes| +|recipients|[InputBusinessRecipients](/API_docs/types/InputBusinessRecipients.html) | Yes| + + + +### Type: [InputBusinessAwayMessage](/API_docs/types/InputBusinessAwayMessage.html) + + +### Example: + +``` +$inputBusinessAwayMessage = ['_' => 'inputBusinessAwayMessage', 'offline_only' => Bool, 'shortcut_id' => int, 'schedule' => BusinessAwayMessageSchedule, 'recipients' => InputBusinessRecipients]; +``` diff --git a/docs/API_docs/constructors/inputBusinessBotRecipients.md b/docs/API_docs/constructors/inputBusinessBotRecipients.md new file mode 100644 index 0000000000..59827a16bc --- /dev/null +++ b/docs/API_docs/constructors/inputBusinessBotRecipients.md @@ -0,0 +1,33 @@ +--- +title: "inputBusinessBotRecipients" +description: "inputBusinessBotRecipients attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBusinessBotRecipients +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|existing\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|new\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|non\_contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|exclude\_selected|[Bool](/API_docs/types/Bool.html) | Optional| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional| +|exclude\_users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional| + + + +### Type: [InputBusinessBotRecipients](/API_docs/types/InputBusinessBotRecipients.html) + + +### Example: + +``` +$inputBusinessBotRecipients = ['_' => 'inputBusinessBotRecipients', 'existing_chats' => Bool, 'new_chats' => Bool, 'contacts' => Bool, 'non_contacts' => Bool, 'exclude_selected' => Bool, 'users' => [InputUser, InputUser], 'exclude_users' => [InputUser, InputUser]]; +``` diff --git a/docs/API_docs/constructors/inputBusinessChatLink.md b/docs/API_docs/constructors/inputBusinessChatLink.md new file mode 100644 index 0000000000..cedc7dfce2 --- /dev/null +++ b/docs/API_docs/constructors/inputBusinessChatLink.md @@ -0,0 +1,90 @@ +--- +title: "inputBusinessChatLink" +description: "inputBusinessChatLink attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBusinessChatLink +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|message|[string](/API_docs/types/string.html) | Yes| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|title|[string](/API_docs/types/string.html) | Optional| + + + +### Type: [InputBusinessChatLink](/API_docs/types/InputBusinessChatLink.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$inputBusinessChatLink = ['_' => 'inputBusinessChatLink', 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'title' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputBusinessGreetingMessage.md b/docs/API_docs/constructors/inputBusinessGreetingMessage.md new file mode 100644 index 0000000000..1ed4d6695e --- /dev/null +++ b/docs/API_docs/constructors/inputBusinessGreetingMessage.md @@ -0,0 +1,29 @@ +--- +title: "inputBusinessGreetingMessage" +description: "inputBusinessGreetingMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBusinessGreetingMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| +|recipients|[InputBusinessRecipients](/API_docs/types/InputBusinessRecipients.html) | Yes| +|no\_activity\_days|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [InputBusinessGreetingMessage](/API_docs/types/InputBusinessGreetingMessage.html) + + +### Example: + +``` +$inputBusinessGreetingMessage = ['_' => 'inputBusinessGreetingMessage', 'shortcut_id' => int, 'recipients' => InputBusinessRecipients, 'no_activity_days' => int]; +``` diff --git a/docs/API_docs/constructors/inputBusinessIntro.md b/docs/API_docs/constructors/inputBusinessIntro.md new file mode 100644 index 0000000000..658e5f7103 --- /dev/null +++ b/docs/API_docs/constructors/inputBusinessIntro.md @@ -0,0 +1,29 @@ +--- +title: "inputBusinessIntro" +description: "inputBusinessIntro attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBusinessIntro +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|title|[string](/API_docs/types/string.html) | Yes| +|description|[string](/API_docs/types/string.html) | Yes| +|sticker|[MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional| + + + +### Type: [InputBusinessIntro](/API_docs/types/InputBusinessIntro.html) + + +### Example: + +``` +$inputBusinessIntro = ['_' => 'inputBusinessIntro', 'title' => 'string', 'description' => 'string', 'sticker' => InputDocument]; +``` diff --git a/docs/API_docs/constructors/inputBusinessRecipients.md b/docs/API_docs/constructors/inputBusinessRecipients.md new file mode 100644 index 0000000000..7c7fee8ccd --- /dev/null +++ b/docs/API_docs/constructors/inputBusinessRecipients.md @@ -0,0 +1,32 @@ +--- +title: "inputBusinessRecipients" +description: "inputBusinessRecipients attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputBusinessRecipients +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|existing\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|new\_chats|[Bool](/API_docs/types/Bool.html) | Optional| +|contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|non\_contacts|[Bool](/API_docs/types/Bool.html) | Optional| +|exclude\_selected|[Bool](/API_docs/types/Bool.html) | Optional| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional| + + + +### Type: [InputBusinessRecipients](/API_docs/types/InputBusinessRecipients.html) + + +### Example: + +``` +$inputBusinessRecipients = ['_' => 'inputBusinessRecipients', 'existing_chats' => Bool, 'new_chats' => Bool, 'contacts' => Bool, 'non_contacts' => Bool, 'exclude_selected' => Bool, 'users' => [InputUser, InputUser]]; +``` diff --git a/docs/API_docs/constructors/inputChannel.md b/docs/API_docs/constructors/inputChannel.md new file mode 100644 index 0000000000..1118c8639c --- /dev/null +++ b/docs/API_docs/constructors/inputChannel.md @@ -0,0 +1,30 @@ +--- +title: "inputChannel" +description: "Represents a channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash taken from the [channel](../constructors/channel.html) constructor| + + + +### Type: [InputChannel](/API_docs/types/InputChannel.html) + + +### Example: + +``` +$inputChannel = ['_' => 'inputChannel', 'channel_id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputChannelEmpty.md b/docs/API_docs/constructors/inputChannelEmpty.md new file mode 100644 index 0000000000..e0b5927dfc --- /dev/null +++ b/docs/API_docs/constructors/inputChannelEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputChannelEmpty" +description: "Represents the absence of a channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChannelEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents the absence of a channel + + + + +### Type: [InputChannel](/API_docs/types/InputChannel.html) + + +### Example: + +``` +$inputChannelEmpty = ['_' => 'inputChannelEmpty']; +``` diff --git a/docs/API_docs/constructors/inputChannelFromMessage.md b/docs/API_docs/constructors/inputChannelFromMessage.md new file mode 100644 index 0000000000..b957d44f27 --- /dev/null +++ b/docs/API_docs/constructors/inputChannelFromMessage.md @@ -0,0 +1,31 @@ +--- +title: "inputChannelFromMessage" +description: "Defines a min channel that was seen in a certain message of a certain chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChannelFromMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a [min](https://core.telegram.org/api/min) channel that was seen in a certain message of a certain chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|The chat where the channel was seen| +|msg\_id|[int](/API_docs/types/int.html) | Yes|The message ID in the chat where the channel was seen| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The channel ID| + + + +### Type: [InputChannel](/API_docs/types/InputChannel.html) + + +### Example: + +``` +$inputChannelFromMessage = ['_' => 'inputChannelFromMessage', 'peer' => InputPeer, 'msg_id' => int, 'channel_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputChatPhoto.md b/docs/API_docs/constructors/inputChatPhoto.md new file mode 100644 index 0000000000..aa0cec8daf --- /dev/null +++ b/docs/API_docs/constructors/inputChatPhoto.md @@ -0,0 +1,29 @@ +--- +title: "inputChatPhoto" +description: "Existing photo to be set as a chat profile photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChatPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Existing photo to be set as a chat profile photo. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[MessageMedia, Message, Update or InputPhoto](/API_docs/types/InputPhoto.html) | Optional|Existing photo| + + + +### Type: [InputChatPhoto](/API_docs/types/InputChatPhoto.html) + + +### Example: + +``` +$inputChatPhoto = ['_' => 'inputChatPhoto', 'id' => InputPhoto]; +``` diff --git a/docs/API_docs/constructors/inputChatPhotoEmpty.md b/docs/API_docs/constructors/inputChatPhotoEmpty.md new file mode 100644 index 0000000000..7ef5a708c8 --- /dev/null +++ b/docs/API_docs/constructors/inputChatPhotoEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputChatPhotoEmpty" +description: "Empty constructor, remove group photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChatPhotoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, remove group photo. + + + + +### Type: [InputChatPhoto](/API_docs/types/InputChatPhoto.html) + + +### Example: + +``` +$inputChatPhotoEmpty = ['_' => 'inputChatPhotoEmpty']; +``` diff --git a/docs/API_docs/constructors/inputChatUploadedPhoto.md b/docs/API_docs/constructors/inputChatUploadedPhoto.md new file mode 100644 index 0000000000..e5e2851e0e --- /dev/null +++ b/docs/API_docs/constructors/inputChatUploadedPhoto.md @@ -0,0 +1,34 @@ +--- +title: "inputChatUploadedPhoto" +description: "New photo to be set as group profile photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChatUploadedPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +New photo to be set as group profile photo. + +The `file`, `video` and `video_emoji_markup` flags are mutually exclusive. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Optional|File saved in parts using the method [upload.saveFilePart](../methods/upload.saveFilePart.html)| +|video|[File path or InputFile](/API_docs/types/InputFile.html) | Optional|Square video for animated profile picture| +|video\_start\_ts|[double](/API_docs/types/double.html) | Optional|Floating point UNIX timestamp in seconds, indicating the frame of the video/sticker that should be used as static preview; can only be used if `video` or `video_emoji_markup` is set.| +|video\_emoji\_markup|[VideoSize](/API_docs/types/VideoSize.html) | Optional|Animated sticker profile picture, must contain either a [videoSizeEmojiMarkup](../constructors/videoSizeEmojiMarkup.html) or a [videoSizeStickerMarkup](../constructors/videoSizeStickerMarkup.html) constructor.| + + + +### Type: [InputChatPhoto](/API_docs/types/InputChatPhoto.html) + + +### Example: + +``` +$inputChatUploadedPhoto = ['_' => 'inputChatUploadedPhoto', 'file' => InputFile, 'video' => InputFile, 'video_start_ts' => double, 'video_emoji_markup' => VideoSize]; +``` diff --git a/docs/API_docs/constructors/inputChatlistDialogFilter.md b/docs/API_docs/constructors/inputChatlistDialogFilter.md new file mode 100644 index 0000000000..62148c79d8 --- /dev/null +++ b/docs/API_docs/constructors/inputChatlistDialogFilter.md @@ -0,0 +1,29 @@ +--- +title: "inputChatlistDialogFilter" +description: "Folder ID" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputChatlistDialogFilter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Folder ID + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|filter\_id|[int](/API_docs/types/int.html) | Yes|[Folder](https://core.telegram.org/api/folders) ID| + + + +### Type: [InputChatlist](/API_docs/types/InputChatlist.html) + + +### Example: + +``` +$inputChatlistDialogFilter = ['_' => 'inputChatlistDialogFilter', 'filter_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputCheckPasswordEmpty.md b/docs/API_docs/constructors/inputCheckPasswordEmpty.md new file mode 100644 index 0000000000..f09fe04bb3 --- /dev/null +++ b/docs/API_docs/constructors/inputCheckPasswordEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputCheckPasswordEmpty" +description: "There is no password" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputCheckPasswordEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +There is no password + + + + +### Type: [InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) + + +### Example: + +``` +$inputCheckPasswordEmpty = ['_' => 'inputCheckPasswordEmpty']; +``` diff --git a/docs/API_docs/constructors/inputCheckPasswordSRP.md b/docs/API_docs/constructors/inputCheckPasswordSRP.md new file mode 100644 index 0000000000..728130fecc --- /dev/null +++ b/docs/API_docs/constructors/inputCheckPasswordSRP.md @@ -0,0 +1,31 @@ +--- +title: "inputCheckPasswordSRP" +description: "Constructor for checking the validity of a 2FA SRP password (see SRP)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputCheckPasswordSRP +[Back to constructors index](/API_docs/constructors/index.html) + + + +Constructor for checking the validity of a 2FA SRP password (see [SRP](https://core.telegram.org/api/srp)) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|srp\_id|[long](/API_docs/types/long.html) | Yes|[SRP ID](https://core.telegram.org/api/srp)| +|A|[bytes](/API_docs/types/bytes.html) | Yes|`A` parameter (see [SRP](https://core.telegram.org/api/srp))| +|M1|[bytes](/API_docs/types/bytes.html) | Yes|`M1` parameter (see [SRP](https://core.telegram.org/api/srp))| + + + +### Type: [InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) + + +### Example: + +``` +$inputCheckPasswordSRP = ['_' => 'inputCheckPasswordSRP', 'srp_id' => long, 'A' => 'bytes', 'M1' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/inputClientProxy.md b/docs/API_docs/constructors/inputClientProxy.md new file mode 100644 index 0000000000..4f3ceb8257 --- /dev/null +++ b/docs/API_docs/constructors/inputClientProxy.md @@ -0,0 +1,30 @@ +--- +title: "inputClientProxy" +description: "Info about an MTProxy used to connect." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputClientProxy +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about an [MTProxy](https://core.telegram.org/mtproto/mtproto-transports#transport-obfuscation) used to connect. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|address|[string](/API_docs/types/string.html) | Yes|Proxy address| +|port|[int](/API_docs/types/int.html) | Yes|Proxy port| + + + +### Type: [InputClientProxy](/API_docs/types/InputClientProxy.html) + + +### Example: + +``` +$inputClientProxy = ['_' => 'inputClientProxy', 'address' => 'string', 'port' => int]; +``` diff --git a/docs/API_docs/constructors/inputCollectiblePhone.md b/docs/API_docs/constructors/inputCollectiblePhone.md new file mode 100644 index 0000000000..b57071e929 --- /dev/null +++ b/docs/API_docs/constructors/inputCollectiblePhone.md @@ -0,0 +1,27 @@ +--- +title: "inputCollectiblePhone" +description: "inputCollectiblePhone attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputCollectiblePhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|phone|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [InputCollectible](/API_docs/types/InputCollectible.html) + + +### Example: + +``` +$inputCollectiblePhone = ['_' => 'inputCollectiblePhone', 'phone' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputCollectibleUsername.md b/docs/API_docs/constructors/inputCollectibleUsername.md new file mode 100644 index 0000000000..47c104c90f --- /dev/null +++ b/docs/API_docs/constructors/inputCollectibleUsername.md @@ -0,0 +1,27 @@ +--- +title: "inputCollectibleUsername" +description: "inputCollectibleUsername attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputCollectibleUsername +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|username|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [InputCollectible](/API_docs/types/InputCollectible.html) + + +### Example: + +``` +$inputCollectibleUsername = ['_' => 'inputCollectibleUsername', 'username' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputDialogPeer.md b/docs/API_docs/constructors/inputDialogPeer.md new file mode 100644 index 0000000000..e5ac837f98 --- /dev/null +++ b/docs/API_docs/constructors/inputDialogPeer.md @@ -0,0 +1,29 @@ +--- +title: "inputDialogPeer" +description: "A peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputDialogPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +A peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Peer| + + + +### Type: [InputDialogPeer](/API_docs/types/InputDialogPeer.html) + + +### Example: + +``` +$inputDialogPeer = ['_' => 'inputDialogPeer', 'peer' => InputPeer]; +``` diff --git a/docs/API_docs/constructors/inputDialogPeerFolder.md b/docs/API_docs/constructors/inputDialogPeerFolder.md new file mode 100644 index 0000000000..4447b87c0f --- /dev/null +++ b/docs/API_docs/constructors/inputDialogPeerFolder.md @@ -0,0 +1,29 @@ +--- +title: "inputDialogPeerFolder" +description: "All peers in a peer folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputDialogPeerFolder +[Back to constructors index](/API_docs/constructors/index.html) + + + +All peers in a [peer folder](https://core.telegram.org/api/folders#peer-folders) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_id|[int](/API_docs/types/int.html) | Yes|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| + + + +### Type: [InputDialogPeer](/API_docs/types/InputDialogPeer.html) + + +### Example: + +``` +$inputDialogPeerFolder = ['_' => 'inputDialogPeerFolder', 'folder_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputDocument.md b/docs/API_docs/constructors/inputDocument.md new file mode 100644 index 0000000000..9c97fa6964 --- /dev/null +++ b/docs/API_docs/constructors/inputDocument.md @@ -0,0 +1,31 @@ +--- +title: "inputDocument" +description: "Defines a document for subsequent interaction." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a document for subsequent interaction. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Document ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|**access\_hash** parameter from the [document](../constructors/document.html) constructor| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[File reference](https://core.telegram.org/api/file_reference)| + + + +### Type: [InputDocument](/API_docs/types/InputDocument.html) + + +### Example: + +``` +$inputDocument = ['_' => 'inputDocument', 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/inputDocumentEmpty.md b/docs/API_docs/constructors/inputDocumentEmpty.md new file mode 100644 index 0000000000..e2d090889c --- /dev/null +++ b/docs/API_docs/constructors/inputDocumentEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputDocumentEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputDocumentEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + + + + +### Type: [InputDocument](/API_docs/types/InputDocument.html) + + +### Example: + +``` +$inputDocumentEmpty = ['_' => 'inputDocumentEmpty']; +``` diff --git a/docs/API_docs/constructors/inputDocumentFileLocation.md b/docs/API_docs/constructors/inputDocumentFileLocation.md new file mode 100644 index 0000000000..02c6916d88 --- /dev/null +++ b/docs/API_docs/constructors/inputDocumentFileLocation.md @@ -0,0 +1,32 @@ +--- +title: "inputDocumentFileLocation" +description: "Document location (video, voice, audio, basically every type except photo)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputDocumentFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document location (video, voice, audio, basically every type except photo) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Document ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|**access\_hash** parameter from the [document](../constructors/document.html) constructor| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[File reference](https://core.telegram.org/api/file_reference)| +|thumb\_size|[string](/API_docs/types/string.html) | Yes|Thumbnail size to download the thumbnail| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputDocumentFileLocation = ['_' => 'inputDocumentFileLocation', 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes', 'thumb_size' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputEncryptedChat.md b/docs/API_docs/constructors/inputEncryptedChat.md new file mode 100644 index 0000000000..a410a151c4 --- /dev/null +++ b/docs/API_docs/constructors/inputEncryptedChat.md @@ -0,0 +1,30 @@ +--- +title: "inputEncryptedChat" +description: "Creates an encrypted chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputEncryptedChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Creates an encrypted chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[int](/API_docs/types/int.html) | Yes|Chat ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Checking sum from constructor [encryptedChat](../constructors/encryptedChat.html), [encryptedChatWaiting](../constructors/encryptedChatWaiting.html) or [encryptedChatRequested](../constructors/encryptedChatRequested.html)| + + + +### Type: [InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) + + +### Example: + +``` +$inputEncryptedChat = ['_' => 'inputEncryptedChat', 'chat_id' => int, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputEncryptedFile.md b/docs/API_docs/constructors/inputEncryptedFile.md new file mode 100644 index 0000000000..5c706cabce --- /dev/null +++ b/docs/API_docs/constructors/inputEncryptedFile.md @@ -0,0 +1,30 @@ +--- +title: "inputEncryptedFile" +description: "Sets forwarded encrypted file for attachment." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputEncryptedFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Sets forwarded encrypted file for attachment. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|File ID, value of **id** parameter from [encryptedFile](../constructors/encryptedFile.html)| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Checking sum, value of **access\_hash** parameter from [encryptedFile](../constructors/encryptedFile.html)| + + + +### Type: [InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) + + +### Example: + +``` +$inputEncryptedFile = ['_' => 'inputEncryptedFile', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputEncryptedFileBigUploaded.md b/docs/API_docs/constructors/inputEncryptedFileBigUploaded.md new file mode 100644 index 0000000000..0a8f1005fd --- /dev/null +++ b/docs/API_docs/constructors/inputEncryptedFileBigUploaded.md @@ -0,0 +1,31 @@ +--- +title: "inputEncryptedFileBigUploaded" +description: "Assigns a new big encrypted file (over 10 MB in size), saved in parts using the method upload.saveBigFilePart." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputEncryptedFileBigUploaded +[Back to constructors index](/API_docs/constructors/index.html) + + + +Assigns a new big encrypted file (over 10 MB in size), saved in parts using the method [upload.saveBigFilePart](../methods/upload.saveBigFilePart.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Random file id, created by the client| +|parts|[int](/API_docs/types/int.html) | Yes|Number of saved parts| +|key\_fingerprint|[int](/API_docs/types/int.html) | Yes|32-bit imprint of the key used to encrypt the file| + + + +### Type: [InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) + + +### Example: + +``` +$inputEncryptedFileBigUploaded = ['_' => 'inputEncryptedFileBigUploaded', 'id' => long, 'parts' => int, 'key_fingerprint' => int]; +``` diff --git a/docs/API_docs/constructors/inputEncryptedFileEmpty.md b/docs/API_docs/constructors/inputEncryptedFileEmpty.md new file mode 100644 index 0000000000..a747f22be7 --- /dev/null +++ b/docs/API_docs/constructors/inputEncryptedFileEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputEncryptedFileEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputEncryptedFileEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + + + + +### Type: [InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) + + +### Example: + +``` +$inputEncryptedFileEmpty = ['_' => 'inputEncryptedFileEmpty']; +``` diff --git a/docs/API_docs/constructors/inputEncryptedFileLocation.md b/docs/API_docs/constructors/inputEncryptedFileLocation.md new file mode 100644 index 0000000000..ffb83d5ff9 --- /dev/null +++ b/docs/API_docs/constructors/inputEncryptedFileLocation.md @@ -0,0 +1,30 @@ +--- +title: "inputEncryptedFileLocation" +description: "Location of encrypted secret chat file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputEncryptedFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Location of encrypted secret chat file. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|File ID, **id** parameter value from [encryptedFile](../constructors/encryptedFile.html)| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Checksum, **access\_hash** parameter value from [encryptedFile](../constructors/encryptedFile.html)| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputEncryptedFileLocation = ['_' => 'inputEncryptedFileLocation', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputEncryptedFileUploaded.md b/docs/API_docs/constructors/inputEncryptedFileUploaded.md new file mode 100644 index 0000000000..640281d706 --- /dev/null +++ b/docs/API_docs/constructors/inputEncryptedFileUploaded.md @@ -0,0 +1,32 @@ +--- +title: "inputEncryptedFileUploaded" +description: "Sets new encrypted file saved by parts using upload.saveFilePart method." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputEncryptedFileUploaded +[Back to constructors index](/API_docs/constructors/index.html) + + + +Sets new encrypted file saved by parts using upload.saveFilePart method. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Random file ID created by client| +|parts|[int](/API_docs/types/int.html) | Yes|Number of saved parts| +|md5\_checksum|[string](/API_docs/types/string.html) | Yes|In case [md5-HASH](https://en.wikipedia.org/wiki/MD5) of the (already encrypted) file was transmitted, file content will be checked prior to use| +|key\_fingerprint|[int](/API_docs/types/int.html) | Yes|32-bit fingerprint of the key used to encrypt a file| + + + +### Type: [InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) + + +### Example: + +``` +$inputEncryptedFileUploaded = ['_' => 'inputEncryptedFileUploaded', 'id' => long, 'parts' => int, 'md5_checksum' => 'string', 'key_fingerprint' => int]; +``` diff --git a/docs/API_docs/constructors/inputFile.md b/docs/API_docs/constructors/inputFile.md new file mode 100644 index 0000000000..0669737ce1 --- /dev/null +++ b/docs/API_docs/constructors/inputFile.md @@ -0,0 +1,32 @@ +--- +title: "inputFile" +description: "Defines a file saved in parts using the method upload.saveFilePart." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a file saved in parts using the method [upload.saveFilePart](../methods/upload.saveFilePart.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Random file identifier created by the client| +|parts|[int](/API_docs/types/int.html) | Yes|Number of parts saved| +|name|[string](/API_docs/types/string.html) | Yes|Full name of the file| +|md5\_checksum|[string](/API_docs/types/string.html) | Yes|In case the file's [md5-hash](https://en.wikipedia.org/wiki/MD5#MD5_hashes) was passed, contents of the file will be checked prior to use| + + + +### Type: [InputFile](/API_docs/types/InputFile.html) + + +### Example: + +``` +$inputFile = ['_' => 'inputFile', 'id' => long, 'parts' => int, 'name' => 'string', 'md5_checksum' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputFileBig.md b/docs/API_docs/constructors/inputFileBig.md new file mode 100644 index 0000000000..3a00636f0f --- /dev/null +++ b/docs/API_docs/constructors/inputFileBig.md @@ -0,0 +1,31 @@ +--- +title: "inputFileBig" +description: "Assigns a big file (over 10 MB in size), saved in part using the method upload.saveBigFilePart." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputFileBig +[Back to constructors index](/API_docs/constructors/index.html) + + + +Assigns a big file (over 10 MB in size), saved in part using the method [upload.saveBigFilePart](../methods/upload.saveBigFilePart.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Random file id, created by the client| +|parts|[int](/API_docs/types/int.html) | Yes|Number of parts saved| +|name|[string](/API_docs/types/string.html) | Yes|Full file name| + + + +### Type: [InputFile](/API_docs/types/InputFile.html) + + +### Example: + +``` +$inputFileBig = ['_' => 'inputFileBig', 'id' => long, 'parts' => int, 'name' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputFileLocation.md b/docs/API_docs/constructors/inputFileLocation.md new file mode 100644 index 0000000000..0fccfb105c --- /dev/null +++ b/docs/API_docs/constructors/inputFileLocation.md @@ -0,0 +1,32 @@ +--- +title: "inputFileLocation" +description: "DEPRECATED location of a photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +DEPRECATED location of a photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|volume\_id|[long](/API_docs/types/long.html) | Yes|Server volume| +|local\_id|[int](/API_docs/types/int.html) | Yes|File identifier| +|secret|[long](/API_docs/types/long.html) | Yes|Check sum to access the file| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[File reference](https://core.telegram.org/api/file_reference)| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputFileLocation = ['_' => 'inputFileLocation', 'volume_id' => long, 'local_id' => int, 'secret' => long, 'file_reference' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/inputFolderPeer.md b/docs/API_docs/constructors/inputFolderPeer.md new file mode 100644 index 0000000000..df6f5234f9 --- /dev/null +++ b/docs/API_docs/constructors/inputFolderPeer.md @@ -0,0 +1,30 @@ +--- +title: "inputFolderPeer" +description: "Peer in a folder" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputFolderPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer in a folder + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Peer| +|folder\_id|[int](/API_docs/types/int.html) | Yes|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| + + + +### Type: [InputFolderPeer](/API_docs/types/InputFolderPeer.html) + + +### Example: + +``` +$inputFolderPeer = ['_' => 'inputFolderPeer', 'peer' => InputPeer, 'folder_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputGameID.md b/docs/API_docs/constructors/inputGameID.md new file mode 100644 index 0000000000..0f9626f785 --- /dev/null +++ b/docs/API_docs/constructors/inputGameID.md @@ -0,0 +1,30 @@ +--- +title: "inputGameID" +description: "Indicates an already sent game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputGameID +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates an already sent game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|game ID from [Game](../types/Game.html) constructor| +|access\_hash|[long](/API_docs/types/long.html) | Yes|access hash from [Game](../types/Game.html) constructor| + + + +### Type: [InputGame](/API_docs/types/InputGame.html) + + +### Example: + +``` +$inputGameID = ['_' => 'inputGameID', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputGameShortName.md b/docs/API_docs/constructors/inputGameShortName.md new file mode 100644 index 0000000000..70351d47eb --- /dev/null +++ b/docs/API_docs/constructors/inputGameShortName.md @@ -0,0 +1,30 @@ +--- +title: "inputGameShortName" +description: "Game by short name" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputGameShortName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Game by short name + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|bot\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional|The bot that provides the game| +|short\_name|[string](/API_docs/types/string.html) | Yes|The game's short name, usually obtained from a [game link »](https://core.telegram.org/api/links#game-links)| + + + +### Type: [InputGame](/API_docs/types/InputGame.html) + + +### Example: + +``` +$inputGameShortName = ['_' => 'inputGameShortName', 'bot_id' => InputUser, 'short_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputGeoPoint.md b/docs/API_docs/constructors/inputGeoPoint.md new file mode 100644 index 0000000000..337ee7e081 --- /dev/null +++ b/docs/API_docs/constructors/inputGeoPoint.md @@ -0,0 +1,31 @@ +--- +title: "inputGeoPoint" +description: "Defines a GeoPoint by its coordinates." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputGeoPoint +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a GeoPoint by its coordinates. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lat|[double](/API_docs/types/double.html) | Yes|Latitude| +|long|[double](/API_docs/types/double.html) | Yes|Longitude| +|accuracy\_radius|[int](/API_docs/types/int.html) | Optional|The estimated horizontal accuracy of the location, in meters; as defined by the sender.| + + + +### Type: [InputGeoPoint](/API_docs/types/InputGeoPoint.html) + + +### Example: + +``` +$inputGeoPoint = ['_' => 'inputGeoPoint', 'lat' => double, 'long' => double, 'accuracy_radius' => int]; +``` diff --git a/docs/API_docs/constructors/inputGeoPointEmpty.md b/docs/API_docs/constructors/inputGeoPointEmpty.md new file mode 100644 index 0000000000..4f426be2d1 --- /dev/null +++ b/docs/API_docs/constructors/inputGeoPointEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputGeoPointEmpty" +description: "Empty GeoPoint constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputGeoPointEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty GeoPoint constructor. + + + + +### Type: [InputGeoPoint](/API_docs/types/InputGeoPoint.html) + + +### Example: + +``` +$inputGeoPointEmpty = ['_' => 'inputGeoPointEmpty']; +``` diff --git a/docs/API_docs/constructors/inputGroupCall.md b/docs/API_docs/constructors/inputGroupCall.md new file mode 100644 index 0000000000..225940837c --- /dev/null +++ b/docs/API_docs/constructors/inputGroupCall.md @@ -0,0 +1,30 @@ +--- +title: "inputGroupCall" +description: "Points to a specific group call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputGroupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Points to a specific group call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Group call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Group call access hash| + + + +### Type: [InputGroupCall](/API_docs/types/InputGroupCall.html) + + +### Example: + +``` +$inputGroupCall = ['_' => 'inputGroupCall', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputGroupCallStream.md b/docs/API_docs/constructors/inputGroupCallStream.md new file mode 100644 index 0000000000..0b7a503aa1 --- /dev/null +++ b/docs/API_docs/constructors/inputGroupCallStream.md @@ -0,0 +1,33 @@ +--- +title: "inputGroupCallStream" +description: "Chunk of a livestream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputGroupCallStream +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chunk of a livestream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|Livestream info| +|time\_ms|[long](/API_docs/types/long.html) | Yes|Timestamp in milliseconds| +|scale|[int](/API_docs/types/int.html) | Yes|Specifies the duration of the video segment to fetch in milliseconds, by bitshifting `1000` to the right `scale` times: `duration_ms := 1000 >> scale`| +|video\_channel|[int](/API_docs/types/int.html) | Optional|Selected video channel| +|video\_quality|[int](/API_docs/types/int.html) | Optional|Selected video quality (0 = lowest, 1 = medium, 2 = best)| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputGroupCallStream = ['_' => 'inputGroupCallStream', 'call' => InputGroupCall, 'time_ms' => long, 'scale' => int, 'video_channel' => int, 'video_quality' => int]; +``` diff --git a/docs/API_docs/constructors/inputInvoiceMessage.md b/docs/API_docs/constructors/inputInvoiceMessage.md new file mode 100644 index 0000000000..956267d306 --- /dev/null +++ b/docs/API_docs/constructors/inputInvoiceMessage.md @@ -0,0 +1,30 @@ +--- +title: "inputInvoiceMessage" +description: "An invoice contained in a messageMediaInvoice message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputInvoiceMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +An invoice contained in a [messageMediaInvoice](../constructors/messageMediaInvoice.html) message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Chat where the invoice was sent| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID| + + + +### Type: [InputInvoice](/API_docs/types/InputInvoice.html) + + +### Example: + +``` +$inputInvoiceMessage = ['_' => 'inputInvoiceMessage', 'peer' => InputPeer, 'msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputInvoicePremiumGiftCode.md b/docs/API_docs/constructors/inputInvoicePremiumGiftCode.md new file mode 100644 index 0000000000..2e6c729128 --- /dev/null +++ b/docs/API_docs/constructors/inputInvoicePremiumGiftCode.md @@ -0,0 +1,30 @@ +--- +title: "inputInvoicePremiumGiftCode" +description: "Used if the user wishes to start a channel giveaway or send some giftcodes to members of a channel, in exchange for boosts." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputInvoicePremiumGiftCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used if the user wishes to start a channel [giveaway](https://core.telegram.org/api/giveaways) or send some [giftcodes](https://core.telegram.org/api/giveaways) to members of a channel, in exchange for [boosts](https://core.telegram.org/api/boost). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|purpose|[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) | Yes|Should be populated with [inputStorePaymentPremiumGiveaway](../constructors/inputStorePaymentPremiumGiveaway.html) for [giveaways](https://core.telegram.org/api/giveaways) and [inputStorePaymentPremiumGiftCode](../constructors/inputStorePaymentPremiumGiftCode.html) for [gifts](https://core.telegram.org/api/giveaways).| +|option|[PremiumGiftCodeOption](/API_docs/types/PremiumGiftCodeOption.html) | Yes|Should be populated with one of the giveaway options returned by [payments.getPremiumGiftCodeOptions](../methods/payments.getPremiumGiftCodeOptions.html), see the [giveaways »](https://core.telegram.org/api/giveaways) documentation for more info.| + + + +### Type: [InputInvoice](/API_docs/types/InputInvoice.html) + + +### Example: + +``` +$inputInvoicePremiumGiftCode = ['_' => 'inputInvoicePremiumGiftCode', 'purpose' => InputStorePaymentPurpose, 'option' => PremiumGiftCodeOption]; +``` diff --git a/docs/API_docs/constructors/inputInvoiceSlug.md b/docs/API_docs/constructors/inputInvoiceSlug.md new file mode 100644 index 0000000000..29a6f4ad9c --- /dev/null +++ b/docs/API_docs/constructors/inputInvoiceSlug.md @@ -0,0 +1,29 @@ +--- +title: "inputInvoiceSlug" +description: "An invoice slug taken from an invoice deep link or from the premium_invoice_slug app config parameter »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputInvoiceSlug +[Back to constructors index](/API_docs/constructors/index.html) + + + +An invoice slug taken from an [invoice deep link](https://core.telegram.org/api/links#invoice-links) or from the [`premium_invoice_slug` app config parameter »](https://core.telegram.org/api/config#premium-invoice-slug) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|slug|[string](/API_docs/types/string.html) | Yes|The invoice slug| + + + +### Type: [InputInvoice](/API_docs/types/InputInvoice.html) + + +### Example: + +``` +$inputInvoiceSlug = ['_' => 'inputInvoiceSlug', 'slug' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputKeyboardButtonRequestPeer.md b/docs/API_docs/constructors/inputKeyboardButtonRequestPeer.md new file mode 100644 index 0000000000..ba8b082c53 --- /dev/null +++ b/docs/API_docs/constructors/inputKeyboardButtonRequestPeer.md @@ -0,0 +1,33 @@ +--- +title: "inputKeyboardButtonRequestPeer" +description: "inputKeyboardButtonRequestPeer attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputKeyboardButtonRequestPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|name\_requested|[Bool](/API_docs/types/Bool.html) | Optional| +|username\_requested|[Bool](/API_docs/types/Bool.html) | Optional| +|photo\_requested|[Bool](/API_docs/types/Bool.html) | Optional| +|text|[string](/API_docs/types/string.html) | Yes| +|button\_id|[int](/API_docs/types/int.html) | Yes| +|peer\_type|[RequestPeerType](/API_docs/types/RequestPeerType.html) | Yes| +|max\_quantity|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$inputKeyboardButtonRequestPeer = ['_' => 'inputKeyboardButtonRequestPeer', 'name_requested' => Bool, 'username_requested' => Bool, 'photo_requested' => Bool, 'text' => 'string', 'button_id' => int, 'peer_type' => RequestPeerType, 'max_quantity' => int]; +``` diff --git a/docs/API_docs/constructors/inputKeyboardButtonUrlAuth.md b/docs/API_docs/constructors/inputKeyboardButtonUrlAuth.md new file mode 100644 index 0000000000..622667417f --- /dev/null +++ b/docs/API_docs/constructors/inputKeyboardButtonUrlAuth.md @@ -0,0 +1,33 @@ +--- +title: "inputKeyboardButtonUrlAuth" +description: "Button to request a user to authorize via URL using Seamless Telegram Login." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputKeyboardButtonUrlAuth +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to request a user to [authorize](../methods/messages.acceptUrlAuth.html) via URL using [Seamless Telegram Login](https://telegram.org/blog/privacy-discussions-web-bots#meet-seamless-web-bots). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|request\_write\_access|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag to request the permission for your bot to send messages to the user.| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|fwd\_text|[string](/API_docs/types/string.html) | Optional|New text of the button in forwarded messages.| +|url|[string](/API_docs/types/string.html) | Yes|An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in [Receiving authorization data](https://core.telegram.org/widgets/login#receiving-authorization-data).
NOTE: You must always check the hash of the received data to verify the authentication and the integrity of the data as described in [Checking authorization](https://core.telegram.org/widgets/login#checking-authorization).| +|bot|[InputUser](/API_docs/types/InputUser.html) | Optional|Username of a bot, which will be used for user authorization. See [Setting up a bot](https://core.telegram.org/widgets/login#setting-up-a-bot) for more details. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See [Linking your domain to the bot](https://core.telegram.org/widgets/login#linking-your-domain-to-the-bot) for more details.| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$inputKeyboardButtonUrlAuth = ['_' => 'inputKeyboardButtonUrlAuth', 'request_write_access' => Bool, 'text' => 'string', 'fwd_text' => 'string', 'url' => 'string', 'bot' => InputUser]; +``` diff --git a/docs/API_docs/constructors/inputKeyboardButtonUserProfile.md b/docs/API_docs/constructors/inputKeyboardButtonUserProfile.md new file mode 100644 index 0000000000..f3e5ddfae9 --- /dev/null +++ b/docs/API_docs/constructors/inputKeyboardButtonUserProfile.md @@ -0,0 +1,30 @@ +--- +title: "inputKeyboardButtonUserProfile" +description: "Button that links directly to a user profile" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputKeyboardButtonUserProfile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button that links directly to a user profile + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|user\_id|[InputUser](/API_docs/types/InputUser.html) | Optional|User ID| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$inputKeyboardButtonUserProfile = ['_' => 'inputKeyboardButtonUserProfile', 'text' => 'string', 'user_id' => InputUser]; +``` diff --git a/docs/API_docs/constructors/inputMediaAreaChannelPost.md b/docs/API_docs/constructors/inputMediaAreaChannelPost.md new file mode 100644 index 0000000000..51d4f310d4 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaAreaChannelPost.md @@ -0,0 +1,31 @@ +--- +title: "inputMediaAreaChannelPost" +description: "Represents a channel post" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaAreaChannelPost +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a channel post + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|coordinates|[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) | Yes|The size and location of the media area corresponding to the location sticker on top of the story media.| +|channel|[InputChannel](/API_docs/types/InputChannel.html) | Optional|The channel that posted the message| +|msg\_id|[int](/API_docs/types/int.html) | Yes|ID of the channel message| + + + +### Type: [MediaArea](/API_docs/types/MediaArea.html) + + +### Example: + +``` +$inputMediaAreaChannelPost = ['_' => 'inputMediaAreaChannelPost', 'coordinates' => MediaAreaCoordinates, 'channel' => InputChannel, 'msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaAreaVenue.md b/docs/API_docs/constructors/inputMediaAreaVenue.md new file mode 100644 index 0000000000..1dd0774d6f --- /dev/null +++ b/docs/API_docs/constructors/inputMediaAreaVenue.md @@ -0,0 +1,31 @@ +--- +title: "inputMediaAreaVenue" +description: "Represents a location tag attached to a story, with additional venue information." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaAreaVenue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [location tag](https://core.telegram.org/api/stories#media-areas) attached to a [story](https://core.telegram.org/api/stories), with additional venue information. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|coordinates|[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) | Yes|The size and location of the media area corresponding to the location sticker on top of the story media.| +|query\_id|[long](/API_docs/types/long.html) | Yes|The `query_id` from [messages.botResults](../constructors/messages.botResults.html), see [here »](https://core.telegram.org/api/stories#media-areas) for more info.| +|result\_id|[string](/API_docs/types/string.html) | Yes|The `id` of the chosen result, see [here »](https://core.telegram.org/api/stories#media-areas) for more info.| + + + +### Type: [MediaArea](/API_docs/types/MediaArea.html) + + +### Example: + +``` +$inputMediaAreaVenue = ['_' => 'inputMediaAreaVenue', 'coordinates' => MediaAreaCoordinates, 'query_id' => long, 'result_id' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputMediaContact.md b/docs/API_docs/constructors/inputMediaContact.md new file mode 100644 index 0000000000..b499b55086 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaContact.md @@ -0,0 +1,32 @@ +--- +title: "inputMediaContact" +description: "Phone book contact" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Phone book contact + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|Contact's first name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Contact's last name| +|vcard|[string](/API_docs/types/string.html) | Yes|Contact vcard| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaContact = ['_' => 'inputMediaContact', 'phone_number' => 'string', 'first_name' => 'string', 'last_name' => 'string', 'vcard' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputMediaDice.md b/docs/API_docs/constructors/inputMediaDice.md new file mode 100644 index 0000000000..381dba3589 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaDice.md @@ -0,0 +1,29 @@ +--- +title: "inputMediaDice" +description: "Send a dice-based animated sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaDice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Send a [dice-based animated sticker](https://core.telegram.org/api/dice) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|The emoji, for now 🏀, 🎲 and 🎯 are supported| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaDice = ['_' => 'inputMediaDice', 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputMediaDocument.md b/docs/API_docs/constructors/inputMediaDocument.md new file mode 100644 index 0000000000..54904cae7e --- /dev/null +++ b/docs/API_docs/constructors/inputMediaDocument.md @@ -0,0 +1,32 @@ +--- +title: "inputMediaDocument" +description: "Forwarded document" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +Forwarded document + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|id|[MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|The document to be forwarded.| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Time to live of self-destructing document| +|query|[string](/API_docs/types/string.html) | Optional|Text query or emoji that was used by the user to find this sticker or GIF: used to improve search result relevance.| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaDocument = ['_' => 'inputMediaDocument', 'spoiler' => Bool, 'id' => InputDocument, 'ttl_seconds' => int, 'query' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputMediaDocumentExternal.md b/docs/API_docs/constructors/inputMediaDocumentExternal.md new file mode 100644 index 0000000000..a2926b253a --- /dev/null +++ b/docs/API_docs/constructors/inputMediaDocumentExternal.md @@ -0,0 +1,31 @@ +--- +title: "inputMediaDocumentExternal" +description: "Document that will be downloaded by the telegram servers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaDocumentExternal +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document that will be downloaded by the telegram servers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|url|[string](/API_docs/types/string.html) | Yes|URL of the document| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Self-destruct time to live of document| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaDocumentExternal = ['_' => 'inputMediaDocumentExternal', 'spoiler' => Bool, 'url' => 'string', 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaEmpty.md b/docs/API_docs/constructors/inputMediaEmpty.md new file mode 100644 index 0000000000..ceeb947fd0 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputMediaEmpty" +description: "Empty media content of a message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty media content of a message. + + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaEmpty = ['_' => 'inputMediaEmpty']; +``` diff --git a/docs/API_docs/constructors/inputMediaGame.md b/docs/API_docs/constructors/inputMediaGame.md new file mode 100644 index 0000000000..a92620ce18 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaGame.md @@ -0,0 +1,29 @@ +--- +title: "inputMediaGame" +description: "A game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaGame +[Back to constructors index](/API_docs/constructors/index.html) + + + +A game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[InputGame](/API_docs/types/InputGame.html) | Yes|The game to forward| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaGame = ['_' => 'inputMediaGame', 'id' => InputGame]; +``` diff --git a/docs/API_docs/constructors/inputMediaGeoLive.md b/docs/API_docs/constructors/inputMediaGeoLive.md new file mode 100644 index 0000000000..fa747c3524 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaGeoLive.md @@ -0,0 +1,33 @@ +--- +title: "inputMediaGeoLive" +description: "Live geolocation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaGeoLive +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Live geolocation](https://core.telegram.org/api/live-location) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|stopped|[Bool](/API_docs/types/Bool.html) | Optional|Whether sending of the geolocation was stopped| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional|Current geolocation| +|heading|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a direction in which the location moves, in degrees; 1-360.| +|period|[int](/API_docs/types/int.html) | Optional|Validity period of the current location| +|proximity\_notification\_radius|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a maximum distance to another chat member for proximity alerts, in meters (0-100000)| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaGeoLive = ['_' => 'inputMediaGeoLive', 'stopped' => Bool, 'geo_point' => InputGeoPoint, 'heading' => int, 'period' => int, 'proximity_notification_radius' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaGeoPoint.md b/docs/API_docs/constructors/inputMediaGeoPoint.md new file mode 100644 index 0000000000..3cb4de3d44 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaGeoPoint.md @@ -0,0 +1,29 @@ +--- +title: "inputMediaGeoPoint" +description: "Map." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaGeoPoint +[Back to constructors index](/API_docs/constructors/index.html) + + + +Map. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional|GeoPoint| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaGeoPoint = ['_' => 'inputMediaGeoPoint', 'geo_point' => InputGeoPoint]; +``` diff --git a/docs/API_docs/constructors/inputMediaInvoice.md b/docs/API_docs/constructors/inputMediaInvoice.md new file mode 100644 index 0000000000..ce5868cb83 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaInvoice.md @@ -0,0 +1,37 @@ +--- +title: "inputMediaInvoice" +description: "Generated invoice of a bot payment" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaInvoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Generated invoice of a [bot payment](https://core.telegram.org/bots/payments) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Product name, 1-32 characters| +|description|[string](/API_docs/types/string.html) | Yes|Product description, 1-255 characters| +|photo|[InputWebDocument](/API_docs/types/InputWebDocument.html) | Optional|URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service. People like it better when they see what they are paying for.| +|invoice|[Invoice](/API_docs/types/Invoice.html) | Yes|The actual invoice| +|payload|[bytes](/API_docs/types/bytes.html) | Yes|Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes.| +|provider|[string](/API_docs/types/string.html) | Yes|Payments provider token, obtained via [Botfather](https://t.me/botfather)| +|provider\_data|[DataJSON](/API_docs/types/DataJSON.html) | Yes|JSON-encoded data about the invoice, which will be shared with the payment provider. A detailed description of required fields should be provided by the payment provider.| +|start\_param|[string](/API_docs/types/string.html) | Optional|Unique [bot deep links start parameter](https://core.telegram.org/api/links#bot-links). If present, forwarded copies of the sent message will have a URL button with a [deep link](https://core.telegram.org/api/links#bot-links) to the bot (instead of a Pay button), with the value used as the start parameter. If absent, forwarded copies of the sent message will have a Pay button, allowing multiple users to pay directly from the forwarded message, using the same invoice.| +|extended\_media|[MessageMedia, Message, Update or InputMedia](/API_docs/types/InputMedia.html) | Optional|Extended media| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaInvoice = ['_' => 'inputMediaInvoice', 'title' => 'string', 'description' => 'string', 'photo' => InputWebDocument, 'invoice' => Invoice, 'payload' => 'bytes', 'provider' => 'string', 'provider_data' => DataJSON, 'start_param' => 'string', 'extended_media' => InputMedia]; +``` diff --git a/docs/API_docs/constructors/inputMediaPhoto.md b/docs/API_docs/constructors/inputMediaPhoto.md new file mode 100644 index 0000000000..d5aad56900 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaPhoto.md @@ -0,0 +1,31 @@ +--- +title: "inputMediaPhoto" +description: "Forwarded photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Forwarded photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|id|[MessageMedia, Message, Update or InputPhoto](/API_docs/types/InputPhoto.html) | Optional|Photo to be forwarded| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Time to live in seconds of self-destructing photo| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaPhoto = ['_' => 'inputMediaPhoto', 'spoiler' => Bool, 'id' => InputPhoto, 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaPhotoExternal.md b/docs/API_docs/constructors/inputMediaPhotoExternal.md new file mode 100644 index 0000000000..6fa1eed5e8 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaPhotoExternal.md @@ -0,0 +1,31 @@ +--- +title: "inputMediaPhotoExternal" +description: "New photo that will be uploaded by the server using the specified URL" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaPhotoExternal +[Back to constructors index](/API_docs/constructors/index.html) + + + +New photo that will be uploaded by the server using the specified URL + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|url|[string](/API_docs/types/string.html) | Yes|URL of the photo| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Self-destruct time to live of photo| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaPhotoExternal = ['_' => 'inputMediaPhotoExternal', 'spoiler' => Bool, 'url' => 'string', 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaPoll.md b/docs/API_docs/constructors/inputMediaPoll.md new file mode 100644 index 0000000000..b7a35fd93a --- /dev/null +++ b/docs/API_docs/constructors/inputMediaPoll.md @@ -0,0 +1,32 @@ +--- +title: "inputMediaPoll" +description: "A poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaPoll +[Back to constructors index](/API_docs/constructors/index.html) + + + +A poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|poll|[Poll](/API_docs/types/Poll.html) | Yes|The poll to send| +|correct\_answers|Array of [bytes](/API_docs/types/bytes.html) | Optional|Correct answer IDs (for quiz polls)| +|solution|[string](/API_docs/types/string.html) | Optional|Explanation of quiz solution| +|solution\_entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaPoll = ['_' => 'inputMediaPoll', 'poll' => Poll, 'correct_answers' => ['bytes', 'bytes'], 'solution' => 'string', 'solution_entities' => [MessageEntity, MessageEntity]]; +``` diff --git a/docs/API_docs/constructors/inputMediaStory.md b/docs/API_docs/constructors/inputMediaStory.md new file mode 100644 index 0000000000..49d5c859e1 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaStory.md @@ -0,0 +1,30 @@ +--- +title: "inputMediaStory" +description: "Forwarded story" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Forwarded story + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Peer where the story was posted| +|id|[int](/API_docs/types/int.html) | Yes|Story ID| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaStory = ['_' => 'inputMediaStory', 'peer' => InputPeer, 'id' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaUploadedDocument.md b/docs/API_docs/constructors/inputMediaUploadedDocument.md new file mode 100644 index 0000000000..68f9ab56c9 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaUploadedDocument.md @@ -0,0 +1,37 @@ +--- +title: "inputMediaUploadedDocument" +description: "New document" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaUploadedDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +New document + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|nosound\_video|[Bool](/API_docs/types/Bool.html) | Optional|Whether the specified document is a video file with no audio tracks (a GIF animation (even as MPEG4), for example)| +|force\_file|[Bool](/API_docs/types/Bool.html) | Optional|Force the media file to be uploaded as document| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Yes|The [uploaded file](https://core.telegram.org/api/files)| +|thumb|[File path or InputFile](/API_docs/types/InputFile.html) | Optional|Thumbnail of the document, uploaded as for the file| +|mime\_type|[string](/API_docs/types/string.html) | Optional|MIME type of document| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Attributes that specify the type of the document (video, audio, voice, sticker, etc.)| +|stickers|Array of [MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|Attached stickers| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Time to live in seconds of self-destructing document| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaUploadedDocument = ['_' => 'inputMediaUploadedDocument', 'nosound_video' => Bool, 'force_file' => Bool, 'spoiler' => Bool, 'file' => InputFile, 'thumb' => InputFile, 'mime_type' => 'string', 'attributes' => [DocumentAttribute, DocumentAttribute], 'stickers' => [InputDocument, InputDocument], 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaUploadedPhoto.md b/docs/API_docs/constructors/inputMediaUploadedPhoto.md new file mode 100644 index 0000000000..05f3c73cab --- /dev/null +++ b/docs/API_docs/constructors/inputMediaUploadedPhoto.md @@ -0,0 +1,32 @@ +--- +title: "inputMediaUploadedPhoto" +description: "Photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaUploadedPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Yes|The [uploaded file](https://core.telegram.org/api/files)| +|stickers|Array of [MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|Attached mask stickers| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Time to live in seconds of self-destructing photo| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaUploadedPhoto = ['_' => 'inputMediaUploadedPhoto', 'spoiler' => Bool, 'file' => InputFile, 'stickers' => [InputDocument, InputDocument], 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/inputMediaVenue.md b/docs/API_docs/constructors/inputMediaVenue.md new file mode 100644 index 0000000000..4dacc91d5e --- /dev/null +++ b/docs/API_docs/constructors/inputMediaVenue.md @@ -0,0 +1,34 @@ +--- +title: "inputMediaVenue" +description: "Can be used to send a venue geolocation." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaVenue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Can be used to send a venue geolocation. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional|Geolocation| +|title|[string](/API_docs/types/string.html) | Yes|Venue name| +|address|[string](/API_docs/types/string.html) | Yes|Physical address of the venue| +|provider|[string](/API_docs/types/string.html) | Yes|Venue provider: currently only "foursquare" and "gplaces" (Google Places) need to be supported| +|venue\_id|[string](/API_docs/types/string.html) | Yes|Venue ID in the provider's database| +|venue\_type|[string](/API_docs/types/string.html) | Yes|Venue type in the provider's database| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaVenue = ['_' => 'inputMediaVenue', 'geo_point' => InputGeoPoint, 'title' => 'string', 'address' => 'string', 'provider' => 'string', 'venue_id' => 'string', 'venue_type' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputMediaWebPage.md b/docs/API_docs/constructors/inputMediaWebPage.md new file mode 100644 index 0000000000..3f1b0dbb98 --- /dev/null +++ b/docs/API_docs/constructors/inputMediaWebPage.md @@ -0,0 +1,32 @@ +--- +title: "inputMediaWebPage" +description: "Specifies options that will be used to generate the link preview for the caption, or even a standalone link preview without an attached message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMediaWebPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Specifies options that will be used to generate the link preview for the caption, or even a standalone link preview without an attached message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|force\_large\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a large media preview should be used.| +|force\_small\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a small media preview should be used.| +|optional|[Bool](/API_docs/types/Bool.html) | Optional|If **not** set, a `WEBPAGE_NOT_FOUND` RPC error will be emitted if a webpage preview cannot be generated for the specified `url`; otherwise, no error will be emitted (unless the provided message is also empty, in which case a `MESSAGE_EMPTY` will be emitted, instead).| +|url|[string](/API_docs/types/string.html) | Yes|The URL to use for the link preview.| + + + +### Type: [InputMedia](/API_docs/types/InputMedia.html) + + +### Example: + +``` +$inputMediaWebPage = ['_' => 'inputMediaWebPage', 'force_large_media' => Bool, 'force_small_media' => Bool, 'optional' => Bool, 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputMessageCallbackQuery.md b/docs/API_docs/constructors/inputMessageCallbackQuery.md new file mode 100644 index 0000000000..4c5157d674 --- /dev/null +++ b/docs/API_docs/constructors/inputMessageCallbackQuery.md @@ -0,0 +1,30 @@ +--- +title: "inputMessageCallbackQuery" +description: "Used by bots for fetching information about the message that originated a callback query" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessageCallbackQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used by bots for fetching information about the message that originated a callback query + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Message ID| +|query\_id|[long](/API_docs/types/long.html) | Yes|Callback query ID| + + + +### Type: [InputMessage](/API_docs/types/InputMessage.html) + + +### Example: + +``` +$inputMessageCallbackQuery = ['_' => 'inputMessageCallbackQuery', 'id' => int, 'query_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputMessageEntityMentionName.md b/docs/API_docs/constructors/inputMessageEntityMentionName.md new file mode 100644 index 0000000000..77c59f039e --- /dev/null +++ b/docs/API_docs/constructors/inputMessageEntityMentionName.md @@ -0,0 +1,31 @@ +--- +title: "inputMessageEntityMentionName" +description: "Message entity that can be used to create a user user mention: received mentions use the messageEntityMentionName constructor, instead." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessageEntityMentionName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity that can be used to create a user [user mention](https://core.telegram.org/api/mentions): received mentions use the [messageEntityMentionName](../constructors/messageEntityMentionName.html) constructor, instead. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|user\_id|[InputUser](/API_docs/types/InputUser.html) | Optional|Identifier of the user that was mentioned| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$inputMessageEntityMentionName = ['_' => 'inputMessageEntityMentionName', 'offset' => int, 'length' => int, 'user_id' => InputUser]; +``` diff --git a/docs/API_docs/constructors/inputMessageID.md b/docs/API_docs/constructors/inputMessageID.md new file mode 100644 index 0000000000..d252db9d7b --- /dev/null +++ b/docs/API_docs/constructors/inputMessageID.md @@ -0,0 +1,29 @@ +--- +title: "inputMessageID" +description: "Message by ID" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessageID +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message by ID + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Message ID| + + + +### Type: [InputMessage](/API_docs/types/InputMessage.html) + + +### Example: + +``` +$inputMessageID = ['_' => 'inputMessageID', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/inputMessagePinned.md b/docs/API_docs/constructors/inputMessagePinned.md new file mode 100644 index 0000000000..0b6f4b565d --- /dev/null +++ b/docs/API_docs/constructors/inputMessagePinned.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagePinned" +description: "Pinned message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagePinned +[Back to constructors index](/API_docs/constructors/index.html) + + + +Pinned message + + + + +### Type: [InputMessage](/API_docs/types/InputMessage.html) + + +### Example: + +``` +$inputMessagePinned = ['_' => 'inputMessagePinned']; +``` diff --git a/docs/API_docs/constructors/inputMessageReplyTo.md b/docs/API_docs/constructors/inputMessageReplyTo.md new file mode 100644 index 0000000000..0b3cd37762 --- /dev/null +++ b/docs/API_docs/constructors/inputMessageReplyTo.md @@ -0,0 +1,29 @@ +--- +title: "inputMessageReplyTo" +description: "Message to which the specified message replies to" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessageReplyTo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message to which the specified message replies to + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|ID of the message that replies to the message we need| + + + +### Type: [InputMessage](/API_docs/types/InputMessage.html) + + +### Example: + +``` +$inputMessageReplyTo = ['_' => 'inputMessageReplyTo', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterChatPhotos.md b/docs/API_docs/constructors/inputMessagesFilterChatPhotos.md new file mode 100644 index 0000000000..aed48dd9e4 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterChatPhotos.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterChatPhotos" +description: "Return only chat photo changes" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterChatPhotos +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only chat photo changes + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterChatPhotos = ['_' => 'inputMessagesFilterChatPhotos']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterContacts.md b/docs/API_docs/constructors/inputMessagesFilterContacts.md new file mode 100644 index 0000000000..da469d94b2 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterContacts.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterContacts" +description: "Return only messages containing contacts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages containing contacts + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterContacts = ['_' => 'inputMessagesFilterContacts']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterDocument.md b/docs/API_docs/constructors/inputMessagesFilterDocument.md new file mode 100644 index 0000000000..b1a5b37167 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterDocument.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterDocument" +description: "Filter for messages containing documents." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter for messages containing documents. + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterDocument = ['_' => 'inputMessagesFilterDocument']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterEmpty.md b/docs/API_docs/constructors/inputMessagesFilterEmpty.md new file mode 100644 index 0000000000..517dac57c2 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterEmpty" +description: "Filter is absent." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter is absent. + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterEmpty = ['_' => 'inputMessagesFilterEmpty']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterGeo.md b/docs/API_docs/constructors/inputMessagesFilterGeo.md new file mode 100644 index 0000000000..2346b73775 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterGeo.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterGeo" +description: "Return only messages containing geolocations" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterGeo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages containing geolocations + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterGeo = ['_' => 'inputMessagesFilterGeo']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterGif.md b/docs/API_docs/constructors/inputMessagesFilterGif.md new file mode 100644 index 0000000000..b1a3d157d2 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterGif.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterGif" +description: "Return only messages containing gifs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterGif +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages containing gifs + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterGif = ['_' => 'inputMessagesFilterGif']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterMusic.md b/docs/API_docs/constructors/inputMessagesFilterMusic.md new file mode 100644 index 0000000000..3e54505ab1 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterMusic.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterMusic" +description: "Return only messages containing audio files" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterMusic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages containing audio files + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterMusic = ['_' => 'inputMessagesFilterMusic']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterMyMentions.md b/docs/API_docs/constructors/inputMessagesFilterMyMentions.md new file mode 100644 index 0000000000..ef2efc2637 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterMyMentions.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterMyMentions" +description: "Return only messages where the current user was mentioned." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterMyMentions +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages where the current user was [mentioned](https://core.telegram.org/api/mentions). + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterMyMentions = ['_' => 'inputMessagesFilterMyMentions']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterPhoneCalls.md b/docs/API_docs/constructors/inputMessagesFilterPhoneCalls.md new file mode 100644 index 0000000000..5fd8a8d9cf --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterPhoneCalls.md @@ -0,0 +1,29 @@ +--- +title: "inputMessagesFilterPhoneCalls" +description: "Return only phone calls" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterPhoneCalls +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only phone calls + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|missed|[Bool](/API_docs/types/Bool.html) | Optional|Return only missed phone calls| + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterPhoneCalls = ['_' => 'inputMessagesFilterPhoneCalls', 'missed' => Bool]; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterPhotoVideo.md b/docs/API_docs/constructors/inputMessagesFilterPhotoVideo.md new file mode 100644 index 0000000000..2f676921f3 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterPhotoVideo.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterPhotoVideo" +description: "Filter for messages containing photos or videos." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterPhotoVideo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter for messages containing photos or videos. + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterPhotoVideo = ['_' => 'inputMessagesFilterPhotoVideo']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterPhotos.md b/docs/API_docs/constructors/inputMessagesFilterPhotos.md new file mode 100644 index 0000000000..ae7b6c36f7 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterPhotos.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterPhotos" +description: "Filter for messages containing photos." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterPhotos +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter for messages containing photos. + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterPhotos = ['_' => 'inputMessagesFilterPhotos']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterPinned.md b/docs/API_docs/constructors/inputMessagesFilterPinned.md new file mode 100644 index 0000000000..43cee9dae1 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterPinned.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterPinned" +description: "Fetch only pinned messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterPinned +[Back to constructors index](/API_docs/constructors/index.html) + + + +Fetch only pinned messages + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterPinned = ['_' => 'inputMessagesFilterPinned']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterRoundVideo.md b/docs/API_docs/constructors/inputMessagesFilterRoundVideo.md new file mode 100644 index 0000000000..5d7a265ab2 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterRoundVideo.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterRoundVideo" +description: "Return only round videos" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterRoundVideo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only round videos + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterRoundVideo = ['_' => 'inputMessagesFilterRoundVideo']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterRoundVoice.md b/docs/API_docs/constructors/inputMessagesFilterRoundVoice.md new file mode 100644 index 0000000000..1a3cb91ba4 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterRoundVoice.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterRoundVoice" +description: "Return only round videos and voice notes" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterRoundVoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only round videos and voice notes + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterRoundVoice = ['_' => 'inputMessagesFilterRoundVoice']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterUrl.md b/docs/API_docs/constructors/inputMessagesFilterUrl.md new file mode 100644 index 0000000000..72a4eccb01 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterUrl.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterUrl" +description: "Return only messages containing URLs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages containing URLs + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterUrl = ['_' => 'inputMessagesFilterUrl']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterVideo.md b/docs/API_docs/constructors/inputMessagesFilterVideo.md new file mode 100644 index 0000000000..799b85bb83 --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterVideo.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterVideo" +description: "Filter for messages containing videos." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterVideo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Filter for messages containing videos. + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterVideo = ['_' => 'inputMessagesFilterVideo']; +``` diff --git a/docs/API_docs/constructors/inputMessagesFilterVoice.md b/docs/API_docs/constructors/inputMessagesFilterVoice.md new file mode 100644 index 0000000000..fb1586b37e --- /dev/null +++ b/docs/API_docs/constructors/inputMessagesFilterVoice.md @@ -0,0 +1,24 @@ +--- +title: "inputMessagesFilterVoice" +description: "Return only messages containing voice notes" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputMessagesFilterVoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Return only messages containing voice notes + + + + +### Type: [MessagesFilter](/API_docs/types/MessagesFilter.html) + + +### Example: + +``` +$inputMessagesFilterVoice = ['_' => 'inputMessagesFilterVoice']; +``` diff --git a/docs/API_docs/constructors/inputNotifyBroadcasts.md b/docs/API_docs/constructors/inputNotifyBroadcasts.md new file mode 100644 index 0000000000..6f9749adf4 --- /dev/null +++ b/docs/API_docs/constructors/inputNotifyBroadcasts.md @@ -0,0 +1,24 @@ +--- +title: "inputNotifyBroadcasts" +description: "All channels" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputNotifyBroadcasts +[Back to constructors index](/API_docs/constructors/index.html) + + + +All [channels](https://core.telegram.org/api/channel) + + + + +### Type: [InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) + + +### Example: + +``` +$inputNotifyBroadcasts = ['_' => 'inputNotifyBroadcasts']; +``` diff --git a/docs/API_docs/constructors/inputNotifyChats.md b/docs/API_docs/constructors/inputNotifyChats.md new file mode 100644 index 0000000000..7ef4d48b0d --- /dev/null +++ b/docs/API_docs/constructors/inputNotifyChats.md @@ -0,0 +1,24 @@ +--- +title: "inputNotifyChats" +description: "Notifications generated by all groups." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputNotifyChats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by all groups. + + + + +### Type: [InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) + + +### Example: + +``` +$inputNotifyChats = ['_' => 'inputNotifyChats']; +``` diff --git a/docs/API_docs/constructors/inputNotifyForumTopic.md b/docs/API_docs/constructors/inputNotifyForumTopic.md new file mode 100644 index 0000000000..9ac7a433a5 --- /dev/null +++ b/docs/API_docs/constructors/inputNotifyForumTopic.md @@ -0,0 +1,30 @@ +--- +title: "inputNotifyForumTopic" +description: "Notifications generated by a topic in a forum." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputNotifyForumTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by a [topic](https://core.telegram.org/api/forum#forum-topics) in a [forum](https://core.telegram.org/api/forum). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Forum ID| +|top\_msg\_id|[int](/API_docs/types/int.html) | Yes|[Topic ID](https://core.telegram.org/api/forum#forum-topics)| + + + +### Type: [InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) + + +### Example: + +``` +$inputNotifyForumTopic = ['_' => 'inputNotifyForumTopic', 'peer' => InputPeer, 'top_msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputNotifyPeer.md b/docs/API_docs/constructors/inputNotifyPeer.md new file mode 100644 index 0000000000..83a3ce31e7 --- /dev/null +++ b/docs/API_docs/constructors/inputNotifyPeer.md @@ -0,0 +1,29 @@ +--- +title: "inputNotifyPeer" +description: "Notifications generated by a certain user or group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputNotifyPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by a certain user or group. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|User or group| + + + +### Type: [InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) + + +### Example: + +``` +$inputNotifyPeer = ['_' => 'inputNotifyPeer', 'peer' => InputPeer]; +``` diff --git a/docs/API_docs/constructors/inputNotifyUsers.md b/docs/API_docs/constructors/inputNotifyUsers.md new file mode 100644 index 0000000000..870c36b1b4 --- /dev/null +++ b/docs/API_docs/constructors/inputNotifyUsers.md @@ -0,0 +1,24 @@ +--- +title: "inputNotifyUsers" +description: "Notifications generated by all users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputNotifyUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by all users. + + + + +### Type: [InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) + + +### Example: + +``` +$inputNotifyUsers = ['_' => 'inputNotifyUsers']; +``` diff --git a/docs/API_docs/constructors/inputPaymentCredentials.md b/docs/API_docs/constructors/inputPaymentCredentials.md new file mode 100644 index 0000000000..0cff77bd33 --- /dev/null +++ b/docs/API_docs/constructors/inputPaymentCredentials.md @@ -0,0 +1,30 @@ +--- +title: "inputPaymentCredentials" +description: "Payment credentials" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPaymentCredentials +[Back to constructors index](/API_docs/constructors/index.html) + + + +Payment credentials + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|save|[Bool](/API_docs/types/Bool.html) | Optional|Save payment credential for future use| +|data|[DataJSON](/API_docs/types/DataJSON.html) | Yes|Payment credentials| + + + +### Type: [InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html) + + +### Example: + +``` +$inputPaymentCredentials = ['_' => 'inputPaymentCredentials', 'save' => Bool, 'data' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/inputPaymentCredentialsApplePay.md b/docs/API_docs/constructors/inputPaymentCredentialsApplePay.md new file mode 100644 index 0000000000..6421858018 --- /dev/null +++ b/docs/API_docs/constructors/inputPaymentCredentialsApplePay.md @@ -0,0 +1,29 @@ +--- +title: "inputPaymentCredentialsApplePay" +description: "Apple pay payment credentials" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPaymentCredentialsApplePay +[Back to constructors index](/API_docs/constructors/index.html) + + + +Apple pay payment credentials + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|payment\_data|[DataJSON](/API_docs/types/DataJSON.html) | Yes|Payment data| + + + +### Type: [InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html) + + +### Example: + +``` +$inputPaymentCredentialsApplePay = ['_' => 'inputPaymentCredentialsApplePay', 'payment_data' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/inputPaymentCredentialsGooglePay.md b/docs/API_docs/constructors/inputPaymentCredentialsGooglePay.md new file mode 100644 index 0000000000..cc0f83fca6 --- /dev/null +++ b/docs/API_docs/constructors/inputPaymentCredentialsGooglePay.md @@ -0,0 +1,29 @@ +--- +title: "inputPaymentCredentialsGooglePay" +description: "Google Pay payment credentials" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPaymentCredentialsGooglePay +[Back to constructors index](/API_docs/constructors/index.html) + + + +Google Pay payment credentials + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|payment\_token|[DataJSON](/API_docs/types/DataJSON.html) | Yes|Payment token| + + + +### Type: [InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html) + + +### Example: + +``` +$inputPaymentCredentialsGooglePay = ['_' => 'inputPaymentCredentialsGooglePay', 'payment_token' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/inputPaymentCredentialsSaved.md b/docs/API_docs/constructors/inputPaymentCredentialsSaved.md new file mode 100644 index 0000000000..de2ebeda2f --- /dev/null +++ b/docs/API_docs/constructors/inputPaymentCredentialsSaved.md @@ -0,0 +1,30 @@ +--- +title: "inputPaymentCredentialsSaved" +description: "Saved payment credentials" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPaymentCredentialsSaved +[Back to constructors index](/API_docs/constructors/index.html) + + + +Saved payment credentials + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Credential ID| +|tmp\_password|[bytes](/API_docs/types/bytes.html) | Yes|Temporary password| + + + +### Type: [InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html) + + +### Example: + +``` +$inputPaymentCredentialsSaved = ['_' => 'inputPaymentCredentialsSaved', 'id' => 'string', 'tmp_password' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/inputPeerChannel.md b/docs/API_docs/constructors/inputPeerChannel.md new file mode 100644 index 0000000000..b56c487ecc --- /dev/null +++ b/docs/API_docs/constructors/inputPeerChannel.md @@ -0,0 +1,30 @@ +--- +title: "inputPeerChannel" +description: "Defines a channel for further interaction." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a channel for further interaction. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel identifier| +|access\_hash|[long](/API_docs/types/long.html) | Yes|**access\_hash** value from the [channel](../constructors/channel.html) constructor| + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerChannel = ['_' => 'inputPeerChannel', 'channel_id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputPeerChannelFromMessage.md b/docs/API_docs/constructors/inputPeerChannelFromMessage.md new file mode 100644 index 0000000000..bdba308148 --- /dev/null +++ b/docs/API_docs/constructors/inputPeerChannelFromMessage.md @@ -0,0 +1,31 @@ +--- +title: "inputPeerChannelFromMessage" +description: "Defines a min channel that was seen in a certain message of a certain chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerChannelFromMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a [min](https://core.telegram.org/api/min) channel that was seen in a certain message of a certain chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|The chat where the channel's message was seen| +|msg\_id|[int](/API_docs/types/int.html) | Yes|The message ID| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The identifier of the channel that was seen| + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerChannelFromMessage = ['_' => 'inputPeerChannelFromMessage', 'peer' => InputPeer, 'msg_id' => int, 'channel_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputPeerChat.md b/docs/API_docs/constructors/inputPeerChat.md new file mode 100644 index 0000000000..f41a202503 --- /dev/null +++ b/docs/API_docs/constructors/inputPeerChat.md @@ -0,0 +1,29 @@ +--- +title: "inputPeerChat" +description: "Defines a chat for further interaction." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a chat for further interaction. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Chat identifier| + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerChat = ['_' => 'inputPeerChat', 'chat_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputPeerEmpty.md b/docs/API_docs/constructors/inputPeerEmpty.md new file mode 100644 index 0000000000..40195dff50 --- /dev/null +++ b/docs/API_docs/constructors/inputPeerEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputPeerEmpty" +description: "An empty constructor, no user or chat is defined." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +An empty constructor, no user or chat is defined. + + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerEmpty = ['_' => 'inputPeerEmpty']; +``` diff --git a/docs/API_docs/constructors/inputPeerNotifySettings.md b/docs/API_docs/constructors/inputPeerNotifySettings.md new file mode 100644 index 0000000000..18110dd47b --- /dev/null +++ b/docs/API_docs/constructors/inputPeerNotifySettings.md @@ -0,0 +1,35 @@ +--- +title: "inputPeerNotifySettings" +description: "Notification settings." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerNotifySettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notification settings. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|show\_previews|[Bool](/API_docs/types/Bool.html) | Optional|If the text of the message shall be displayed in notification| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|Peer was muted?| +|mute\_until|[int](/API_docs/types/int.html) | Optional|Date until which all notifications shall be switched off| +|sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Identifier of an audio file to play for notifications.| +|stories\_muted|[Bool](/API_docs/types/Bool.html) | Optional|Whether story notifications should be disabled.| +|stories\_hide\_sender|[Bool](/API_docs/types/Bool.html) | Optional|Whether the sender name should be displayed in story notifications.| +|stories\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Identifier of an audio file to play for story notifications.| + + + +### Type: [InputPeerNotifySettings](/API_docs/types/InputPeerNotifySettings.html) + + +### Example: + +``` +$inputPeerNotifySettings = ['_' => 'inputPeerNotifySettings', 'show_previews' => Bool, 'silent' => Bool, 'mute_until' => int, 'sound' => NotificationSound, 'stories_muted' => Bool, 'stories_hide_sender' => Bool, 'stories_sound' => NotificationSound]; +``` diff --git a/docs/API_docs/constructors/inputPeerPhotoFileLocation.md b/docs/API_docs/constructors/inputPeerPhotoFileLocation.md new file mode 100644 index 0000000000..a817c6b3c3 --- /dev/null +++ b/docs/API_docs/constructors/inputPeerPhotoFileLocation.md @@ -0,0 +1,31 @@ +--- +title: "inputPeerPhotoFileLocation" +description: "Location of profile photo of channel/group/supergroup/user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerPhotoFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Location of profile photo of channel/group/supergroup/user + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|big|[Bool](/API_docs/types/Bool.html) | Optional|Whether to download the high-quality version of the picture| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|The peer whose profile picture should be downloaded| +|photo\_id|[long](/API_docs/types/long.html) | Yes|Photo ID| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputPeerPhotoFileLocation = ['_' => 'inputPeerPhotoFileLocation', 'big' => Bool, 'peer' => InputPeer, 'photo_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputPeerSelf.md b/docs/API_docs/constructors/inputPeerSelf.md new file mode 100644 index 0000000000..e1b891ab8e --- /dev/null +++ b/docs/API_docs/constructors/inputPeerSelf.md @@ -0,0 +1,24 @@ +--- +title: "inputPeerSelf" +description: "Defines the current user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerSelf +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines the current user. + + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerSelf = ['_' => 'inputPeerSelf']; +``` diff --git a/docs/API_docs/constructors/inputPeerUser.md b/docs/API_docs/constructors/inputPeerUser.md new file mode 100644 index 0000000000..319126e37c --- /dev/null +++ b/docs/API_docs/constructors/inputPeerUser.md @@ -0,0 +1,30 @@ +--- +title: "inputPeerUser" +description: "Defines a user for further interaction." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a user for further interaction. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|access\_hash|[long](/API_docs/types/long.html) | Yes|**access\_hash** value from the [user](../constructors/user.html) constructor| + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerUser = ['_' => 'inputPeerUser', 'user_id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputPeerUserFromMessage.md b/docs/API_docs/constructors/inputPeerUserFromMessage.md new file mode 100644 index 0000000000..fdf6a60f57 --- /dev/null +++ b/docs/API_docs/constructors/inputPeerUserFromMessage.md @@ -0,0 +1,31 @@ +--- +title: "inputPeerUserFromMessage" +description: "Defines a min user that was seen in a certain message of a certain chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPeerUserFromMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a [min](https://core.telegram.org/api/min) user that was seen in a certain message of a certain chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|The chat where the user was seen| +|msg\_id|[int](/API_docs/types/int.html) | Yes|The message ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|The identifier of the user that was seen| + + + +### Type: [InputPeer](/API_docs/types/InputPeer.html) + + +### Example: + +``` +$inputPeerUserFromMessage = ['_' => 'inputPeerUserFromMessage', 'peer' => InputPeer, 'msg_id' => int, 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputPhoneCall.md b/docs/API_docs/constructors/inputPhoneCall.md new file mode 100644 index 0000000000..41345a525d --- /dev/null +++ b/docs/API_docs/constructors/inputPhoneCall.md @@ -0,0 +1,30 @@ +--- +title: "inputPhoneCall" +description: "Phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPhoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| + + + +### Type: [InputPhoneCall](/API_docs/types/InputPhoneCall.html) + + +### Example: + +``` +$inputPhoneCall = ['_' => 'inputPhoneCall', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputPhoneContact.md b/docs/API_docs/constructors/inputPhoneContact.md new file mode 100644 index 0000000000..174a5e7106 --- /dev/null +++ b/docs/API_docs/constructors/inputPhoneContact.md @@ -0,0 +1,32 @@ +--- +title: "inputPhoneContact" +description: "Phone contact." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPhoneContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Phone contact. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|client\_id|[long](/API_docs/types/long.html) | Yes|An arbitrary 64-bit integer: it should be set, for example, to an incremental number when using [contacts.importContacts](../methods/contacts.importContacts.html), in order to retry importing only the contacts that weren't imported successfully, according to the client\_ids returned in [contacts.importedContacts](../constructors/contacts.importedContacts.html).`retry_contacts`.| +|phone|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|Contact's first name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Contact's last name| + + + +### Type: [InputContact](/API_docs/types/InputContact.html) + + +### Example: + +``` +$inputPhoneContact = ['_' => 'inputPhoneContact', 'client_id' => long, 'phone' => 'string', 'first_name' => 'string', 'last_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputPhoto.md b/docs/API_docs/constructors/inputPhoto.md new file mode 100644 index 0000000000..04b18d3e4b --- /dev/null +++ b/docs/API_docs/constructors/inputPhoto.md @@ -0,0 +1,31 @@ +--- +title: "inputPhoto" +description: "Defines a photo for further interaction." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a photo for further interaction. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Photo identifier| +|access\_hash|[long](/API_docs/types/long.html) | Yes|**access\_hash** value from the [photo](../constructors/photo.html) constructor| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[File reference](https://core.telegram.org/api/file_reference)| + + + +### Type: [InputPhoto](/API_docs/types/InputPhoto.html) + + +### Example: + +``` +$inputPhoto = ['_' => 'inputPhoto', 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/inputPhotoEmpty.md b/docs/API_docs/constructors/inputPhotoEmpty.md new file mode 100644 index 0000000000..2ec2204276 --- /dev/null +++ b/docs/API_docs/constructors/inputPhotoEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputPhotoEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPhotoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + + + + +### Type: [InputPhoto](/API_docs/types/InputPhoto.html) + + +### Example: + +``` +$inputPhotoEmpty = ['_' => 'inputPhotoEmpty']; +``` diff --git a/docs/API_docs/constructors/inputPhotoFileLocation.md b/docs/API_docs/constructors/inputPhotoFileLocation.md new file mode 100644 index 0000000000..5dc9dd62af --- /dev/null +++ b/docs/API_docs/constructors/inputPhotoFileLocation.md @@ -0,0 +1,32 @@ +--- +title: "inputPhotoFileLocation" +description: "Use this object to download a photo with upload.getFile method" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPhotoFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Use this object to download a photo with [upload.getFile](../methods/upload.getFile.html) method + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Photo ID, obtained from the [photo](../constructors/photo.html) object| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Photo's access hash, obtained from the [photo](../constructors/photo.html) object| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[File reference](https://core.telegram.org/api/file_reference)| +|thumb\_size|[string](/API_docs/types/string.html) | Yes|The [PhotoSize](../types/PhotoSize.html) to download: must be set to the `type` field of the desired PhotoSize object of the [photo](../constructors/photo.html)| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputPhotoFileLocation = ['_' => 'inputPhotoFileLocation', 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes', 'thumb_size' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputPhotoLegacyFileLocation.md b/docs/API_docs/constructors/inputPhotoLegacyFileLocation.md new file mode 100644 index 0000000000..36ba1adc5a --- /dev/null +++ b/docs/API_docs/constructors/inputPhotoLegacyFileLocation.md @@ -0,0 +1,34 @@ +--- +title: "inputPhotoLegacyFileLocation" +description: "DEPRECATED legacy photo file location" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPhotoLegacyFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +DEPRECATED legacy photo file location + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Photo ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|File reference| +|volume\_id|[long](/API_docs/types/long.html) | Yes|Volume ID| +|local\_id|[int](/API_docs/types/int.html) | Yes|Local ID| +|secret|[long](/API_docs/types/long.html) | Yes|Secret| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputPhotoLegacyFileLocation = ['_' => 'inputPhotoLegacyFileLocation', 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes', 'volume_id' => long, 'local_id' => int, 'secret' => long]; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyAbout.md b/docs/API_docs/constructors/inputPrivacyKeyAbout.md new file mode 100644 index 0000000000..aca846de12 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyAbout.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyAbout" +description: "Whether people can see your bio" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyAbout +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people can see your bio + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyAbout = ['_' => 'inputPrivacyKeyAbout']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyAddedByPhone.md b/docs/API_docs/constructors/inputPrivacyKeyAddedByPhone.md new file mode 100644 index 0000000000..3e55faf379 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyAddedByPhone.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyAddedByPhone" +description: "Whether people can add you to their contact list by your phone number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyAddedByPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people can add you to their contact list by your phone number + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyAddedByPhone = ['_' => 'inputPrivacyKeyAddedByPhone']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyBirthday.md b/docs/API_docs/constructors/inputPrivacyKeyBirthday.md new file mode 100644 index 0000000000..5cde39a874 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyBirthday.md @@ -0,0 +1,22 @@ +--- +title: "inputPrivacyKeyBirthday" +description: "inputPrivacyKeyBirthday attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyBirthday +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyBirthday = ['_' => 'inputPrivacyKeyBirthday']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyChatInvite.md b/docs/API_docs/constructors/inputPrivacyKeyChatInvite.md new file mode 100644 index 0000000000..07868b74c8 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyChatInvite.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyChatInvite" +description: "Whether people will be able to invite you to chats" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyChatInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people will be able to invite you to chats + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyChatInvite = ['_' => 'inputPrivacyKeyChatInvite']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyForwards.md b/docs/API_docs/constructors/inputPrivacyKeyForwards.md new file mode 100644 index 0000000000..049cfb9597 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyForwards.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyForwards" +description: "Whether messages forwarded from you will be anonymous" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyForwards +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether messages forwarded from you will be [anonymous](https://telegram.org/blog/unsend-privacy-emoji#anonymous-forwarding) + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyForwards = ['_' => 'inputPrivacyKeyForwards']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyPhoneCall.md b/docs/API_docs/constructors/inputPrivacyKeyPhoneCall.md new file mode 100644 index 0000000000..1cdbd4ef06 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyPhoneCall.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyPhoneCall" +description: "Whether you will accept phone calls" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyPhoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether you will accept phone calls + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyPhoneCall = ['_' => 'inputPrivacyKeyPhoneCall']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyPhoneNumber.md b/docs/API_docs/constructors/inputPrivacyKeyPhoneNumber.md new file mode 100644 index 0000000000..7e4c7120b8 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyPhoneNumber.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyPhoneNumber" +description: "Whether people will be able to see your phone number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyPhoneNumber +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people will be able to see your phone number + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyPhoneNumber = ['_' => 'inputPrivacyKeyPhoneNumber']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyPhoneP2P.md b/docs/API_docs/constructors/inputPrivacyKeyPhoneP2P.md new file mode 100644 index 0000000000..6a65c40b12 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyPhoneP2P.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyPhoneP2P" +description: "Whether to allow P2P communication during VoIP calls" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyPhoneP2P +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether to allow P2P communication during VoIP calls + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyPhoneP2P = ['_' => 'inputPrivacyKeyPhoneP2P']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyProfilePhoto.md b/docs/API_docs/constructors/inputPrivacyKeyProfilePhoto.md new file mode 100644 index 0000000000..e63504d89c --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyProfilePhoto.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyProfilePhoto" +description: "Whether people will be able to see your profile picture" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyProfilePhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people will be able to see your profile picture + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyProfilePhoto = ['_' => 'inputPrivacyKeyProfilePhoto']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyStatusTimestamp.md b/docs/API_docs/constructors/inputPrivacyKeyStatusTimestamp.md new file mode 100644 index 0000000000..f8915c5146 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyStatusTimestamp.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyStatusTimestamp" +description: "Whether people will be able to see your exact last online timestamp" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyStatusTimestamp +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people will be able to see your exact last online timestamp + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyStatusTimestamp = ['_' => 'inputPrivacyKeyStatusTimestamp']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyKeyVoiceMessages.md b/docs/API_docs/constructors/inputPrivacyKeyVoiceMessages.md new file mode 100644 index 0000000000..3a2d87ae4b --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyKeyVoiceMessages.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyKeyVoiceMessages" +description: "Whether people can send you voice messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyKeyVoiceMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people can send you voice messages + + + + +### Type: [InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + + +### Example: + +``` +$inputPrivacyKeyVoiceMessages = ['_' => 'inputPrivacyKeyVoiceMessages']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueAllowAll.md b/docs/API_docs/constructors/inputPrivacyValueAllowAll.md new file mode 100644 index 0000000000..006bb0beca --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueAllowAll.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyValueAllowAll" +description: "Allow all users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueAllowAll +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow all users + + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueAllowAll = ['_' => 'inputPrivacyValueAllowAll']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueAllowChatParticipants.md b/docs/API_docs/constructors/inputPrivacyValueAllowChatParticipants.md new file mode 100644 index 0000000000..879e8a5a36 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueAllowChatParticipants.md @@ -0,0 +1,29 @@ +--- +title: "inputPrivacyValueAllowChatParticipants" +description: "Allow only participants of certain chats" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueAllowChatParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow only participants of certain chats + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chats|Array of [long](/API_docs/types/long.html) | Yes|Allowed chat IDs| + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueAllowChatParticipants = ['_' => 'inputPrivacyValueAllowChatParticipants', 'chats' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueAllowCloseFriends.md b/docs/API_docs/constructors/inputPrivacyValueAllowCloseFriends.md new file mode 100644 index 0000000000..bfa6f93527 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueAllowCloseFriends.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyValueAllowCloseFriends" +description: "Allow only close friends »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueAllowCloseFriends +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow only [close friends »](https://core.telegram.org/api/privacy) + + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueAllowCloseFriends = ['_' => 'inputPrivacyValueAllowCloseFriends']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueAllowContacts.md b/docs/API_docs/constructors/inputPrivacyValueAllowContacts.md new file mode 100644 index 0000000000..0513a7514e --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueAllowContacts.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyValueAllowContacts" +description: "Allow only contacts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueAllowContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow only contacts + + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueAllowContacts = ['_' => 'inputPrivacyValueAllowContacts']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueAllowPremium.md b/docs/API_docs/constructors/inputPrivacyValueAllowPremium.md new file mode 100644 index 0000000000..558ea08798 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueAllowPremium.md @@ -0,0 +1,22 @@ +--- +title: "inputPrivacyValueAllowPremium" +description: "inputPrivacyValueAllowPremium attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueAllowPremium +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueAllowPremium = ['_' => 'inputPrivacyValueAllowPremium']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueAllowUsers.md b/docs/API_docs/constructors/inputPrivacyValueAllowUsers.md new file mode 100644 index 0000000000..986bbe4980 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueAllowUsers.md @@ -0,0 +1,29 @@ +--- +title: "inputPrivacyValueAllowUsers" +description: "Allow only certain users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueAllowUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow only certain users + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Yes|Allowed users| + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueAllowUsers = ['_' => 'inputPrivacyValueAllowUsers', 'users' => [InputUser, InputUser]]; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueDisallowAll.md b/docs/API_docs/constructors/inputPrivacyValueDisallowAll.md new file mode 100644 index 0000000000..c6a9a373fb --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueDisallowAll.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyValueDisallowAll" +description: "Disallow all" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueDisallowAll +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow all + + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueDisallowAll = ['_' => 'inputPrivacyValueDisallowAll']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueDisallowChatParticipants.md b/docs/API_docs/constructors/inputPrivacyValueDisallowChatParticipants.md new file mode 100644 index 0000000000..9cb2fe9bf3 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueDisallowChatParticipants.md @@ -0,0 +1,29 @@ +--- +title: "inputPrivacyValueDisallowChatParticipants" +description: "Disallow only participants of certain chats" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueDisallowChatParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow only participants of certain chats + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chats|Array of [long](/API_docs/types/long.html) | Yes|Disallowed chat IDs| + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueDisallowChatParticipants = ['_' => 'inputPrivacyValueDisallowChatParticipants', 'chats' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueDisallowContacts.md b/docs/API_docs/constructors/inputPrivacyValueDisallowContacts.md new file mode 100644 index 0000000000..b3cb129c31 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueDisallowContacts.md @@ -0,0 +1,24 @@ +--- +title: "inputPrivacyValueDisallowContacts" +description: "Disallow only contacts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueDisallowContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow only contacts + + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueDisallowContacts = ['_' => 'inputPrivacyValueDisallowContacts']; +``` diff --git a/docs/API_docs/constructors/inputPrivacyValueDisallowUsers.md b/docs/API_docs/constructors/inputPrivacyValueDisallowUsers.md new file mode 100644 index 0000000000..ce50b253a9 --- /dev/null +++ b/docs/API_docs/constructors/inputPrivacyValueDisallowUsers.md @@ -0,0 +1,29 @@ +--- +title: "inputPrivacyValueDisallowUsers" +description: "Disallow only certain users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputPrivacyValueDisallowUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow only certain users + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Yes|Users to disallow| + + + +### Type: [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + + +### Example: + +``` +$inputPrivacyValueDisallowUsers = ['_' => 'inputPrivacyValueDisallowUsers', 'users' => [InputUser, InputUser]]; +``` diff --git a/docs/API_docs/constructors/inputQuickReplyShortcut.md b/docs/API_docs/constructors/inputQuickReplyShortcut.md new file mode 100644 index 0000000000..1eb144d750 --- /dev/null +++ b/docs/API_docs/constructors/inputQuickReplyShortcut.md @@ -0,0 +1,27 @@ +--- +title: "inputQuickReplyShortcut" +description: "inputQuickReplyShortcut attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputQuickReplyShortcut +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) + + +### Example: + +``` +$inputQuickReplyShortcut = ['_' => 'inputQuickReplyShortcut', 'shortcut' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputQuickReplyShortcutId.md b/docs/API_docs/constructors/inputQuickReplyShortcutId.md new file mode 100644 index 0000000000..83513d79a1 --- /dev/null +++ b/docs/API_docs/constructors/inputQuickReplyShortcutId.md @@ -0,0 +1,27 @@ +--- +title: "inputQuickReplyShortcutId" +description: "inputQuickReplyShortcutId attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputQuickReplyShortcutId +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) + + +### Example: + +``` +$inputQuickReplyShortcutId = ['_' => 'inputQuickReplyShortcutId', 'shortcut_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputReplyToMessage.md b/docs/API_docs/constructors/inputReplyToMessage.md new file mode 100644 index 0000000000..2508f55965 --- /dev/null +++ b/docs/API_docs/constructors/inputReplyToMessage.md @@ -0,0 +1,34 @@ +--- +title: "inputReplyToMessage" +description: "Reply to a message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReplyToMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Reply to a message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|reply\_to\_msg\_id|[int](/API_docs/types/int.html) | Yes|The message ID to reply to.| +|top\_msg\_id|[int](/API_docs/types/int.html) | Optional|This field must contain the topic ID **only** when replying to messages in forum topics different from the "General" topic (i.e. `reply_to_msg_id` is set and `reply_to_msg_id != topicID` and `topicID != 1`).
If the replied-to message is deleted before the method finishes execution, the value in this field will be used to send the message to the correct topic, instead of the "General" topic.| +|reply\_to\_peer\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Used to reply to messages sent to another chat (specified here), can only be used for non-`protected` chats and messages.| +|quote\_text|[string](/API_docs/types/string.html) | Optional|Used to quote-reply to only a certain section (specified here) of the original message. The maximum UTF-8 length for quotes is specified in the [quote\_length\_max](https://core.telegram.org/api/config#quote-length-max) config key.| +|quote\_entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities) from the `quote_text` field.| +|quote\_offset|[int](/API_docs/types/int.html) | Optional|Offset of the message `quote_text` within the original message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length)).| + + + +### Type: [InputReplyTo](/API_docs/types/InputReplyTo.html) + + +### Example: + +``` +$inputReplyToMessage = ['_' => 'inputReplyToMessage', 'reply_to_msg_id' => int, 'top_msg_id' => int, 'reply_to_peer_id' => InputPeer, 'quote_text' => 'string', 'quote_entities' => [MessageEntity, MessageEntity], 'quote_offset' => int]; +``` diff --git a/docs/API_docs/constructors/inputReplyToStory.md b/docs/API_docs/constructors/inputReplyToStory.md new file mode 100644 index 0000000000..18575674a4 --- /dev/null +++ b/docs/API_docs/constructors/inputReplyToStory.md @@ -0,0 +1,30 @@ +--- +title: "inputReplyToStory" +description: "Reply to a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReplyToStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Reply to a story. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| +|story\_id|[int](/API_docs/types/int.html) | Yes|ID of the story to reply to.| + + + +### Type: [InputReplyTo](/API_docs/types/InputReplyTo.html) + + +### Example: + +``` +$inputReplyToStory = ['_' => 'inputReplyToStory', 'peer' => InputPeer, 'story_id' => int]; +``` diff --git a/docs/API_docs/constructors/inputReportReasonChildAbuse.md b/docs/API_docs/constructors/inputReportReasonChildAbuse.md new file mode 100644 index 0000000000..0b8f6b1d7f --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonChildAbuse.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonChildAbuse" +description: "Report for child abuse" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonChildAbuse +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for child abuse + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonChildAbuse = ['_' => 'inputReportReasonChildAbuse']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonCopyright.md b/docs/API_docs/constructors/inputReportReasonCopyright.md new file mode 100644 index 0000000000..274a97f098 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonCopyright.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonCopyright" +description: "Report for copyrighted content" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonCopyright +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for copyrighted content + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonCopyright = ['_' => 'inputReportReasonCopyright']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonFake.md b/docs/API_docs/constructors/inputReportReasonFake.md new file mode 100644 index 0000000000..2de96805d9 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonFake.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonFake" +description: "Report for impersonation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonFake +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for impersonation + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonFake = ['_' => 'inputReportReasonFake']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonGeoIrrelevant.md b/docs/API_docs/constructors/inputReportReasonGeoIrrelevant.md new file mode 100644 index 0000000000..41d3193a95 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonGeoIrrelevant.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonGeoIrrelevant" +description: "Report an irrelevant geogroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonGeoIrrelevant +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report an irrelevant geogroup + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonGeoIrrelevant = ['_' => 'inputReportReasonGeoIrrelevant']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonIllegalDrugs.md b/docs/API_docs/constructors/inputReportReasonIllegalDrugs.md new file mode 100644 index 0000000000..1e1378f19a --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonIllegalDrugs.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonIllegalDrugs" +description: "Report for illegal drugs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonIllegalDrugs +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for illegal drugs + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonIllegalDrugs = ['_' => 'inputReportReasonIllegalDrugs']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonOther.md b/docs/API_docs/constructors/inputReportReasonOther.md new file mode 100644 index 0000000000..ea052df844 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonOther.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonOther" +description: "Other" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonOther +[Back to constructors index](/API_docs/constructors/index.html) + + + +Other + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonOther = ['_' => 'inputReportReasonOther']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonPersonalDetails.md b/docs/API_docs/constructors/inputReportReasonPersonalDetails.md new file mode 100644 index 0000000000..181b13e3a1 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonPersonalDetails.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonPersonalDetails" +description: "Report for divulgation of personal details" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonPersonalDetails +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for divulgation of personal details + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonPersonalDetails = ['_' => 'inputReportReasonPersonalDetails']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonPornography.md b/docs/API_docs/constructors/inputReportReasonPornography.md new file mode 100644 index 0000000000..fc1d1c47a6 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonPornography.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonPornography" +description: "Report for pornography" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonPornography +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for pornography + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonPornography = ['_' => 'inputReportReasonPornography']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonSpam.md b/docs/API_docs/constructors/inputReportReasonSpam.md new file mode 100644 index 0000000000..a408873903 --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonSpam.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonSpam" +description: "Report for spam" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonSpam +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for spam + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonSpam = ['_' => 'inputReportReasonSpam']; +``` diff --git a/docs/API_docs/constructors/inputReportReasonViolence.md b/docs/API_docs/constructors/inputReportReasonViolence.md new file mode 100644 index 0000000000..7eb784303e --- /dev/null +++ b/docs/API_docs/constructors/inputReportReasonViolence.md @@ -0,0 +1,24 @@ +--- +title: "inputReportReasonViolence" +description: "Report for violence" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputReportReasonViolence +[Back to constructors index](/API_docs/constructors/index.html) + + + +Report for violence + + + + +### Type: [ReportReason](/API_docs/types/ReportReason.html) + + +### Example: + +``` +$inputReportReasonViolence = ['_' => 'inputReportReasonViolence']; +``` diff --git a/docs/API_docs/constructors/inputSecureFile.md b/docs/API_docs/constructors/inputSecureFile.md new file mode 100644 index 0000000000..9e0ac20c2a --- /dev/null +++ b/docs/API_docs/constructors/inputSecureFile.md @@ -0,0 +1,30 @@ +--- +title: "inputSecureFile" +description: "Pre-uploaded passport file, for more info see the passport docs »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputSecureFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Pre-uploaded [passport](https://core.telegram.org/passport) file, for more info [see the passport docs »](https://core.telegram.org/passport/encryption#inputsecurefile) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Secure file ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Secure file access hash| + + + +### Type: [InputSecureFile](/API_docs/types/InputSecureFile.html) + + +### Example: + +``` +$inputSecureFile = ['_' => 'inputSecureFile', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputSecureFileLocation.md b/docs/API_docs/constructors/inputSecureFileLocation.md new file mode 100644 index 0000000000..98236f136b --- /dev/null +++ b/docs/API_docs/constructors/inputSecureFileLocation.md @@ -0,0 +1,30 @@ +--- +title: "inputSecureFileLocation" +description: "Location of encrypted telegram passport file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputSecureFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Location of encrypted telegram [passport](https://core.telegram.org/passport) file. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|File ID, **id** parameter value from [secureFile](../constructors/secureFile.html)| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Checksum, **access\_hash** parameter value from [secureFile](../constructors/secureFile.html)| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputSecureFileLocation = ['_' => 'inputSecureFileLocation', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputSecureFileUploaded.md b/docs/API_docs/constructors/inputSecureFileUploaded.md new file mode 100644 index 0000000000..2e7bba5040 --- /dev/null +++ b/docs/API_docs/constructors/inputSecureFileUploaded.md @@ -0,0 +1,33 @@ +--- +title: "inputSecureFileUploaded" +description: "Uploaded secure file, for more info see the passport docs »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputSecureFileUploaded +[Back to constructors index](/API_docs/constructors/index.html) + + + +Uploaded secure file, for more info [see the passport docs »](https://core.telegram.org/passport/encryption#inputsecurefile) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Secure file ID| +|parts|[int](/API_docs/types/int.html) | Yes|Secure file part count| +|md5\_checksum|[string](/API_docs/types/string.html) | Yes|MD5 hash of encrypted uploaded file, to be checked server-side| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|secret|[bytes](/API_docs/types/bytes.html) | Yes|Secret| + + + +### Type: [InputSecureFile](/API_docs/types/InputSecureFile.html) + + +### Example: + +``` +$inputSecureFileUploaded = ['_' => 'inputSecureFileUploaded', 'id' => long, 'parts' => int, 'md5_checksum' => 'string', 'file_hash' => 'bytes', 'secret' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/inputSecureValue.md b/docs/API_docs/constructors/inputSecureValue.md new file mode 100644 index 0000000000..aac28bb8d5 --- /dev/null +++ b/docs/API_docs/constructors/inputSecureValue.md @@ -0,0 +1,36 @@ +--- +title: "inputSecureValue" +description: "Secure value, for more info see the passport docs »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputSecureValue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure value, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|Secure [passport](https://core.telegram.org/passport) value type| +|data|[SecureData](/API_docs/types/SecureData.html) | Optional|Encrypted [Telegram Passport](https://core.telegram.org/passport) element data| +|front\_side|[InputSecureFile](/API_docs/types/InputSecureFile.html) | Optional|Encrypted [passport](https://core.telegram.org/passport) file with the front side of the document| +|reverse\_side|[InputSecureFile](/API_docs/types/InputSecureFile.html) | Optional|Encrypted [passport](https://core.telegram.org/passport) file with the reverse side of the document| +|selfie|[InputSecureFile](/API_docs/types/InputSecureFile.html) | Optional|Encrypted [passport](https://core.telegram.org/passport) file with a selfie of the user holding the document| +|translation|Array of [InputSecureFile](/API_docs/types/InputSecureFile.html) | Optional|Array of encrypted [passport](https://core.telegram.org/passport) files with translated versions of the provided documents| +|files|Array of [InputSecureFile](/API_docs/types/InputSecureFile.html) | Optional|Array of encrypted [passport](https://core.telegram.org/passport) files with photos the of the documents| +|plain\_data|[SecurePlainData](/API_docs/types/SecurePlainData.html) | Optional|Plaintext verified [passport](https://core.telegram.org/passport) data| + + + +### Type: [InputSecureValue](/API_docs/types/InputSecureValue.html) + + +### Example: + +``` +$inputSecureValue = ['_' => 'inputSecureValue', 'type' => SecureValueType, 'data' => SecureData, 'front_side' => InputSecureFile, 'reverse_side' => InputSecureFile, 'selfie' => InputSecureFile, 'translation' => [InputSecureFile, InputSecureFile], 'files' => [InputSecureFile, InputSecureFile], 'plain_data' => SecurePlainData]; +``` diff --git a/docs/API_docs/constructors/inputSingleMedia.md b/docs/API_docs/constructors/inputSingleMedia.md new file mode 100644 index 0000000000..7c314fed29 --- /dev/null +++ b/docs/API_docs/constructors/inputSingleMedia.md @@ -0,0 +1,92 @@ +--- +title: "inputSingleMedia" +description: "A single media in an album or grouped media sent with messages.sendMultiMedia." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputSingleMedia +[Back to constructors index](/API_docs/constructors/index.html) + + + +A single media in an [album or grouped media](https://core.telegram.org/api/files#albums-grouped-media) sent with [messages.sendMultiMedia](../methods/messages.sendMultiMedia.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|media|[MessageMedia, Message, Update or InputMedia](/API_docs/types/InputMedia.html) | Optional|The media| +|message|[string](/API_docs/types/string.html) | Yes|A caption for the media| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|Message [entities](https://core.telegram.org/api/entities) for styled text| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + + +### Type: [InputSingleMedia](/API_docs/types/InputSingleMedia.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$inputSingleMedia = ['_' => 'inputSingleMedia', 'media' => InputMedia, 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', ]; +``` diff --git a/docs/API_docs/constructors/inputStickerSetAnimatedEmoji.md b/docs/API_docs/constructors/inputStickerSetAnimatedEmoji.md new file mode 100644 index 0000000000..690287b400 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetAnimatedEmoji.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetAnimatedEmoji" +description: "Animated emojis stickerset" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetAnimatedEmoji +[Back to constructors index](/API_docs/constructors/index.html) + + + +Animated emojis stickerset + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetAnimatedEmoji = ['_' => 'inputStickerSetAnimatedEmoji']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetAnimatedEmojiAnimations.md b/docs/API_docs/constructors/inputStickerSetAnimatedEmojiAnimations.md new file mode 100644 index 0000000000..10d18cecdb --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetAnimatedEmojiAnimations.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetAnimatedEmojiAnimations" +description: "Animated emoji reaction stickerset (contains animations to play when a user clicks on a given animated emoji)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetAnimatedEmojiAnimations +[Back to constructors index](/API_docs/constructors/index.html) + + + +Animated emoji reaction stickerset (contains animations to play when a user clicks on a given animated emoji) + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetAnimatedEmojiAnimations = ['_' => 'inputStickerSetAnimatedEmojiAnimations']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetDice.md b/docs/API_docs/constructors/inputStickerSetDice.md new file mode 100644 index 0000000000..d2db1fd36f --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetDice.md @@ -0,0 +1,29 @@ +--- +title: "inputStickerSetDice" +description: "Used for fetching animated dice stickers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetDice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used for fetching [animated dice stickers](https://core.telegram.org/api/dice) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|The emoji, for now 🏀, 🎲 and 🎯 are supported| + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetDice = ['_' => 'inputStickerSetDice', 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetEmojiChannelDefaultStatuses.md b/docs/API_docs/constructors/inputStickerSetEmojiChannelDefaultStatuses.md new file mode 100644 index 0000000000..5e2fdbc0b3 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetEmojiChannelDefaultStatuses.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetEmojiChannelDefaultStatuses" +description: "Default custom emoji status stickerset for channel statuses" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetEmojiChannelDefaultStatuses +[Back to constructors index](/API_docs/constructors/index.html) + + + +Default [custom emoji status](https://core.telegram.org/api/emoji-status) stickerset for channel statuses + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetEmojiChannelDefaultStatuses = ['_' => 'inputStickerSetEmojiChannelDefaultStatuses']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetEmojiDefaultStatuses.md b/docs/API_docs/constructors/inputStickerSetEmojiDefaultStatuses.md new file mode 100644 index 0000000000..62f289ad73 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetEmojiDefaultStatuses.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetEmojiDefaultStatuses" +description: "Default custom emoji status stickerset" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetEmojiDefaultStatuses +[Back to constructors index](/API_docs/constructors/index.html) + + + +Default [custom emoji status](https://core.telegram.org/api/emoji-status) stickerset + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetEmojiDefaultStatuses = ['_' => 'inputStickerSetEmojiDefaultStatuses']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.md b/docs/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.md new file mode 100644 index 0000000000..818553b71c --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetEmojiDefaultTopicIcons" +description: "Default custom emoji stickerset for forum topic icons" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetEmojiDefaultTopicIcons +[Back to constructors index](/API_docs/constructors/index.html) + + + +Default [custom emoji](https://core.telegram.org/api/custom-emoji) stickerset for [forum topic icons](https://core.telegram.org/api/forum#forum-topics) + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetEmojiDefaultTopicIcons = ['_' => 'inputStickerSetEmojiDefaultTopicIcons']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetEmojiGenericAnimations.md b/docs/API_docs/constructors/inputStickerSetEmojiGenericAnimations.md new file mode 100644 index 0000000000..ee81399c33 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetEmojiGenericAnimations.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetEmojiGenericAnimations" +description: "Generic animation stickerset containing animations to play when reacting to messages using a normal emoji without a custom animation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetEmojiGenericAnimations +[Back to constructors index](/API_docs/constructors/index.html) + + + +Generic animation stickerset containing animations to play when [reacting to messages using a normal emoji without a custom animation](https://core.telegram.org/api/reactions) + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetEmojiGenericAnimations = ['_' => 'inputStickerSetEmojiGenericAnimations']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetEmpty.md b/docs/API_docs/constructors/inputStickerSetEmpty.md new file mode 100644 index 0000000000..295d0df465 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetEmpty" +description: "Empty constructor" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetEmpty = ['_' => 'inputStickerSetEmpty']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetID.md b/docs/API_docs/constructors/inputStickerSetID.md new file mode 100644 index 0000000000..3910a81193 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetID.md @@ -0,0 +1,30 @@ +--- +title: "inputStickerSetID" +description: "Stickerset by ID" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetID +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickerset by ID + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetID = ['_' => 'inputStickerSetID', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputStickerSetItem.md b/docs/API_docs/constructors/inputStickerSetItem.md new file mode 100644 index 0000000000..6d01a63156 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetItem.md @@ -0,0 +1,32 @@ +--- +title: "inputStickerSetItem" +description: "Sticker in a stickerset" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetItem +[Back to constructors index](/API_docs/constructors/index.html) + + + +Sticker in a stickerset + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document|[MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|The sticker| +|emoji|[string](/API_docs/types/string.html) | Yes|Associated emoji| +|mask\_coords|[MaskCoords](/API_docs/types/MaskCoords.html) | Optional|Coordinates for mask sticker| +|keywords|[string](/API_docs/types/string.html) | Optional|Set of keywords, separated by commas (can't be provided for mask stickers)| + + + +### Type: [InputStickerSetItem](/API_docs/types/InputStickerSetItem.html) + + +### Example: + +``` +$inputStickerSetItem = ['_' => 'inputStickerSetItem', 'document' => InputDocument, 'emoji' => 'string', 'mask_coords' => MaskCoords, 'keywords' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetPremiumGifts.md b/docs/API_docs/constructors/inputStickerSetPremiumGifts.md new file mode 100644 index 0000000000..80702abfea --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetPremiumGifts.md @@ -0,0 +1,24 @@ +--- +title: "inputStickerSetPremiumGifts" +description: "Stickers to show when receiving a gifted Telegram Premium subscription" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetPremiumGifts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickers to show when receiving a gifted Telegram Premium subscription + + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetPremiumGifts = ['_' => 'inputStickerSetPremiumGifts']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetShortName.md b/docs/API_docs/constructors/inputStickerSetShortName.md new file mode 100644 index 0000000000..bd66cab664 --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetShortName.md @@ -0,0 +1,29 @@ +--- +title: "inputStickerSetShortName" +description: "Stickerset by short name, from a stickerset deep link »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetShortName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickerset by short name, from a [stickerset deep link »](https://core.telegram.org/api/links#stickerset-links) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|short\_name|[string](/API_docs/types/string.html) | Yes|Short name from a [stickerset deep link »](https://core.telegram.org/api/links#stickerset-links)| + + + +### Type: [InputStickerSet](/API_docs/types/InputStickerSet.html) + + +### Example: + +``` +$inputStickerSetShortName = ['_' => 'inputStickerSetShortName', 'short_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputStickerSetThumb.md b/docs/API_docs/constructors/inputStickerSetThumb.md new file mode 100644 index 0000000000..3fb52b6fca --- /dev/null +++ b/docs/API_docs/constructors/inputStickerSetThumb.md @@ -0,0 +1,30 @@ +--- +title: "inputStickerSetThumb" +description: "Location of stickerset thumbnail (see files)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickerSetThumb +[Back to constructors index](/API_docs/constructors/index.html) + + + +Location of stickerset thumbnail (see [files](https://core.telegram.org/api/files)) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|Sticker set| +|thumb\_version|[int](/API_docs/types/int.html) | Yes|Thumbnail version| + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputStickerSetThumb = ['_' => 'inputStickerSetThumb', 'stickerset' => InputStickerSet, 'thumb_version' => int]; +``` diff --git a/docs/API_docs/constructors/inputStickeredMediaDocument.md b/docs/API_docs/constructors/inputStickeredMediaDocument.md new file mode 100644 index 0000000000..199b1df9b7 --- /dev/null +++ b/docs/API_docs/constructors/inputStickeredMediaDocument.md @@ -0,0 +1,29 @@ +--- +title: "inputStickeredMediaDocument" +description: "A document with stickers attached" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickeredMediaDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +A document with stickers attached + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|The document| + + + +### Type: [InputStickeredMedia](/API_docs/types/InputStickeredMedia.html) + + +### Example: + +``` +$inputStickeredMediaDocument = ['_' => 'inputStickeredMediaDocument', 'id' => InputDocument]; +``` diff --git a/docs/API_docs/constructors/inputStickeredMediaPhoto.md b/docs/API_docs/constructors/inputStickeredMediaPhoto.md new file mode 100644 index 0000000000..d252a8e973 --- /dev/null +++ b/docs/API_docs/constructors/inputStickeredMediaPhoto.md @@ -0,0 +1,29 @@ +--- +title: "inputStickeredMediaPhoto" +description: "A photo with stickers attached" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStickeredMediaPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +A photo with stickers attached + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[MessageMedia, Message, Update or InputPhoto](/API_docs/types/InputPhoto.html) | Optional|The photo| + + + +### Type: [InputStickeredMedia](/API_docs/types/InputStickeredMedia.html) + + +### Example: + +``` +$inputStickeredMediaPhoto = ['_' => 'inputStickeredMediaPhoto', 'id' => InputPhoto]; +``` diff --git a/docs/API_docs/constructors/inputStorePaymentGiftPremium.md b/docs/API_docs/constructors/inputStorePaymentGiftPremium.md new file mode 100644 index 0000000000..4b0d3b6654 --- /dev/null +++ b/docs/API_docs/constructors/inputStorePaymentGiftPremium.md @@ -0,0 +1,31 @@ +--- +title: "inputStorePaymentGiftPremium" +description: "Info about a gifted Telegram Premium purchase" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStorePaymentGiftPremium +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a gifted Telegram Premium purchase + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional|The user to which the Telegram Premium subscription was gifted| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| + + + +### Type: [InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) + + +### Example: + +``` +$inputStorePaymentGiftPremium = ['_' => 'inputStorePaymentGiftPremium', 'user_id' => InputUser, 'currency' => 'string', 'amount' => long]; +``` diff --git a/docs/API_docs/constructors/inputStorePaymentPremiumGiftCode.md b/docs/API_docs/constructors/inputStorePaymentPremiumGiftCode.md new file mode 100644 index 0000000000..47ad33c20c --- /dev/null +++ b/docs/API_docs/constructors/inputStorePaymentPremiumGiftCode.md @@ -0,0 +1,32 @@ +--- +title: "inputStorePaymentPremiumGiftCode" +description: "Used to gift Telegram Premium subscriptions only to some specific subscribers of a channel or to some of our contacts, see here » for more info on giveaways and gifts." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStorePaymentPremiumGiftCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to gift [Telegram Premium](https://core.telegram.org/api/premium) subscriptions only to some specific subscribers of a channel or to some of our contacts, see [here »](https://core.telegram.org/api/giveaways) for more info on giveaways and gifts. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Yes|The users that will receive the [Telegram Premium](https://core.telegram.org/api/premium) subscriptions.| +|boost\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|If set, the gifts will be sent on behalf of a channel we are an admin of, which will also assign some [boosts](https://core.telegram.org/api/boost) to it. Otherwise, the gift will be sent directly from the currently logged in users, and we will gain some extra [boost slots](https://core.telegram.org/api/boost). See [here »](https://core.telegram.org/api/giveaways) for more info on giveaways and gifts.| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| + + + +### Type: [InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) + + +### Example: + +``` +$inputStorePaymentPremiumGiftCode = ['_' => 'inputStorePaymentPremiumGiftCode', 'users' => [InputUser, InputUser], 'boost_peer' => InputPeer, 'currency' => 'string', 'amount' => long]; +``` diff --git a/docs/API_docs/constructors/inputStorePaymentPremiumGiveaway.md b/docs/API_docs/constructors/inputStorePaymentPremiumGiveaway.md new file mode 100644 index 0000000000..d577a4a544 --- /dev/null +++ b/docs/API_docs/constructors/inputStorePaymentPremiumGiveaway.md @@ -0,0 +1,37 @@ +--- +title: "inputStorePaymentPremiumGiveaway" +description: "Used to pay for a giveaway, see here » for more info." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStorePaymentPremiumGiveaway +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to pay for a [giveaway, see here »](https://core.telegram.org/api/giveaways) for more info. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|only\_new\_subscribers|[Bool](/API_docs/types/Bool.html) | Optional|If set, only new subscribers starting from the giveaway creation date will be able to participate to the giveaway.| +|winners\_are\_visible|[Bool](/API_docs/types/Bool.html) | Optional|If set, giveaway winners are public and will be listed in a [messageMediaGiveawayResults](../constructors/messageMediaGiveawayResults.html) message that will be automatically sent to the channel once the giveaway ends.| +|boost\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|The channel starting the giveaway, that the user must join to participate, that will receive the giveaway [boosts](https://core.telegram.org/api/boost); see [here »](https://core.telegram.org/api/giveaways) for more info on giveaways.| +|additional\_peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|Additional channels that the user must join to participate to the giveaway can be specified here.| +|countries\_iso2|Array of [string](/API_docs/types/string.html) | Optional|The set of users that can participate to the giveaway can be restricted by passing here an explicit whitelist of up to [giveaway\_countries\_max](https://core.telegram.org/api/config#giveaway-countries-max) countries, specified as two-letter ISO 3166-1 alpha-2 country codes.| +|prize\_description|[string](/API_docs/types/string.html) | Optional|Can contain a textual description of additional giveaway prizes.| +|until\_date|[int](/API_docs/types/int.html) | Yes|The end date of the giveaway, must be at most [giveaway\_period\_max](https://core.telegram.org/api/config#giveaway-period-max) seconds in the future; see [here »](https://core.telegram.org/api/giveaways) for more info on giveaways.| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| + + + +### Type: [InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) + + +### Example: + +``` +$inputStorePaymentPremiumGiveaway = ['_' => 'inputStorePaymentPremiumGiveaway', 'only_new_subscribers' => Bool, 'winners_are_visible' => Bool, 'boost_peer' => InputPeer, 'additional_peers' => [InputPeer, InputPeer], 'countries_iso2' => ['string', 'string'], 'prize_description' => 'string', 'until_date' => int, 'currency' => 'string', 'amount' => long]; +``` diff --git a/docs/API_docs/constructors/inputStorePaymentPremiumSubscription.md b/docs/API_docs/constructors/inputStorePaymentPremiumSubscription.md new file mode 100644 index 0000000000..ce87e94bff --- /dev/null +++ b/docs/API_docs/constructors/inputStorePaymentPremiumSubscription.md @@ -0,0 +1,30 @@ +--- +title: "inputStorePaymentPremiumSubscription" +description: "Info about a Telegram Premium purchase" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputStorePaymentPremiumSubscription +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a Telegram Premium purchase + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|restore|[Bool](/API_docs/types/Bool.html) | Optional|Pass true if this is a restore of a Telegram Premium purchase; only for the App Store| +|upgrade|[Bool](/API_docs/types/Bool.html) | Optional|Pass true if this is an upgrade from a monthly subscription to a yearly subscription; only for App Store| + + + +### Type: [InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) + + +### Example: + +``` +$inputStorePaymentPremiumSubscription = ['_' => 'inputStorePaymentPremiumSubscription', 'restore' => Bool, 'upgrade' => Bool]; +``` diff --git a/docs/API_docs/constructors/inputTakeoutFileLocation.md b/docs/API_docs/constructors/inputTakeoutFileLocation.md new file mode 100644 index 0000000000..8bf1def1d7 --- /dev/null +++ b/docs/API_docs/constructors/inputTakeoutFileLocation.md @@ -0,0 +1,24 @@ +--- +title: "inputTakeoutFileLocation" +description: "Used to download a JSON file that will contain all personal data related to features that do not have a specialized takeout method yet, see here » for more info on the takeout API." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputTakeoutFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to download a JSON file that will contain all personal data related to features that do not have a specialized [takeout method](https://core.telegram.org/api/takeout) yet, see [here »](https://core.telegram.org/api/takeout) for more info on the takeout API. + + + + +### Type: [InputFileLocation](/API_docs/types/InputFileLocation.html) + + +### Example: + +``` +$inputTakeoutFileLocation = ['_' => 'inputTakeoutFileLocation']; +``` diff --git a/docs/API_docs/constructors/inputTheme.md b/docs/API_docs/constructors/inputTheme.md new file mode 100644 index 0000000000..067ea88894 --- /dev/null +++ b/docs/API_docs/constructors/inputTheme.md @@ -0,0 +1,30 @@ +--- +title: "inputTheme" +description: "Theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputTheme +[Back to constructors index](/API_docs/constructors/index.html) + + + +Theme + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| + + + +### Type: [InputTheme](/API_docs/types/InputTheme.html) + + +### Example: + +``` +$inputTheme = ['_' => 'inputTheme', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputThemeSettings.md b/docs/API_docs/constructors/inputThemeSettings.md new file mode 100644 index 0000000000..3c4b08f370 --- /dev/null +++ b/docs/API_docs/constructors/inputThemeSettings.md @@ -0,0 +1,35 @@ +--- +title: "inputThemeSettings" +description: "Theme settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputThemeSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Theme settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message\_colors\_animated|[Bool](/API_docs/types/Bool.html) | Optional|If set, the freeform gradient fill needs to be animated on every sent message| +|base\_theme|[BaseTheme](/API_docs/types/BaseTheme.html) | Yes|Default theme on which this theme is based| +|accent\_color|[int](/API_docs/types/int.html) | Yes|Accent color, ARGB format| +|outbox\_accent\_color|[int](/API_docs/types/int.html) | Optional|Accent color of outgoing messages in ARGB format| +|message\_colors|Array of [int](/API_docs/types/int.html) | Optional|The fill to be used as a background for outgoing messages, in RGB24 format.
If just one or two equal colors are provided, describes a solid fill of a background.
If two different colors are provided, describes the top and bottom colors of a 0-degree gradient.
If three or four colors are provided, describes a freeform gradient fill of a background.| +|wallpaper|[InputWallPaper](/API_docs/types/InputWallPaper.html) | Optional|[inputWallPaper](../constructors/inputWallPaper.html) or [inputWallPaperSlug](../constructors/inputWallPaper.html) when passing wallpaper files for [image](https://core.telegram.org/api/wallpapers#image-wallpapers) or [pattern](https://core.telegram.org/api/wallpapers#pattern-wallpapers) wallpapers, [inputWallPaperNoFile](../constructors/inputWallPaperNoFile.html) with `id=0` otherwise.| +|wallpaper\_settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | Optional|[Wallpaper](https://core.telegram.org/api/wallpapers) settings.| + + + +### Type: [InputThemeSettings](/API_docs/types/InputThemeSettings.html) + + +### Example: + +``` +$inputThemeSettings = ['_' => 'inputThemeSettings', 'message_colors_animated' => Bool, 'base_theme' => BaseTheme, 'accent_color' => int, 'outbox_accent_color' => int, 'message_colors' => [int, int], 'wallpaper' => InputWallPaper, 'wallpaper_settings' => WallPaperSettings]; +``` diff --git a/docs/API_docs/constructors/inputThemeSlug.md b/docs/API_docs/constructors/inputThemeSlug.md new file mode 100644 index 0000000000..c9078c1fa0 --- /dev/null +++ b/docs/API_docs/constructors/inputThemeSlug.md @@ -0,0 +1,29 @@ +--- +title: "inputThemeSlug" +description: "Theme by theme ID" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputThemeSlug +[Back to constructors index](/API_docs/constructors/index.html) + + + +Theme by theme ID + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|slug|[string](/API_docs/types/string.html) | Yes|Unique theme ID obtained from a [theme deep link »](https://core.telegram.org/api/links#theme-links)| + + + +### Type: [InputTheme](/API_docs/types/InputTheme.html) + + +### Example: + +``` +$inputThemeSlug = ['_' => 'inputThemeSlug', 'slug' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputUser.md b/docs/API_docs/constructors/inputUser.md new file mode 100644 index 0000000000..de31b5455c --- /dev/null +++ b/docs/API_docs/constructors/inputUser.md @@ -0,0 +1,30 @@ +--- +title: "inputUser" +description: "Defines a user for further interaction." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a user for further interaction. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|access\_hash|[long](/API_docs/types/long.html) | Yes|**access\_hash** value from the [user](../constructors/user.html) constructor| + + + +### Type: [InputUser](/API_docs/types/InputUser.html) + + +### Example: + +``` +$inputUser = ['_' => 'inputUser', 'user_id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputUserEmpty.md b/docs/API_docs/constructors/inputUserEmpty.md new file mode 100644 index 0000000000..6c7bf93952 --- /dev/null +++ b/docs/API_docs/constructors/inputUserEmpty.md @@ -0,0 +1,24 @@ +--- +title: "inputUserEmpty" +description: "Empty constructor, does not define a user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputUserEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, does not define a user. + + + + +### Type: [InputUser](/API_docs/types/InputUser.html) + + +### Example: + +``` +$inputUserEmpty = ['_' => 'inputUserEmpty']; +``` diff --git a/docs/API_docs/constructors/inputUserFromMessage.md b/docs/API_docs/constructors/inputUserFromMessage.md new file mode 100644 index 0000000000..17d686d39f --- /dev/null +++ b/docs/API_docs/constructors/inputUserFromMessage.md @@ -0,0 +1,31 @@ +--- +title: "inputUserFromMessage" +description: "Defines a min user that was seen in a certain message of a certain chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputUserFromMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines a [min](https://core.telegram.org/api/min) user that was seen in a certain message of a certain chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional|The chat where the user was seen| +|msg\_id|[int](/API_docs/types/int.html) | Yes|The message ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|The identifier of the user that was seen| + + + +### Type: [InputUser](/API_docs/types/InputUser.html) + + +### Example: + +``` +$inputUserFromMessage = ['_' => 'inputUserFromMessage', 'peer' => InputPeer, 'msg_id' => int, 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/inputUserSelf.md b/docs/API_docs/constructors/inputUserSelf.md new file mode 100644 index 0000000000..a0925ee67d --- /dev/null +++ b/docs/API_docs/constructors/inputUserSelf.md @@ -0,0 +1,24 @@ +--- +title: "inputUserSelf" +description: "Defines the current user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputUserSelf +[Back to constructors index](/API_docs/constructors/index.html) + + + +Defines the current user. + + + + +### Type: [InputUser](/API_docs/types/InputUser.html) + + +### Example: + +``` +$inputUserSelf = ['_' => 'inputUserSelf']; +``` diff --git a/docs/API_docs/constructors/inputWallPaper.md b/docs/API_docs/constructors/inputWallPaper.md new file mode 100644 index 0000000000..08be735879 --- /dev/null +++ b/docs/API_docs/constructors/inputWallPaper.md @@ -0,0 +1,30 @@ +--- +title: "inputWallPaper" +description: "Wallpaper" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWallPaper +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Wallpaper](https://core.telegram.org/api/wallpapers) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|[Wallpaper](https://core.telegram.org/api/wallpapers) ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| + + + +### Type: [InputWallPaper](/API_docs/types/InputWallPaper.html) + + +### Example: + +``` +$inputWallPaper = ['_' => 'inputWallPaper', 'id' => long, 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/inputWallPaperNoFile.md b/docs/API_docs/constructors/inputWallPaperNoFile.md new file mode 100644 index 0000000000..7320999aef --- /dev/null +++ b/docs/API_docs/constructors/inputWallPaperNoFile.md @@ -0,0 +1,29 @@ +--- +title: "inputWallPaperNoFile" +description: "Wallpaper with no file access hash, used for example when deleting (unsave=true) wallpapers using account.saveWallPaper, specifying just the wallpaper ID." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWallPaperNoFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Wallpaper](https://core.telegram.org/api/wallpapers) with no file access hash, used for example when deleting (`unsave=true`) wallpapers using [account.saveWallPaper](../methods/account.saveWallPaper.html), specifying just the wallpaper ID. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Wallpaper ID| + + + +### Type: [InputWallPaper](/API_docs/types/InputWallPaper.html) + + +### Example: + +``` +$inputWallPaperNoFile = ['_' => 'inputWallPaperNoFile', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/inputWallPaperSlug.md b/docs/API_docs/constructors/inputWallPaperSlug.md new file mode 100644 index 0000000000..2f6d085f63 --- /dev/null +++ b/docs/API_docs/constructors/inputWallPaperSlug.md @@ -0,0 +1,29 @@ +--- +title: "inputWallPaperSlug" +description: "Wallpaper by slug (a unique ID, obtained from a wallpaper link »)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWallPaperSlug +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Wallpaper](https://core.telegram.org/api/wallpapers) by slug (a unique ID, obtained from a [wallpaper link »](https://core.telegram.org/api/links#wallpaper-links)) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|slug|[string](/API_docs/types/string.html) | Yes|Unique wallpaper ID| + + + +### Type: [InputWallPaper](/API_docs/types/InputWallPaper.html) + + +### Example: + +``` +$inputWallPaperSlug = ['_' => 'inputWallPaperSlug', 'slug' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputWebDocument.md b/docs/API_docs/constructors/inputWebDocument.md new file mode 100644 index 0000000000..92895c5ab0 --- /dev/null +++ b/docs/API_docs/constructors/inputWebDocument.md @@ -0,0 +1,32 @@ +--- +title: "inputWebDocument" +description: "The document" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWebDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +The document + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Remote document URL to be downloaded using the appropriate [method](https://core.telegram.org/api/files)| +|size|[int](/API_docs/types/int.html) | Yes|Remote file size| +|mime\_type|[string](/API_docs/types/string.html) | Yes|Mime type| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Attributes for media types| + + + +### Type: [InputWebDocument](/API_docs/types/InputWebDocument.html) + + +### Example: + +``` +$inputWebDocument = ['_' => 'inputWebDocument', 'url' => 'string', 'size' => int, 'mime_type' => 'string', 'attributes' => [DocumentAttribute, DocumentAttribute]]; +``` diff --git a/docs/API_docs/constructors/inputWebFileAudioAlbumThumbLocation.md b/docs/API_docs/constructors/inputWebFileAudioAlbumThumbLocation.md new file mode 100644 index 0000000000..4a6cce7a74 --- /dev/null +++ b/docs/API_docs/constructors/inputWebFileAudioAlbumThumbLocation.md @@ -0,0 +1,32 @@ +--- +title: "inputWebFileAudioAlbumThumbLocation" +description: "Used to download an album cover for any music file using upload.getWebFile, see the webfile docs for more info »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWebFileAudioAlbumThumbLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to download an album cover for any music file using [upload.getWebFile](../methods/upload.getWebFile.html), see the [webfile docs for more info »](https://core.telegram.org/api/files#downloading-webfiles). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|small|[Bool](/API_docs/types/Bool.html) | Optional|Used to return a thumbnail with `100x100` resolution (instead of the default `600x600`)| +|document|[MessageMedia, Message, Update or InputDocument](/API_docs/types/InputDocument.html) | Optional|The audio file in question: must NOT be provided in secret chats, provide the `title` and `performer` fields instead.| +|title|[string](/API_docs/types/string.html) | Optional|Song title: should only be used in secret chats, in normal chats provide `document` instead, as it has more lax rate limits.| +|performer|[string](/API_docs/types/string.html) | Optional|Song performer: should only be used in secret chats, in normal chats provide `document` instead, as it has more lax rate limits.| + + + +### Type: [InputWebFileLocation](/API_docs/types/InputWebFileLocation.html) + + +### Example: + +``` +$inputWebFileAudioAlbumThumbLocation = ['_' => 'inputWebFileAudioAlbumThumbLocation', 'small' => Bool, 'document' => InputDocument, 'title' => 'string', 'performer' => 'string']; +``` diff --git a/docs/API_docs/constructors/inputWebFileGeoPointLocation.md b/docs/API_docs/constructors/inputWebFileGeoPointLocation.md new file mode 100644 index 0000000000..22d912b283 --- /dev/null +++ b/docs/API_docs/constructors/inputWebFileGeoPointLocation.md @@ -0,0 +1,34 @@ +--- +title: "inputWebFileGeoPointLocation" +description: "Used to download a server-generated image with the map preview from a geoPoint, see the webfile docs for more info »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWebFileGeoPointLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Used to download a server-generated image with the map preview from a [geoPoint](../constructors/geoPoint.html), see the [webfile docs for more info »](https://core.telegram.org/api/files#downloading-webfiles). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional|Generated from the `lat`, `long` and `accuracy_radius` parameters of the [geoPoint](../constructors/geoPoint.html)| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash of the [geoPoint](../constructors/geoPoint.html)| +|w|[int](/API_docs/types/int.html) | Yes|Map width in pixels before applying scale; 16-1024| +|h|[int](/API_docs/types/int.html) | Yes|Map height in pixels before applying scale; 16-1024| +|zoom|[int](/API_docs/types/int.html) | Yes|Map zoom level; 13-20| +|scale|[int](/API_docs/types/int.html) | Yes|Map scale; 1-3| + + + +### Type: [InputWebFileLocation](/API_docs/types/InputWebFileLocation.html) + + +### Example: + +``` +$inputWebFileGeoPointLocation = ['_' => 'inputWebFileGeoPointLocation', 'geo_point' => InputGeoPoint, 'access_hash' => long, 'w' => int, 'h' => int, 'zoom' => int, 'scale' => int]; +``` diff --git a/docs/API_docs/constructors/inputWebFileLocation.md b/docs/API_docs/constructors/inputWebFileLocation.md new file mode 100644 index 0000000000..6bf34ee8e8 --- /dev/null +++ b/docs/API_docs/constructors/inputWebFileLocation.md @@ -0,0 +1,30 @@ +--- +title: "inputWebFileLocation" +description: "Location of a remote HTTP(s) file" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: inputWebFileLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Location of a remote HTTP(s) file + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|HTTP URL of file| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| + + + +### Type: [InputWebFileLocation](/API_docs/types/InputWebFileLocation.html) + + +### Example: + +``` +$inputWebFileLocation = ['_' => 'inputWebFileLocation', 'url' => 'string', 'access_hash' => long]; +``` diff --git a/docs/API_docs/constructors/invoice.md b/docs/API_docs/constructors/invoice.md new file mode 100644 index 0000000000..5be1968d8d --- /dev/null +++ b/docs/API_docs/constructors/invoice.md @@ -0,0 +1,42 @@ +--- +title: "invoice" +description: "Invoice" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: invoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Invoice + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|test|[Bool](/API_docs/types/Bool.html) | Optional|Test invoice| +|name\_requested|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if you require the user's full name to complete the order| +|phone\_requested|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if you require the user's phone number to complete the order| +|email\_requested|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if you require the user's email address to complete the order| +|shipping\_address\_requested|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if you require the user's shipping address to complete the order| +|flexible|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if the final price depends on the shipping method| +|phone\_to\_provider|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if user's phone number should be sent to provider| +|email\_to\_provider|[Bool](/API_docs/types/Bool.html) | Optional|Set this flag if user's email address should be sent to provider| +|recurring|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a recurring payment| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|prices|Array of [LabeledPrice](/API_docs/types/LabeledPrice.html) | Yes|Price breakdown, a list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.)| +|max\_tip\_amount|[long](/API_docs/types/long.html) | Optional|The maximum accepted amount for tips in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|suggested\_tip\_amounts|Array of [long](/API_docs/types/long.html) | Optional|A vector of suggested amounts of tips in the *smallest units* of the currency (integer, not float/double). At most 4 suggested tip amounts can be specified. The suggested tip amounts must be positive, passed in a strictly increased order and must not exceed `max_tip_amount`.| +|terms\_url|[string](/API_docs/types/string.html) | Optional|Terms of service URL| + + + +### Type: [Invoice](/API_docs/types/Invoice.html) + + +### Example: + +``` +$invoice = ['_' => 'invoice', 'test' => Bool, 'name_requested' => Bool, 'phone_requested' => Bool, 'email_requested' => Bool, 'shipping_address_requested' => Bool, 'flexible' => Bool, 'phone_to_provider' => Bool, 'email_to_provider' => Bool, 'recurring' => Bool, 'currency' => 'string', 'prices' => [LabeledPrice, LabeledPrice], 'max_tip_amount' => long, 'suggested_tip_amounts' => [long, long], 'terms_url' => 'string']; +``` diff --git a/docs/API_docs/constructors/jsonArray.md b/docs/API_docs/constructors/jsonArray.md new file mode 100644 index 0000000000..b99e508661 --- /dev/null +++ b/docs/API_docs/constructors/jsonArray.md @@ -0,0 +1,29 @@ +--- +title: "jsonArray" +description: "JSON array" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonArray +[Back to constructors index](/API_docs/constructors/index.html) + + + +JSON array + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|value|Array of [JSONValue](/API_docs/types/JSONValue.html) | Yes|JSON values| + + + +### Type: [JSONValue](/API_docs/types/JSONValue.html) + + +### Example: + +``` +$jsonArray = ['_' => 'jsonArray', 'value' => [JSONValue, JSONValue]]; +``` diff --git a/docs/API_docs/constructors/jsonBool.md b/docs/API_docs/constructors/jsonBool.md new file mode 100644 index 0000000000..0bae8ac858 --- /dev/null +++ b/docs/API_docs/constructors/jsonBool.md @@ -0,0 +1,29 @@ +--- +title: "jsonBool" +description: "JSON boolean value" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonBool +[Back to constructors index](/API_docs/constructors/index.html) + + + +JSON boolean value + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|value|[Bool](/API_docs/types/Bool.html) | Yes|Value| + + + +### Type: [JSONValue](/API_docs/types/JSONValue.html) + + +### Example: + +``` +$jsonBool = ['_' => 'jsonBool', 'value' => Bool]; +``` diff --git a/docs/API_docs/constructors/jsonNull.md b/docs/API_docs/constructors/jsonNull.md new file mode 100644 index 0000000000..0384cc7552 --- /dev/null +++ b/docs/API_docs/constructors/jsonNull.md @@ -0,0 +1,24 @@ +--- +title: "jsonNull" +description: "null JSON value" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonNull +[Back to constructors index](/API_docs/constructors/index.html) + + + +null JSON value + + + + +### Type: [JSONValue](/API_docs/types/JSONValue.html) + + +### Example: + +``` +$jsonNull = ['_' => 'jsonNull']; +``` diff --git a/docs/API_docs/constructors/jsonNumber.md b/docs/API_docs/constructors/jsonNumber.md new file mode 100644 index 0000000000..57d44db390 --- /dev/null +++ b/docs/API_docs/constructors/jsonNumber.md @@ -0,0 +1,29 @@ +--- +title: "jsonNumber" +description: "JSON numeric value" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonNumber +[Back to constructors index](/API_docs/constructors/index.html) + + + +JSON numeric value + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|value|[double](/API_docs/types/double.html) | Yes|Value| + + + +### Type: [JSONValue](/API_docs/types/JSONValue.html) + + +### Example: + +``` +$jsonNumber = ['_' => 'jsonNumber', 'value' => double]; +``` diff --git a/docs/API_docs/constructors/jsonObject.md b/docs/API_docs/constructors/jsonObject.md new file mode 100644 index 0000000000..63956b011b --- /dev/null +++ b/docs/API_docs/constructors/jsonObject.md @@ -0,0 +1,29 @@ +--- +title: "jsonObject" +description: "JSON object value" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonObject +[Back to constructors index](/API_docs/constructors/index.html) + + + +JSON object value + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|value|Array of [JSONObjectValue](/API_docs/types/JSONObjectValue.html) | Yes|Values| + + + +### Type: [JSONValue](/API_docs/types/JSONValue.html) + + +### Example: + +``` +$jsonObject = ['_' => 'jsonObject', 'value' => [JSONObjectValue, JSONObjectValue]]; +``` diff --git a/docs/API_docs/constructors/jsonObjectValue.md b/docs/API_docs/constructors/jsonObjectValue.md new file mode 100644 index 0000000000..892a59d46c --- /dev/null +++ b/docs/API_docs/constructors/jsonObjectValue.md @@ -0,0 +1,30 @@ +--- +title: "jsonObjectValue" +description: "JSON key: value pair" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonObjectValue +[Back to constructors index](/API_docs/constructors/index.html) + + + +JSON key: value pair + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|key|[string](/API_docs/types/string.html) | Yes|Key| +|value|[JSONValue](/API_docs/types/JSONValue.html) | Yes|Value| + + + +### Type: [JSONObjectValue](/API_docs/types/JSONObjectValue.html) + + +### Example: + +``` +$jsonObjectValue = ['_' => 'jsonObjectValue', 'key' => 'string', 'value' => JSONValue]; +``` diff --git a/docs/API_docs/constructors/jsonString.md b/docs/API_docs/constructors/jsonString.md new file mode 100644 index 0000000000..8b12df0872 --- /dev/null +++ b/docs/API_docs/constructors/jsonString.md @@ -0,0 +1,29 @@ +--- +title: "jsonString" +description: "JSON string" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: jsonString +[Back to constructors index](/API_docs/constructors/index.html) + + + +JSON string + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|value|[string](/API_docs/types/string.html) | Yes|Value| + + + +### Type: [JSONValue](/API_docs/types/JSONValue.html) + + +### Example: + +``` +$jsonString = ['_' => 'jsonString', 'value' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButton.md b/docs/API_docs/constructors/keyboardButton.md new file mode 100644 index 0000000000..98acd1fea4 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButton.md @@ -0,0 +1,29 @@ +--- +title: "keyboardButton" +description: "Bot keyboard button" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButton +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bot keyboard button + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButton = ['_' => 'keyboardButton', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonBuy.md b/docs/API_docs/constructors/keyboardButtonBuy.md new file mode 100644 index 0000000000..aacf550cc0 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonBuy.md @@ -0,0 +1,29 @@ +--- +title: "keyboardButtonBuy" +description: "Button to buy a product" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonBuy +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to buy a product + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonBuy = ['_' => 'keyboardButtonBuy', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonCallback.md b/docs/API_docs/constructors/keyboardButtonCallback.md new file mode 100644 index 0000000000..1236bbe759 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonCallback.md @@ -0,0 +1,31 @@ +--- +title: "keyboardButtonCallback" +description: "Callback button" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonCallback +[Back to constructors index](/API_docs/constructors/index.html) + + + +Callback button + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|requires\_password|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user should verify his identity by entering his [2FA SRP parameters](https://core.telegram.org/api/srp) to the [messages.getBotCallbackAnswer](../methods/messages.getBotCallbackAnswer.html) method. NOTE: telegram and the bot WILL NOT have access to the plaintext password, thanks to [SRP](https://core.telegram.org/api/srp). This button is mainly used by the official [@botfather](https://t.me/botfather) bot, for verifying the user's identity before transferring ownership of a bot to another user.| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|data|[bytes](/API_docs/types/bytes.html) | Yes|Callback data| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonCallback = ['_' => 'keyboardButtonCallback', 'requires_password' => Bool, 'text' => 'string', 'data' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonGame.md b/docs/API_docs/constructors/keyboardButtonGame.md new file mode 100644 index 0000000000..4bf18b1e23 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonGame.md @@ -0,0 +1,29 @@ +--- +title: "keyboardButtonGame" +description: "Button to start a game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonGame +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to start a game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonGame = ['_' => 'keyboardButtonGame', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonRequestGeoLocation.md b/docs/API_docs/constructors/keyboardButtonRequestGeoLocation.md new file mode 100644 index 0000000000..bdb26e502c --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonRequestGeoLocation.md @@ -0,0 +1,29 @@ +--- +title: "keyboardButtonRequestGeoLocation" +description: "Button to request a user's geolocation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonRequestGeoLocation +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to request a user's geolocation + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonRequestGeoLocation = ['_' => 'keyboardButtonRequestGeoLocation', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonRequestPeer.md b/docs/API_docs/constructors/keyboardButtonRequestPeer.md new file mode 100644 index 0000000000..1bec3a447c --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonRequestPeer.md @@ -0,0 +1,32 @@ +--- +title: "keyboardButtonRequestPeer" +description: "Prompts the user to select and share one or more peers with the bot using messages.sendBotRequestedPeer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonRequestPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Prompts the user to select and share one or more peers with the bot using [messages.sendBotRequestedPeer](../methods/messages.sendBotRequestedPeer.html) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|button\_id|[int](/API_docs/types/int.html) | Yes|Button ID, to be passed to [messages.sendBotRequestedPeer](../methods/messages.sendBotRequestedPeer.html).| +|peer\_type|[RequestPeerType](/API_docs/types/RequestPeerType.html) | Yes|Filtering criteria to use for the peer selection list shown to the user.
The list should display all existing peers of the specified type, and should also offer an option for the user to create and immediately use one or more (up to `max_quantity`) peers of the specified type, if needed.| +|max\_quantity|[int](/API_docs/types/int.html) | Yes|Maximum number of peers that can be chosne.| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonRequestPeer = ['_' => 'keyboardButtonRequestPeer', 'text' => 'string', 'button_id' => int, 'peer_type' => RequestPeerType, 'max_quantity' => int]; +``` diff --git a/docs/API_docs/constructors/keyboardButtonRequestPhone.md b/docs/API_docs/constructors/keyboardButtonRequestPhone.md new file mode 100644 index 0000000000..9a8b100914 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonRequestPhone.md @@ -0,0 +1,29 @@ +--- +title: "keyboardButtonRequestPhone" +description: "Button to request a user's phone number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonRequestPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to request a user's phone number + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonRequestPhone = ['_' => 'keyboardButtonRequestPhone', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonRequestPoll.md b/docs/API_docs/constructors/keyboardButtonRequestPoll.md new file mode 100644 index 0000000000..102018c72e --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonRequestPoll.md @@ -0,0 +1,30 @@ +--- +title: "keyboardButtonRequestPoll" +description: "A button that allows the user to create and send a poll when pressed; available only in private" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonRequestPoll +[Back to constructors index](/API_docs/constructors/index.html) + + + +A button that allows the user to create and send a poll when pressed; available only in private + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|quiz|[Bool](/API_docs/types/Bool.html) | Optional|If set, only quiz polls can be sent| +|text|[string](/API_docs/types/string.html) | Yes|Button text| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonRequestPoll = ['_' => 'keyboardButtonRequestPoll', 'quiz' => Bool, 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonRow.md b/docs/API_docs/constructors/keyboardButtonRow.md new file mode 100644 index 0000000000..50f6704f59 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonRow.md @@ -0,0 +1,29 @@ +--- +title: "keyboardButtonRow" +description: "Inline keyboard row" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonRow +[Back to constructors index](/API_docs/constructors/index.html) + + + +Inline keyboard row + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|buttons|Array of [KeyboardButton](/API_docs/types/KeyboardButton.html) | Yes|Bot or inline keyboard buttons| + + + +### Type: [KeyboardButtonRow](/API_docs/types/KeyboardButtonRow.html) + + +### Example: + +``` +$keyboardButtonRow = ['_' => 'keyboardButtonRow', 'buttons' => [KeyboardButton, KeyboardButton]]; +``` diff --git a/docs/API_docs/constructors/keyboardButtonSimpleWebView.md b/docs/API_docs/constructors/keyboardButtonSimpleWebView.md new file mode 100644 index 0000000000..b928533d44 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonSimpleWebView.md @@ -0,0 +1,32 @@ +--- +title: "keyboardButtonSimpleWebView" +description: "Button to open a bot mini app using messages.requestSimpleWebView, without sending user information to the web app." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonSimpleWebView +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to open a [bot mini app](https://core.telegram.org/api/bots/webapps) using [messages.requestSimpleWebView](../methods/messages.requestSimpleWebView.html), without sending user information to the web app. + +Can only be sent or received as part of a reply keyboard, use [keyboardButtonWebView](../constructors/keyboardButtonWebView.html) for inline keyboards. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|url|[string](/API_docs/types/string.html) | Yes|[Web app URL](https://core.telegram.org/api/bots/webapps)| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonSimpleWebView = ['_' => 'keyboardButtonSimpleWebView', 'text' => 'string', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonSwitchInline.md b/docs/API_docs/constructors/keyboardButtonSwitchInline.md new file mode 100644 index 0000000000..95a4821d85 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonSwitchInline.md @@ -0,0 +1,32 @@ +--- +title: "keyboardButtonSwitchInline" +description: "Button to force a user to switch to inline mode: pressing the button will prompt the user to select one of their chats, open that chat and insert the bot's username and the specified inline query in the input field." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonSwitchInline +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to force a user to switch to inline mode: pressing the button will prompt the user to select one of their chats, open that chat and insert the bot's username and the specified inline query in the input field. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|same\_peer|[Bool](/API_docs/types/Bool.html) | Optional|If set, pressing the button will insert the bot's username and the specified inline `query` in the current chat's input field.| +|text|[string](/API_docs/types/string.html) | Yes|Button label| +|query|[string](/API_docs/types/string.html) | Yes|The inline query to use| +|peer\_types|Array of [InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) | Optional|Filter to use when selecting chats.| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonSwitchInline = ['_' => 'keyboardButtonSwitchInline', 'same_peer' => Bool, 'text' => 'string', 'query' => 'string', 'peer_types' => [InlineQueryPeerType, InlineQueryPeerType]]; +``` diff --git a/docs/API_docs/constructors/keyboardButtonUrl.md b/docs/API_docs/constructors/keyboardButtonUrl.md new file mode 100644 index 0000000000..e386ce25af --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonUrl.md @@ -0,0 +1,30 @@ +--- +title: "keyboardButtonUrl" +description: "URL button" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +URL button + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button label| +|url|[string](/API_docs/types/string.html) | Yes|URL| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonUrl = ['_' => 'keyboardButtonUrl', 'text' => 'string', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/keyboardButtonUrlAuth.md b/docs/API_docs/constructors/keyboardButtonUrlAuth.md new file mode 100644 index 0000000000..5c896b24e4 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonUrlAuth.md @@ -0,0 +1,32 @@ +--- +title: "keyboardButtonUrlAuth" +description: "Button to request a user to authorize via URL using Seamless Telegram Login. When the user clicks on such a button, messages.requestUrlAuth should be called, providing the button_id and the ID of the container message. The returned urlAuthResultRequest object will contain more details about the authorization request (request_write_access if the bot would like to send messages to the user along with the username of the bot which will be used for user authorization). Finally, the user can choose to call messages.acceptUrlAuth to get a urlAuthResultAccepted with the URL to open instead of the url of this constructor, or a urlAuthResultDefault, in which case the url of this constructor must be opened, instead. If the user refuses the authorization request but still wants to open the link, the url of this constructor must be used." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonUrlAuth +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to request a user to authorize via URL using [Seamless Telegram Login](https://telegram.org/blog/privacy-discussions-web-bots#meet-seamless-web-bots). When the user clicks on such a button, [messages.requestUrlAuth](../methods/messages.requestUrlAuth.html) should be called, providing the `button_id` and the ID of the container message. The returned [urlAuthResultRequest](../constructors/urlAuthResultRequest.html) object will contain more details about the authorization request (`request_write_access` if the bot would like to send messages to the user along with the username of the bot which will be used for user authorization). Finally, the user can choose to call [messages.acceptUrlAuth](../methods/messages.acceptUrlAuth.html) to get a [urlAuthResultAccepted](../constructors/urlAuthResultAccepted.html) with the URL to open instead of the `url` of this constructor, or a [urlAuthResultDefault](../constructors/urlAuthResultDefault.html), in which case the `url` of this constructor must be opened, instead. If the user refuses the authorization request but still wants to open the link, the `url` of this constructor must be used. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button label| +|fwd\_text|[string](/API_docs/types/string.html) | Optional|New text of the button in forwarded messages.| +|url|[string](/API_docs/types/string.html) | Yes|An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in [Receiving authorization data](https://core.telegram.org/widgets/login#receiving-authorization-data).

**NOTE**: Services must **always** check the hash of the received data to verify the authentication and the integrity of the data as described in [Checking authorization](https://core.telegram.org/widgets/login#checking-authorization).| +|button\_id|[int](/API_docs/types/int.html) | Yes|ID of the button to pass to [messages.requestUrlAuth](../methods/messages.requestUrlAuth.html)| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonUrlAuth = ['_' => 'keyboardButtonUrlAuth', 'text' => 'string', 'fwd_text' => 'string', 'url' => 'string', 'button_id' => int]; +``` diff --git a/docs/API_docs/constructors/keyboardButtonUserProfile.md b/docs/API_docs/constructors/keyboardButtonUserProfile.md new file mode 100644 index 0000000000..6ac6bd6c30 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonUserProfile.md @@ -0,0 +1,30 @@ +--- +title: "keyboardButtonUserProfile" +description: "Button that links directly to a user profile" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonUserProfile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button that links directly to a user profile + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonUserProfile = ['_' => 'keyboardButtonUserProfile', 'text' => 'string', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/keyboardButtonWebView.md b/docs/API_docs/constructors/keyboardButtonWebView.md new file mode 100644 index 0000000000..3cf80f3863 --- /dev/null +++ b/docs/API_docs/constructors/keyboardButtonWebView.md @@ -0,0 +1,32 @@ +--- +title: "keyboardButtonWebView" +description: "Button to open a bot mini app using messages.requestWebView, sending over user information after user confirmation." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: keyboardButtonWebView +[Back to constructors index](/API_docs/constructors/index.html) + + + +Button to open a [bot mini app](https://core.telegram.org/api/bots/webapps) using [messages.requestWebView](../methods/messages.requestWebView.html), sending over user information after user confirmation. + +Can only be sent or received as part of an inline keyboard, use [keyboardButtonSimpleWebView](../constructors/keyboardButtonSimpleWebView.html) for reply keyboards. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Button text| +|url|[string](/API_docs/types/string.html) | Yes|[Web app url](https://core.telegram.org/api/bots/webapps)| + + + +### Type: [KeyboardButton](/API_docs/types/KeyboardButton.html) + + +### Example: + +``` +$keyboardButtonWebView = ['_' => 'keyboardButtonWebView', 'text' => 'string', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/labeledPrice.md b/docs/API_docs/constructors/labeledPrice.md new file mode 100644 index 0000000000..7af5f521a7 --- /dev/null +++ b/docs/API_docs/constructors/labeledPrice.md @@ -0,0 +1,30 @@ +--- +title: "labeledPrice" +description: "This object represents a portion of the price for goods or services." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: labeledPrice +[Back to constructors index](/API_docs/constructors/index.html) + + + +This object represents a portion of the price for goods or services. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|label|[string](/API_docs/types/string.html) | Yes|Portion label| +|amount|[long](/API_docs/types/long.html) | Yes|Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| + + + +### Type: [LabeledPrice](/API_docs/types/LabeledPrice.html) + + +### Example: + +``` +$labeledPrice = ['_' => 'labeledPrice', 'label' => 'string', 'amount' => long]; +``` diff --git a/docs/API_docs/constructors/langPackDifference.md b/docs/API_docs/constructors/langPackDifference.md new file mode 100644 index 0000000000..acd2da97b0 --- /dev/null +++ b/docs/API_docs/constructors/langPackDifference.md @@ -0,0 +1,32 @@ +--- +title: "langPackDifference" +description: "Changes to the app's localization pack" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: langPackDifference +[Back to constructors index](/API_docs/constructors/index.html) + + + +Changes to the app's localization pack + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lang\_code|[string](/API_docs/types/string.html) | Yes|Language code| +|from\_version|[int](/API_docs/types/int.html) | Yes|Previous version number| +|version|[int](/API_docs/types/int.html) | Yes|New version number| +|strings|Array of [LangPackString](/API_docs/types/LangPackString.html) | Yes|Localized strings| + + + +### Type: [LangPackDifference](/API_docs/types/LangPackDifference.html) + + +### Example: + +``` +$langPackDifference = ['_' => 'langPackDifference', 'lang_code' => 'string', 'from_version' => int, 'version' => int, 'strings' => [LangPackString, LangPackString]]; +``` diff --git a/docs/API_docs/constructors/langPackLanguage.md b/docs/API_docs/constructors/langPackLanguage.md new file mode 100644 index 0000000000..f4a92cc87d --- /dev/null +++ b/docs/API_docs/constructors/langPackLanguage.md @@ -0,0 +1,39 @@ +--- +title: "langPackLanguage" +description: "Identifies a localization pack" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: langPackLanguage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Identifies a localization pack + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|official|[Bool](/API_docs/types/Bool.html) | Optional|Whether the language pack is official| +|rtl|[Bool](/API_docs/types/Bool.html) | Optional|Is this a localization pack for an RTL language| +|beta|[Bool](/API_docs/types/Bool.html) | Optional|Is this a beta localization pack?| +|name|[string](/API_docs/types/string.html) | Yes|Language name| +|native\_name|[string](/API_docs/types/string.html) | Yes|Language name in the language itself| +|lang\_code|[string](/API_docs/types/string.html) | Yes|Language code (pack identifier)| +|base\_lang\_code|[string](/API_docs/types/string.html) | Optional|Identifier of a base language pack; may be empty. If a string is missed in the language pack, then it should be fetched from base language pack. Unsupported in custom language packs| +|plural\_code|[string](/API_docs/types/string.html) | Yes|A language code to be used to apply plural forms. See [https://www.unicode.org/cldr/charts/latest/supplemental/language\_plural\_rules.html](https://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html) for more info| +|strings\_count|[int](/API_docs/types/int.html) | Yes|Total number of non-deleted strings from the language pack| +|translated\_count|[int](/API_docs/types/int.html) | Yes|Total number of translated strings from the language pack| +|translations\_url|[string](/API_docs/types/string.html) | Yes|Link to language translation interface; empty for custom local language packs| + + + +### Type: [LangPackLanguage](/API_docs/types/LangPackLanguage.html) + + +### Example: + +``` +$langPackLanguage = ['_' => 'langPackLanguage', 'official' => Bool, 'rtl' => Bool, 'beta' => Bool, 'name' => 'string', 'native_name' => 'string', 'lang_code' => 'string', 'base_lang_code' => 'string', 'plural_code' => 'string', 'strings_count' => int, 'translated_count' => int, 'translations_url' => 'string']; +``` diff --git a/docs/API_docs/constructors/langPackString.md b/docs/API_docs/constructors/langPackString.md new file mode 100644 index 0000000000..45853f6d59 --- /dev/null +++ b/docs/API_docs/constructors/langPackString.md @@ -0,0 +1,30 @@ +--- +title: "langPackString" +description: "Translated localization string" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: langPackString +[Back to constructors index](/API_docs/constructors/index.html) + + + +Translated localization string + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|key|[string](/API_docs/types/string.html) | Yes|Language key| +|value|[string](/API_docs/types/string.html) | Yes|Value| + + + +### Type: [LangPackString](/API_docs/types/LangPackString.html) + + +### Example: + +``` +$langPackString = ['_' => 'langPackString', 'key' => 'string', 'value' => 'string']; +``` diff --git a/docs/API_docs/constructors/langPackStringDeleted.md b/docs/API_docs/constructors/langPackStringDeleted.md new file mode 100644 index 0000000000..e371d75276 --- /dev/null +++ b/docs/API_docs/constructors/langPackStringDeleted.md @@ -0,0 +1,29 @@ +--- +title: "langPackStringDeleted" +description: "Deleted localization string" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: langPackStringDeleted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Deleted localization string + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|key|[string](/API_docs/types/string.html) | Yes|Localization key| + + + +### Type: [LangPackString](/API_docs/types/LangPackString.html) + + +### Example: + +``` +$langPackStringDeleted = ['_' => 'langPackStringDeleted', 'key' => 'string']; +``` diff --git a/docs/API_docs/constructors/langPackStringPluralized.md b/docs/API_docs/constructors/langPackStringPluralized.md new file mode 100644 index 0000000000..4b66414172 --- /dev/null +++ b/docs/API_docs/constructors/langPackStringPluralized.md @@ -0,0 +1,35 @@ +--- +title: "langPackStringPluralized" +description: "A language pack string which has different forms based on the number of some object it mentions. See https://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html for more info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: langPackStringPluralized +[Back to constructors index](/API_docs/constructors/index.html) + + + +A language pack string which has different forms based on the number of some object it mentions. See [https://www.unicode.org/cldr/charts/latest/supplemental/language\_plural\_rules.html](https://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html) for more info + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|key|[string](/API_docs/types/string.html) | Yes|Localization key| +|zero\_value|[string](/API_docs/types/string.html) | Optional|Value for zero objects| +|one\_value|[string](/API_docs/types/string.html) | Optional|Value for one object| +|two\_value|[string](/API_docs/types/string.html) | Optional|Value for two objects| +|few\_value|[string](/API_docs/types/string.html) | Optional|Value for a few objects| +|many\_value|[string](/API_docs/types/string.html) | Optional|Value for many objects| +|other\_value|[string](/API_docs/types/string.html) | Yes|Default value| + + + +### Type: [LangPackString](/API_docs/types/LangPackString.html) + + +### Example: + +``` +$langPackStringPluralized = ['_' => 'langPackStringPluralized', 'key' => 'string', 'zero_value' => 'string', 'one_value' => 'string', 'two_value' => 'string', 'few_value' => 'string', 'many_value' => 'string', 'other_value' => 'string']; +``` diff --git a/docs/API_docs/constructors/maskCoords.md b/docs/API_docs/constructors/maskCoords.md new file mode 100644 index 0000000000..1fb53b4438 --- /dev/null +++ b/docs/API_docs/constructors/maskCoords.md @@ -0,0 +1,39 @@ +--- +title: "maskCoords" +description: "Position on a photo where a mask should be placed when attaching stickers to media »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: maskCoords +[Back to constructors index](/API_docs/constructors/index.html) + + + +Position on a photo where a mask should be placed when [attaching stickers to media »](https://core.telegram.org/api/stickers#attached-stickers) + +The `n` position indicates where the mask should be placed: + +- 0 => Relative to the forehead +- 1 => Relative to the eyes +- 2 => Relative to the mouth +- 3 => Relative to the chin + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|n|[int](/API_docs/types/int.html) | Yes|Part of the face, relative to which the mask should be placed| +|x|[double](/API_docs/types/double.html) | Yes|Shift by X-axis measured in widths of the mask scaled to the face size, from left to right. (For example, -1.0 will place the mask just to the left of the default mask position)| +|y|[double](/API_docs/types/double.html) | Yes|Shift by Y-axis measured in widths of the mask scaled to the face size, from left to right. (For example, -1.0 will place the mask just below the default mask position)| +|zoom|[double](/API_docs/types/double.html) | Yes|Mask scaling coefficient. (For example, 2.0 means a doubled size)| + + + +### Type: [MaskCoords](/API_docs/types/MaskCoords.html) + + +### Example: + +``` +$maskCoords = ['_' => 'maskCoords', 'n' => int, 'x' => double, 'y' => double, 'zoom' => double]; +``` diff --git a/docs/API_docs/constructors/mediaAreaChannelPost.md b/docs/API_docs/constructors/mediaAreaChannelPost.md new file mode 100644 index 0000000000..8bd00ed10e --- /dev/null +++ b/docs/API_docs/constructors/mediaAreaChannelPost.md @@ -0,0 +1,31 @@ +--- +title: "mediaAreaChannelPost" +description: "Represents a channel post." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: mediaAreaChannelPost +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a channel post. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|coordinates|[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) | Yes|The size and location of the media area corresponding to the location sticker on top of the story media.| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The channel that posted the message| +|msg\_id|[int](/API_docs/types/int.html) | Yes|ID of the channel message| + + + +### Type: [MediaArea](/API_docs/types/MediaArea.html) + + +### Example: + +``` +$mediaAreaChannelPost = ['_' => 'mediaAreaChannelPost', 'coordinates' => MediaAreaCoordinates, 'channel_id' => long, 'msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/mediaAreaCoordinates.md b/docs/API_docs/constructors/mediaAreaCoordinates.md new file mode 100644 index 0000000000..14bbce208d --- /dev/null +++ b/docs/API_docs/constructors/mediaAreaCoordinates.md @@ -0,0 +1,33 @@ +--- +title: "mediaAreaCoordinates" +description: "Coordinates and size of a clicable rectangular area on top of a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: mediaAreaCoordinates +[Back to constructors index](/API_docs/constructors/index.html) + + + +Coordinates and size of a clicable rectangular area on top of a story. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|x|[double](/API_docs/types/double.html) | Yes|The abscissa of the rectangle's center, as a percentage of the media width (0-100).| +|y|[double](/API_docs/types/double.html) | Yes|The ordinate of the rectangle's center, as a percentage of the media height (0-100).| +|w|[double](/API_docs/types/double.html) | Yes|The width of the rectangle, as a percentage of the media width (0-100).| +|h|[double](/API_docs/types/double.html) | Yes|The height of the rectangle, as a percentage of the media height (0-100).| +|rotation|[double](/API_docs/types/double.html) | Yes|Clockwise rotation angle of the rectangle, in degrees (0-360).| + + + +### Type: [MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) + + +### Example: + +``` +$mediaAreaCoordinates = ['_' => 'mediaAreaCoordinates', 'x' => double, 'y' => double, 'w' => double, 'h' => double, 'rotation' => double]; +``` diff --git a/docs/API_docs/constructors/mediaAreaGeoPoint.md b/docs/API_docs/constructors/mediaAreaGeoPoint.md new file mode 100644 index 0000000000..69666696de --- /dev/null +++ b/docs/API_docs/constructors/mediaAreaGeoPoint.md @@ -0,0 +1,30 @@ +--- +title: "mediaAreaGeoPoint" +description: "Represents a geolocation tag attached to a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: mediaAreaGeoPoint +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a geolocation tag attached to a [story](https://core.telegram.org/api/stories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|coordinates|[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) | Yes|The size and position of the media area corresponding to the location sticker on top of the story media.| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Coordinates of the geolocation tag.| + + + +### Type: [MediaArea](/API_docs/types/MediaArea.html) + + +### Example: + +``` +$mediaAreaGeoPoint = ['_' => 'mediaAreaGeoPoint', 'coordinates' => MediaAreaCoordinates, 'geo' => GeoPoint]; +``` diff --git a/docs/API_docs/constructors/mediaAreaSuggestedReaction.md b/docs/API_docs/constructors/mediaAreaSuggestedReaction.md new file mode 100644 index 0000000000..d77dd289aa --- /dev/null +++ b/docs/API_docs/constructors/mediaAreaSuggestedReaction.md @@ -0,0 +1,32 @@ +--- +title: "mediaAreaSuggestedReaction" +description: "Represents a reaction bubble." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: mediaAreaSuggestedReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a reaction bubble. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dark|[Bool](/API_docs/types/Bool.html) | Optional|Whether the reaction bubble has a dark background.| +|flipped|[Bool](/API_docs/types/Bool.html) | Optional|Whether the reaction bubble is mirrored (see [here »](https://core.telegram.org/api/stories#reactions) for more info).| +|coordinates|[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) | Yes|The coordinates of the media area corresponding to the reaction button.| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|The reaction that should be sent when this area is clicked.| + + + +### Type: [MediaArea](/API_docs/types/MediaArea.html) + + +### Example: + +``` +$mediaAreaSuggestedReaction = ['_' => 'mediaAreaSuggestedReaction', 'dark' => Bool, 'flipped' => Bool, 'coordinates' => MediaAreaCoordinates, 'reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/mediaAreaVenue.md b/docs/API_docs/constructors/mediaAreaVenue.md new file mode 100644 index 0000000000..a61600eac9 --- /dev/null +++ b/docs/API_docs/constructors/mediaAreaVenue.md @@ -0,0 +1,35 @@ +--- +title: "mediaAreaVenue" +description: "Represents a location tag attached to a story, with additional venue information." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: mediaAreaVenue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a location tag attached to a [story](https://core.telegram.org/api/stories), with additional venue information. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|coordinates|[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) | Yes|The size and location of the media area corresponding to the location sticker on top of the story media.| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Coordinates of the venue| +|title|[string](/API_docs/types/string.html) | Yes|Venue name| +|address|[string](/API_docs/types/string.html) | Yes|Address| +|provider|[string](/API_docs/types/string.html) | Yes|Venue provider: currently only "foursquare" needs to be supported.| +|venue\_id|[string](/API_docs/types/string.html) | Yes|Venue ID in the provider's database| +|venue\_type|[string](/API_docs/types/string.html) | Yes|Venue type in the provider's database| + + + +### Type: [MediaArea](/API_docs/types/MediaArea.html) + + +### Example: + +``` +$mediaAreaVenue = ['_' => 'mediaAreaVenue', 'coordinates' => MediaAreaCoordinates, 'geo' => GeoPoint, 'title' => 'string', 'address' => 'string', 'provider' => 'string', 'venue_id' => 'string', 'venue_type' => 'string']; +``` diff --git a/docs/API_docs/constructors/message.md b/docs/API_docs/constructors/message.md new file mode 100644 index 0000000000..5129cb8729 --- /dev/null +++ b/docs/API_docs/constructors/message.md @@ -0,0 +1,125 @@ +--- +title: "message" +description: "A message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: message +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|out|[Bool](/API_docs/types/Bool.html) | Optional|Is this an outgoing message| +|mentioned|[Bool](/API_docs/types/Bool.html) | Optional|Whether we were [mentioned](https://core.telegram.org/api/mentions) in this message| +|media\_unread|[Bool](/API_docs/types/Bool.html) | Optional|Whether there are unread media attachments in this message| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a silent message (no notification triggered)| +|post|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a channel post| +|from\_scheduled|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a [scheduled message](https://core.telegram.org/api/scheduled-messages)| +|legacy|[Bool](/API_docs/types/Bool.html) | Optional|This is a legacy message: it has to be refetched with the new layer| +|edit\_hide|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message should be shown as not modified to the user, even if an edit date is present| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether this message is [pinned](https://core.telegram.org/api/pin)| +|noforwards|[Bool](/API_docs/types/Bool.html) | Optional|Whether this message is [protected](https://telegram.org/blog/protected-content-delete-by-date-and-more) and thus cannot be forwarded; clients should also prevent users from saving attached media (i.e. videos should only be streamed, photos should be kept in RAM, et cetera).| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|offline|[Bool](/API_docs/types/Bool.html) | Optional| +|id|[int](/API_docs/types/int.html) | Yes|ID of the message| +|from\_id|[Peer](/API_docs/types/Peer.html) | Optional|ID of the sender of the message| +|from\_boosts\_applied|[int](/API_docs/types/int.html) | Optional| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|Peer ID, the chat where this message was sent| +|saved\_peer\_id|[Peer](/API_docs/types/Peer.html) | Optional|Messages fetched from a [saved messages dialog »](https://core.telegram.org/api/saved-messages) will have `peer`=[inputPeerSelf](../constructors/inputPeerSelf.html) and the `saved_peer_id` flag set to the ID of the saved dialog.
| +|fwd\_from|[MessageFwdHeader](/API_docs/types/MessageFwdHeader.html) | Optional|Info about forwarded messages| +|via\_bot\_id|[long](/API_docs/types/long.html) | Optional|ID of the inline bot that generated the message| +|via\_business\_bot\_id|[long](/API_docs/types/long.html) | Optional| +|reply\_to|[MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) | Optional|Reply information| +|date|[int](/API_docs/types/int.html) | Yes|Date of the message| +|message|[string](/API_docs/types/string.html) | Yes|The message| +|media|[MessageMedia](/API_docs/types/MessageMedia.html) | Optional|Media attachment| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Optional|Reply markup (bot/inline keyboards)| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|Message [entities](https://core.telegram.org/api/entities) for styled text| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|views|[int](/API_docs/types/int.html) | Optional|View count for channel posts| +|forwards|[int](/API_docs/types/int.html) | Optional|Forward counter| +|replies|[MessageReplies](/API_docs/types/MessageReplies.html) | Optional|Info about [post comments (for channels) or message replies (for groups)](https://core.telegram.org/api/threads)| +|edit\_date|[int](/API_docs/types/int.html) | Optional|Last edit date of this message| +|post\_author|[string](/API_docs/types/string.html) | Optional|Name of the author of this message for channel posts (with signatures enabled)| +|grouped\_id|[long](/API_docs/types/long.html) | Optional|Multiple media messages sent using [messages.sendMultiMedia](../methods/messages.sendMultiMedia.html) with the same grouped ID indicate an [album or media group](https://core.telegram.org/api/files#albums-grouped-media)| +|reactions|[MessageReactions](/API_docs/types/MessageReactions.html) | Optional|Reactions to this message| +|restriction\_reason|Array of [RestrictionReason](/API_docs/types/RestrictionReason.html) | Optional|Contains the reason why access to this message must be restricted.| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time To Live of the message, once message.date+message.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well.| +|quick\_reply\_shortcut\_id|[int](/API_docs/types/int.html) | Optional| + + + +### Type: [Message](/API_docs/types/Message.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$message = ['_' => 'message', 'out' => Bool, 'mentioned' => Bool, 'media_unread' => Bool, 'silent' => Bool, 'post' => Bool, 'from_scheduled' => Bool, 'legacy' => Bool, 'edit_hide' => Bool, 'pinned' => Bool, 'noforwards' => Bool, 'invert_media' => Bool, 'offline' => Bool, 'id' => int, 'from_id' => Peer, 'from_boosts_applied' => int, 'peer_id' => Peer, 'saved_peer_id' => Peer, 'fwd_from' => MessageFwdHeader, 'via_bot_id' => long, 'via_business_bot_id' => long, 'reply_to' => MessageReplyHeader, 'date' => int, 'message' => 'string', 'media' => MessageMedia, 'reply_markup' => ReplyMarkup, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'views' => int, 'forwards' => int, 'replies' => MessageReplies, 'edit_date' => int, 'post_author' => 'string', 'grouped_id' => long, 'reactions' => MessageReactions, 'restriction_reason' => [RestrictionReason, RestrictionReason], 'ttl_period' => int, 'quick_reply_shortcut_id' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionBoostApply.md b/docs/API_docs/constructors/messageActionBoostApply.md new file mode 100644 index 0000000000..707dcd2784 --- /dev/null +++ b/docs/API_docs/constructors/messageActionBoostApply.md @@ -0,0 +1,27 @@ +--- +title: "messageActionBoostApply" +description: "messageActionBoostApply attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionBoostApply +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|boosts|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionBoostApply = ['_' => 'messageActionBoostApply', 'boosts' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionBotAllowed.md b/docs/API_docs/constructors/messageActionBotAllowed.md new file mode 100644 index 0000000000..e45e3cb23d --- /dev/null +++ b/docs/API_docs/constructors/messageActionBotAllowed.md @@ -0,0 +1,34 @@ +--- +title: "messageActionBotAllowed" +description: "We have given the bot permission to send us direct messages." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionBotAllowed +[Back to constructors index](/API_docs/constructors/index.html) + + + +We have given the bot permission to send us direct messages. + +The optional fields specify how did we authorize the bot to send us messages. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|attach\_menu|[Bool](/API_docs/types/Bool.html) | Optional|We have authorized the bot to send us messages by installing the bot's [attachment menu](https://core.telegram.org/api/bots/attach).| +|from\_request|[Bool](/API_docs/types/Bool.html) | Optional|We have allowed the bot to send us messages using [bots.allowSendMessage »](../methods/bots.allowSendMessage.html).| +|domain|[string](/API_docs/types/string.html) | Optional|We have authorized the bot to send us messages by logging into a website via [Telegram Login »](https://core.telegram.org/widgets/login); this field contains the domain name of the website on which the user has logged in.| +|app|[BotApp](/API_docs/types/BotApp.html) | Optional|We have authorized the bot to send us messages by opening the specified [bot mini app](https://core.telegram.org/api/bots/webapps).| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionBotAllowed = ['_' => 'messageActionBotAllowed', 'attach_menu' => Bool, 'from_request' => Bool, 'domain' => 'string', 'app' => BotApp]; +``` diff --git a/docs/API_docs/constructors/messageActionChannelCreate.md b/docs/API_docs/constructors/messageActionChannelCreate.md new file mode 100644 index 0000000000..d0d0488dce --- /dev/null +++ b/docs/API_docs/constructors/messageActionChannelCreate.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChannelCreate" +description: "The channel was created" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChannelCreate +[Back to constructors index](/API_docs/constructors/index.html) + + + +The channel was created + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Original channel/supergroup title| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChannelCreate = ['_' => 'messageActionChannelCreate', 'title' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageActionChannelMigrateFrom.md b/docs/API_docs/constructors/messageActionChannelMigrateFrom.md new file mode 100644 index 0000000000..fcfdb0ad82 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChannelMigrateFrom.md @@ -0,0 +1,30 @@ +--- +title: "messageActionChannelMigrateFrom" +description: "Indicates the channel was migrated from the specified chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChannelMigrateFrom +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates the channel was [migrated](https://core.telegram.org/api/channel) from the specified chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|The old chat title| +|chat\_id|[long](/API_docs/types/long.html) | Yes|The old chat ID| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChannelMigrateFrom = ['_' => 'messageActionChannelMigrateFrom', 'title' => 'string', 'chat_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionChatAddUser.md b/docs/API_docs/constructors/messageActionChatAddUser.md new file mode 100644 index 0000000000..1add132aff --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatAddUser.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChatAddUser" +description: "New member in the group" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatAddUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +New member in the group + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|Array of [long](/API_docs/types/long.html) | Yes|Users that were invited to the chat| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatAddUser = ['_' => 'messageActionChatAddUser', 'users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/messageActionChatCreate.md b/docs/API_docs/constructors/messageActionChatCreate.md new file mode 100644 index 0000000000..cade391c34 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatCreate.md @@ -0,0 +1,30 @@ +--- +title: "messageActionChatCreate" +description: "Group created" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatCreate +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group created + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Group name| +|users|Array of [long](/API_docs/types/long.html) | Yes|List of group members| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatCreate = ['_' => 'messageActionChatCreate', 'title' => 'string', 'users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/messageActionChatDeletePhoto.md b/docs/API_docs/constructors/messageActionChatDeletePhoto.md new file mode 100644 index 0000000000..257b245067 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatDeletePhoto.md @@ -0,0 +1,24 @@ +--- +title: "messageActionChatDeletePhoto" +description: "Group profile photo removed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatDeletePhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group profile photo removed. + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatDeletePhoto = ['_' => 'messageActionChatDeletePhoto']; +``` diff --git a/docs/API_docs/constructors/messageActionChatDeleteUser.md b/docs/API_docs/constructors/messageActionChatDeleteUser.md new file mode 100644 index 0000000000..40a329fae1 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatDeleteUser.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChatDeleteUser" +description: "User left the group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatDeleteUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +User left the group. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|Leaving user ID| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatDeleteUser = ['_' => 'messageActionChatDeleteUser', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionChatEditPhoto.md b/docs/API_docs/constructors/messageActionChatEditPhoto.md new file mode 100644 index 0000000000..f04708aab7 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatEditPhoto.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChatEditPhoto" +description: "Group profile changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatEditPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group profile changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|New group profile photo| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatEditPhoto = ['_' => 'messageActionChatEditPhoto', 'photo' => Photo]; +``` diff --git a/docs/API_docs/constructors/messageActionChatEditTitle.md b/docs/API_docs/constructors/messageActionChatEditTitle.md new file mode 100644 index 0000000000..c513dc6e19 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatEditTitle.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChatEditTitle" +description: "Group name changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatEditTitle +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group name changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|New group name| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatEditTitle = ['_' => 'messageActionChatEditTitle', 'title' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageActionChatJoinedByLink.md b/docs/API_docs/constructors/messageActionChatJoinedByLink.md new file mode 100644 index 0000000000..3dff95e851 --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatJoinedByLink.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChatJoinedByLink" +description: "A user joined the chat via an invite link" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatJoinedByLink +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user joined the chat via an invite link + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inviter\_id|[long](/API_docs/types/long.html) | Yes|ID of the user that created the invite link| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatJoinedByLink = ['_' => 'messageActionChatJoinedByLink', 'inviter_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionChatJoinedByRequest.md b/docs/API_docs/constructors/messageActionChatJoinedByRequest.md new file mode 100644 index 0000000000..5b26d01cce --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatJoinedByRequest.md @@ -0,0 +1,24 @@ +--- +title: "messageActionChatJoinedByRequest" +description: "A user was accepted into the group by an admin" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatJoinedByRequest +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user was accepted into the group by an admin + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatJoinedByRequest = ['_' => 'messageActionChatJoinedByRequest']; +``` diff --git a/docs/API_docs/constructors/messageActionChatMigrateTo.md b/docs/API_docs/constructors/messageActionChatMigrateTo.md new file mode 100644 index 0000000000..3e1335db5c --- /dev/null +++ b/docs/API_docs/constructors/messageActionChatMigrateTo.md @@ -0,0 +1,29 @@ +--- +title: "messageActionChatMigrateTo" +description: "Indicates the chat was migrated to the specified supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionChatMigrateTo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates the chat was [migrated](https://core.telegram.org/api/channel) to the specified supergroup + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The supergroup it was migrated to| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionChatMigrateTo = ['_' => 'messageActionChatMigrateTo', 'channel_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionContactSignUp.md b/docs/API_docs/constructors/messageActionContactSignUp.md new file mode 100644 index 0000000000..25fe4ca0b6 --- /dev/null +++ b/docs/API_docs/constructors/messageActionContactSignUp.md @@ -0,0 +1,24 @@ +--- +title: "messageActionContactSignUp" +description: "A contact just signed up to telegram" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionContactSignUp +[Back to constructors index](/API_docs/constructors/index.html) + + + +A contact just signed up to telegram + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionContactSignUp = ['_' => 'messageActionContactSignUp']; +``` diff --git a/docs/API_docs/constructors/messageActionCustomAction.md b/docs/API_docs/constructors/messageActionCustomAction.md new file mode 100644 index 0000000000..30d3985b2d --- /dev/null +++ b/docs/API_docs/constructors/messageActionCustomAction.md @@ -0,0 +1,29 @@ +--- +title: "messageActionCustomAction" +description: "Custom action (most likely not supported by the current layer, an upgrade might be needed)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionCustomAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Custom action (most likely not supported by the current layer, an upgrade might be needed) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[string](/API_docs/types/string.html) | Yes|Action message| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionCustomAction = ['_' => 'messageActionCustomAction', 'message' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageActionEmpty.md b/docs/API_docs/constructors/messageActionEmpty.md new file mode 100644 index 0000000000..d4fd120b13 --- /dev/null +++ b/docs/API_docs/constructors/messageActionEmpty.md @@ -0,0 +1,24 @@ +--- +title: "messageActionEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionEmpty = ['_' => 'messageActionEmpty']; +``` diff --git a/docs/API_docs/constructors/messageActionGameScore.md b/docs/API_docs/constructors/messageActionGameScore.md new file mode 100644 index 0000000000..88cf8e7dea --- /dev/null +++ b/docs/API_docs/constructors/messageActionGameScore.md @@ -0,0 +1,30 @@ +--- +title: "messageActionGameScore" +description: "Someone scored in a game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGameScore +[Back to constructors index](/API_docs/constructors/index.html) + + + +Someone scored in a game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|game\_id|[long](/API_docs/types/long.html) | Yes|Game ID| +|score|[int](/API_docs/types/int.html) | Yes|Score| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGameScore = ['_' => 'messageActionGameScore', 'game_id' => long, 'score' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionGeoProximityReached.md b/docs/API_docs/constructors/messageActionGeoProximityReached.md new file mode 100644 index 0000000000..a2bd5e21ad --- /dev/null +++ b/docs/API_docs/constructors/messageActionGeoProximityReached.md @@ -0,0 +1,31 @@ +--- +title: "messageActionGeoProximityReached" +description: "A user of the chat is now in proximity of another user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGeoProximityReached +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user of the chat is now in proximity of another user + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|from\_id|[Peer](/API_docs/types/Peer.html) | Yes|The user or chat that is now in proximity of `to_id`| +|to\_id|[Peer](/API_docs/types/Peer.html) | Yes|The user or chat that subscribed to [live geolocation proximity alerts](https://core.telegram.org/api/live-location#proximity-alert)| +|distance|[int](/API_docs/types/int.html) | Yes|Distance, in meters (0-100000)| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGeoProximityReached = ['_' => 'messageActionGeoProximityReached', 'from_id' => Peer, 'to_id' => Peer, 'distance' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionGiftCode.md b/docs/API_docs/constructors/messageActionGiftCode.md new file mode 100644 index 0000000000..414513b456 --- /dev/null +++ b/docs/API_docs/constructors/messageActionGiftCode.md @@ -0,0 +1,37 @@ +--- +title: "messageActionGiftCode" +description: "Contains a Telegram Premium giftcode link." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGiftCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains a [Telegram Premium giftcode link](https://core.telegram.org/api/links#premium-giftcode-links). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|via\_giveaway|[Bool](/API_docs/types/Bool.html) | Optional|If set, this gift code was received from a [giveaway »](https://core.telegram.org/api/giveaways) started by a channel we're subscribed to.| +|unclaimed|[Bool](/API_docs/types/Bool.html) | Optional|If set, the link was not [redeemed](https://core.telegram.org/api/links#premium-giftcode-links) yet.| +|boost\_peer|[Peer](/API_docs/types/Peer.html) | Optional|Identifier of the channel that created the gift code [either directly or through a giveaway](https://core.telegram.org/api/giveaways): if we import this giftcode link, we will also automatically [boost](https://core.telegram.org/api/boost) this channel.| +|months|[int](/API_docs/types/int.html) | Yes|Duration in months of the gifted [Telegram Premium subscription](https://core.telegram.org/api/premium).| +|slug|[string](/API_docs/types/string.html) | Yes|Slug of the [Telegram Premium giftcode link](https://core.telegram.org/api/links#premium-giftcode-links)| +|currency|[string](/API_docs/types/string.html) | Optional|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Optional|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|crypto\_currency|[string](/API_docs/types/string.html) | Optional|If set, the gift was made using the specified cryptocurrency.| +|crypto\_amount|[long](/API_docs/types/long.html) | Optional|If `crypto_currency` is set, contains the paid amount, in the smallest units of the cryptocurrency.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGiftCode = ['_' => 'messageActionGiftCode', 'via_giveaway' => Bool, 'unclaimed' => Bool, 'boost_peer' => Peer, 'months' => int, 'slug' => 'string', 'currency' => 'string', 'amount' => long, 'crypto_currency' => 'string', 'crypto_amount' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionGiftPremium.md b/docs/API_docs/constructors/messageActionGiftPremium.md new file mode 100644 index 0000000000..4318c49223 --- /dev/null +++ b/docs/API_docs/constructors/messageActionGiftPremium.md @@ -0,0 +1,33 @@ +--- +title: "messageActionGiftPremium" +description: "Info about a gifted Telegram Premium subscription" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGiftPremium +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a gifted Telegram Premium subscription + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Price of the gift in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|months|[int](/API_docs/types/int.html) | Yes|Duration of the gifted Telegram Premium subscription| +|crypto\_currency|[string](/API_docs/types/string.html) | Optional|If the gift was bought using a cryptocurrency, the cryptocurrency name.| +|crypto\_amount|[long](/API_docs/types/long.html) | Optional|If the gift was bought using a cryptocurrency, price of the gift in the smallest units of a cryptocurrency.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGiftPremium = ['_' => 'messageActionGiftPremium', 'currency' => 'string', 'amount' => long, 'months' => int, 'crypto_currency' => 'string', 'crypto_amount' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionGiveawayLaunch.md b/docs/API_docs/constructors/messageActionGiveawayLaunch.md new file mode 100644 index 0000000000..f43c4d2cd4 --- /dev/null +++ b/docs/API_docs/constructors/messageActionGiveawayLaunch.md @@ -0,0 +1,24 @@ +--- +title: "messageActionGiveawayLaunch" +description: "A giveaway was started." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGiveawayLaunch +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [giveaway](https://core.telegram.org/api/giveaways) was started. + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGiveawayLaunch = ['_' => 'messageActionGiveawayLaunch']; +``` diff --git a/docs/API_docs/constructors/messageActionGiveawayResults.md b/docs/API_docs/constructors/messageActionGiveawayResults.md new file mode 100644 index 0000000000..a5c8a62c35 --- /dev/null +++ b/docs/API_docs/constructors/messageActionGiveawayResults.md @@ -0,0 +1,30 @@ +--- +title: "messageActionGiveawayResults" +description: "A giveaway has ended." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGiveawayResults +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [giveaway](https://core.telegram.org/api/giveaways) has ended. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|winners\_count|[int](/API_docs/types/int.html) | Yes|Number of winners in the giveaway| +|unclaimed\_count|[int](/API_docs/types/int.html) | Yes|Number of undistributed prizes| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGiveawayResults = ['_' => 'messageActionGiveawayResults', 'winners_count' => int, 'unclaimed_count' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionGroupCall.md b/docs/API_docs/constructors/messageActionGroupCall.md new file mode 100644 index 0000000000..cbb2d4b06f --- /dev/null +++ b/docs/API_docs/constructors/messageActionGroupCall.md @@ -0,0 +1,30 @@ +--- +title: "messageActionGroupCall" +description: "The group call has ended" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGroupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +The group call has ended + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|Group call| +|duration|[int](/API_docs/types/int.html) | Optional|Group call duration| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGroupCall = ['_' => 'messageActionGroupCall', 'call' => InputGroupCall, 'duration' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionGroupCallScheduled.md b/docs/API_docs/constructors/messageActionGroupCallScheduled.md new file mode 100644 index 0000000000..2ef451991a --- /dev/null +++ b/docs/API_docs/constructors/messageActionGroupCallScheduled.md @@ -0,0 +1,30 @@ +--- +title: "messageActionGroupCallScheduled" +description: "A group call was scheduled" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionGroupCallScheduled +[Back to constructors index](/API_docs/constructors/index.html) + + + +A group call was scheduled + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|The group call| +|schedule\_date|[int](/API_docs/types/int.html) | Yes|When is this group call scheduled to start| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionGroupCallScheduled = ['_' => 'messageActionGroupCallScheduled', 'call' => InputGroupCall, 'schedule_date' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionHistoryClear.md b/docs/API_docs/constructors/messageActionHistoryClear.md new file mode 100644 index 0000000000..43473dff6c --- /dev/null +++ b/docs/API_docs/constructors/messageActionHistoryClear.md @@ -0,0 +1,24 @@ +--- +title: "messageActionHistoryClear" +description: "Chat history was cleared" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionHistoryClear +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat history was cleared + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionHistoryClear = ['_' => 'messageActionHistoryClear']; +``` diff --git a/docs/API_docs/constructors/messageActionInviteToGroupCall.md b/docs/API_docs/constructors/messageActionInviteToGroupCall.md new file mode 100644 index 0000000000..c50fb15518 --- /dev/null +++ b/docs/API_docs/constructors/messageActionInviteToGroupCall.md @@ -0,0 +1,30 @@ +--- +title: "messageActionInviteToGroupCall" +description: "A set of users was invited to the group call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionInviteToGroupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +A set of users was invited to the group call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|The group call| +|users|Array of [long](/API_docs/types/long.html) | Yes|The invited users| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionInviteToGroupCall = ['_' => 'messageActionInviteToGroupCall', 'call' => InputGroupCall, 'users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/messageActionPaymentSent.md b/docs/API_docs/constructors/messageActionPaymentSent.md new file mode 100644 index 0000000000..07e5fefc9f --- /dev/null +++ b/docs/API_docs/constructors/messageActionPaymentSent.md @@ -0,0 +1,33 @@ +--- +title: "messageActionPaymentSent" +description: "A payment was sent" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionPaymentSent +[Back to constructors index](/API_docs/constructors/index.html) + + + +A payment was sent + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|recurring\_init|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is the first payment of a recurring payment we just subscribed to| +|recurring\_used|[Bool](/API_docs/types/Bool.html) | Optional|Whether this payment is part of a recurring payment| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|total\_amount|[long](/API_docs/types/long.html) | Yes|Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|invoice\_slug|[string](/API_docs/types/string.html) | Optional|An invoice slug taken from an [invoice deep link](https://core.telegram.org/api/links#invoice-links) or from the [`premium_invoice_slug` app config parameter »](https://core.telegram.org/api/config#premium-invoice-slug)| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionPaymentSent = ['_' => 'messageActionPaymentSent', 'recurring_init' => Bool, 'recurring_used' => Bool, 'currency' => 'string', 'total_amount' => long, 'invoice_slug' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageActionPaymentSentMe.md b/docs/API_docs/constructors/messageActionPaymentSentMe.md new file mode 100644 index 0000000000..8d09a77d90 --- /dev/null +++ b/docs/API_docs/constructors/messageActionPaymentSentMe.md @@ -0,0 +1,36 @@ +--- +title: "messageActionPaymentSentMe" +description: "A user just sent a payment to me (a bot)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionPaymentSentMe +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user just sent a payment to me (a bot) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|recurring\_init|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is the first payment of a recurring payment we just subscribed to| +|recurring\_used|[Bool](/API_docs/types/Bool.html) | Optional|Whether this payment is part of a recurring payment| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|total\_amount|[long](/API_docs/types/long.html) | Yes|Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|payload|[bytes](/API_docs/types/bytes.html) | Yes|Bot specified invoice payload| +|info|[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) | Optional|Order info provided by the user| +|shipping\_option\_id|[string](/API_docs/types/string.html) | Optional|Identifier of the shipping option chosen by the user| +|charge|[PaymentCharge](/API_docs/types/PaymentCharge.html) | Yes|Provider payment identifier| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionPaymentSentMe = ['_' => 'messageActionPaymentSentMe', 'recurring_init' => Bool, 'recurring_used' => Bool, 'currency' => 'string', 'total_amount' => long, 'payload' => 'bytes', 'info' => PaymentRequestedInfo, 'shipping_option_id' => 'string', 'charge' => PaymentCharge]; +``` diff --git a/docs/API_docs/constructors/messageActionPhoneCall.md b/docs/API_docs/constructors/messageActionPhoneCall.md new file mode 100644 index 0000000000..9f3e7bbae2 --- /dev/null +++ b/docs/API_docs/constructors/messageActionPhoneCall.md @@ -0,0 +1,32 @@ +--- +title: "messageActionPhoneCall" +description: "A phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionPhoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +A phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Is this a video call?| +|call\_id|[long](/API_docs/types/long.html) | Yes|Call ID| +|reason|[PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) | Optional|If the call has ended, the reason why it ended| +|duration|[int](/API_docs/types/int.html) | Optional|Duration of the call in seconds| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionPhoneCall = ['_' => 'messageActionPhoneCall', 'video' => Bool, 'call_id' => long, 'reason' => PhoneCallDiscardReason, 'duration' => int]; +``` diff --git a/docs/API_docs/constructors/messageActionPinMessage.md b/docs/API_docs/constructors/messageActionPinMessage.md new file mode 100644 index 0000000000..d232ed1fb0 --- /dev/null +++ b/docs/API_docs/constructors/messageActionPinMessage.md @@ -0,0 +1,24 @@ +--- +title: "messageActionPinMessage" +description: "A message was pinned" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionPinMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was pinned + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionPinMessage = ['_' => 'messageActionPinMessage']; +``` diff --git a/docs/API_docs/constructors/messageActionRequestedPeer.md b/docs/API_docs/constructors/messageActionRequestedPeer.md new file mode 100644 index 0000000000..9ad862b6bc --- /dev/null +++ b/docs/API_docs/constructors/messageActionRequestedPeer.md @@ -0,0 +1,30 @@ +--- +title: "messageActionRequestedPeer" +description: "Contains info about one or more peers that the user shared with the bot after clicking on a keyboardButtonRequestPeer button." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionRequestedPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about one or more peers that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html) button. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|button\_id|[int](/API_docs/types/int.html) | Yes|`button_id` contained in the [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html)| +|peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|The shared peers| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionRequestedPeer = ['_' => 'messageActionRequestedPeer', 'button_id' => int, 'peers' => [Peer, Peer]]; +``` diff --git a/docs/API_docs/constructors/messageActionRequestedPeerSentMe.md b/docs/API_docs/constructors/messageActionRequestedPeerSentMe.md new file mode 100644 index 0000000000..1cced97b0d --- /dev/null +++ b/docs/API_docs/constructors/messageActionRequestedPeerSentMe.md @@ -0,0 +1,28 @@ +--- +title: "messageActionRequestedPeerSentMe" +description: "messageActionRequestedPeerSentMe attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionRequestedPeerSentMe +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|button\_id|[int](/API_docs/types/int.html) | Yes| +|peers|Array of [RequestedPeer](/API_docs/types/RequestedPeer.html) | Yes| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionRequestedPeerSentMe = ['_' => 'messageActionRequestedPeerSentMe', 'button_id' => int, 'peers' => [RequestedPeer, RequestedPeer]]; +``` diff --git a/docs/API_docs/constructors/messageActionScreenshotTaken.md b/docs/API_docs/constructors/messageActionScreenshotTaken.md new file mode 100644 index 0000000000..9932af8fd0 --- /dev/null +++ b/docs/API_docs/constructors/messageActionScreenshotTaken.md @@ -0,0 +1,24 @@ +--- +title: "messageActionScreenshotTaken" +description: "A screenshot of the chat was taken" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionScreenshotTaken +[Back to constructors index](/API_docs/constructors/index.html) + + + +A screenshot of the chat was taken + + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionScreenshotTaken = ['_' => 'messageActionScreenshotTaken']; +``` diff --git a/docs/API_docs/constructors/messageActionSecureValuesSent.md b/docs/API_docs/constructors/messageActionSecureValuesSent.md new file mode 100644 index 0000000000..28ad5a5f0b --- /dev/null +++ b/docs/API_docs/constructors/messageActionSecureValuesSent.md @@ -0,0 +1,29 @@ +--- +title: "messageActionSecureValuesSent" +description: "Request for secure telegram passport values was sent" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionSecureValuesSent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Request for secure [telegram passport](https://core.telegram.org/passport) values was sent + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|types|Array of [SecureValueType](/API_docs/types/SecureValueType.html) | Yes|Secure value types| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionSecureValuesSent = ['_' => 'messageActionSecureValuesSent', 'types' => [SecureValueType, SecureValueType]]; +``` diff --git a/docs/API_docs/constructors/messageActionSecureValuesSentMe.md b/docs/API_docs/constructors/messageActionSecureValuesSentMe.md new file mode 100644 index 0000000000..822d206ffd --- /dev/null +++ b/docs/API_docs/constructors/messageActionSecureValuesSentMe.md @@ -0,0 +1,30 @@ +--- +title: "messageActionSecureValuesSentMe" +description: "Secure telegram passport values were received" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionSecureValuesSentMe +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure [telegram passport](https://core.telegram.org/passport) values were received + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|values|Array of [SecureValue](/API_docs/types/SecureValue.html) | Yes|Vector with information about documents and other Telegram Passport elements that were shared with the bot| +|credentials|[SecureCredentialsEncrypted](/API_docs/types/SecureCredentialsEncrypted.html) | Yes|Encrypted credentials required to decrypt the data| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionSecureValuesSentMe = ['_' => 'messageActionSecureValuesSentMe', 'values' => [SecureValue, SecureValue], 'credentials' => SecureCredentialsEncrypted]; +``` diff --git a/docs/API_docs/constructors/messageActionSetChatTheme.md b/docs/API_docs/constructors/messageActionSetChatTheme.md new file mode 100644 index 0000000000..126ddcda2c --- /dev/null +++ b/docs/API_docs/constructors/messageActionSetChatTheme.md @@ -0,0 +1,29 @@ +--- +title: "messageActionSetChatTheme" +description: "The chat theme was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionSetChatTheme +[Back to constructors index](/API_docs/constructors/index.html) + + + +The chat theme was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|The emoji that identifies a chat theme| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionSetChatTheme = ['_' => 'messageActionSetChatTheme', 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageActionSetChatWallPaper.md b/docs/API_docs/constructors/messageActionSetChatWallPaper.md new file mode 100644 index 0000000000..97bb43e80f --- /dev/null +++ b/docs/API_docs/constructors/messageActionSetChatWallPaper.md @@ -0,0 +1,31 @@ +--- +title: "messageActionSetChatWallPaper" +description: "The wallpaper » of the current chat was changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionSetChatWallPaper +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [wallpaper »](https://core.telegram.org/api/wallpapers) of the current chat was changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|same|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates the user applied a [wallpaper »](https://core.telegram.org/api/wallpapers) previously sent by the other user in a [messageActionSetChatWallPaper](../constructors/messageActionSetChatWallPaper.html) message.| +|for\_both|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates the wallpaper was forcefully applied for both sides, without explicit confirmation from the other side.
If the message is incoming, and we did not like the new wallpaper the other user has chosen for us, we can re-set our previous wallpaper just on our side, by invoking [messages.setChatWallPaper](../methods/messages.setChatWallPaper.html), providing only the `revert` flag (and obviously the `peer` parameter).| +|wallpaper|[WallPaper](/API_docs/types/WallPaper.html) | Yes|New [wallpaper](https://core.telegram.org/api/wallpapers)| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionSetChatWallPaper = ['_' => 'messageActionSetChatWallPaper', 'same' => Bool, 'for_both' => Bool, 'wallpaper' => WallPaper]; +``` diff --git a/docs/API_docs/constructors/messageActionSetMessagesTTL.md b/docs/API_docs/constructors/messageActionSetMessagesTTL.md new file mode 100644 index 0000000000..f4d18dca25 --- /dev/null +++ b/docs/API_docs/constructors/messageActionSetMessagesTTL.md @@ -0,0 +1,30 @@ +--- +title: "messageActionSetMessagesTTL" +description: "The Time-To-Live of messages in this chat was changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionSetMessagesTTL +[Back to constructors index](/API_docs/constructors/index.html) + + + +The Time-To-Live of messages in this chat was changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|period|[int](/API_docs/types/int.html) | Yes|New Time-To-Live of all messages sent in this chat; if 0, autodeletion was disabled.| +|auto\_setting\_from|[long](/API_docs/types/long.html) | Optional|If set, the chat TTL setting was set not due to a manual change by one of participants, but automatically because one of the participants has the [default TTL settings enabled »](../methods/messages.setDefaultHistoryTTL.html). For example, when a user writes to us for the first time and we have set a default messages TTL of 1 week, this service message (with `auto_setting_from=our_userid`) will be emitted before our first message.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionSetMessagesTTL = ['_' => 'messageActionSetMessagesTTL', 'period' => int, 'auto_setting_from' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionSuggestProfilePhoto.md b/docs/API_docs/constructors/messageActionSuggestProfilePhoto.md new file mode 100644 index 0000000000..8f85be2102 --- /dev/null +++ b/docs/API_docs/constructors/messageActionSuggestProfilePhoto.md @@ -0,0 +1,29 @@ +--- +title: "messageActionSuggestProfilePhoto" +description: "A new profile picture was suggested using photos.uploadContactProfilePhoto." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionSuggestProfilePhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new profile picture was suggested using [photos.uploadContactProfilePhoto](../methods/photos.uploadContactProfilePhoto.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|The photo that the user suggested we set as profile picture.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionSuggestProfilePhoto = ['_' => 'messageActionSuggestProfilePhoto', 'photo' => Photo]; +``` diff --git a/docs/API_docs/constructors/messageActionTopicCreate.md b/docs/API_docs/constructors/messageActionTopicCreate.md new file mode 100644 index 0000000000..053db88ef6 --- /dev/null +++ b/docs/API_docs/constructors/messageActionTopicCreate.md @@ -0,0 +1,31 @@ +--- +title: "messageActionTopicCreate" +description: "A forum topic was created." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionTopicCreate +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Topic name.| +|icon\_color|[int](/API_docs/types/int.html) | Yes|If no custom emoji icon is specified, specifies the color of the fallback topic icon (RGB), one of `0x6FB9F0`, `0xFFD67E`, `0xCB86DB`, `0x8EEE98`, `0xFF93B2`, or `0xFB6F5F`.| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | Optional|ID of the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionTopicCreate = ['_' => 'messageActionTopicCreate', 'title' => 'string', 'icon_color' => int, 'icon_emoji_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageActionTopicEdit.md b/docs/API_docs/constructors/messageActionTopicEdit.md new file mode 100644 index 0000000000..70b3746e72 --- /dev/null +++ b/docs/API_docs/constructors/messageActionTopicEdit.md @@ -0,0 +1,32 @@ +--- +title: "messageActionTopicEdit" +description: "Forum topic information was edited." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionTopicEdit +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Optional|New topic title.| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | Optional|ID of the new [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon, or if it was removed.| +|closed|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic was opened or closed.| +|hidden|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic was hidden or unhidden (only valid for the "General" topic, `id=1`).| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionTopicEdit = ['_' => 'messageActionTopicEdit', 'title' => 'string', 'icon_emoji_id' => long, 'closed' => Bool, 'hidden' => Bool]; +``` diff --git a/docs/API_docs/constructors/messageActionWebViewDataSent.md b/docs/API_docs/constructors/messageActionWebViewDataSent.md new file mode 100644 index 0000000000..d98e99462d --- /dev/null +++ b/docs/API_docs/constructors/messageActionWebViewDataSent.md @@ -0,0 +1,31 @@ +--- +title: "messageActionWebViewDataSent" +description: "Data from an opened reply keyboard bot mini app was relayed to the bot that owns it (user side service message)." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionWebViewDataSent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Data from an opened [reply keyboard bot mini app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user side service message). + +Clients should display a service message with the text `Data from the «$text» button was transferred to the bot.` + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Text of the [keyboardButtonSimpleWebView](../constructors/keyboardButtonSimpleWebView.html) that was pressed to open the web app.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionWebViewDataSent = ['_' => 'messageActionWebViewDataSent', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageActionWebViewDataSentMe.md b/docs/API_docs/constructors/messageActionWebViewDataSentMe.md new file mode 100644 index 0000000000..b2ae80ccbf --- /dev/null +++ b/docs/API_docs/constructors/messageActionWebViewDataSentMe.md @@ -0,0 +1,30 @@ +--- +title: "messageActionWebViewDataSentMe" +description: "Data from an opened reply keyboard bot mini app was relayed to the bot that owns it (bot side service message)." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageActionWebViewDataSentMe +[Back to constructors index](/API_docs/constructors/index.html) + + + +Data from an opened [reply keyboard bot mini app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (bot side service message). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Text of the [keyboardButtonSimpleWebView](../constructors/keyboardButtonSimpleWebView.html) that was pressed to open the web app.| +|data|[string](/API_docs/types/string.html) | Yes|Relayed data.| + + + +### Type: [MessageAction](/API_docs/types/MessageAction.html) + + +### Example: + +``` +$messageActionWebViewDataSentMe = ['_' => 'messageActionWebViewDataSentMe', 'text' => 'string', 'data' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageEmpty.md b/docs/API_docs/constructors/messageEmpty.md new file mode 100644 index 0000000000..af627d6d1b --- /dev/null +++ b/docs/API_docs/constructors/messageEmpty.md @@ -0,0 +1,30 @@ +--- +title: "messageEmpty" +description: "Empty constructor, non-existent message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, non-existent message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Message identifier| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Optional|Peer ID, the chat where this message was sent| + + + +### Type: [Message](/API_docs/types/Message.html) + + +### Example: + +``` +$messageEmpty = ['_' => 'messageEmpty', 'id' => int, 'peer_id' => Peer]; +``` diff --git a/docs/API_docs/constructors/messageEntityBankCard.md b/docs/API_docs/constructors/messageEntityBankCard.md new file mode 100644 index 0000000000..789a31e2dc --- /dev/null +++ b/docs/API_docs/constructors/messageEntityBankCard.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityBankCard" +description: "Indicates a credit card number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityBankCard +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a credit card number + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityBankCard = ['_' => 'messageEntityBankCard', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityBlockquote.md b/docs/API_docs/constructors/messageEntityBlockquote.md new file mode 100644 index 0000000000..e69319b3b9 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityBlockquote.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityBlockquote" +description: "Message entity representing a block quote." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityBlockquote +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a block quote. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityBlockquote = ['_' => 'messageEntityBlockquote', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityBold.md b/docs/API_docs/constructors/messageEntityBold.md new file mode 100644 index 0000000000..933fa92d67 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityBold.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityBold" +description: "Message entity representing bold text." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityBold +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing **bold text**. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityBold = ['_' => 'messageEntityBold', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityBotCommand.md b/docs/API_docs/constructors/messageEntityBotCommand.md new file mode 100644 index 0000000000..0d2a4a1733 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityBotCommand.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityBotCommand" +description: "Message entity representing a bot /command" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityBotCommand +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a bot /command + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityBotCommand = ['_' => 'messageEntityBotCommand', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityCashtag.md b/docs/API_docs/constructors/messageEntityCashtag.md new file mode 100644 index 0000000000..61217300f8 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityCashtag.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityCashtag" +description: "Message entity representing a $cashtag." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityCashtag +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a **$cashtag**. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityCashtag = ['_' => 'messageEntityCashtag', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityCode.md b/docs/API_docs/constructors/messageEntityCode.md new file mode 100644 index 0000000000..bb1313bea2 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityCode.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityCode" +description: "Message entity representing a codeblock." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityCode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a `codeblock`. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityCode = ['_' => 'messageEntityCode', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityCustomEmoji.md b/docs/API_docs/constructors/messageEntityCustomEmoji.md new file mode 100644 index 0000000000..633a8f84a1 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityCustomEmoji.md @@ -0,0 +1,32 @@ +--- +title: "messageEntityCustomEmoji" +description: "Represents a custom emoji." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityCustomEmoji +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a custom emoji. +Note that this entity must wrap exactly one regular emoji (the one contained in [documentAttributeCustomEmoji](../constructors/documentAttributeCustomEmoji.html).`alt`) in the related text, otherwise the server will ignore it. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|document\_id|[long](/API_docs/types/long.html) | Yes|Document ID of the [custom emoji](https://core.telegram.org/api/custom-emoji), use [messages.getCustomEmojiDocuments](../methods/messages.getCustomEmojiDocuments.html) to fetch the emoji animation and the actual emoji it represents.| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityCustomEmoji = ['_' => 'messageEntityCustomEmoji', 'offset' => int, 'length' => int, 'document_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageEntityEmail.md b/docs/API_docs/constructors/messageEntityEmail.md new file mode 100644 index 0000000000..b96db42298 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityEmail.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityEmail" +description: "Message entity representing an ." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityEmail +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing an . + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityEmail = ['_' => 'messageEntityEmail', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityHashtag.md b/docs/API_docs/constructors/messageEntityHashtag.md new file mode 100644 index 0000000000..6d80c7dce0 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityHashtag.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityHashtag" +description: "#hashtag message entity" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityHashtag +[Back to constructors index](/API_docs/constructors/index.html) + + + +**\#hashtag** message entity + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityHashtag = ['_' => 'messageEntityHashtag', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityItalic.md b/docs/API_docs/constructors/messageEntityItalic.md new file mode 100644 index 0000000000..bd25ceade0 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityItalic.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityItalic" +description: "Message entity representing italic text." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityItalic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing *italic text*. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityItalic = ['_' => 'messageEntityItalic', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityMention.md b/docs/API_docs/constructors/messageEntityMention.md new file mode 100644 index 0000000000..9dd6d6ca8c --- /dev/null +++ b/docs/API_docs/constructors/messageEntityMention.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityMention" +description: "Message entity mentioning a user by @username; messageEntityMentionName can also be used to mention users by their ID." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityMention +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity [mentioning](https://core.telegram.org/api/mentions) a user by `@username`; [messageEntityMentionName](../constructors/messageEntityMentionName.html) can also be used to mention users by their ID. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityMention = ['_' => 'messageEntityMention', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityMentionName.md b/docs/API_docs/constructors/messageEntityMentionName.md new file mode 100644 index 0000000000..3af34c53b1 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityMentionName.md @@ -0,0 +1,31 @@ +--- +title: "messageEntityMentionName" +description: "Message entity representing a user mention: for creating a mention use inputMessageEntityMentionName." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityMentionName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a [user mention](https://core.telegram.org/api/mentions): for *creating* a mention use [inputMessageEntityMentionName](../constructors/inputMessageEntityMentionName.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|user\_id|[long](/API_docs/types/long.html) | Yes|Identifier of the user that was mentioned| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityMentionName = ['_' => 'messageEntityMentionName', 'offset' => int, 'length' => int, 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageEntityPhone.md b/docs/API_docs/constructors/messageEntityPhone.md new file mode 100644 index 0000000000..259f596040 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityPhone.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityPhone" +description: "Message entity representing a phone number." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a phone number. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityPhone = ['_' => 'messageEntityPhone', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityPre.md b/docs/API_docs/constructors/messageEntityPre.md new file mode 100644 index 0000000000..f1d38528dd --- /dev/null +++ b/docs/API_docs/constructors/messageEntityPre.md @@ -0,0 +1,31 @@ +--- +title: "messageEntityPre" +description: "Message entity representing a preformatted codeblock, allowing the user to specify a programming language for the codeblock." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityPre +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a preformatted `codeblock`, allowing the user to specify a programming language for the codeblock. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|language|[string](/API_docs/types/string.html) | Yes|Programming language of the code| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityPre = ['_' => 'messageEntityPre', 'offset' => int, 'length' => int, 'language' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageEntitySpoiler.md b/docs/API_docs/constructors/messageEntitySpoiler.md new file mode 100644 index 0000000000..4bc8b0c8da --- /dev/null +++ b/docs/API_docs/constructors/messageEntitySpoiler.md @@ -0,0 +1,30 @@ +--- +title: "messageEntitySpoiler" +description: "Message entity representing a spoiler" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntitySpoiler +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a spoiler + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntitySpoiler = ['_' => 'messageEntitySpoiler', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityStrike.md b/docs/API_docs/constructors/messageEntityStrike.md new file mode 100644 index 0000000000..546fbbf46f --- /dev/null +++ b/docs/API_docs/constructors/messageEntityStrike.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityStrike" +description: "Message entity representing strikethrough text." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityStrike +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing strikethrough text. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityStrike = ['_' => 'messageEntityStrike', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityTextUrl.md b/docs/API_docs/constructors/messageEntityTextUrl.md new file mode 100644 index 0000000000..985009f453 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityTextUrl.md @@ -0,0 +1,33 @@ +--- +title: "messageEntityTextUrl" +description: "Message entity representing a text url: for in-text urls like use messageEntityUrl." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityTextUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing a [text url](https://google.com): for in-text urls like use [messageEntityUrl](../constructors/messageEntityUrl.html). + +Note that an additional confirmation popup with the full URL must be displayed to the user before opening this link, unless the domain satisfies the conditions specified in the [domain whitelist documentation »](https://core.telegram.org/api/config#whitelisted-domains). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|url|[string](/API_docs/types/string.html) | Yes|The actual URL| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityTextUrl = ['_' => 'messageEntityTextUrl', 'offset' => int, 'length' => int, 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageEntityUnderline.md b/docs/API_docs/constructors/messageEntityUnderline.md new file mode 100644 index 0000000000..b3b4e7cd62 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityUnderline.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityUnderline" +description: "Message entity representing underlined text." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityUnderline +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing underlined text. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityUnderline = ['_' => 'messageEntityUnderline', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityUnknown.md b/docs/API_docs/constructors/messageEntityUnknown.md new file mode 100644 index 0000000000..0c060ad4f2 --- /dev/null +++ b/docs/API_docs/constructors/messageEntityUnknown.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityUnknown" +description: "Unknown message entity" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityUnknown +[Back to constructors index](/API_docs/constructors/index.html) + + + +Unknown message entity + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityUnknown = ['_' => 'messageEntityUnknown', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageEntityUrl.md b/docs/API_docs/constructors/messageEntityUrl.md new file mode 100644 index 0000000000..da5d16906d --- /dev/null +++ b/docs/API_docs/constructors/messageEntityUrl.md @@ -0,0 +1,30 @@ +--- +title: "messageEntityUrl" +description: "Message entity representing an in-text url: ; for text urls, use messageEntityTextUrl." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageEntityUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message entity representing an in-text url: ; for [text urls](https://google.com), use [messageEntityTextUrl](../constructors/messageEntityTextUrl.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|offset|[int](/API_docs/types/int.html) | Yes|Offset of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| +|length|[int](/API_docs/types/int.html) | Yes|Length of message entity within message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length))| + + + +### Type: [MessageEntity](/API_docs/types/MessageEntity.html) + + +### Example: + +``` +$messageEntityUrl = ['_' => 'messageEntityUrl', 'offset' => int, 'length' => int]; +``` diff --git a/docs/API_docs/constructors/messageExtendedMedia.md b/docs/API_docs/constructors/messageExtendedMedia.md new file mode 100644 index 0000000000..1dcd1a8647 --- /dev/null +++ b/docs/API_docs/constructors/messageExtendedMedia.md @@ -0,0 +1,29 @@ +--- +title: "messageExtendedMedia" +description: "Extended media" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageExtendedMedia +[Back to constructors index](/API_docs/constructors/index.html) + + + +Extended media + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|media|[MessageMedia](/API_docs/types/MessageMedia.html) | Optional|Media| + + + +### Type: [MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html) + + +### Example: + +``` +$messageExtendedMedia = ['_' => 'messageExtendedMedia', 'media' => MessageMedia]; +``` diff --git a/docs/API_docs/constructors/messageExtendedMediaPreview.md b/docs/API_docs/constructors/messageExtendedMediaPreview.md new file mode 100644 index 0000000000..3d3b2b11d0 --- /dev/null +++ b/docs/API_docs/constructors/messageExtendedMediaPreview.md @@ -0,0 +1,32 @@ +--- +title: "messageExtendedMediaPreview" +description: "Extended media preview" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageExtendedMediaPreview +[Back to constructors index](/API_docs/constructors/index.html) + + + +Extended media preview + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|w|[int](/API_docs/types/int.html) | Optional|Width| +|h|[int](/API_docs/types/int.html) | Optional|Height| +|thumb|[PhotoSize](/API_docs/types/PhotoSize.html) | Optional|Thumbnail| +|video\_duration|[int](/API_docs/types/int.html) | Optional|Video duration| + + + +### Type: [MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html) + + +### Example: + +``` +$messageExtendedMediaPreview = ['_' => 'messageExtendedMediaPreview', 'w' => int, 'h' => int, 'thumb' => PhotoSize, 'video_duration' => int]; +``` diff --git a/docs/API_docs/constructors/messageFwdHeader.md b/docs/API_docs/constructors/messageFwdHeader.md new file mode 100644 index 0000000000..da72d05d9c --- /dev/null +++ b/docs/API_docs/constructors/messageFwdHeader.md @@ -0,0 +1,41 @@ +--- +title: "messageFwdHeader" +description: "Info about a forwarded message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageFwdHeader +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a forwarded message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|imported|[Bool](/API_docs/types/Bool.html) | Optional|Whether this message was [imported from a foreign chat service, click here for more info »](https://core.telegram.org/api/import)| +|saved\_out|[Bool](/API_docs/types/Bool.html) | Optional|Only for messages forwarded to [saved messages »](https://core.telegram.org/api/saved-messages), set if the original message was outgoing (though the message may have been originally outgoing even if this flag is not set, if `from_id` points to the current user).| +|from\_id|[Peer](/API_docs/types/Peer.html) | Optional|The ID of the user that originally sent the message| +|from\_name|[string](/API_docs/types/string.html) | Optional|The name of the user that originally sent the message| +|date|[int](/API_docs/types/int.html) | Yes|When was the message originally sent| +|channel\_post|[int](/API_docs/types/int.html) | Optional|ID of the channel message that was forwarded| +|post\_author|[string](/API_docs/types/string.html) | Optional|For channels and if signatures are enabled, author of the channel message| +|saved\_from\_peer|[Peer](/API_docs/types/Peer.html) | Optional|Only for messages forwarded to [saved messages »](https://core.telegram.org/api/saved-messages), contains the dialog where the message was originally sent.| +|saved\_from\_msg\_id|[int](/API_docs/types/int.html) | Optional|Only for messages forwarded to [saved messages »](https://core.telegram.org/api/saved-messages), contains the original ID of the message in `saved_from_peer`.| +|saved\_from\_id|[Peer](/API_docs/types/Peer.html) | Optional|Only for forwarded messages reforwarded to [saved messages »](https://core.telegram.org/api/saved-messages), contains the sender of the original message (i.e. if user A sends a message, then user B forwards it somewhere, then user C saves it to saved messages, this field will contain the ID of user B and `from_id` will contain the ID of user A).| +|saved\_from\_name|[string](/API_docs/types/string.html) | Optional|Only for forwarded messages from users with forward privacy enabled, sent by users with forward privacy enabled, reforwarded to [saved messages »](https://core.telegram.org/api/saved-messages), contains the sender of the original message (i.e. if user A (fwd privacy enabled) sends a message, then user B (fwd privacy enabled) forwards it somewhere, then user C saves it to saved messages, this field will contain the name of user B and `from_name` will contain the name of user A).| +|saved\_date|[int](/API_docs/types/int.html) | Optional|Only for forwarded messages reforwarded to [saved messages »](https://core.telegram.org/api/saved-messages), indicates when was the original message sent (i.e. if user A sends a message @ unixtime 1, then user B forwards it somewhere @ unixtime 2, then user C saves it to saved messages @ unixtime 3, this field will contain 2, `date` will contain 1 and the `date` of the containing [message](../constructors/message.html) will contain 3).| +|psa\_type|[string](/API_docs/types/string.html) | Optional|PSA type| + + + +### Type: [MessageFwdHeader](/API_docs/types/MessageFwdHeader.html) + + +### Example: + +``` +$messageFwdHeader = ['_' => 'messageFwdHeader', 'imported' => Bool, 'saved_out' => Bool, 'from_id' => Peer, 'from_name' => 'string', 'date' => int, 'channel_post' => int, 'post_author' => 'string', 'saved_from_peer' => Peer, 'saved_from_msg_id' => int, 'saved_from_id' => Peer, 'saved_from_name' => 'string', 'saved_date' => int, 'psa_type' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageMediaContact.md b/docs/API_docs/constructors/messageMediaContact.md new file mode 100644 index 0000000000..921755044c --- /dev/null +++ b/docs/API_docs/constructors/messageMediaContact.md @@ -0,0 +1,33 @@ +--- +title: "messageMediaContact" +description: "Attached contact." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Attached contact. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_number|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|Contact's first name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Contact's last name| +|vcard|[string](/API_docs/types/string.html) | Yes|VCARD of contact| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier or `0`, if the user with the given phone number is not registered| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaContact = ['_' => 'messageMediaContact', 'phone_number' => 'string', 'first_name' => 'string', 'last_name' => 'string', 'vcard' => 'string', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/messageMediaDice.md b/docs/API_docs/constructors/messageMediaDice.md new file mode 100644 index 0000000000..0c332153a8 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaDice.md @@ -0,0 +1,30 @@ +--- +title: "messageMediaDice" +description: "Dice-based animated sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaDice +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Dice-based animated sticker](https://core.telegram.org/api/dice) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|value|[int](/API_docs/types/int.html) | Yes|[Dice value](https://core.telegram.org/api/dice)| +|emoticon|[string](/API_docs/types/string.html) | Yes|The emoji, for now 🏀, 🎲 and 🎯 are supported| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaDice = ['_' => 'messageMediaDice', 'value' => int, 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageMediaDocument.md b/docs/API_docs/constructors/messageMediaDocument.md new file mode 100644 index 0000000000..e697ab5b3c --- /dev/null +++ b/docs/API_docs/constructors/messageMediaDocument.md @@ -0,0 +1,36 @@ +--- +title: "messageMediaDocument" +description: "Document (video, audio, voice, sticker, any media type except photo)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +Document (video, audio, voice, sticker, any media type except photo) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|nopremium|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a normal sticker, if not set this is a premium sticker and a premium sticker animation must be played.| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a video.| +|round|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a round video.| +|voice|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a voice message.| +|document|[Document](/API_docs/types/Document.html) | Optional|Attached document| +|alt\_document|[Document](/API_docs/types/Document.html) | Optional|Currently only used for story videos, may contain an alternative version of the story video, explicitly encoded using H.264 (in MPEG4 transport) at a lower resolution than `document`.| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Time to live of self-destructing document| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaDocument = ['_' => 'messageMediaDocument', 'nopremium' => Bool, 'spoiler' => Bool, 'video' => Bool, 'round' => Bool, 'voice' => Bool, 'document' => Document, 'alt_document' => Document, 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/messageMediaEmpty.md b/docs/API_docs/constructors/messageMediaEmpty.md new file mode 100644 index 0000000000..c80e4b21ad --- /dev/null +++ b/docs/API_docs/constructors/messageMediaEmpty.md @@ -0,0 +1,24 @@ +--- +title: "messageMediaEmpty" +description: "Empty constructor." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. + + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaEmpty = ['_' => 'messageMediaEmpty']; +``` diff --git a/docs/API_docs/constructors/messageMediaGame.md b/docs/API_docs/constructors/messageMediaGame.md new file mode 100644 index 0000000000..2662405b02 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaGame.md @@ -0,0 +1,29 @@ +--- +title: "messageMediaGame" +description: "Telegram game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaGame +[Back to constructors index](/API_docs/constructors/index.html) + + + +Telegram game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|game|[Game](/API_docs/types/Game.html) | Yes|Game| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaGame = ['_' => 'messageMediaGame', 'game' => Game]; +``` diff --git a/docs/API_docs/constructors/messageMediaGeo.md b/docs/API_docs/constructors/messageMediaGeo.md new file mode 100644 index 0000000000..51a72ed4b9 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaGeo.md @@ -0,0 +1,29 @@ +--- +title: "messageMediaGeo" +description: "Attached map." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaGeo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Attached map. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|GeoPoint| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaGeo = ['_' => 'messageMediaGeo', 'geo' => GeoPoint]; +``` diff --git a/docs/API_docs/constructors/messageMediaGeoLive.md b/docs/API_docs/constructors/messageMediaGeoLive.md new file mode 100644 index 0000000000..d8c5868f7e --- /dev/null +++ b/docs/API_docs/constructors/messageMediaGeoLive.md @@ -0,0 +1,32 @@ +--- +title: "messageMediaGeoLive" +description: "Indicates a live geolocation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaGeoLive +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a [live geolocation](https://core.telegram.org/api/live-location) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Geolocation| +|heading|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a direction in which the location moves, in degrees; 1-360| +|period|[int](/API_docs/types/int.html) | Yes|Validity period of provided geolocation| +|proximity\_notification\_radius|[int](/API_docs/types/int.html) | Optional|For [live locations](https://core.telegram.org/api/live-location), a maximum distance to another chat member for proximity alerts, in meters (0-100000).| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaGeoLive = ['_' => 'messageMediaGeoLive', 'geo' => GeoPoint, 'heading' => int, 'period' => int, 'proximity_notification_radius' => int]; +``` diff --git a/docs/API_docs/constructors/messageMediaGiveaway.md b/docs/API_docs/constructors/messageMediaGiveaway.md new file mode 100644 index 0000000000..0e2c973e57 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaGiveaway.md @@ -0,0 +1,36 @@ +--- +title: "messageMediaGiveaway" +description: "Contains info about a giveaway, see here » for more info." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaGiveaway +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a [giveaway, see here »](https://core.telegram.org/api/giveaways) for more info. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|only\_new\_subscribers|[Bool](/API_docs/types/Bool.html) | Optional|If set, only new subscribers starting from the giveaway creation date will be able to participate to the giveaway.| +|winners\_are\_visible|[Bool](/API_docs/types/Bool.html) | Optional|If set, giveaway winners are public and will be listed in a [messageMediaGiveawayResults](../constructors/messageMediaGiveawayResults.html) message that will be automatically sent to the channel once the giveaway ends.| +|channels|Array of [long](/API_docs/types/long.html) | Yes|The channels that the user must join to participate in the giveaway.| +|countries\_iso2|Array of [string](/API_docs/types/string.html) | Optional|If set, only users residing in these countries can participate in the giveaway, (specified as a list of two-letter ISO 3166-1 alpha-2 country codes); otherwise there are no country-based limitations.| +|prize\_description|[string](/API_docs/types/string.html) | Optional|Can contain a textual description of additional giveaway prizes.| +|quantity|[int](/API_docs/types/int.html) | Yes|Number of [Telegram Premium](https://core.telegram.org/api/premium) subscriptions given away.| +|months|[int](/API_docs/types/int.html) | Yes|Duration in months of each [Telegram Premium](https://core.telegram.org/api/premium) subscription in the giveaway.| +|until\_date|[int](/API_docs/types/int.html) | Yes|The end date of the giveaway.| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaGiveaway = ['_' => 'messageMediaGiveaway', 'only_new_subscribers' => Bool, 'winners_are_visible' => Bool, 'channels' => [long, long], 'countries_iso2' => ['string', 'string'], 'prize_description' => 'string', 'quantity' => int, 'months' => int, 'until_date' => int]; +``` diff --git a/docs/API_docs/constructors/messageMediaGiveawayResults.md b/docs/API_docs/constructors/messageMediaGiveawayResults.md new file mode 100644 index 0000000000..945e494b98 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaGiveawayResults.md @@ -0,0 +1,39 @@ +--- +title: "messageMediaGiveawayResults" +description: "A giveaway with public winners has finished, this constructor contains info about the winners." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaGiveawayResults +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [giveaway](https://core.telegram.org/api/giveaways) with public winners has finished, this constructor contains info about the winners. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|only\_new\_subscribers|[Bool](/API_docs/types/Bool.html) | Optional|If set, only new subscribers starting from the giveaway creation date participated in the giveaway.| +|refunded|[Bool](/API_docs/types/Bool.html) | Optional|If set, the giveaway was canceled and was fully refunded.| +|channel\_id|[long](/API_docs/types/long.html) | Yes|ID of the channel that was automatically [boosted](https://core.telegram.org/api/boost) by the winners of the giveaway for duration of the Premium subscription.| +|additional\_peers\_count|[int](/API_docs/types/int.html) | Optional|Number of other channels that participated in the giveaway.| +|launch\_msg\_id|[int](/API_docs/types/int.html) | Yes|Identifier of the message with the giveaway in `channel_id`.| +|winners\_count|[int](/API_docs/types/int.html) | Yes|Total number of winners in the giveaway.| +|unclaimed\_count|[int](/API_docs/types/int.html) | Yes|Number of not-yet-claimed prizes.| +|winners|Array of [long](/API_docs/types/long.html) | Yes|Up to 100 user identifiers of the winners of the giveaway.| +|months|[int](/API_docs/types/int.html) | Yes|Duration in months of each [Telegram Premium](https://core.telegram.org/api/premium) subscription in the giveaway.| +|prize\_description|[string](/API_docs/types/string.html) | Optional|Can contain a textual description of additional giveaway prizes.| +|until\_date|[int](/API_docs/types/int.html) | Yes|Point in time (Unix timestamp) when the winners were selected. May be bigger than winners selection date specified in initial parameters of the giveaway.| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaGiveawayResults = ['_' => 'messageMediaGiveawayResults', 'only_new_subscribers' => Bool, 'refunded' => Bool, 'channel_id' => long, 'additional_peers_count' => int, 'launch_msg_id' => int, 'winners_count' => int, 'unclaimed_count' => int, 'winners' => [long, long], 'months' => int, 'prize_description' => 'string', 'until_date' => int]; +``` diff --git a/docs/API_docs/constructors/messageMediaInvoice.md b/docs/API_docs/constructors/messageMediaInvoice.md new file mode 100644 index 0000000000..982732b2c4 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaInvoice.md @@ -0,0 +1,38 @@ +--- +title: "messageMediaInvoice" +description: "Invoice" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaInvoice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Invoice + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|shipping\_address\_requested|[Bool](/API_docs/types/Bool.html) | Optional|Whether the shipping address was requested| +|test|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is an example invoice| +|title|[string](/API_docs/types/string.html) | Yes|Product name, 1-32 characters| +|description|[string](/API_docs/types/string.html) | Yes|Product description, 1-255 characters| +|photo|[WebDocument](/API_docs/types/WebDocument.html) | Optional|URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service. People like it better when they see what they are paying for.| +|receipt\_msg\_id|[int](/API_docs/types/int.html) | Optional|Message ID of receipt: if set, clients should change the text of the first [keyboardButtonBuy](../constructors/keyboardButtonBuy.html) button always attached to the [message](../constructors/message.html) to a localized version of the word `Receipt`| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|total\_amount|[long](/API_docs/types/long.html) | Yes|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|start\_param|[string](/API_docs/types/string.html) | Yes|Unique bot deep-linking parameter that can be used to generate this invoice| +|extended\_media|[MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html) | Optional|Extended media| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaInvoice = ['_' => 'messageMediaInvoice', 'shipping_address_requested' => Bool, 'test' => Bool, 'title' => 'string', 'description' => 'string', 'photo' => WebDocument, 'receipt_msg_id' => int, 'currency' => 'string', 'total_amount' => long, 'start_param' => 'string', 'extended_media' => MessageExtendedMedia]; +``` diff --git a/docs/API_docs/constructors/messageMediaPhoto.md b/docs/API_docs/constructors/messageMediaPhoto.md new file mode 100644 index 0000000000..5a1c3fc69f --- /dev/null +++ b/docs/API_docs/constructors/messageMediaPhoto.md @@ -0,0 +1,31 @@ +--- +title: "messageMediaPhoto" +description: "Attached photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Attached photo. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|spoiler|[Bool](/API_docs/types/Bool.html) | Optional|Whether this media should be hidden behind a spoiler warning| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|Photo| +|ttl\_seconds|[int](/API_docs/types/int.html) | Optional|Time to live in seconds of self-destructing photo| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaPhoto = ['_' => 'messageMediaPhoto', 'spoiler' => Bool, 'photo' => Photo, 'ttl_seconds' => int]; +``` diff --git a/docs/API_docs/constructors/messageMediaPoll.md b/docs/API_docs/constructors/messageMediaPoll.md new file mode 100644 index 0000000000..719b86fe44 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaPoll.md @@ -0,0 +1,30 @@ +--- +title: "messageMediaPoll" +description: "Poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaPoll +[Back to constructors index](/API_docs/constructors/index.html) + + + +Poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|poll|[Poll](/API_docs/types/Poll.html) | Yes|The poll| +|results|[PollResults](/API_docs/types/PollResults.html) | Yes|The results of the poll| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaPoll = ['_' => 'messageMediaPoll', 'poll' => Poll, 'results' => PollResults]; +``` diff --git a/docs/API_docs/constructors/messageMediaStory.md b/docs/API_docs/constructors/messageMediaStory.md new file mode 100644 index 0000000000..891ba82837 --- /dev/null +++ b/docs/API_docs/constructors/messageMediaStory.md @@ -0,0 +1,32 @@ +--- +title: "messageMediaStory" +description: "Represents a forwarded story or a story mention." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a forwarded [story](https://core.telegram.org/api/stories) or a story mention. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|via\_mention|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates that this someone has mentioned us in this story (i.e. by tagging us in the description) or vice versa, we have mentioned the other peer (if the message is outgoing).| +|peer|[long](/API_docs/types/long.html) | Yes|Peer that posted the story.| +|id|[int](/API_docs/types/int.html) | Yes|Story ID| +|story|[StoryItem](/API_docs/types/StoryItem.html) | Optional|The story itself, if absent fetch it using [stories.getStoriesByID](../methods/stories.getStoriesByID.html) and the `peer`/`id` parameters specified above.| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaStory = ['_' => 'messageMediaStory', 'via_mention' => Bool, 'peer' => long, 'id' => int, 'story' => StoryItem]; +``` diff --git a/docs/API_docs/constructors/messageMediaUnsupported.md b/docs/API_docs/constructors/messageMediaUnsupported.md new file mode 100644 index 0000000000..8da4f1464d --- /dev/null +++ b/docs/API_docs/constructors/messageMediaUnsupported.md @@ -0,0 +1,24 @@ +--- +title: "messageMediaUnsupported" +description: "Current version of the client does not support this media type." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaUnsupported +[Back to constructors index](/API_docs/constructors/index.html) + + + +Current version of the client does not support this media type. + + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaUnsupported = ['_' => 'messageMediaUnsupported']; +``` diff --git a/docs/API_docs/constructors/messageMediaVenue.md b/docs/API_docs/constructors/messageMediaVenue.md new file mode 100644 index 0000000000..7a19576bfd --- /dev/null +++ b/docs/API_docs/constructors/messageMediaVenue.md @@ -0,0 +1,34 @@ +--- +title: "messageMediaVenue" +description: "Venue" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaVenue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Venue + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Geolocation of venue| +|title|[string](/API_docs/types/string.html) | Yes|Venue name| +|address|[string](/API_docs/types/string.html) | Yes|Address| +|provider|[string](/API_docs/types/string.html) | Yes|Venue provider: currently only "foursquare" and "gplaces" (Google Places) need to be supported| +|venue\_id|[string](/API_docs/types/string.html) | Yes|Venue ID in the provider's database| +|venue\_type|[string](/API_docs/types/string.html) | Yes|Venue type in the provider's database| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaVenue = ['_' => 'messageMediaVenue', 'geo' => GeoPoint, 'title' => 'string', 'address' => 'string', 'provider' => 'string', 'venue_id' => 'string', 'venue_type' => 'string']; +``` diff --git a/docs/API_docs/constructors/messageMediaWebPage.md b/docs/API_docs/constructors/messageMediaWebPage.md new file mode 100644 index 0000000000..6501c523ad --- /dev/null +++ b/docs/API_docs/constructors/messageMediaWebPage.md @@ -0,0 +1,33 @@ +--- +title: "messageMediaWebPage" +description: "Preview of webpage" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageMediaWebPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Preview of webpage + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|force\_large\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a large media preview should be used.| +|force\_small\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, specifies that a small media preview should be used.| +|manual|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates that the URL used for the webpage preview was specified manually using [inputMediaWebPage](../constructors/inputMediaWebPage.html), and may not be related to any of the URLs specified in the message.| +|safe|[Bool](/API_docs/types/Bool.html) | Optional|If set, the webpage can be opened directly without user confirmation; otherwise, user confirmation is required, showing the exact URL that will be opened.| +|webpage|[WebPage](/API_docs/types/WebPage.html) | Optional|Webpage preview| + + + +### Type: [MessageMedia](/API_docs/types/MessageMedia.html) + + +### Example: + +``` +$messageMediaWebPage = ['_' => 'messageMediaWebPage', 'force_large_media' => Bool, 'force_small_media' => Bool, 'manual' => Bool, 'safe' => Bool, 'webpage' => WebPage]; +``` diff --git a/docs/API_docs/constructors/messagePeerReaction.md b/docs/API_docs/constructors/messagePeerReaction.md new file mode 100644 index 0000000000..d2beca765b --- /dev/null +++ b/docs/API_docs/constructors/messagePeerReaction.md @@ -0,0 +1,34 @@ +--- +title: "messagePeerReaction" +description: "How a certain peer reacted to the message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messagePeerReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +How a certain peer reacted to the message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|big|[Bool](/API_docs/types/Bool.html) | Optional|Whether the specified [message reaction »](https://core.telegram.org/api/reactions) should elicit a bigger and longer reaction| +|unread|[Bool](/API_docs/types/Bool.html) | Optional|Whether the reaction wasn't yet marked as read by the current user| +|my|[Bool](/API_docs/types/Bool.html) | Optional|Starting from layer 159, [messages.sendReaction](../methods/messages.sendReaction.html) will send reactions from the peer (user or channel) specified using [messages.saveDefaultSendAs](../methods/messages.saveDefaultSendAs.html).
If set, this flag indicates that this reaction was sent by us, even if the `peer` doesn't point to the current account.| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|Peer that reacted to the message| +|date|[int](/API_docs/types/int.html) | Yes|When was this reaction added| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|Reaction emoji| + + + +### Type: [MessagePeerReaction](/API_docs/types/MessagePeerReaction.html) + + +### Example: + +``` +$messagePeerReaction = ['_' => 'messagePeerReaction', 'big' => Bool, 'unread' => Bool, 'my' => Bool, 'peer_id' => Peer, 'date' => int, 'reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/messagePeerVote.md b/docs/API_docs/constructors/messagePeerVote.md new file mode 100644 index 0000000000..7bd7a5e3c9 --- /dev/null +++ b/docs/API_docs/constructors/messagePeerVote.md @@ -0,0 +1,31 @@ +--- +title: "messagePeerVote" +description: "How a peer voted in a poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messagePeerVote +[Back to constructors index](/API_docs/constructors/index.html) + + + +How a peer voted in a poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer ID| +|option|[bytes](/API_docs/types/bytes.html) | Yes|The option chosen by the peer| +|date|[int](/API_docs/types/int.html) | Yes|When did the peer cast the vote| + + + +### Type: [MessagePeerVote](/API_docs/types/MessagePeerVote.html) + + +### Example: + +``` +$messagePeerVote = ['_' => 'messagePeerVote', 'peer' => long, 'option' => 'bytes', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/messagePeerVoteInputOption.md b/docs/API_docs/constructors/messagePeerVoteInputOption.md new file mode 100644 index 0000000000..3dbb321252 --- /dev/null +++ b/docs/API_docs/constructors/messagePeerVoteInputOption.md @@ -0,0 +1,30 @@ +--- +title: "messagePeerVoteInputOption" +description: "How a peer voted in a poll (reduced constructor, returned if an option was provided to messages.getPollVotes)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messagePeerVoteInputOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +How a peer voted in a poll (reduced constructor, returned if an `option` was provided to [messages.getPollVotes](../methods/messages.getPollVotes.html)) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer that voted for the queried `option`| +|date|[int](/API_docs/types/int.html) | Yes|When did the peer cast the vote| + + + +### Type: [MessagePeerVote](/API_docs/types/MessagePeerVote.html) + + +### Example: + +``` +$messagePeerVoteInputOption = ['_' => 'messagePeerVoteInputOption', 'peer' => long, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/messagePeerVoteMultiple.md b/docs/API_docs/constructors/messagePeerVoteMultiple.md new file mode 100644 index 0000000000..0191971066 --- /dev/null +++ b/docs/API_docs/constructors/messagePeerVoteMultiple.md @@ -0,0 +1,31 @@ +--- +title: "messagePeerVoteMultiple" +description: "How a peer voted in a multiple-choice poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messagePeerVoteMultiple +[Back to constructors index](/API_docs/constructors/index.html) + + + +How a peer voted in a multiple-choice poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer ID| +|options|Array of [bytes](/API_docs/types/bytes.html) | Yes|Options chosen by the peer| +|date|[int](/API_docs/types/int.html) | Yes|When did the peer cast their votes| + + + +### Type: [MessagePeerVote](/API_docs/types/MessagePeerVote.html) + + +### Example: + +``` +$messagePeerVoteMultiple = ['_' => 'messagePeerVoteMultiple', 'peer' => long, 'options' => ['bytes', 'bytes'], 'date' => int]; +``` diff --git a/docs/API_docs/constructors/messageRange.md b/docs/API_docs/constructors/messageRange.md new file mode 100644 index 0000000000..1d98cf44a9 --- /dev/null +++ b/docs/API_docs/constructors/messageRange.md @@ -0,0 +1,30 @@ +--- +title: "messageRange" +description: "Indicates a range of chat messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageRange +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a range of chat messages + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|min\_id|[int](/API_docs/types/int.html) | Yes|Start of range (message ID)| +|max\_id|[int](/API_docs/types/int.html) | Yes|End of range (message ID)| + + + +### Type: [MessageRange](/API_docs/types/MessageRange.html) + + +### Example: + +``` +$messageRange = ['_' => 'messageRange', 'min_id' => int, 'max_id' => int]; +``` diff --git a/docs/API_docs/constructors/messageReactions.md b/docs/API_docs/constructors/messageReactions.md new file mode 100644 index 0000000000..3b6f835b1f --- /dev/null +++ b/docs/API_docs/constructors/messageReactions.md @@ -0,0 +1,33 @@ +--- +title: "messageReactions" +description: "Message reactions »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageReactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Message reactions »](https://core.telegram.org/api/reactions) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|min|[Bool](/API_docs/types/Bool.html) | Optional|Similar to [min](https://core.telegram.org/api/min) objects, used for [message reaction »](https://core.telegram.org/api/reactions) constructors that are the same for all users so they don't have the reactions sent by the current user (you can use [messages.getMessagesReactions](../methods/messages.getMessagesReactions.html) to get the full reaction info).| +|can\_see\_list|[Bool](/API_docs/types/Bool.html) | Optional|Whether [messages.getMessageReactionsList](../methods/messages.getMessageReactionsList.html) can be used to see how each specific peer reacted to the message| +|reactions\_as\_tags|[Bool](/API_docs/types/Bool.html) | Optional| +|results|Array of [ReactionCount](/API_docs/types/ReactionCount.html) | Yes|Reactions| +|recent\_reactions|Array of [MessagePeerReaction](/API_docs/types/MessagePeerReaction.html) | Optional|List of recent peers and their reactions| + + + +### Type: [MessageReactions](/API_docs/types/MessageReactions.html) + + +### Example: + +``` +$messageReactions = ['_' => 'messageReactions', 'min' => Bool, 'can_see_list' => Bool, 'reactions_as_tags' => Bool, 'results' => [ReactionCount, ReactionCount], 'recent_reactions' => [MessagePeerReaction, MessagePeerReaction]]; +``` diff --git a/docs/API_docs/constructors/messageReplies.md b/docs/API_docs/constructors/messageReplies.md new file mode 100644 index 0000000000..ef6058ea9f --- /dev/null +++ b/docs/API_docs/constructors/messageReplies.md @@ -0,0 +1,35 @@ +--- +title: "messageReplies" +description: "Info about the comment section of a channel post, or a simple message thread" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageReplies +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about [the comment section of a channel post, or a simple message thread](https://core.telegram.org/api/threads) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|comments|[Bool](/API_docs/types/Bool.html) | Optional|Whether this constructor contains information about the [comment section of a channel post, or a simple message thread](https://core.telegram.org/api/threads)| +|replies|[int](/API_docs/types/int.html) | Yes|Contains the total number of replies in this thread or comment section.| +|replies\_pts|[int](/API_docs/types/int.html) | Yes|[PTS](https://core.telegram.org/api/updates) of the message that started this thread.| +|recent\_repliers|Array of [Peer](/API_docs/types/Peer.html) | Optional|For channel post comments, contains information about the last few comment posters for a specific thread, to show a small list of commenter profile pictures in client previews.| +|channel\_id|[long](/API_docs/types/long.html) | Optional|For channel post comments, contains the ID of the associated [discussion supergroup](https://core.telegram.org/api/discussion)| +|max\_id|[int](/API_docs/types/int.html) | Optional|ID of the latest message in this thread or comment section.| +|read\_max\_id|[int](/API_docs/types/int.html) | Optional|Contains the ID of the latest read message in this thread or comment section.| + + + +### Type: [MessageReplies](/API_docs/types/MessageReplies.html) + + +### Example: + +``` +$messageReplies = ['_' => 'messageReplies', 'comments' => Bool, 'replies' => int, 'replies_pts' => int, 'recent_repliers' => [Peer, Peer], 'channel_id' => long, 'max_id' => int, 'read_max_id' => int]; +``` diff --git a/docs/API_docs/constructors/messageReplyHeader.md b/docs/API_docs/constructors/messageReplyHeader.md new file mode 100644 index 0000000000..f3767076ae --- /dev/null +++ b/docs/API_docs/constructors/messageReplyHeader.md @@ -0,0 +1,39 @@ +--- +title: "messageReplyHeader" +description: "Message replies and thread information" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageReplyHeader +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message replies and [thread](https://core.telegram.org/api/threads) information + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|reply\_to\_scheduled|[Bool](/API_docs/types/Bool.html) | Optional|This is a reply to a scheduled message.| +|forum\_topic|[Bool](/API_docs/types/Bool.html) | Optional|Whether this message was sent in a [forum topic](https://core.telegram.org/api/forum#forum-topics) (except for the General topic).| +|quote|[Bool](/API_docs/types/Bool.html) | Optional|Whether this message is quoting a part of another message.| +|reply\_to\_msg\_id|[int](/API_docs/types/int.html) | Optional|ID of message to which this message is replying| +|reply\_to\_peer\_id|[Peer](/API_docs/types/Peer.html) | Optional|For replies sent in [channel discussion threads](https://core.telegram.org/api/threads) of which the current user is not a member, the discussion group ID| +|reply\_from|[MessageFwdHeader](/API_docs/types/MessageFwdHeader.html) | Optional|When replying to a message sent by a certain peer to another chat, contains info about the peer that originally sent the message to that other chat.| +|reply\_media|[MessageMedia](/API_docs/types/MessageMedia.html) | Optional|When replying to a media sent by a certain peer to another chat, contains the media of the replied-to message.| +|reply\_to\_top\_id|[int](/API_docs/types/int.html) | Optional|ID of the message that started this [message thread](https://core.telegram.org/api/threads)| +|quote\_text|[string](/API_docs/types/string.html) | Optional|Used to quote-reply to only a certain section (specified here) of the original message.| +|quote\_entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities) from the `quote_text` field.| +|quote\_offset|[int](/API_docs/types/int.html) | Optional|Offset of the message `quote_text` within the original message (in [UTF-16 code units](https://core.telegram.org/api/entities#entity-length)).| + + + +### Type: [MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) + + +### Example: + +``` +$messageReplyHeader = ['_' => 'messageReplyHeader', 'reply_to_scheduled' => Bool, 'forum_topic' => Bool, 'quote' => Bool, 'reply_to_msg_id' => int, 'reply_to_peer_id' => Peer, 'reply_from' => MessageFwdHeader, 'reply_media' => MessageMedia, 'reply_to_top_id' => int, 'quote_text' => 'string', 'quote_entities' => [MessageEntity, MessageEntity], 'quote_offset' => int]; +``` diff --git a/docs/API_docs/constructors/messageReplyStoryHeader.md b/docs/API_docs/constructors/messageReplyStoryHeader.md new file mode 100644 index 0000000000..afa17f5792 --- /dev/null +++ b/docs/API_docs/constructors/messageReplyStoryHeader.md @@ -0,0 +1,30 @@ +--- +title: "messageReplyStoryHeader" +description: "Represents a reply to a story" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageReplyStoryHeader +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a reply to a [story](https://core.telegram.org/api/stories) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes| +|story\_id|[int](/API_docs/types/int.html) | Yes|Story ID| + + + +### Type: [MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) + + +### Example: + +``` +$messageReplyStoryHeader = ['_' => 'messageReplyStoryHeader', 'peer' => long, 'story_id' => int]; +``` diff --git a/docs/API_docs/constructors/messageService.md b/docs/API_docs/constructors/messageService.md new file mode 100644 index 0000000000..f4ab80e58b --- /dev/null +++ b/docs/API_docs/constructors/messageService.md @@ -0,0 +1,41 @@ +--- +title: "messageService" +description: "Indicates a service message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageService +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a service message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|out|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message is outgoing| +|mentioned|[Bool](/API_docs/types/Bool.html) | Optional|Whether we were mentioned in the message| +|media\_unread|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message contains unread media| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message is silent| +|post|[Bool](/API_docs/types/Bool.html) | Optional|Whether it's a channel post| +|legacy|[Bool](/API_docs/types/Bool.html) | Optional|This is a legacy message: it has to be refetched with the new layer| +|id|[int](/API_docs/types/int.html) | Yes|Message ID| +|from\_id|[Peer](/API_docs/types/Peer.html) | Optional|ID of the sender of this message| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|Sender of service message| +|reply\_to|[MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) | Optional|Reply (thread) information| +|date|[int](/API_docs/types/int.html) | Yes|Message date| +|action|[MessageAction](/API_docs/types/MessageAction.html) | Optional|Event connected with the service message| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time To Live of the message, once message.date+message.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well.| + + + +### Type: [Message](/API_docs/types/Message.html) + + +### Example: + +``` +$messageService = ['_' => 'messageService', 'out' => Bool, 'mentioned' => Bool, 'media_unread' => Bool, 'silent' => Bool, 'post' => Bool, 'legacy' => Bool, 'id' => int, 'from_id' => Peer, 'peer_id' => Peer, 'reply_to' => MessageReplyHeader, 'date' => int, 'action' => MessageAction, 'ttl_period' => int]; +``` diff --git a/docs/API_docs/constructors/messageViews.md b/docs/API_docs/constructors/messageViews.md new file mode 100644 index 0000000000..79273dab2e --- /dev/null +++ b/docs/API_docs/constructors/messageViews.md @@ -0,0 +1,31 @@ +--- +title: "messageViews" +description: "View, forward counter + info about replies of a specific message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: messageViews +[Back to constructors index](/API_docs/constructors/index.html) + + + +View, forward counter + info about replies of a specific message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|views|[int](/API_docs/types/int.html) | Optional|View count of message| +|forwards|[int](/API_docs/types/int.html) | Optional|Forward count of message| +|replies|[MessageReplies](/API_docs/types/MessageReplies.html) | Optional|Reply and [thread](https://core.telegram.org/api/threads) information of message| + + + +### Type: [MessageViews](/API_docs/types/MessageViews.html) + + +### Example: + +``` +$messageViews = ['_' => 'messageViews', 'views' => int, 'forwards' => int, 'replies' => MessageReplies]; +``` diff --git a/docs/API_docs/constructors/messages.affectedFoundMessages.md b/docs/API_docs/constructors/messages.affectedFoundMessages.md new file mode 100644 index 0000000000..85ef437758 --- /dev/null +++ b/docs/API_docs/constructors/messages.affectedFoundMessages.md @@ -0,0 +1,33 @@ +--- +title: "messages.affectedFoundMessages" +description: "Messages found and affected by changes" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_affectedFoundMessages.html +--- +# Constructor: messages.affectedFoundMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Messages found and affected by changes + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| +|offset|[int](/API_docs/types/int.html) | Yes|If bigger than zero, the request must be repeated to remove more messages| +|messages|Array of [int](/API_docs/types/int.html) | Yes|Affected message IDs| + + + +### Type: [messages.AffectedFoundMessages](/API_docs/types/messages.AffectedFoundMessages.html) + + +### Example: + +``` +$messages_affectedFoundMessages = ['_' => 'messages.affectedFoundMessages', 'pts' => int, 'pts_count' => int, 'offset' => int, 'messages' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/messages.affectedHistory.md b/docs/API_docs/constructors/messages.affectedHistory.md new file mode 100644 index 0000000000..58207638b5 --- /dev/null +++ b/docs/API_docs/constructors/messages.affectedHistory.md @@ -0,0 +1,32 @@ +--- +title: "messages.affectedHistory" +description: "Affected part of communication history with the user or in a chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_affectedHistory.html +--- +# Constructor: messages.affectedHistory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Affected part of communication history with the user or in a chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pts|[int](/API_docs/types/int.html) | Yes|Number of events occurred in a text box| +|pts\_count|[int](/API_docs/types/int.html) | Yes|Number of affected events| +|offset|[int](/API_docs/types/int.html) | Yes|If a parameter contains positive value, it is necessary to repeat the method call using the given value; during the proceeding of all the history the value itself shall gradually decrease| + + + +### Type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + + +### Example: + +``` +$messages_affectedHistory = ['_' => 'messages.affectedHistory', 'pts' => int, 'pts_count' => int, 'offset' => int]; +``` diff --git a/docs/API_docs/constructors/messages.affectedMessages.md b/docs/API_docs/constructors/messages.affectedMessages.md new file mode 100644 index 0000000000..16bda3b883 --- /dev/null +++ b/docs/API_docs/constructors/messages.affectedMessages.md @@ -0,0 +1,31 @@ +--- +title: "messages.affectedMessages" +description: "Events affected by operation" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_affectedMessages.html +--- +# Constructor: messages.affectedMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Events affected by operation + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + + +### Example: + +``` +$messages_affectedMessages = ['_' => 'messages.affectedMessages', 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/messages.allStickers.md b/docs/API_docs/constructors/messages.allStickers.md new file mode 100644 index 0000000000..b052ac3835 --- /dev/null +++ b/docs/API_docs/constructors/messages.allStickers.md @@ -0,0 +1,31 @@ +--- +title: "messages.allStickers" +description: "Info about all installed stickers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_allStickers.html +--- +# Constructor: messages.allStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about all installed stickers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|sets|Array of [StickerSet](/API_docs/types/StickerSet.html) | Yes|All stickersets| + + + +### Type: [messages.AllStickers](/API_docs/types/messages.AllStickers.html) + + +### Example: + +``` +$messages_allStickers = ['_' => 'messages.allStickers', 'hash' => long, 'sets' => [StickerSet, StickerSet]]; +``` diff --git a/docs/API_docs/constructors/messages.allStickersNotModified.md b/docs/API_docs/constructors/messages.allStickersNotModified.md new file mode 100644 index 0000000000..9a456b062e --- /dev/null +++ b/docs/API_docs/constructors/messages.allStickersNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.allStickersNotModified" +description: "Info about all installed stickers hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_allStickersNotModified.html +--- +# Constructor: messages.allStickersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about all installed stickers hasn't changed + + + + +### Type: [messages.AllStickers](/API_docs/types/messages.AllStickers.html) + + +### Example: + +``` +$messages_allStickersNotModified = ['_' => 'messages.allStickersNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.archivedStickers.md b/docs/API_docs/constructors/messages.archivedStickers.md new file mode 100644 index 0000000000..e82ea65e16 --- /dev/null +++ b/docs/API_docs/constructors/messages.archivedStickers.md @@ -0,0 +1,31 @@ +--- +title: "messages.archivedStickers" +description: "Archived stickersets" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_archivedStickers.html +--- +# Constructor: messages.archivedStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Archived stickersets + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of archived stickers| +|sets|Array of [StickerSetCovered](/API_docs/types/StickerSetCovered.html) | Yes|Archived stickersets| + + + +### Type: [messages.ArchivedStickers](/API_docs/types/messages.ArchivedStickers.html) + + +### Example: + +``` +$messages_archivedStickers = ['_' => 'messages.archivedStickers', 'count' => int, 'sets' => [StickerSetCovered, StickerSetCovered]]; +``` diff --git a/docs/API_docs/constructors/messages.availableReactions.md b/docs/API_docs/constructors/messages.availableReactions.md new file mode 100644 index 0000000000..1b919a1b4f --- /dev/null +++ b/docs/API_docs/constructors/messages.availableReactions.md @@ -0,0 +1,31 @@ +--- +title: "messages.availableReactions" +description: "Animations and metadata associated with message reactions »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_availableReactions.html +--- +# Constructor: messages.availableReactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +Animations and metadata associated with [message reactions »](https://core.telegram.org/api/reactions) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[int](/API_docs/types/int.html) | Yes| +|reactions|Array of [AvailableReaction](/API_docs/types/AvailableReaction.html) | Yes|Animations and metadata associated with [message reactions »](https://core.telegram.org/api/reactions)| + + + +### Type: [messages.AvailableReactions](/API_docs/types/messages.AvailableReactions.html) + + +### Example: + +``` +$messages_availableReactions = ['_' => 'messages.availableReactions', 'hash' => int, 'reactions' => [AvailableReaction, AvailableReaction]]; +``` diff --git a/docs/API_docs/constructors/messages.availableReactionsNotModified.md b/docs/API_docs/constructors/messages.availableReactionsNotModified.md new file mode 100644 index 0000000000..2a618e4071 --- /dev/null +++ b/docs/API_docs/constructors/messages.availableReactionsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.availableReactionsNotModified" +description: "No new reactions are available" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_availableReactionsNotModified.html +--- +# Constructor: messages.availableReactionsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new reactions are available + + + + +### Type: [messages.AvailableReactions](/API_docs/types/messages.AvailableReactions.html) + + +### Example: + +``` +$messages_availableReactionsNotModified = ['_' => 'messages.availableReactionsNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.botApp.md b/docs/API_docs/constructors/messages.botApp.md new file mode 100644 index 0000000000..719218e864 --- /dev/null +++ b/docs/API_docs/constructors/messages.botApp.md @@ -0,0 +1,33 @@ +--- +title: "messages.botApp" +description: "Contains information about a direct link Mini App" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_botApp.html +--- +# Constructor: messages.botApp +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains information about a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inactive|[Bool](/API_docs/types/Bool.html) | Optional|Whether the web app was never used by the user, and confirmation must be asked from the user before opening it.| +|request\_write\_access|[Bool](/API_docs/types/Bool.html) | Optional|The bot is asking permission to send messages to the user: if the user agrees, set the `write_allowed` flag when invoking [messages.requestAppWebView](../methods/messages.requestAppWebView.html).| +|has\_settings|[Bool](/API_docs/types/Bool.html) | Optional|Deprecated flag, can be ignored.| +|app|[BotApp](/API_docs/types/BotApp.html) | Yes|Bot app information| + + + +### Type: [messages.BotApp](/API_docs/types/messages.BotApp.html) + + +### Example: + +``` +$messages_botApp = ['_' => 'messages.botApp', 'inactive' => Bool, 'request_write_access' => Bool, 'has_settings' => Bool, 'app' => BotApp]; +``` diff --git a/docs/API_docs/constructors/messages.botCallbackAnswer.md b/docs/API_docs/constructors/messages.botCallbackAnswer.md new file mode 100644 index 0000000000..38056e6a89 --- /dev/null +++ b/docs/API_docs/constructors/messages.botCallbackAnswer.md @@ -0,0 +1,35 @@ +--- +title: "messages.botCallbackAnswer" +description: "Callback answer sent by the bot in response to a button press" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_botCallbackAnswer.html +--- +# Constructor: messages.botCallbackAnswer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Callback answer sent by the bot in response to a button press + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|alert|[Bool](/API_docs/types/Bool.html) | Optional|Whether an alert should be shown to the user instead of a toast notification| +|has\_url|[Bool](/API_docs/types/Bool.html) | Optional|Whether an URL is present| +|native\_ui|[Bool](/API_docs/types/Bool.html) | Optional|Whether to show games in WebView or in native UI.| +|message|[string](/API_docs/types/string.html) | Optional|Alert to show| +|url|[string](/API_docs/types/string.html) | Optional|URL to open| +|cache\_time|[int](/API_docs/types/int.html) | Yes|For how long should this answer be cached| + + + +### Type: [messages.BotCallbackAnswer](/API_docs/types/messages.BotCallbackAnswer.html) + + +### Example: + +``` +$messages_botCallbackAnswer = ['_' => 'messages.botCallbackAnswer', 'alert' => Bool, 'has_url' => Bool, 'native_ui' => Bool, 'message' => 'string', 'url' => 'string', 'cache_time' => int]; +``` diff --git a/docs/API_docs/constructors/messages.botResults.md b/docs/API_docs/constructors/messages.botResults.md new file mode 100644 index 0000000000..dd0aea6f89 --- /dev/null +++ b/docs/API_docs/constructors/messages.botResults.md @@ -0,0 +1,37 @@ +--- +title: "messages.botResults" +description: "Result of a query to an inline bot" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_botResults.html +--- +# Constructor: messages.botResults +[Back to constructors index](/API_docs/constructors/index.html) + + + +Result of a query to an inline bot + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|gallery|[Bool](/API_docs/types/Bool.html) | Optional|Whether the result is a picture gallery| +|query\_id|[long](/API_docs/types/long.html) | Yes|Query ID| +|next\_offset|[string](/API_docs/types/string.html) | Optional|The next offset to use when navigating through results| +|switch\_pm|[InlineBotSwitchPM](/API_docs/types/InlineBotSwitchPM.html) | Optional|Shown as a button on top of the remaining inline result list; if clicked, redirects the user to a private chat with the bot with the specified start parameter.| +|switch\_webview|[InlineBotWebView](/API_docs/types/InlineBotWebView.html) | Optional|Shown as a button on top of the remaining inline result list; if clicked, opens the specified [inline mode mini app](https://core.telegram.org/api/bots/webapps#inline-mode-mini-apps).| +|results|Array of [BotInlineResult](/API_docs/types/BotInlineResult.html) | Yes|The results| +|cache\_time|[int](/API_docs/types/int.html) | Yes|Caching validity of the results| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the results| + + + +### Type: [messages.BotResults](/API_docs/types/messages.BotResults.html) + + +### Example: + +``` +$messages_botResults = ['_' => 'messages.botResults', 'gallery' => Bool, 'query_id' => long, 'next_offset' => 'string', 'switch_pm' => InlineBotSwitchPM, 'switch_webview' => InlineBotWebView, 'results' => [BotInlineResult, BotInlineResult], 'cache_time' => int, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.channelMessages.md b/docs/API_docs/constructors/messages.channelMessages.md new file mode 100644 index 0000000000..d5b7e20f6a --- /dev/null +++ b/docs/API_docs/constructors/messages.channelMessages.md @@ -0,0 +1,37 @@ +--- +title: "messages.channelMessages" +description: "Channel messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_channelMessages.html +--- +# Constructor: messages.channelMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel messages + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inexact|[Bool](/API_docs/types/Bool.html) | Optional|If set, returned results may be inexact| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|count|[int](/API_docs/types/int.html) | Yes|Total number of results were found server-side (may not be all included here)| +|offset\_id\_offset|[int](/API_docs/types/int.html) | Optional|Indicates the absolute position of `messages[0]` within the total result set with count `count`.
This is useful, for example, if the result was fetched using `offset_id`, and we need to display a `progress/total` counter (like `photo 134 of 200`, for all media in a chat, we could simply use `photo ${offset_id_offset} of ${count}`.| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|Found messages| +|topics|Array of [ForumTopic](/API_docs/types/ForumTopic.html) | Yes|[Forum topic](https://core.telegram.org/api/forum#forum-topics) information| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [messages.Messages](/API_docs/types/messages.Messages.html) + + +### Example: + +``` +$messages_channelMessages = ['_' => 'messages.channelMessages', 'inexact' => Bool, 'pts' => int, 'count' => int, 'offset_id_offset' => int, 'messages' => [Message, Message], 'topics' => [ForumTopic, ForumTopic], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.chatAdminsWithInvites.md b/docs/API_docs/constructors/messages.chatAdminsWithInvites.md new file mode 100644 index 0000000000..03d3efaebd --- /dev/null +++ b/docs/API_docs/constructors/messages.chatAdminsWithInvites.md @@ -0,0 +1,31 @@ +--- +title: "messages.chatAdminsWithInvites" +description: "Info about chat invites generated by admins." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_chatAdminsWithInvites.html +--- +# Constructor: messages.chatAdminsWithInvites +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about chat invites generated by admins. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|admins|Array of [ChatAdminWithInvites](/API_docs/types/ChatAdminWithInvites.html) | Yes|Info about chat invites generated by admins.| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.ChatAdminsWithInvites](/API_docs/types/messages.ChatAdminsWithInvites.html) + + +### Example: + +``` +$messages_chatAdminsWithInvites = ['_' => 'messages.chatAdminsWithInvites', 'admins' => [ChatAdminWithInvites, ChatAdminWithInvites], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.chatFull.md b/docs/API_docs/constructors/messages.chatFull.md new file mode 100644 index 0000000000..55f0e97486 --- /dev/null +++ b/docs/API_docs/constructors/messages.chatFull.md @@ -0,0 +1,32 @@ +--- +title: "messages.chatFull" +description: "Full info about a channel, supergroup, gigagroup or basic group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_chatFull.html +--- +# Constructor: messages.chatFull +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full info about a [channel](https://core.telegram.org/api/channel#channels), [supergroup](https://core.telegram.org/api/channel#supergroups), [gigagroup](https://core.telegram.org/api/channel#gigagroups) or [basic group](https://core.telegram.org/api/channel#basic-groups). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|full\_chat|[ChatFull](/API_docs/types/ChatFull.html) | Yes|Full info| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.ChatFull](/API_docs/types/messages.ChatFull.html) + + +### Example: + +``` +$messages_chatFull = ['_' => 'messages.chatFull', 'full_chat' => ChatFull, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.chatInviteImporters.md b/docs/API_docs/constructors/messages.chatInviteImporters.md new file mode 100644 index 0000000000..39310bb0d5 --- /dev/null +++ b/docs/API_docs/constructors/messages.chatInviteImporters.md @@ -0,0 +1,32 @@ +--- +title: "messages.chatInviteImporters" +description: "Info about the users that joined the chat using a specific chat invite" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_chatInviteImporters.html +--- +# Constructor: messages.chatInviteImporters +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about the users that joined the chat using a specific chat invite + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of users that joined| +|importers|Array of [ChatInviteImporter](/API_docs/types/ChatInviteImporter.html) | Yes|The users that joined| +|users|Array of [User](/API_docs/types/User.html) | Yes|The users that joined| + + + +### Type: [messages.ChatInviteImporters](/API_docs/types/messages.ChatInviteImporters.html) + + +### Example: + +``` +$messages_chatInviteImporters = ['_' => 'messages.chatInviteImporters', 'count' => int, 'importers' => [ChatInviteImporter, ChatInviteImporter], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.chats.md b/docs/API_docs/constructors/messages.chats.md new file mode 100644 index 0000000000..a70926a0f3 --- /dev/null +++ b/docs/API_docs/constructors/messages.chats.md @@ -0,0 +1,30 @@ +--- +title: "messages.chats" +description: "List of chats with auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_chats.html +--- +# Constructor: messages.chats +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of chats with auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats| + + + +### Type: [messages.Chats](/API_docs/types/messages.Chats.html) + + +### Example: + +``` +$messages_chats = ['_' => 'messages.chats', 'chats' => [Chat, Chat]]; +``` diff --git a/docs/API_docs/constructors/messages.chatsSlice.md b/docs/API_docs/constructors/messages.chatsSlice.md new file mode 100644 index 0000000000..c5783f6d14 --- /dev/null +++ b/docs/API_docs/constructors/messages.chatsSlice.md @@ -0,0 +1,31 @@ +--- +title: "messages.chatsSlice" +description: "Partial list of chats, more would have to be fetched with pagination" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_chatsSlice.html +--- +# Constructor: messages.chatsSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Partial list of chats, more would have to be fetched with [pagination](https://core.telegram.org/api/offsets) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of results that were found server-side (not all are included in `chats`)| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| + + + +### Type: [messages.Chats](/API_docs/types/messages.Chats.html) + + +### Example: + +``` +$messages_chatsSlice = ['_' => 'messages.chatsSlice', 'count' => int, 'chats' => [Chat, Chat]]; +``` diff --git a/docs/API_docs/constructors/messages.checkedHistoryImportPeer.md b/docs/API_docs/constructors/messages.checkedHistoryImportPeer.md new file mode 100644 index 0000000000..948c368b34 --- /dev/null +++ b/docs/API_docs/constructors/messages.checkedHistoryImportPeer.md @@ -0,0 +1,30 @@ +--- +title: "messages.checkedHistoryImportPeer" +description: "Contains a confirmation text to be shown to the user, upon importing chat history, click here for more info »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_checkedHistoryImportPeer.html +--- +# Constructor: messages.checkedHistoryImportPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains a confirmation text to be shown to the user, upon [importing chat history, click here for more info »](https://core.telegram.org/api/import). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|confirm\_text|[string](/API_docs/types/string.html) | Yes|A confirmation text to be shown to the user, upon [importing chat history »](https://core.telegram.org/api/import).| + + + +### Type: [messages.CheckedHistoryImportPeer](/API_docs/types/messages.CheckedHistoryImportPeer.html) + + +### Example: + +``` +$messages_checkedHistoryImportPeer = ['_' => 'messages.checkedHistoryImportPeer', 'confirm_text' => 'string']; +``` diff --git a/docs/API_docs/constructors/messages.dhConfig.md b/docs/API_docs/constructors/messages.dhConfig.md new file mode 100644 index 0000000000..421a7452e3 --- /dev/null +++ b/docs/API_docs/constructors/messages.dhConfig.md @@ -0,0 +1,33 @@ +--- +title: "messages.dhConfig" +description: "New set of configuring parameters." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_dhConfig.html +--- +# Constructor: messages.dhConfig +[Back to constructors index](/API_docs/constructors/index.html) + + + +New set of configuring parameters. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|g|[int](/API_docs/types/int.html) | Yes|New value **prime**, see [Wikipedia](https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange)| +|p|[bytes](/API_docs/types/bytes.html) | Yes|New value **primitive root**, see [Wikipedia](https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange)| +|version|[int](/API_docs/types/int.html) | Yes|Version of set of parameters| +|random|[bytes](/API_docs/types/bytes.html) | Yes|Random sequence of bytes of assigned length| + + + +### Type: [messages.DhConfig](/API_docs/types/messages.DhConfig.html) + + +### Example: + +``` +$messages_dhConfig = ['_' => 'messages.dhConfig', 'g' => int, 'p' => 'bytes', 'version' => int, 'random' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/messages.dhConfigNotModified.md b/docs/API_docs/constructors/messages.dhConfigNotModified.md new file mode 100644 index 0000000000..bad86de96b --- /dev/null +++ b/docs/API_docs/constructors/messages.dhConfigNotModified.md @@ -0,0 +1,30 @@ +--- +title: "messages.dhConfigNotModified" +description: "Configuring parameters did not change." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_dhConfigNotModified.html +--- +# Constructor: messages.dhConfigNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Configuring parameters did not change. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|random|[bytes](/API_docs/types/bytes.html) | Yes|Random sequence of bytes of assigned length| + + + +### Type: [messages.DhConfig](/API_docs/types/messages.DhConfig.html) + + +### Example: + +``` +$messages_dhConfigNotModified = ['_' => 'messages.dhConfigNotModified', 'random' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/messages.dialogFilters.md b/docs/API_docs/constructors/messages.dialogFilters.md new file mode 100644 index 0000000000..a4656f3578 --- /dev/null +++ b/docs/API_docs/constructors/messages.dialogFilters.md @@ -0,0 +1,29 @@ +--- +title: "messages.dialogFilters" +description: "messages.dialogFilters attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_dialogFilters.html +--- +# Constructor: messages.dialogFilters +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|tags\_enabled|[Bool](/API_docs/types/Bool.html) | Optional| +|filters|Array of [DialogFilter](/API_docs/types/DialogFilter.html) | Yes| + + + +### Type: [messages.DialogFilters](/API_docs/types/messages.DialogFilters.html) + + +### Example: + +``` +$messages_dialogFilters = ['_' => 'messages.dialogFilters', 'tags_enabled' => Bool, 'filters' => [DialogFilter, DialogFilter]]; +``` diff --git a/docs/API_docs/constructors/messages.dialogs.md b/docs/API_docs/constructors/messages.dialogs.md new file mode 100644 index 0000000000..6f2c576aca --- /dev/null +++ b/docs/API_docs/constructors/messages.dialogs.md @@ -0,0 +1,33 @@ +--- +title: "messages.dialogs" +description: "Full list of chats with messages and auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_dialogs.html +--- +# Constructor: messages.dialogs +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full list of chats with messages and auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dialogs|Array of [Dialog](/API_docs/types/Dialog.html) | Yes|List of chats| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of last messages from each chat| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of groups mentioned in the chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in messages and groups| + + + +### Type: [messages.Dialogs](/API_docs/types/messages.Dialogs.html) + + +### Example: + +``` +$messages_dialogs = ['_' => 'messages.dialogs', 'dialogs' => [Dialog, Dialog], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.dialogsNotModified.md b/docs/API_docs/constructors/messages.dialogsNotModified.md new file mode 100644 index 0000000000..8c57834078 --- /dev/null +++ b/docs/API_docs/constructors/messages.dialogsNotModified.md @@ -0,0 +1,30 @@ +--- +title: "messages.dialogsNotModified" +description: "Dialogs haven't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_dialogsNotModified.html +--- +# Constructor: messages.dialogsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Dialogs haven't changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of dialogs found server-side by the query| + + + +### Type: [messages.Dialogs](/API_docs/types/messages.Dialogs.html) + + +### Example: + +``` +$messages_dialogsNotModified = ['_' => 'messages.dialogsNotModified', 'count' => int]; +``` diff --git a/docs/API_docs/constructors/messages.dialogsSlice.md b/docs/API_docs/constructors/messages.dialogsSlice.md new file mode 100644 index 0000000000..372ad650a8 --- /dev/null +++ b/docs/API_docs/constructors/messages.dialogsSlice.md @@ -0,0 +1,34 @@ +--- +title: "messages.dialogsSlice" +description: "Incomplete list of dialogs with messages and auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_dialogsSlice.html +--- +# Constructor: messages.dialogsSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incomplete list of dialogs with messages and auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of dialogs| +|dialogs|Array of [Dialog](/API_docs/types/Dialog.html) | Yes|List of dialogs| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of last messages from dialogs| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in dialogs| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in messages and chats| + + + +### Type: [messages.Dialogs](/API_docs/types/messages.Dialogs.html) + + +### Example: + +``` +$messages_dialogsSlice = ['_' => 'messages.dialogsSlice', 'count' => int, 'dialogs' => [Dialog, Dialog], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.discussionMessage.md b/docs/API_docs/constructors/messages.discussionMessage.md new file mode 100644 index 0000000000..7092946445 --- /dev/null +++ b/docs/API_docs/constructors/messages.discussionMessage.md @@ -0,0 +1,36 @@ +--- +title: "messages.discussionMessage" +description: "Information about a message thread" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_discussionMessage.html +--- +# Constructor: messages.discussionMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about a [message thread](https://core.telegram.org/api/threads) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|The messages from which the thread starts. The messages are returned in reverse chronological order (i.e., in order of decreasing message ID).| +|max\_id|[int](/API_docs/types/int.html) | Optional|Message ID of latest reply in this [thread](https://core.telegram.org/api/threads)| +|read\_inbox\_max\_id|[int](/API_docs/types/int.html) | Optional|Message ID of latest read incoming message in this [thread](https://core.telegram.org/api/threads)| +|read\_outbox\_max\_id|[int](/API_docs/types/int.html) | Optional|Message ID of latest read outgoing message in this [thread](https://core.telegram.org/api/threads)| +|unread\_count|[int](/API_docs/types/int.html) | Yes|Number of unread messages| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in constructor| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in constructor| + + + +### Type: [messages.DiscussionMessage](/API_docs/types/messages.DiscussionMessage.html) + + +### Example: + +``` +$messages_discussionMessage = ['_' => 'messages.discussionMessage', 'messages' => [Message, Message], 'max_id' => int, 'read_inbox_max_id' => int, 'read_outbox_max_id' => int, 'unread_count' => int, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.emojiGroups.md b/docs/API_docs/constructors/messages.emojiGroups.md new file mode 100644 index 0000000000..c090ee0dc0 --- /dev/null +++ b/docs/API_docs/constructors/messages.emojiGroups.md @@ -0,0 +1,31 @@ +--- +title: "messages.emojiGroups" +description: "Represents a list of emoji categories." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_emojiGroups.html +--- +# Constructor: messages.emojiGroups +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[int](/API_docs/types/int.html) | Yes| +|groups|Array of [EmojiGroup](/API_docs/types/EmojiGroup.html) | Yes|A list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories).| + + + +### Type: [messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + + +### Example: + +``` +$messages_emojiGroups = ['_' => 'messages.emojiGroups', 'hash' => int, 'groups' => [EmojiGroup, EmojiGroup]]; +``` diff --git a/docs/API_docs/constructors/messages.emojiGroupsNotModified.md b/docs/API_docs/constructors/messages.emojiGroupsNotModified.md new file mode 100644 index 0000000000..8e4d6018d9 --- /dev/null +++ b/docs/API_docs/constructors/messages.emojiGroupsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.emojiGroupsNotModified" +description: "The list of emoji categories hasn't changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_emojiGroupsNotModified.html +--- +# Constructor: messages.emojiGroupsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories) hasn't changed. + + + + +### Type: [messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + + +### Example: + +``` +$messages_emojiGroupsNotModified = ['_' => 'messages.emojiGroupsNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.exportedChatInvite.md b/docs/API_docs/constructors/messages.exportedChatInvite.md new file mode 100644 index 0000000000..230d603821 --- /dev/null +++ b/docs/API_docs/constructors/messages.exportedChatInvite.md @@ -0,0 +1,31 @@ +--- +title: "messages.exportedChatInvite" +description: "Info about a chat invite" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_exportedChatInvite.html +--- +# Constructor: messages.exportedChatInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a chat invite + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|Info about the chat invite| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + + +### Example: + +``` +$messages_exportedChatInvite = ['_' => 'messages.exportedChatInvite', 'invite' => ExportedChatInvite, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.exportedChatInviteReplaced.md b/docs/API_docs/constructors/messages.exportedChatInviteReplaced.md new file mode 100644 index 0000000000..b063336056 --- /dev/null +++ b/docs/API_docs/constructors/messages.exportedChatInviteReplaced.md @@ -0,0 +1,32 @@ +--- +title: "messages.exportedChatInviteReplaced" +description: "The specified chat invite was replaced with another one" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_exportedChatInviteReplaced.html +--- +# Constructor: messages.exportedChatInviteReplaced +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified chat invite was replaced with another one + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|The replaced chat invite| +|new\_invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|The invite that replaces the previous invite| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + + +### Example: + +``` +$messages_exportedChatInviteReplaced = ['_' => 'messages.exportedChatInviteReplaced', 'invite' => ExportedChatInvite, 'new_invite' => ExportedChatInvite, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.exportedChatInvites.md b/docs/API_docs/constructors/messages.exportedChatInvites.md new file mode 100644 index 0000000000..b0f83130b3 --- /dev/null +++ b/docs/API_docs/constructors/messages.exportedChatInvites.md @@ -0,0 +1,32 @@ +--- +title: "messages.exportedChatInvites" +description: "Info about chat invites exported by a certain admin." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_exportedChatInvites.html +--- +# Constructor: messages.exportedChatInvites +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about chat invites exported by a certain admin. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of invites exported by the admin| +|invites|Array of [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|Exported invites| +|users|Array of [User](/API_docs/types/User.html) | Yes|Info about the admin| + + + +### Type: [messages.ExportedChatInvites](/API_docs/types/messages.ExportedChatInvites.html) + + +### Example: + +``` +$messages_exportedChatInvites = ['_' => 'messages.exportedChatInvites', 'count' => int, 'invites' => [ExportedChatInvite, ExportedChatInvite], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.favedStickers.md b/docs/API_docs/constructors/messages.favedStickers.md new file mode 100644 index 0000000000..619ea427d5 --- /dev/null +++ b/docs/API_docs/constructors/messages.favedStickers.md @@ -0,0 +1,32 @@ +--- +title: "messages.favedStickers" +description: "Favorited stickers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_favedStickers.html +--- +# Constructor: messages.favedStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Favorited stickers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|packs|Array of [StickerPack](/API_docs/types/StickerPack.html) | Yes|Emojis associated to stickers| +|stickers|Array of [Document](/API_docs/types/Document.html) | Yes|Favorited stickers| + + + +### Type: [messages.FavedStickers](/API_docs/types/messages.FavedStickers.html) + + +### Example: + +``` +$messages_favedStickers = ['_' => 'messages.favedStickers', 'hash' => long, 'packs' => [StickerPack, StickerPack], 'stickers' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/messages.favedStickersNotModified.md b/docs/API_docs/constructors/messages.favedStickersNotModified.md new file mode 100644 index 0000000000..3cd2481cbd --- /dev/null +++ b/docs/API_docs/constructors/messages.favedStickersNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.favedStickersNotModified" +description: "No new favorited stickers were found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_favedStickersNotModified.html +--- +# Constructor: messages.favedStickersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new favorited stickers were found + + + + +### Type: [messages.FavedStickers](/API_docs/types/messages.FavedStickers.html) + + +### Example: + +``` +$messages_favedStickersNotModified = ['_' => 'messages.favedStickersNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.featuredStickers.md b/docs/API_docs/constructors/messages.featuredStickers.md new file mode 100644 index 0000000000..64e9c09328 --- /dev/null +++ b/docs/API_docs/constructors/messages.featuredStickers.md @@ -0,0 +1,34 @@ +--- +title: "messages.featuredStickers" +description: "Featured stickersets" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_featuredStickers.html +--- +# Constructor: messages.featuredStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Featured stickersets + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|premium|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a premium stickerset| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|count|[int](/API_docs/types/int.html) | Yes|Total number of featured stickers| +|sets|Array of [StickerSetCovered](/API_docs/types/StickerSetCovered.html) | Yes|Featured stickersets| +|unread|Array of [long](/API_docs/types/long.html) | Yes|IDs of new featured stickersets| + + + +### Type: [messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + + +### Example: + +``` +$messages_featuredStickers = ['_' => 'messages.featuredStickers', 'premium' => Bool, 'hash' => long, 'count' => int, 'sets' => [StickerSetCovered, StickerSetCovered], 'unread' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/messages.featuredStickersNotModified.md b/docs/API_docs/constructors/messages.featuredStickersNotModified.md new file mode 100644 index 0000000000..27605b6e2f --- /dev/null +++ b/docs/API_docs/constructors/messages.featuredStickersNotModified.md @@ -0,0 +1,30 @@ +--- +title: "messages.featuredStickersNotModified" +description: "Featured stickers haven't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_featuredStickersNotModified.html +--- +# Constructor: messages.featuredStickersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +Featured stickers haven't changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of featured stickers| + + + +### Type: [messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + + +### Example: + +``` +$messages_featuredStickersNotModified = ['_' => 'messages.featuredStickersNotModified', 'count' => int]; +``` diff --git a/docs/API_docs/constructors/messages.forumTopics.md b/docs/API_docs/constructors/messages.forumTopics.md new file mode 100644 index 0000000000..7e4556ada4 --- /dev/null +++ b/docs/API_docs/constructors/messages.forumTopics.md @@ -0,0 +1,36 @@ +--- +title: "messages.forumTopics" +description: "Contains information about multiple forum topics" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_forumTopics.html +--- +# Constructor: messages.forumTopics +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains information about multiple [forum topics](https://core.telegram.org/api/forum#forum-topics) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|order\_by\_create\_date|[Bool](/API_docs/types/Bool.html) | Optional|Whether the returned topics are ordered by creation date; if set, pagination by `offset_date` should use [forumTopic](../constructors/forumTopic.html).`date`; otherwise topics are ordered by the last message date, so paginate by the `date` of the [message](../types/Message.html) referenced by [forumTopic](../constructors/forumTopic.html).`top_message`.| +|count|[int](/API_docs/types/int.html) | Yes|Total number of topics matching query; may be more than the topics contained in `topics`, in which case [pagination](https://core.telegram.org/api/offsets) is required.| +|topics|Array of [ForumTopic](/API_docs/types/ForumTopic.html) | Yes|Forum topics| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|Related messages (contains the messages mentioned by [forumTopic](../constructors/forumTopic.html).`top_message`).| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Related chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Related users| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| + + + +### Type: [messages.ForumTopics](/API_docs/types/messages.ForumTopics.html) + + +### Example: + +``` +$messages_forumTopics = ['_' => 'messages.forumTopics', 'order_by_create_date' => Bool, 'count' => int, 'topics' => [ForumTopic, ForumTopic], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User], 'pts' => int]; +``` diff --git a/docs/API_docs/constructors/messages.foundStickerSets.md b/docs/API_docs/constructors/messages.foundStickerSets.md new file mode 100644 index 0000000000..585f2ee535 --- /dev/null +++ b/docs/API_docs/constructors/messages.foundStickerSets.md @@ -0,0 +1,31 @@ +--- +title: "messages.foundStickerSets" +description: "Found stickersets" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_foundStickerSets.html +--- +# Constructor: messages.foundStickerSets +[Back to constructors index](/API_docs/constructors/index.html) + + + +Found stickersets + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|sets|Array of [StickerSetCovered](/API_docs/types/StickerSetCovered.html) | Yes|Found stickersets| + + + +### Type: [messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + + +### Example: + +``` +$messages_foundStickerSets = ['_' => 'messages.foundStickerSets', 'hash' => long, 'sets' => [StickerSetCovered, StickerSetCovered]]; +``` diff --git a/docs/API_docs/constructors/messages.foundStickerSetsNotModified.md b/docs/API_docs/constructors/messages.foundStickerSetsNotModified.md new file mode 100644 index 0000000000..93b3054ea8 --- /dev/null +++ b/docs/API_docs/constructors/messages.foundStickerSetsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.foundStickerSetsNotModified" +description: "No further results were found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_foundStickerSetsNotModified.html +--- +# Constructor: messages.foundStickerSetsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No further results were found + + + + +### Type: [messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + + +### Example: + +``` +$messages_foundStickerSetsNotModified = ['_' => 'messages.foundStickerSetsNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.highScores.md b/docs/API_docs/constructors/messages.highScores.md new file mode 100644 index 0000000000..9ab5029c03 --- /dev/null +++ b/docs/API_docs/constructors/messages.highScores.md @@ -0,0 +1,31 @@ +--- +title: "messages.highScores" +description: "Highscores in a game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_highScores.html +--- +# Constructor: messages.highScores +[Back to constructors index](/API_docs/constructors/index.html) + + + +Highscores in a game + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|scores|Array of [HighScore](/API_docs/types/HighScore.html) | Yes|Highscores| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users, associated to the highscores| + + + +### Type: [messages.HighScores](/API_docs/types/messages.HighScores.html) + + +### Example: + +``` +$messages_highScores = ['_' => 'messages.highScores', 'scores' => [HighScore, HighScore], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.historyImport.md b/docs/API_docs/constructors/messages.historyImport.md new file mode 100644 index 0000000000..20b892096c --- /dev/null +++ b/docs/API_docs/constructors/messages.historyImport.md @@ -0,0 +1,30 @@ +--- +title: "messages.historyImport" +description: "ID of a specific chat import session, click here for more info »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_historyImport.html +--- +# Constructor: messages.historyImport +[Back to constructors index](/API_docs/constructors/index.html) + + + +ID of a specific [chat import session, click here for more info »](https://core.telegram.org/api/import). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|[History import ID](https://core.telegram.org/api/import)| + + + +### Type: [messages.HistoryImport](/API_docs/types/messages.HistoryImport.html) + + +### Example: + +``` +$messages_historyImport = ['_' => 'messages.historyImport', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/messages.historyImportParsed.md b/docs/API_docs/constructors/messages.historyImportParsed.md new file mode 100644 index 0000000000..73558acf3c --- /dev/null +++ b/docs/API_docs/constructors/messages.historyImportParsed.md @@ -0,0 +1,33 @@ +--- +title: "messages.historyImportParsed" +description: "Contains information about a chat export file generated by a foreign chat app, click here for more info." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_historyImportParsed.html +--- +# Constructor: messages.historyImportParsed +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains information about a chat export file [generated by a foreign chat app, click here for more info](https://core.telegram.org/api/import). +If neither the `pm` or `group` flags are set, the specified chat export was generated from a chat of unknown type. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pm|[Bool](/API_docs/types/Bool.html) | Optional|The chat export file was generated from a private chat.| +|group|[Bool](/API_docs/types/Bool.html) | Optional|The chat export file was generated from a group chat.| +|title|[string](/API_docs/types/string.html) | Optional|Title of the chat.| + + + +### Type: [messages.HistoryImportParsed](/API_docs/types/messages.HistoryImportParsed.html) + + +### Example: + +``` +$messages_historyImportParsed = ['_' => 'messages.historyImportParsed', 'pm' => Bool, 'group' => Bool, 'title' => 'string']; +``` diff --git a/docs/API_docs/constructors/messages.inactiveChats.md b/docs/API_docs/constructors/messages.inactiveChats.md new file mode 100644 index 0000000000..2340d04eb5 --- /dev/null +++ b/docs/API_docs/constructors/messages.inactiveChats.md @@ -0,0 +1,32 @@ +--- +title: "messages.inactiveChats" +description: "Inactive chat list" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_inactiveChats.html +--- +# Constructor: messages.inactiveChats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Inactive chat list + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dates|Array of [int](/API_docs/types/int.html) | Yes|When was the chat last active| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chat list| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the chat list| + + + +### Type: [messages.InactiveChats](/API_docs/types/messages.InactiveChats.html) + + +### Example: + +``` +$messages_inactiveChats = ['_' => 'messages.inactiveChats', 'dates' => [int, int], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.invitedUsers.md b/docs/API_docs/constructors/messages.invitedUsers.md new file mode 100644 index 0000000000..3ae34b7445 --- /dev/null +++ b/docs/API_docs/constructors/messages.invitedUsers.md @@ -0,0 +1,29 @@ +--- +title: "messages.invitedUsers" +description: "messages.invitedUsers attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_invitedUsers.html +--- +# Constructor: messages.invitedUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|updates|[Updates](/API_docs/types/Updates.html) | Yes| +|missing\_invitees|Array of [MissingInvitee](/API_docs/types/MissingInvitee.html) | Yes| + + + +### Type: [messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + + +### Example: + +``` +$messages_invitedUsers = ['_' => 'messages.invitedUsers', 'updates' => Updates, 'missing_invitees' => [MissingInvitee, MissingInvitee]]; +``` diff --git a/docs/API_docs/constructors/messages.messageEditData.md b/docs/API_docs/constructors/messages.messageEditData.md new file mode 100644 index 0000000000..457bba0b0d --- /dev/null +++ b/docs/API_docs/constructors/messages.messageEditData.md @@ -0,0 +1,30 @@ +--- +title: "messages.messageEditData" +description: "Message edit data for media" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_messageEditData.html +--- +# Constructor: messages.messageEditData +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message edit data for media + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|caption|[Bool](/API_docs/types/Bool.html) | Optional|Media caption, if the specified media's caption can be edited| + + + +### Type: [messages.MessageEditData](/API_docs/types/messages.MessageEditData.html) + + +### Example: + +``` +$messages_messageEditData = ['_' => 'messages.messageEditData', 'caption' => Bool]; +``` diff --git a/docs/API_docs/constructors/messages.messageReactionsList.md b/docs/API_docs/constructors/messages.messageReactionsList.md new file mode 100644 index 0000000000..a9102f9532 --- /dev/null +++ b/docs/API_docs/constructors/messages.messageReactionsList.md @@ -0,0 +1,34 @@ +--- +title: "messages.messageReactionsList" +description: "List of peers that reacted to a specific message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_messageReactionsList.html +--- +# Constructor: messages.messageReactionsList +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of peers that reacted to a specific message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of reactions matching query| +|reactions|Array of [MessagePeerReaction](/API_docs/types/MessagePeerReaction.html) | Yes|List of peers that reacted to a specific message| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| +|next\_offset|[string](/API_docs/types/string.html) | Optional|If set, indicates the next offset to use to load more results by invoking [messages.getMessageReactionsList](../methods/messages.getMessageReactionsList.html).| + + + +### Type: [messages.MessageReactionsList](/API_docs/types/messages.MessageReactionsList.html) + + +### Example: + +``` +$messages_messageReactionsList = ['_' => 'messages.messageReactionsList', 'count' => int, 'reactions' => [MessagePeerReaction, MessagePeerReaction], 'chats' => [Chat, Chat], 'users' => [User, User], 'next_offset' => 'string']; +``` diff --git a/docs/API_docs/constructors/messages.messageViews.md b/docs/API_docs/constructors/messages.messageViews.md new file mode 100644 index 0000000000..3ef5b961d2 --- /dev/null +++ b/docs/API_docs/constructors/messages.messageViews.md @@ -0,0 +1,32 @@ +--- +title: "messages.messageViews" +description: "View, forward counter + info about replies" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_messageViews.html +--- +# Constructor: messages.messageViews +[Back to constructors index](/API_docs/constructors/index.html) + + + +View, forward counter + info about replies + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|views|Array of [MessageViews](/API_docs/types/MessageViews.html) | Yes|View, forward counter + info about replies| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in constructor| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in constructor| + + + +### Type: [messages.MessageViews](/API_docs/types/messages.MessageViews.html) + + +### Example: + +``` +$messages_messageViews = ['_' => 'messages.messageViews', 'views' => [MessageViews, MessageViews], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.messages.md b/docs/API_docs/constructors/messages.messages.md new file mode 100644 index 0000000000..21d715ad67 --- /dev/null +++ b/docs/API_docs/constructors/messages.messages.md @@ -0,0 +1,32 @@ +--- +title: "messages.messages" +description: "Full list of messages with auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_messages.html +--- +# Constructor: messages.messages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full list of messages with auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of messages| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in dialogs| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in messages and chats| + + + +### Type: [messages.Messages](/API_docs/types/messages.Messages.html) + + +### Example: + +``` +$messages_messages = ['_' => 'messages.messages', 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.messagesNotModified.md b/docs/API_docs/constructors/messages.messagesNotModified.md new file mode 100644 index 0000000000..c4f23393fb --- /dev/null +++ b/docs/API_docs/constructors/messages.messagesNotModified.md @@ -0,0 +1,30 @@ +--- +title: "messages.messagesNotModified" +description: "No new messages matching the query were found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_messagesNotModified.html +--- +# Constructor: messages.messagesNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new messages matching the query were found + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of results found server-side by the given query| + + + +### Type: [messages.Messages](/API_docs/types/messages.Messages.html) + + +### Example: + +``` +$messages_messagesNotModified = ['_' => 'messages.messagesNotModified', 'count' => int]; +``` diff --git a/docs/API_docs/constructors/messages.messagesSlice.md b/docs/API_docs/constructors/messages.messagesSlice.md new file mode 100644 index 0000000000..406f942aa7 --- /dev/null +++ b/docs/API_docs/constructors/messages.messagesSlice.md @@ -0,0 +1,36 @@ +--- +title: "messages.messagesSlice" +description: "Incomplete list of messages and auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_messagesSlice.html +--- +# Constructor: messages.messagesSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incomplete list of messages and auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inexact|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates that the results may be inexact| +|count|[int](/API_docs/types/int.html) | Yes|Total number of messages in the list| +|next\_rate|[int](/API_docs/types/int.html) | Optional|Rate to use in the `offset_rate` parameter in the next call to [messages.searchGlobal](../methods/messages.searchGlobal.html)| +|offset\_id\_offset|[int](/API_docs/types/int.html) | Optional|Indicates the absolute position of `messages[0]` within the total result set with count `count`.
This is useful, for example, if the result was fetched using `offset_id`, and we need to display a `progress/total` counter (like `photo 134 of 200`, for all media in a chat, we could simply use `photo ${offset_id_offset} of ${count}`.| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of messages| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in messages| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in messages and chats| + + + +### Type: [messages.Messages](/API_docs/types/messages.Messages.html) + + +### Example: + +``` +$messages_messagesSlice = ['_' => 'messages.messagesSlice', 'inexact' => Bool, 'count' => int, 'next_rate' => int, 'offset_id_offset' => int, 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.myStickers.md b/docs/API_docs/constructors/messages.myStickers.md new file mode 100644 index 0000000000..284aad342b --- /dev/null +++ b/docs/API_docs/constructors/messages.myStickers.md @@ -0,0 +1,29 @@ +--- +title: "messages.myStickers" +description: "messages.myStickers attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_myStickers.html +--- +# Constructor: messages.myStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|count|[int](/API_docs/types/int.html) | Yes| +|sets|Array of [StickerSetCovered](/API_docs/types/StickerSetCovered.html) | Yes| + + + +### Type: [messages.MyStickers](/API_docs/types/messages.MyStickers.html) + + +### Example: + +``` +$messages_myStickers = ['_' => 'messages.myStickers', 'count' => int, 'sets' => [StickerSetCovered, StickerSetCovered]]; +``` diff --git a/docs/API_docs/constructors/messages.peerDialogs.md b/docs/API_docs/constructors/messages.peerDialogs.md new file mode 100644 index 0000000000..d7eecc0836 --- /dev/null +++ b/docs/API_docs/constructors/messages.peerDialogs.md @@ -0,0 +1,34 @@ +--- +title: "messages.peerDialogs" +description: "Dialog info of multiple peers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_peerDialogs.html +--- +# Constructor: messages.peerDialogs +[Back to constructors index](/API_docs/constructors/index.html) + + + +Dialog info of multiple peers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dialogs|Array of [Dialog](/API_docs/types/Dialog.html) | Yes|Dialog info| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|Messages mentioned in dialog info| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| +|state|[updates.State](/API_docs/constructors/updates.State.html) | Yes|Current [update state of dialog](https://core.telegram.org/api/updates)| + + + +### Type: [messages.PeerDialogs](/API_docs/types/messages.PeerDialogs.html) + + +### Example: + +``` +$messages_peerDialogs = ['_' => 'messages.peerDialogs', 'dialogs' => [Dialog, Dialog], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User], 'state' => updates.State]; +``` diff --git a/docs/API_docs/constructors/messages.peerSettings.md b/docs/API_docs/constructors/messages.peerSettings.md new file mode 100644 index 0000000000..a1f98dac62 --- /dev/null +++ b/docs/API_docs/constructors/messages.peerSettings.md @@ -0,0 +1,32 @@ +--- +title: "messages.peerSettings" +description: "Peer settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_peerSettings.html +--- +# Constructor: messages.peerSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|settings|[PeerSettings](/API_docs/types/PeerSettings.html) | Yes|Peer settings| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.PeerSettings](/API_docs/types/messages.PeerSettings.html) + + +### Example: + +``` +$messages_peerSettings = ['_' => 'messages.peerSettings', 'settings' => PeerSettings, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.quickReplies.md b/docs/API_docs/constructors/messages.quickReplies.md new file mode 100644 index 0000000000..f504124ec0 --- /dev/null +++ b/docs/API_docs/constructors/messages.quickReplies.md @@ -0,0 +1,31 @@ +--- +title: "messages.quickReplies" +description: "messages.quickReplies attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_quickReplies.html +--- +# Constructor: messages.quickReplies +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|quick\_replies|Array of [QuickReply](/API_docs/types/QuickReply.html) | Yes| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes| +|users|Array of [User](/API_docs/types/User.html) | Yes| + + + +### Type: [messages.QuickReplies](/API_docs/types/messages.QuickReplies.html) + + +### Example: + +``` +$messages_quickReplies = ['_' => 'messages.quickReplies', 'quick_replies' => [QuickReply, QuickReply], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.quickRepliesNotModified.md b/docs/API_docs/constructors/messages.quickRepliesNotModified.md new file mode 100644 index 0000000000..ecd2dff526 --- /dev/null +++ b/docs/API_docs/constructors/messages.quickRepliesNotModified.md @@ -0,0 +1,23 @@ +--- +title: "messages.quickRepliesNotModified" +description: "messages.quickRepliesNotModified attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_quickRepliesNotModified.html +--- +# Constructor: messages.quickRepliesNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [messages.QuickReplies](/API_docs/types/messages.QuickReplies.html) + + +### Example: + +``` +$messages_quickRepliesNotModified = ['_' => 'messages.quickRepliesNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.reactions.md b/docs/API_docs/constructors/messages.reactions.md new file mode 100644 index 0000000000..0749e3de90 --- /dev/null +++ b/docs/API_docs/constructors/messages.reactions.md @@ -0,0 +1,31 @@ +--- +title: "messages.reactions" +description: "List of message reactions" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_reactions.html +--- +# Constructor: messages.reactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of [message reactions](https://core.telegram.org/api/reactions) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|reactions|Array of [Reaction](/API_docs/types/Reaction.html) | Yes|Reactions| + + + +### Type: [messages.Reactions](/API_docs/types/messages.Reactions.html) + + +### Example: + +``` +$messages_reactions = ['_' => 'messages.reactions', 'hash' => long, 'reactions' => [Reaction, Reaction]]; +``` diff --git a/docs/API_docs/constructors/messages.reactionsNotModified.md b/docs/API_docs/constructors/messages.reactionsNotModified.md new file mode 100644 index 0000000000..1c5f2561e1 --- /dev/null +++ b/docs/API_docs/constructors/messages.reactionsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.reactionsNotModified" +description: "The server-side list of message reactions hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_reactionsNotModified.html +--- +# Constructor: messages.reactionsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The server-side list of [message reactions](https://core.telegram.org/api/reactions) hasn't changed + + + + +### Type: [messages.Reactions](/API_docs/types/messages.Reactions.html) + + +### Example: + +``` +$messages_reactionsNotModified = ['_' => 'messages.reactionsNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.recentStickers.md b/docs/API_docs/constructors/messages.recentStickers.md new file mode 100644 index 0000000000..1a510037ea --- /dev/null +++ b/docs/API_docs/constructors/messages.recentStickers.md @@ -0,0 +1,33 @@ +--- +title: "messages.recentStickers" +description: "Recently used stickers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_recentStickers.html +--- +# Constructor: messages.recentStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recently used stickers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|packs|Array of [StickerPack](/API_docs/types/StickerPack.html) | Yes|Emojis associated to stickers| +|stickers|Array of [Document](/API_docs/types/Document.html) | Yes|Recent stickers| +|dates|Array of [int](/API_docs/types/int.html) | Yes|When was each sticker last used| + + + +### Type: [messages.RecentStickers](/API_docs/types/messages.RecentStickers.html) + + +### Example: + +``` +$messages_recentStickers = ['_' => 'messages.recentStickers', 'hash' => long, 'packs' => [StickerPack, StickerPack], 'stickers' => [Document, Document], 'dates' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/messages.recentStickersNotModified.md b/docs/API_docs/constructors/messages.recentStickersNotModified.md new file mode 100644 index 0000000000..c61f52327d --- /dev/null +++ b/docs/API_docs/constructors/messages.recentStickersNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.recentStickersNotModified" +description: "No new recent sticker was found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_recentStickersNotModified.html +--- +# Constructor: messages.recentStickersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new recent sticker was found + + + + +### Type: [messages.RecentStickers](/API_docs/types/messages.RecentStickers.html) + + +### Example: + +``` +$messages_recentStickersNotModified = ['_' => 'messages.recentStickersNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.savedDialogs.md b/docs/API_docs/constructors/messages.savedDialogs.md new file mode 100644 index 0000000000..5dc0a226af --- /dev/null +++ b/docs/API_docs/constructors/messages.savedDialogs.md @@ -0,0 +1,33 @@ +--- +title: "messages.savedDialogs" +description: "Represents some saved message dialogs »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedDialogs.html +--- +# Constructor: messages.savedDialogs +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents some [saved message dialogs »](https://core.telegram.org/api/saved-messages). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dialogs|Array of [SavedDialog](/API_docs/types/SavedDialog.html) | Yes|[Saved message dialogs »](https://core.telegram.org/api/saved-messages).| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of last messages from each saved dialog| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + + +### Example: + +``` +$messages_savedDialogs = ['_' => 'messages.savedDialogs', 'dialogs' => [SavedDialog, SavedDialog], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.savedDialogsNotModified.md b/docs/API_docs/constructors/messages.savedDialogsNotModified.md new file mode 100644 index 0000000000..cb5b8d3c02 --- /dev/null +++ b/docs/API_docs/constructors/messages.savedDialogsNotModified.md @@ -0,0 +1,30 @@ +--- +title: "messages.savedDialogsNotModified" +description: "The saved dialogs haven't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedDialogsNotModified.html +--- +# Constructor: messages.savedDialogsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The saved dialogs haven't changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of [saved dialogs](https://core.telegram.org/api/saved-messages) found server-side by the query| + + + +### Type: [messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + + +### Example: + +``` +$messages_savedDialogsNotModified = ['_' => 'messages.savedDialogsNotModified', 'count' => int]; +``` diff --git a/docs/API_docs/constructors/messages.savedDialogsSlice.md b/docs/API_docs/constructors/messages.savedDialogsSlice.md new file mode 100644 index 0000000000..6594ee883b --- /dev/null +++ b/docs/API_docs/constructors/messages.savedDialogsSlice.md @@ -0,0 +1,34 @@ +--- +title: "messages.savedDialogsSlice" +description: "Incomplete list of saved message dialogs » with messages and auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedDialogsSlice.html +--- +# Constructor: messages.savedDialogsSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incomplete list of [saved message dialogs »](https://core.telegram.org/api/saved-messages) with messages and auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of saved message dialogs| +|dialogs|Array of [SavedDialog](/API_docs/types/SavedDialog.html) | Yes|List of saved message dialogs| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of last messages from dialogs| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + + +### Example: + +``` +$messages_savedDialogsSlice = ['_' => 'messages.savedDialogsSlice', 'count' => int, 'dialogs' => [SavedDialog, SavedDialog], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.savedGifs.md b/docs/API_docs/constructors/messages.savedGifs.md new file mode 100644 index 0000000000..40d611e678 --- /dev/null +++ b/docs/API_docs/constructors/messages.savedGifs.md @@ -0,0 +1,31 @@ +--- +title: "messages.savedGifs" +description: "Saved gifs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedGifs.html +--- +# Constructor: messages.savedGifs +[Back to constructors index](/API_docs/constructors/index.html) + + + +Saved gifs + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|gifs|Array of [Document](/API_docs/types/Document.html) | Yes|List of saved gifs| + + + +### Type: [messages.SavedGifs](/API_docs/types/messages.SavedGifs.html) + + +### Example: + +``` +$messages_savedGifs = ['_' => 'messages.savedGifs', 'hash' => long, 'gifs' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/messages.savedGifsNotModified.md b/docs/API_docs/constructors/messages.savedGifsNotModified.md new file mode 100644 index 0000000000..b336064ba2 --- /dev/null +++ b/docs/API_docs/constructors/messages.savedGifsNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.savedGifsNotModified" +description: "No new saved gifs were found" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedGifsNotModified.html +--- +# Constructor: messages.savedGifsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new saved gifs were found + + + + +### Type: [messages.SavedGifs](/API_docs/types/messages.SavedGifs.html) + + +### Example: + +``` +$messages_savedGifsNotModified = ['_' => 'messages.savedGifsNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.savedReactionTags.md b/docs/API_docs/constructors/messages.savedReactionTags.md new file mode 100644 index 0000000000..36428240a5 --- /dev/null +++ b/docs/API_docs/constructors/messages.savedReactionTags.md @@ -0,0 +1,29 @@ +--- +title: "messages.savedReactionTags" +description: "messages.savedReactionTags attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedReactionTags.html +--- +# Constructor: messages.savedReactionTags +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|tags|Array of [SavedReactionTag](/API_docs/types/SavedReactionTag.html) | Yes| +|hash|[long](/API_docs/types/long.html) | Yes| + + + +### Type: [messages.SavedReactionTags](/API_docs/types/messages.SavedReactionTags.html) + + +### Example: + +``` +$messages_savedReactionTags = ['_' => 'messages.savedReactionTags', 'tags' => [SavedReactionTag, SavedReactionTag], 'hash' => long]; +``` diff --git a/docs/API_docs/constructors/messages.savedReactionTagsNotModified.md b/docs/API_docs/constructors/messages.savedReactionTagsNotModified.md new file mode 100644 index 0000000000..1583a90a92 --- /dev/null +++ b/docs/API_docs/constructors/messages.savedReactionTagsNotModified.md @@ -0,0 +1,23 @@ +--- +title: "messages.savedReactionTagsNotModified" +description: "messages.savedReactionTagsNotModified attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_savedReactionTagsNotModified.html +--- +# Constructor: messages.savedReactionTagsNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [messages.SavedReactionTags](/API_docs/types/messages.SavedReactionTags.html) + + +### Example: + +``` +$messages_savedReactionTagsNotModified = ['_' => 'messages.savedReactionTagsNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.searchCounter.md b/docs/API_docs/constructors/messages.searchCounter.md new file mode 100644 index 0000000000..a53e0bffd7 --- /dev/null +++ b/docs/API_docs/constructors/messages.searchCounter.md @@ -0,0 +1,32 @@ +--- +title: "messages.searchCounter" +description: "Indicates how many results would be found by a messages.search call with the same parameters" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_searchCounter.html +--- +# Constructor: messages.searchCounter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates how many results would be found by a [messages.search](../methods/messages.search.html) call with the same parameters + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inexact|[Bool](/API_docs/types/Bool.html) | Optional|If set, the results may be inexact| +|filter|[MessagesFilter](/API_docs/types/MessagesFilter.html) | Yes|Provided message filter| +|count|[int](/API_docs/types/int.html) | Yes|Number of results that were found server-side| + + + +### Type: [messages.SearchCounter](/API_docs/types/messages.SearchCounter.html) + + +### Example: + +``` +$messages_searchCounter = ['_' => 'messages.searchCounter', 'inexact' => Bool, 'filter' => MessagesFilter, 'count' => int]; +``` diff --git a/docs/API_docs/constructors/messages.searchResultsCalendar.md b/docs/API_docs/constructors/messages.searchResultsCalendar.md new file mode 100644 index 0000000000..dfb8cdac3b --- /dev/null +++ b/docs/API_docs/constructors/messages.searchResultsCalendar.md @@ -0,0 +1,38 @@ +--- +title: "messages.searchResultsCalendar" +description: "Information about found messages sent on a specific day" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_searchResultsCalendar.html +--- +# Constructor: messages.searchResultsCalendar +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about found messages sent on a specific day + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|inexact|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates that the results may be inexact| +|count|[int](/API_docs/types/int.html) | Yes|Total number of results matching query| +|min\_date|[int](/API_docs/types/int.html) | Yes|Starting timestamp of attached messages| +|min\_msg\_id|[int](/API_docs/types/int.html) | Yes|Ending timestamp of attached messages| +|offset\_id\_offset|[int](/API_docs/types/int.html) | Optional|Indicates the absolute position of `messages[0]` within the total result set with count `count`.
This is useful, for example, if we need to display a `progress/total` counter (like `photo 134 of 200`, for all media in a chat, we could simply use `photo ${offset_id_offset} of ${count}`.| +|periods|Array of [SearchResultsCalendarPeriod](/API_docs/types/SearchResultsCalendarPeriod.html) | Yes|Used to split the `messages` by days: multiple [SearchResultsCalendarPeriod](../types/SearchResultsCalendarPeriod.html) constructors are returned, each containing information about the first, last and total number of messages matching the filter that were sent on a specific day.
This information can be easily used to split the returned `messages` by day.| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|Messages| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [messages.SearchResultsCalendar](/API_docs/types/messages.SearchResultsCalendar.html) + + +### Example: + +``` +$messages_searchResultsCalendar = ['_' => 'messages.searchResultsCalendar', 'inexact' => Bool, 'count' => int, 'min_date' => int, 'min_msg_id' => int, 'offset_id_offset' => int, 'periods' => [SearchResultsCalendarPeriod, SearchResultsCalendarPeriod], 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.searchResultsPositions.md b/docs/API_docs/constructors/messages.searchResultsPositions.md new file mode 100644 index 0000000000..2f2b17fa4a --- /dev/null +++ b/docs/API_docs/constructors/messages.searchResultsPositions.md @@ -0,0 +1,31 @@ +--- +title: "messages.searchResultsPositions" +description: "Information about sparse positions of messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_searchResultsPositions.html +--- +# Constructor: messages.searchResultsPositions +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about sparse positions of messages + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of found messages| +|positions|Array of [SearchResultsPosition](/API_docs/types/SearchResultsPosition.html) | Yes|List of message positions| + + + +### Type: [messages.SearchResultsPositions](/API_docs/types/messages.SearchResultsPositions.html) + + +### Example: + +``` +$messages_searchResultsPositions = ['_' => 'messages.searchResultsPositions', 'count' => int, 'positions' => [SearchResultsPosition, SearchResultsPosition]]; +``` diff --git a/docs/API_docs/constructors/messages.sentEncryptedFile.md b/docs/API_docs/constructors/messages.sentEncryptedFile.md new file mode 100644 index 0000000000..791f3b7ca9 --- /dev/null +++ b/docs/API_docs/constructors/messages.sentEncryptedFile.md @@ -0,0 +1,31 @@ +--- +title: "messages.sentEncryptedFile" +description: "Message with a file enclosure sent to a protected chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_sentEncryptedFile.html +--- +# Constructor: messages.sentEncryptedFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message with a file enclosure sent to a protected chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|date|[int](/API_docs/types/int.html) | Yes|Sending date| +|file|[EncryptedFile](/API_docs/types/EncryptedFile.html) | Optional|Attached file| + + + +### Type: [messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + + +### Example: + +``` +$messages_sentEncryptedFile = ['_' => 'messages.sentEncryptedFile', 'date' => int, 'file' => EncryptedFile]; +``` diff --git a/docs/API_docs/constructors/messages.sentEncryptedMessage.md b/docs/API_docs/constructors/messages.sentEncryptedMessage.md new file mode 100644 index 0000000000..51230e42bf --- /dev/null +++ b/docs/API_docs/constructors/messages.sentEncryptedMessage.md @@ -0,0 +1,30 @@ +--- +title: "messages.sentEncryptedMessage" +description: "Message without file attachments sent to an encrypted file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_sentEncryptedMessage.html +--- +# Constructor: messages.sentEncryptedMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message without file attachments sent to an encrypted file. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|date|[int](/API_docs/types/int.html) | Yes|Date of sending| + + + +### Type: [messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + + +### Example: + +``` +$messages_sentEncryptedMessage = ['_' => 'messages.sentEncryptedMessage', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/messages.sponsoredMessages.md b/docs/API_docs/constructors/messages.sponsoredMessages.md new file mode 100644 index 0000000000..230be486d8 --- /dev/null +++ b/docs/API_docs/constructors/messages.sponsoredMessages.md @@ -0,0 +1,33 @@ +--- +title: "messages.sponsoredMessages" +description: "A set of sponsored messages associated to a channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_sponsoredMessages.html +--- +# Constructor: messages.sponsoredMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +A set of sponsored messages associated to a channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|posts\_between|[int](/API_docs/types/int.html) | Optional|If set, specifies the minimum number of messages between shown sponsored messages; otherwise, only one sponsored message must be shown after all ordinary messages.| +|messages|Array of [SponsoredMessage](/API_docs/types/SponsoredMessage.html) | Yes|Sponsored messages| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in the sponsored messages| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the sponsored messages| + + + +### Type: [messages.SponsoredMessages](/API_docs/types/messages.SponsoredMessages.html) + + +### Example: + +``` +$messages_sponsoredMessages = ['_' => 'messages.sponsoredMessages', 'posts_between' => int, 'messages' => [SponsoredMessage, SponsoredMessage], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/messages.sponsoredMessagesEmpty.md b/docs/API_docs/constructors/messages.sponsoredMessagesEmpty.md new file mode 100644 index 0000000000..16d7474757 --- /dev/null +++ b/docs/API_docs/constructors/messages.sponsoredMessagesEmpty.md @@ -0,0 +1,25 @@ +--- +title: "messages.sponsoredMessagesEmpty" +description: "No sponsored messages are available." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_sponsoredMessagesEmpty.html +--- +# Constructor: messages.sponsoredMessagesEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No sponsored messages are available. + + + + +### Type: [messages.SponsoredMessages](/API_docs/types/messages.SponsoredMessages.html) + + +### Example: + +``` +$messages_sponsoredMessagesEmpty = ['_' => 'messages.sponsoredMessagesEmpty']; +``` diff --git a/docs/API_docs/constructors/messages.stickerSet.md b/docs/API_docs/constructors/messages.stickerSet.md new file mode 100644 index 0000000000..d369f9a645 --- /dev/null +++ b/docs/API_docs/constructors/messages.stickerSet.md @@ -0,0 +1,33 @@ +--- +title: "messages.stickerSet" +description: "Stickerset and stickers inside it" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_stickerSet.html +--- +# Constructor: messages.stickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickerset and stickers inside it + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|set|[StickerSet](/API_docs/types/StickerSet.html) | Yes|The stickerset| +|packs|Array of [StickerPack](/API_docs/types/StickerPack.html) | Yes|Emoji info for stickers| +|keywords|Array of [StickerKeyword](/API_docs/types/StickerKeyword.html) | Yes|Keywords for some or every sticker in the stickerset.| +|documents|Array of [Document](/API_docs/types/Document.html) | Yes|Stickers in stickerset| + + + +### Type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + + +### Example: + +``` +$messages_stickerSet = ['_' => 'messages.stickerSet', 'set' => StickerSet, 'packs' => [StickerPack, StickerPack], 'keywords' => [StickerKeyword, StickerKeyword], 'documents' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/messages.stickerSetInstallResultArchive.md b/docs/API_docs/constructors/messages.stickerSetInstallResultArchive.md new file mode 100644 index 0000000000..2730346a7b --- /dev/null +++ b/docs/API_docs/constructors/messages.stickerSetInstallResultArchive.md @@ -0,0 +1,30 @@ +--- +title: "messages.stickerSetInstallResultArchive" +description: "The stickerset was installed, but since there are too many stickersets some were archived" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_stickerSetInstallResultArchive.html +--- +# Constructor: messages.stickerSetInstallResultArchive +[Back to constructors index](/API_docs/constructors/index.html) + + + +The stickerset was installed, but since there are too many stickersets some were archived + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|sets|Array of [StickerSetCovered](/API_docs/types/StickerSetCovered.html) | Yes|Archived stickersets| + + + +### Type: [messages.StickerSetInstallResult](/API_docs/types/messages.StickerSetInstallResult.html) + + +### Example: + +``` +$messages_stickerSetInstallResultArchive = ['_' => 'messages.stickerSetInstallResultArchive', 'sets' => [StickerSetCovered, StickerSetCovered]]; +``` diff --git a/docs/API_docs/constructors/messages.stickerSetInstallResultSuccess.md b/docs/API_docs/constructors/messages.stickerSetInstallResultSuccess.md new file mode 100644 index 0000000000..03a6b1ba9f --- /dev/null +++ b/docs/API_docs/constructors/messages.stickerSetInstallResultSuccess.md @@ -0,0 +1,25 @@ +--- +title: "messages.stickerSetInstallResultSuccess" +description: "The stickerset was installed successfully" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_stickerSetInstallResultSuccess.html +--- +# Constructor: messages.stickerSetInstallResultSuccess +[Back to constructors index](/API_docs/constructors/index.html) + + + +The stickerset was installed successfully + + + + +### Type: [messages.StickerSetInstallResult](/API_docs/types/messages.StickerSetInstallResult.html) + + +### Example: + +``` +$messages_stickerSetInstallResultSuccess = ['_' => 'messages.stickerSetInstallResultSuccess']; +``` diff --git a/docs/API_docs/constructors/messages.stickerSetNotModified.md b/docs/API_docs/constructors/messages.stickerSetNotModified.md new file mode 100644 index 0000000000..189ef2caab --- /dev/null +++ b/docs/API_docs/constructors/messages.stickerSetNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.stickerSetNotModified" +description: "The stickerset hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_stickerSetNotModified.html +--- +# Constructor: messages.stickerSetNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The stickerset hasn't changed + + + + +### Type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + + +### Example: + +``` +$messages_stickerSetNotModified = ['_' => 'messages.stickerSetNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.stickers.md b/docs/API_docs/constructors/messages.stickers.md new file mode 100644 index 0000000000..e361033318 --- /dev/null +++ b/docs/API_docs/constructors/messages.stickers.md @@ -0,0 +1,31 @@ +--- +title: "messages.stickers" +description: "Found stickers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_stickers.html +--- +# Constructor: messages.stickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Found stickers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|stickers|Array of [Document](/API_docs/types/Document.html) | Yes|Stickers| + + + +### Type: [messages.Stickers](/API_docs/types/messages.Stickers.html) + + +### Example: + +``` +$messages_stickers = ['_' => 'messages.stickers', 'hash' => long, 'stickers' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/messages.stickersNotModified.md b/docs/API_docs/constructors/messages.stickersNotModified.md new file mode 100644 index 0000000000..fd7dbfbbd2 --- /dev/null +++ b/docs/API_docs/constructors/messages.stickersNotModified.md @@ -0,0 +1,25 @@ +--- +title: "messages.stickersNotModified" +description: "No new stickers were found for the given query" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_stickersNotModified.html +--- +# Constructor: messages.stickersNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +No new stickers were found for the given query + + + + +### Type: [messages.Stickers](/API_docs/types/messages.Stickers.html) + + +### Example: + +``` +$messages_stickersNotModified = ['_' => 'messages.stickersNotModified']; +``` diff --git a/docs/API_docs/constructors/messages.transcribedAudio.md b/docs/API_docs/constructors/messages.transcribedAudio.md new file mode 100644 index 0000000000..b0bc70518a --- /dev/null +++ b/docs/API_docs/constructors/messages.transcribedAudio.md @@ -0,0 +1,34 @@ +--- +title: "messages.transcribedAudio" +description: "Transcribed text from a voice message »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_transcribedAudio.html +--- +# Constructor: messages.transcribedAudio +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Transcribed text from a voice message »](https://core.telegram.org/api/transcribe) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pending|[Bool](/API_docs/types/Bool.html) | Optional|Whether the transcription is partial because audio transcription is still in progress, if set the user may receive further [updateTranscribedAudio](../constructors/updateTranscribedAudio.html) updates with the updated transcription.| +|transcription\_id|[long](/API_docs/types/long.html) | Yes|Transcription ID| +|text|[string](/API_docs/types/string.html) | Yes|Transcripted text| +|trial\_remains\_num|[int](/API_docs/types/int.html) | Optional|For non-[Premium](https://core.telegram.org/api/premium) users, this flag will be set, indicating the remaining transcriptions in the free trial period.| +|trial\_remains\_until\_date|[int](/API_docs/types/int.html) | Optional|For non-[Premium](https://core.telegram.org/api/premium) users, this flag will be set, indicating the date when the `trial_remains_num` counter will be reset to the maximum value of [transcribe\_audio\_trial\_weekly\_number](https://core.telegram.org/api/config#transcribe-audio-trial-weekly-number).| + + + +### Type: [messages.TranscribedAudio](/API_docs/types/messages.TranscribedAudio.html) + + +### Example: + +``` +$messages_transcribedAudio = ['_' => 'messages.transcribedAudio', 'pending' => Bool, 'transcription_id' => long, 'text' => 'string', 'trial_remains_num' => int, 'trial_remains_until_date' => int]; +``` diff --git a/docs/API_docs/constructors/messages.translateResult.md b/docs/API_docs/constructors/messages.translateResult.md new file mode 100644 index 0000000000..e0dab4c532 --- /dev/null +++ b/docs/API_docs/constructors/messages.translateResult.md @@ -0,0 +1,30 @@ +--- +title: "messages.translateResult" +description: "Translated text with entities" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_translateResult.html +--- +# Constructor: messages.translateResult +[Back to constructors index](/API_docs/constructors/index.html) + + + +Translated text with [entities](https://core.telegram.org/api/entities) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|result|Array of [TextWithEntities](/API_docs/types/TextWithEntities.html) | Yes|Text+[entities](https://core.telegram.org/api/entities), for each input message.| + + + +### Type: [messages.TranslatedText](/API_docs/types/messages.TranslatedText.html) + + +### Example: + +``` +$messages_translateResult = ['_' => 'messages.translateResult', 'result' => [TextWithEntities, TextWithEntities]]; +``` diff --git a/docs/API_docs/constructors/messages.votesList.md b/docs/API_docs/constructors/messages.votesList.md new file mode 100644 index 0000000000..305c88b103 --- /dev/null +++ b/docs/API_docs/constructors/messages.votesList.md @@ -0,0 +1,34 @@ +--- +title: "messages.votesList" +description: "How users voted in a poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_votesList.html +--- +# Constructor: messages.votesList +[Back to constructors index](/API_docs/constructors/index.html) + + + +How users voted in a poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of votes for all options (or only for the chosen `option`, if provided to [messages.getPollVotes](../methods/messages.getPollVotes.html))| +|votes|Array of [MessagePeerVote](/API_docs/types/MessagePeerVote.html) | Yes|Vote info for each user| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Info about users that voted in the poll| +|next\_offset|[string](/API_docs/types/string.html) | Optional|Offset to use with the next [messages.getPollVotes](../methods/messages.getPollVotes.html) request, empty string if no more results are available.| + + + +### Type: [messages.VotesList](/API_docs/types/messages.VotesList.html) + + +### Example: + +``` +$messages_votesList = ['_' => 'messages.votesList', 'count' => int, 'votes' => [MessagePeerVote, MessagePeerVote], 'chats' => [Chat, Chat], 'users' => [User, User], 'next_offset' => 'string']; +``` diff --git a/docs/API_docs/constructors/messages.webPage.md b/docs/API_docs/constructors/messages.webPage.md new file mode 100644 index 0000000000..66fe106027 --- /dev/null +++ b/docs/API_docs/constructors/messages.webPage.md @@ -0,0 +1,32 @@ +--- +title: "messages.webPage" +description: "Represents an Instant View webpage." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/messages_webPage.html +--- +# Constructor: messages.webPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an Instant View webpage. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|webpage|[WebPage](/API_docs/types/WebPage.html) | Optional|The instant view webpage.| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in the webpage.| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the webpage.| + + + +### Type: [messages.WebPage](/API_docs/types/messages.WebPage.html) + + +### Example: + +``` +$messages_webPage = ['_' => 'messages.webPage', 'webpage' => WebPage, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/missingInvitee.md b/docs/API_docs/constructors/missingInvitee.md new file mode 100644 index 0000000000..eda318ec83 --- /dev/null +++ b/docs/API_docs/constructors/missingInvitee.md @@ -0,0 +1,29 @@ +--- +title: "missingInvitee" +description: "missingInvitee attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: missingInvitee +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|premium\_would\_allow\_invite|[Bool](/API_docs/types/Bool.html) | Optional| +|premium\_required\_for\_pm|[Bool](/API_docs/types/Bool.html) | Optional| +|user\_id|[long](/API_docs/types/long.html) | Yes| + + + +### Type: [MissingInvitee](/API_docs/types/MissingInvitee.html) + + +### Example: + +``` +$missingInvitee = ['_' => 'missingInvitee', 'premium_would_allow_invite' => Bool, 'premium_required_for_pm' => Bool, 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/myBoost.md b/docs/API_docs/constructors/myBoost.md new file mode 100644 index 0000000000..d096f93463 --- /dev/null +++ b/docs/API_docs/constructors/myBoost.md @@ -0,0 +1,33 @@ +--- +title: "myBoost" +description: "Contains information about a single boost slot »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: myBoost +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains information about a single [boost slot »](https://core.telegram.org/api/boost). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|slot|[int](/API_docs/types/int.html) | Yes|[Boost slot ID »](https://core.telegram.org/api/boost)| +|peer|[long](/API_docs/types/long.html) | Optional|If set, indicates this slot is currently occupied, i.e. we are [boosting](https://core.telegram.org/api/boost) this peer.
Note that we can assign multiple boost slots to the same peer.| +|date|[int](/API_docs/types/int.html) | Yes|When (unixtime) we started boosting the `peer`, `0` otherwise.| +|expires|[int](/API_docs/types/int.html) | Yes|Indicates the (unixtime) expiration date of the boost in `peer` (`0` if `peer` is not set).| +|cooldown\_until\_date|[int](/API_docs/types/int.html) | Optional|If `peer` is set, indicates the (unixtime) date after which this boost can be reassigned to another channel.| + + + +### Type: [MyBoost](/API_docs/types/MyBoost.html) + + +### Example: + +``` +$myBoost = ['_' => 'myBoost', 'slot' => int, 'peer' => long, 'date' => int, 'expires' => int, 'cooldown_until_date' => int]; +``` diff --git a/docs/API_docs/constructors/nearestDc.md b/docs/API_docs/constructors/nearestDc.md new file mode 100644 index 0000000000..dec4932391 --- /dev/null +++ b/docs/API_docs/constructors/nearestDc.md @@ -0,0 +1,31 @@ +--- +title: "nearestDc" +description: "Nearest data center, according to geo-ip." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: nearestDc +[Back to constructors index](/API_docs/constructors/index.html) + + + +Nearest data center, according to geo-ip. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|country|[string](/API_docs/types/string.html) | Yes|Country code determined by geo-ip| +|this\_dc|[int](/API_docs/types/int.html) | Yes|Number of current data center| +|nearest\_dc|[int](/API_docs/types/int.html) | Yes|Number of nearest data center| + + + +### Type: [NearestDc](/API_docs/types/NearestDc.html) + + +### Example: + +``` +$nearestDc = ['_' => 'nearestDc', 'country' => 'string', 'this_dc' => int, 'nearest_dc' => int]; +``` diff --git a/docs/API_docs/constructors/notificationSoundDefault.md b/docs/API_docs/constructors/notificationSoundDefault.md new file mode 100644 index 0000000000..a91ff6c3d8 --- /dev/null +++ b/docs/API_docs/constructors/notificationSoundDefault.md @@ -0,0 +1,24 @@ +--- +title: "notificationSoundDefault" +description: "Indicates the default notification sound should be used" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notificationSoundDefault +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates the default notification sound should be used + + + + +### Type: [NotificationSound](/API_docs/types/NotificationSound.html) + + +### Example: + +``` +$notificationSoundDefault = ['_' => 'notificationSoundDefault']; +``` diff --git a/docs/API_docs/constructors/notificationSoundLocal.md b/docs/API_docs/constructors/notificationSoundLocal.md new file mode 100644 index 0000000000..5e3dd0cf27 --- /dev/null +++ b/docs/API_docs/constructors/notificationSoundLocal.md @@ -0,0 +1,30 @@ +--- +title: "notificationSoundLocal" +description: "Indicates a specific local notification sound should be used" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notificationSoundLocal +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a specific local notification sound should be used + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|title|[string](/API_docs/types/string.html) | Yes|Notification sound title| +|data|[string](/API_docs/types/string.html) | Yes|Notification sound identifier (arbitrary data used by the client to identify a specific local notification sound)| + + + +### Type: [NotificationSound](/API_docs/types/NotificationSound.html) + + +### Example: + +``` +$notificationSoundLocal = ['_' => 'notificationSoundLocal', 'title' => 'string', 'data' => 'string']; +``` diff --git a/docs/API_docs/constructors/notificationSoundNone.md b/docs/API_docs/constructors/notificationSoundNone.md new file mode 100644 index 0000000000..94ff759de6 --- /dev/null +++ b/docs/API_docs/constructors/notificationSoundNone.md @@ -0,0 +1,24 @@ +--- +title: "notificationSoundNone" +description: "No notification sound should be used" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notificationSoundNone +[Back to constructors index](/API_docs/constructors/index.html) + + + +No notification sound should be used + + + + +### Type: [NotificationSound](/API_docs/types/NotificationSound.html) + + +### Example: + +``` +$notificationSoundNone = ['_' => 'notificationSoundNone']; +``` diff --git a/docs/API_docs/constructors/notificationSoundRingtone.md b/docs/API_docs/constructors/notificationSoundRingtone.md new file mode 100644 index 0000000000..66dbf3392b --- /dev/null +++ b/docs/API_docs/constructors/notificationSoundRingtone.md @@ -0,0 +1,29 @@ +--- +title: "notificationSoundRingtone" +description: "A specific previously uploaded notification sound should be used" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notificationSoundRingtone +[Back to constructors index](/API_docs/constructors/index.html) + + + +A specific previously uploaded notification sound should be used + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Document ID of notification sound uploaded using [account.uploadRingtone](../methods/account.uploadRingtone.html)| + + + +### Type: [NotificationSound](/API_docs/types/NotificationSound.html) + + +### Example: + +``` +$notificationSoundRingtone = ['_' => 'notificationSoundRingtone', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/notifyBroadcasts.md b/docs/API_docs/constructors/notifyBroadcasts.md new file mode 100644 index 0000000000..04262043a9 --- /dev/null +++ b/docs/API_docs/constructors/notifyBroadcasts.md @@ -0,0 +1,24 @@ +--- +title: "notifyBroadcasts" +description: "Channel notification settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notifyBroadcasts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel notification settings + + + + +### Type: [NotifyPeer](/API_docs/types/NotifyPeer.html) + + +### Example: + +``` +$notifyBroadcasts = ['_' => 'notifyBroadcasts']; +``` diff --git a/docs/API_docs/constructors/notifyChats.md b/docs/API_docs/constructors/notifyChats.md new file mode 100644 index 0000000000..839edebecc --- /dev/null +++ b/docs/API_docs/constructors/notifyChats.md @@ -0,0 +1,24 @@ +--- +title: "notifyChats" +description: "Notifications generated by all groups." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notifyChats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by all groups. + + + + +### Type: [NotifyPeer](/API_docs/types/NotifyPeer.html) + + +### Example: + +``` +$notifyChats = ['_' => 'notifyChats']; +``` diff --git a/docs/API_docs/constructors/notifyForumTopic.md b/docs/API_docs/constructors/notifyForumTopic.md new file mode 100644 index 0000000000..6e514b2a5e --- /dev/null +++ b/docs/API_docs/constructors/notifyForumTopic.md @@ -0,0 +1,30 @@ +--- +title: "notifyForumTopic" +description: "Notifications generated by a topic in a forum." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notifyForumTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by a [topic](https://core.telegram.org/api/forum#forum-topics) in a [forum](https://core.telegram.org/api/forum). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Forum ID| +|top\_msg\_id|[int](/API_docs/types/int.html) | Yes|[Topic ID](https://core.telegram.org/api/forum#forum-topics)| + + + +### Type: [NotifyPeer](/API_docs/types/NotifyPeer.html) + + +### Example: + +``` +$notifyForumTopic = ['_' => 'notifyForumTopic', 'peer' => long, 'top_msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/notifyPeer.md b/docs/API_docs/constructors/notifyPeer.md new file mode 100644 index 0000000000..26a36f973a --- /dev/null +++ b/docs/API_docs/constructors/notifyPeer.md @@ -0,0 +1,29 @@ +--- +title: "notifyPeer" +description: "Notifications generated by a certain user or group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notifyPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by a certain user or group. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|user or group| + + + +### Type: [NotifyPeer](/API_docs/types/NotifyPeer.html) + + +### Example: + +``` +$notifyPeer = ['_' => 'notifyPeer', 'peer' => long]; +``` diff --git a/docs/API_docs/constructors/notifyUsers.md b/docs/API_docs/constructors/notifyUsers.md new file mode 100644 index 0000000000..aba6a9ceb6 --- /dev/null +++ b/docs/API_docs/constructors/notifyUsers.md @@ -0,0 +1,24 @@ +--- +title: "notifyUsers" +description: "Notifications generated by all users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: notifyUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifications generated by all users. + + + + +### Type: [NotifyPeer](/API_docs/types/NotifyPeer.html) + + +### Example: + +``` +$notifyUsers = ['_' => 'notifyUsers']; +``` diff --git a/docs/API_docs/constructors/null.md b/docs/API_docs/constructors/null.md new file mode 100644 index 0000000000..1c1812ad71 --- /dev/null +++ b/docs/API_docs/constructors/null.md @@ -0,0 +1,10 @@ +--- +title: null +description: Represents a null value +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# null +[Back to constructor index](index.html) + +Represents a `null` value. diff --git a/docs/API_docs/constructors/outboxReadDate.md b/docs/API_docs/constructors/outboxReadDate.md new file mode 100644 index 0000000000..b1f9bfa470 --- /dev/null +++ b/docs/API_docs/constructors/outboxReadDate.md @@ -0,0 +1,27 @@ +--- +title: "outboxReadDate" +description: "outboxReadDate attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: outboxReadDate +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|date|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [OutboxReadDate](/API_docs/types/OutboxReadDate.html) + + +### Example: + +``` +$outboxReadDate = ['_' => 'outboxReadDate', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/page.md b/docs/API_docs/constructors/page.md new file mode 100644 index 0000000000..8679628b9a --- /dev/null +++ b/docs/API_docs/constructors/page.md @@ -0,0 +1,36 @@ +--- +title: "page" +description: "Instant view page" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: page +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Instant view](https://instantview.telegram.org) page + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|part|[Bool](/API_docs/types/Bool.html) | Optional|Indicates that not full page preview is available to the client and it will need to fetch full Instant View from the server using [messages.getWebPagePreview](../methods/messages.getWebPagePreview.html).| +|rtl|[Bool](/API_docs/types/Bool.html) | Optional|Whether the page contains RTL text| +|v2|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is an [IV v2](https://instantview.telegram.org/docs#what-39s-new-in-2-0) page| +|url|[string](/API_docs/types/string.html) | Yes|Original page HTTP URL| +|blocks|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Page elements (like with HTML elements, only as TL constructors)| +|photos|Array of [Photo](/API_docs/types/Photo.html) | Yes|Photos in page| +|documents|Array of [Document](/API_docs/types/Document.html) | Yes|Media in page| +|views|[int](/API_docs/types/int.html) | Optional|View count| + + + +### Type: [Page](/API_docs/types/Page.html) + + +### Example: + +``` +$page = ['_' => 'page', 'part' => Bool, 'rtl' => Bool, 'v2' => Bool, 'url' => 'string', 'blocks' => [PageBlock, PageBlock], 'photos' => [Photo, Photo], 'documents' => [Document, Document], 'views' => int]; +``` diff --git a/docs/API_docs/constructors/pageBlockAnchor.md b/docs/API_docs/constructors/pageBlockAnchor.md new file mode 100644 index 0000000000..8b1f570e11 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockAnchor.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockAnchor" +description: "Link to section within the page itself (like anchor)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockAnchor +[Back to constructors index](/API_docs/constructors/index.html) + + + +Link to section within the page itself (like `anchor`) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|name|[string](/API_docs/types/string.html) | Yes|Name of target section| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockAnchor = ['_' => 'pageBlockAnchor', 'name' => 'string']; +``` diff --git a/docs/API_docs/constructors/pageBlockAudio.md b/docs/API_docs/constructors/pageBlockAudio.md new file mode 100644 index 0000000000..f5368db566 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockAudio.md @@ -0,0 +1,30 @@ +--- +title: "pageBlockAudio" +description: "Audio" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockAudio +[Back to constructors index](/API_docs/constructors/index.html) + + + +Audio + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|audio\_id|[long](/API_docs/types/long.html) | Yes|Audio ID (to be fetched from the container [page](../constructors/page.html) constructor| +|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Audio caption| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockAudio = ['_' => 'pageBlockAudio', 'audio_id' => long, 'caption' => PageCaption]; +``` diff --git a/docs/API_docs/constructors/pageBlockAuthorDate.md b/docs/API_docs/constructors/pageBlockAuthorDate.md new file mode 100644 index 0000000000..b36a8c24d0 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockAuthorDate.md @@ -0,0 +1,30 @@ +--- +title: "pageBlockAuthorDate" +description: "Author and date of creation of article" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockAuthorDate +[Back to constructors index](/API_docs/constructors/index.html) + + + +Author and date of creation of article + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|author|[RichText](/API_docs/types/RichText.html) | Yes|Author name| +|published\_date|[int](/API_docs/types/int.html) | Yes|Date of publication| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockAuthorDate = ['_' => 'pageBlockAuthorDate', 'author' => RichText, 'published_date' => int]; +``` diff --git a/docs/API_docs/constructors/pageBlockBlockquote.md b/docs/API_docs/constructors/pageBlockBlockquote.md new file mode 100644 index 0000000000..16ade80485 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockBlockquote.md @@ -0,0 +1,30 @@ +--- +title: "pageBlockBlockquote" +description: "Quote (equivalent to the HTML
)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockBlockquote +[Back to constructors index](/API_docs/constructors/index.html) + + + +Quote (equivalent to the HTML `
`) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Quote contents| +|caption|[RichText](/API_docs/types/RichText.html) | Yes|Caption| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockBlockquote = ['_' => 'pageBlockBlockquote', 'text' => RichText, 'caption' => RichText]; +``` diff --git a/docs/API_docs/constructors/pageBlockChannel.md b/docs/API_docs/constructors/pageBlockChannel.md new file mode 100644 index 0000000000..0251ea8674 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockChannel.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockChannel" +description: "Reference to a telegram channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +Reference to a telegram channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel|[Chat](/API_docs/types/Chat.html) | Optional|The channel/supergroup/chat| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockChannel = ['_' => 'pageBlockChannel', 'channel' => Chat]; +``` diff --git a/docs/API_docs/constructors/pageBlockCollage.md b/docs/API_docs/constructors/pageBlockCollage.md new file mode 100644 index 0000000000..785257b8b6 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockCollage.md @@ -0,0 +1,30 @@ +--- +title: "pageBlockCollage" +description: "Collage of media" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockCollage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Collage of media + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|items|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Media elements| +|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockCollage = ['_' => 'pageBlockCollage', 'items' => [PageBlock, PageBlock], 'caption' => PageCaption]; +``` diff --git a/docs/API_docs/constructors/pageBlockCover.md b/docs/API_docs/constructors/pageBlockCover.md new file mode 100644 index 0000000000..49ae260687 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockCover.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockCover" +description: "A page cover" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockCover +[Back to constructors index](/API_docs/constructors/index.html) + + + +A page cover + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|cover|[PageBlock](/API_docs/types/PageBlock.html) | Yes|Cover| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockCover = ['_' => 'pageBlockCover', 'cover' => PageBlock]; +``` diff --git a/docs/API_docs/constructors/pageBlockDetails.md b/docs/API_docs/constructors/pageBlockDetails.md new file mode 100644 index 0000000000..8fe8e60783 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockDetails.md @@ -0,0 +1,31 @@ +--- +title: "pageBlockDetails" +description: "A collapsible details block" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockDetails +[Back to constructors index](/API_docs/constructors/index.html) + + + +A collapsible details block + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|open|[Bool](/API_docs/types/Bool.html) | Optional|Whether the block is open by default| +|blocks|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Block contents| +|title|[RichText](/API_docs/types/RichText.html) | Yes|Always visible heading for the block| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockDetails = ['_' => 'pageBlockDetails', 'open' => Bool, 'blocks' => [PageBlock, PageBlock], 'title' => RichText]; +``` diff --git a/docs/API_docs/constructors/pageBlockDivider.md b/docs/API_docs/constructors/pageBlockDivider.md new file mode 100644 index 0000000000..8617d4ac5b --- /dev/null +++ b/docs/API_docs/constructors/pageBlockDivider.md @@ -0,0 +1,24 @@ +--- +title: "pageBlockDivider" +description: "An empty block separating a page" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockDivider +[Back to constructors index](/API_docs/constructors/index.html) + + + +An empty block separating a page + + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockDivider = ['_' => 'pageBlockDivider']; +``` diff --git a/docs/API_docs/constructors/pageBlockEmbed.md b/docs/API_docs/constructors/pageBlockEmbed.md new file mode 100644 index 0000000000..a63619622b --- /dev/null +++ b/docs/API_docs/constructors/pageBlockEmbed.md @@ -0,0 +1,36 @@ +--- +title: "pageBlockEmbed" +description: "An embedded webpage" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockEmbed +[Back to constructors index](/API_docs/constructors/index.html) + + + +An embedded webpage + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|full\_width|[Bool](/API_docs/types/Bool.html) | Optional|Whether the block should be full width| +|allow\_scrolling|[Bool](/API_docs/types/Bool.html) | Optional|Whether scrolling should be allowed| +|url|[string](/API_docs/types/string.html) | Optional|Web page URL, if available| +|html|[string](/API_docs/types/string.html) | Optional|HTML-markup of the embedded page| +|poster\_photo\_id|[long](/API_docs/types/long.html) | Optional|Poster photo, if available| +|w|[int](/API_docs/types/int.html) | Optional|Block width, if known| +|h|[int](/API_docs/types/int.html) | Optional|Block height, if known| +|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockEmbed = ['_' => 'pageBlockEmbed', 'full_width' => Bool, 'allow_scrolling' => Bool, 'url' => 'string', 'html' => 'string', 'poster_photo_id' => long, 'w' => int, 'h' => int, 'caption' => PageCaption]; +``` diff --git a/docs/API_docs/constructors/pageBlockEmbedPost.md b/docs/API_docs/constructors/pageBlockEmbedPost.md new file mode 100644 index 0000000000..a463318bd6 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockEmbedPost.md @@ -0,0 +1,35 @@ +--- +title: "pageBlockEmbedPost" +description: "An embedded post" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockEmbedPost +[Back to constructors index](/API_docs/constructors/index.html) + + + +An embedded post + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Web page URL| +|webpage\_id|[long](/API_docs/types/long.html) | Yes|ID of generated webpage preview| +|author\_photo\_id|[long](/API_docs/types/long.html) | Yes|ID of the author's photo| +|author|[string](/API_docs/types/string.html) | Yes|Author name| +|date|[int](/API_docs/types/int.html) | Yes|Creation date| +|blocks|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Post contents| +|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockEmbedPost = ['_' => 'pageBlockEmbedPost', 'url' => 'string', 'webpage_id' => long, 'author_photo_id' => long, 'author' => 'string', 'date' => int, 'blocks' => [PageBlock, PageBlock], 'caption' => PageCaption]; +``` diff --git a/docs/API_docs/constructors/pageBlockFooter.md b/docs/API_docs/constructors/pageBlockFooter.md new file mode 100644 index 0000000000..95d00c22cf --- /dev/null +++ b/docs/API_docs/constructors/pageBlockFooter.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockFooter" +description: "Page footer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockFooter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Page footer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Contents| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockFooter = ['_' => 'pageBlockFooter', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/pageBlockHeader.md b/docs/API_docs/constructors/pageBlockHeader.md new file mode 100644 index 0000000000..77e68a4fc0 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockHeader.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockHeader" +description: "Page header" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockHeader +[Back to constructors index](/API_docs/constructors/index.html) + + + +Page header + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Contents| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockHeader = ['_' => 'pageBlockHeader', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/pageBlockKicker.md b/docs/API_docs/constructors/pageBlockKicker.md new file mode 100644 index 0000000000..ac1ca05bb3 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockKicker.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockKicker" +description: "Kicker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockKicker +[Back to constructors index](/API_docs/constructors/index.html) + + + +Kicker + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Contents| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockKicker = ['_' => 'pageBlockKicker', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/pageBlockList.md b/docs/API_docs/constructors/pageBlockList.md new file mode 100644 index 0000000000..08e5577667 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockList.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockList" +description: "Unordered list of IV blocks" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockList +[Back to constructors index](/API_docs/constructors/index.html) + + + +Unordered list of IV blocks + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|items|Array of [PageListItem](/API_docs/types/PageListItem.html) | Yes|List of blocks in an IV page| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockList = ['_' => 'pageBlockList', 'items' => [PageListItem, PageListItem]]; +``` diff --git a/docs/API_docs/constructors/pageBlockMap.md b/docs/API_docs/constructors/pageBlockMap.md new file mode 100644 index 0000000000..6ee0c18f7e --- /dev/null +++ b/docs/API_docs/constructors/pageBlockMap.md @@ -0,0 +1,33 @@ +--- +title: "pageBlockMap" +description: "A map" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockMap +[Back to constructors index](/API_docs/constructors/index.html) + + + +A map + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Location of the map center| +|zoom|[int](/API_docs/types/int.html) | Yes|Map zoom level; 13-20| +|w|[int](/API_docs/types/int.html) | Yes|Map width in pixels before applying scale; 16-102| +|h|[int](/API_docs/types/int.html) | Yes|Map height in pixels before applying scale; 16-1024| +|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockMap = ['_' => 'pageBlockMap', 'geo' => GeoPoint, 'zoom' => int, 'w' => int, 'h' => int, 'caption' => PageCaption]; +``` diff --git a/docs/API_docs/constructors/pageBlockOrderedList.md b/docs/API_docs/constructors/pageBlockOrderedList.md new file mode 100644 index 0000000000..6987aedef6 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockOrderedList.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockOrderedList" +description: "Ordered list of IV blocks" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockOrderedList +[Back to constructors index](/API_docs/constructors/index.html) + + + +Ordered list of IV blocks + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|items|Array of [PageListOrderedItem](/API_docs/types/PageListOrderedItem.html) | Yes|List items| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockOrderedList = ['_' => 'pageBlockOrderedList', 'items' => [PageListOrderedItem, PageListOrderedItem]]; +``` diff --git a/docs/API_docs/constructors/pageBlockParagraph.md b/docs/API_docs/constructors/pageBlockParagraph.md new file mode 100644 index 0000000000..081091f475 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockParagraph.md @@ -0,0 +1,29 @@ +--- +title: "pageBlockParagraph" +description: "A paragraph" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockParagraph +[Back to constructors index](/API_docs/constructors/index.html) + + + +A paragraph + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockParagraph = ['_' => 'pageBlockParagraph', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/pageBlockPhoto.md b/docs/API_docs/constructors/pageBlockPhoto.md new file mode 100644 index 0000000000..45134516dd --- /dev/null +++ b/docs/API_docs/constructors/pageBlockPhoto.md @@ -0,0 +1,32 @@ +--- +title: "pageBlockPhoto" +description: "A photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pageBlockPhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +A photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|photo\_id|[long](/API_docs/types/long.html) | Yes|Photo ID| +|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption| +|url|[string](/API_docs/types/string.html) | Optional|HTTP URL of page the photo leads to when clicked| +|webpage\_id|[long](/API_docs/types/long.html) | Optional|ID of preview of the page the photo leads to when clicked| + + + +### Type: [PageBlock](/API_docs/types/PageBlock.html) + + +### Example: + +``` +$pageBlockPhoto = ['_' => 'pageBlockPhoto', 'photo_id' => long, 'caption' => PageCaption, 'url' => 'string', 'webpage_id' => long]; +``` diff --git a/docs/API_docs/constructors/pageBlockPreformatted.md b/docs/API_docs/constructors/pageBlockPreformatted.md new file mode 100644 index 0000000000..3d21e62f80 --- /dev/null +++ b/docs/API_docs/constructors/pageBlockPreformatted.md @@ -0,0 +1,30 @@ +--- +title: "pageBlockPreformatted" +description: "Preformatted (
 text)"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockPreformatted  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Preformatted (`
` text)
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Text|
+|language|[string](/API_docs/types/string.html) | Yes|Programming language of preformatted text|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockPreformatted = ['_' => 'pageBlockPreformatted', 'text' => RichText, 'language' => 'string'];
+```  
diff --git a/docs/API_docs/constructors/pageBlockPullquote.md b/docs/API_docs/constructors/pageBlockPullquote.md
new file mode 100644
index 0000000000..e9c2238f2f
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockPullquote.md
@@ -0,0 +1,30 @@
+---
+title: "pageBlockPullquote"
+description: "Pullquote"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockPullquote  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Pullquote
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Text|
+|caption|[RichText](/API_docs/types/RichText.html) | Yes|Caption|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockPullquote = ['_' => 'pageBlockPullquote', 'text' => RichText, 'caption' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageBlockRelatedArticles.md b/docs/API_docs/constructors/pageBlockRelatedArticles.md
new file mode 100644
index 0000000000..b77f87586d
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockRelatedArticles.md
@@ -0,0 +1,30 @@
+---
+title: "pageBlockRelatedArticles"
+description: "Related articles"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockRelatedArticles  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Related articles
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|title|[RichText](/API_docs/types/RichText.html) | Yes|Title|
+|articles|Array of [PageRelatedArticle](/API_docs/types/PageRelatedArticle.html) | Yes|Related articles|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockRelatedArticles = ['_' => 'pageBlockRelatedArticles', 'title' => RichText, 'articles' => [PageRelatedArticle, PageRelatedArticle]];
+```  
diff --git a/docs/API_docs/constructors/pageBlockSlideshow.md b/docs/API_docs/constructors/pageBlockSlideshow.md
new file mode 100644
index 0000000000..c392dece4b
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockSlideshow.md
@@ -0,0 +1,30 @@
+---
+title: "pageBlockSlideshow"
+description: "Slideshow"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockSlideshow  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Slideshow
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|items|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Slideshow items|
+|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockSlideshow = ['_' => 'pageBlockSlideshow', 'items' => [PageBlock, PageBlock], 'caption' => PageCaption];
+```  
diff --git a/docs/API_docs/constructors/pageBlockSubheader.md b/docs/API_docs/constructors/pageBlockSubheader.md
new file mode 100644
index 0000000000..0d4c697d72
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockSubheader.md
@@ -0,0 +1,29 @@
+---
+title: "pageBlockSubheader"
+description: "Subheader"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockSubheader  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Subheader
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Subheader|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockSubheader = ['_' => 'pageBlockSubheader', 'text' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageBlockSubtitle.md b/docs/API_docs/constructors/pageBlockSubtitle.md
new file mode 100644
index 0000000000..d185f7089e
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockSubtitle.md
@@ -0,0 +1,29 @@
+---
+title: "pageBlockSubtitle"
+description: "Subtitle"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockSubtitle  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Subtitle
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Text|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockSubtitle = ['_' => 'pageBlockSubtitle', 'text' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageBlockTable.md b/docs/API_docs/constructors/pageBlockTable.md
new file mode 100644
index 0000000000..7b5cd3f4d1
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockTable.md
@@ -0,0 +1,32 @@
+---
+title: "pageBlockTable"
+description: "Table"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockTable  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Table
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|bordered|[Bool](/API_docs/types/Bool.html) | Optional|Does the table have a visible border?|
+|striped|[Bool](/API_docs/types/Bool.html) | Optional|Is the table striped?|
+|title|[RichText](/API_docs/types/RichText.html) | Yes|Title|
+|rows|Array of [PageTableRow](/API_docs/types/PageTableRow.html) | Yes|Table rows|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockTable = ['_' => 'pageBlockTable', 'bordered' => Bool, 'striped' => Bool, 'title' => RichText, 'rows' => [PageTableRow, PageTableRow]];
+```  
diff --git a/docs/API_docs/constructors/pageBlockTitle.md b/docs/API_docs/constructors/pageBlockTitle.md
new file mode 100644
index 0000000000..d2767f52ef
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockTitle.md
@@ -0,0 +1,29 @@
+---
+title: "pageBlockTitle"
+description: "Title"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockTitle  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Title
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Title|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockTitle = ['_' => 'pageBlockTitle', 'text' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageBlockUnsupported.md b/docs/API_docs/constructors/pageBlockUnsupported.md
new file mode 100644
index 0000000000..177c029704
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockUnsupported.md
@@ -0,0 +1,24 @@
+---
+title: "pageBlockUnsupported"
+description: "Unsupported IV element"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockUnsupported  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Unsupported IV element
+
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockUnsupported = ['_' => 'pageBlockUnsupported'];
+```  
diff --git a/docs/API_docs/constructors/pageBlockVideo.md b/docs/API_docs/constructors/pageBlockVideo.md
new file mode 100644
index 0000000000..f83152af16
--- /dev/null
+++ b/docs/API_docs/constructors/pageBlockVideo.md
@@ -0,0 +1,32 @@
+---
+title: "pageBlockVideo"
+description: "Video"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageBlockVideo  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Video
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|autoplay|[Bool](/API_docs/types/Bool.html) | Optional|Whether the video is set to autoplay|
+|loop|[Bool](/API_docs/types/Bool.html) | Optional|Whether the video is set to loop|
+|video\_id|[long](/API_docs/types/long.html) | Yes|Video ID|
+|caption|[PageCaption](/API_docs/types/PageCaption.html) | Yes|Caption|
+
+
+
+### Type: [PageBlock](/API_docs/types/PageBlock.html)
+
+
+### Example:
+
+```
+$pageBlockVideo = ['_' => 'pageBlockVideo', 'autoplay' => Bool, 'loop' => Bool, 'video_id' => long, 'caption' => PageCaption];
+```  
diff --git a/docs/API_docs/constructors/pageCaption.md b/docs/API_docs/constructors/pageCaption.md
new file mode 100644
index 0000000000..335d616de1
--- /dev/null
+++ b/docs/API_docs/constructors/pageCaption.md
@@ -0,0 +1,30 @@
+---
+title: "pageCaption"
+description: "Page caption"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageCaption  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Page caption
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Caption|
+|credit|[RichText](/API_docs/types/RichText.html) | Yes|Credits|
+
+
+
+### Type: [PageCaption](/API_docs/types/PageCaption.html)
+
+
+### Example:
+
+```
+$pageCaption = ['_' => 'pageCaption', 'text' => RichText, 'credit' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageListItemBlocks.md b/docs/API_docs/constructors/pageListItemBlocks.md
new file mode 100644
index 0000000000..d3b1c40314
--- /dev/null
+++ b/docs/API_docs/constructors/pageListItemBlocks.md
@@ -0,0 +1,29 @@
+---
+title: "pageListItemBlocks"
+description: "List item"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageListItemBlocks  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+List item
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|blocks|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Blocks|
+
+
+
+### Type: [PageListItem](/API_docs/types/PageListItem.html)
+
+
+### Example:
+
+```
+$pageListItemBlocks = ['_' => 'pageListItemBlocks', 'blocks' => [PageBlock, PageBlock]];
+```  
diff --git a/docs/API_docs/constructors/pageListItemText.md b/docs/API_docs/constructors/pageListItemText.md
new file mode 100644
index 0000000000..389d5ff766
--- /dev/null
+++ b/docs/API_docs/constructors/pageListItemText.md
@@ -0,0 +1,29 @@
+---
+title: "pageListItemText"
+description: "List item"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageListItemText  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+List item
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Text|
+
+
+
+### Type: [PageListItem](/API_docs/types/PageListItem.html)
+
+
+### Example:
+
+```
+$pageListItemText = ['_' => 'pageListItemText', 'text' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageListOrderedItemBlocks.md b/docs/API_docs/constructors/pageListOrderedItemBlocks.md
new file mode 100644
index 0000000000..3f8a34ef91
--- /dev/null
+++ b/docs/API_docs/constructors/pageListOrderedItemBlocks.md
@@ -0,0 +1,30 @@
+---
+title: "pageListOrderedItemBlocks"
+description: "Ordered list of IV blocks"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageListOrderedItemBlocks  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Ordered list of [IV](https://instantview.telegram.org) blocks
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|num|[string](/API_docs/types/string.html) | Yes|Number of element within ordered list|
+|blocks|Array of [PageBlock](/API_docs/types/PageBlock.html) | Yes|Item contents|
+
+
+
+### Type: [PageListOrderedItem](/API_docs/types/PageListOrderedItem.html)
+
+
+### Example:
+
+```
+$pageListOrderedItemBlocks = ['_' => 'pageListOrderedItemBlocks', 'num' => 'string', 'blocks' => [PageBlock, PageBlock]];
+```  
diff --git a/docs/API_docs/constructors/pageListOrderedItemText.md b/docs/API_docs/constructors/pageListOrderedItemText.md
new file mode 100644
index 0000000000..a3a77a9e08
--- /dev/null
+++ b/docs/API_docs/constructors/pageListOrderedItemText.md
@@ -0,0 +1,30 @@
+---
+title: "pageListOrderedItemText"
+description: "Ordered list of text items"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageListOrderedItemText  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Ordered list of text items
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|num|[string](/API_docs/types/string.html) | Yes|Number of element within ordered list|
+|text|[RichText](/API_docs/types/RichText.html) | Yes|Text|
+
+
+
+### Type: [PageListOrderedItem](/API_docs/types/PageListOrderedItem.html)
+
+
+### Example:
+
+```
+$pageListOrderedItemText = ['_' => 'pageListOrderedItemText', 'num' => 'string', 'text' => RichText];
+```  
diff --git a/docs/API_docs/constructors/pageRelatedArticle.md b/docs/API_docs/constructors/pageRelatedArticle.md
new file mode 100644
index 0000000000..130dfe998d
--- /dev/null
+++ b/docs/API_docs/constructors/pageRelatedArticle.md
@@ -0,0 +1,35 @@
+---
+title: "pageRelatedArticle"
+description: "Related article"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageRelatedArticle  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Related article
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|url|[string](/API_docs/types/string.html) | Yes|URL of article|
+|webpage\_id|[long](/API_docs/types/long.html) | Yes|Webpage ID of generated IV preview|
+|title|[string](/API_docs/types/string.html) | Optional|Title|
+|description|[string](/API_docs/types/string.html) | Optional|Description|
+|photo\_id|[long](/API_docs/types/long.html) | Optional|ID of preview photo|
+|author|[string](/API_docs/types/string.html) | Optional|Author name|
+|published\_date|[int](/API_docs/types/int.html) | Optional|Date of publication|
+
+
+
+### Type: [PageRelatedArticle](/API_docs/types/PageRelatedArticle.html)
+
+
+### Example:
+
+```
+$pageRelatedArticle = ['_' => 'pageRelatedArticle', 'url' => 'string', 'webpage_id' => long, 'title' => 'string', 'description' => 'string', 'photo_id' => long, 'author' => 'string', 'published_date' => int];
+```  
diff --git a/docs/API_docs/constructors/pageTableCell.md b/docs/API_docs/constructors/pageTableCell.md
new file mode 100644
index 0000000000..0b161eb93a
--- /dev/null
+++ b/docs/API_docs/constructors/pageTableCell.md
@@ -0,0 +1,36 @@
+---
+title: "pageTableCell"
+description: "Table cell"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageTableCell  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Table cell
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|header|[Bool](/API_docs/types/Bool.html) | Optional|Is this element part of the column header|
+|align\_center|[Bool](/API_docs/types/Bool.html) | Optional|Horizontally centered block|
+|align\_right|[Bool](/API_docs/types/Bool.html) | Optional|Right-aligned block|
+|valign\_middle|[Bool](/API_docs/types/Bool.html) | Optional|Vertically centered block|
+|valign\_bottom|[Bool](/API_docs/types/Bool.html) | Optional|Block vertically-aligned to the bottom|
+|text|[RichText](/API_docs/types/RichText.html) | Optional|Content|
+|colspan|[int](/API_docs/types/int.html) | Optional|For how many columns should this cell extend|
+|rowspan|[int](/API_docs/types/int.html) | Optional|For how many rows should this cell extend|
+
+
+
+### Type: [PageTableCell](/API_docs/types/PageTableCell.html)
+
+
+### Example:
+
+```
+$pageTableCell = ['_' => 'pageTableCell', 'header' => Bool, 'align_center' => Bool, 'align_right' => Bool, 'valign_middle' => Bool, 'valign_bottom' => Bool, 'text' => RichText, 'colspan' => int, 'rowspan' => int];
+```  
diff --git a/docs/API_docs/constructors/pageTableRow.md b/docs/API_docs/constructors/pageTableRow.md
new file mode 100644
index 0000000000..3ef974c71d
--- /dev/null
+++ b/docs/API_docs/constructors/pageTableRow.md
@@ -0,0 +1,29 @@
+---
+title: "pageTableRow"
+description: "Table row"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: pageTableRow  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Table row
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|cells|Array of [PageTableCell](/API_docs/types/PageTableCell.html) | Yes|Table cells|
+
+
+
+### Type: [PageTableRow](/API_docs/types/PageTableRow.html)
+
+
+### Example:
+
+```
+$pageTableRow = ['_' => 'pageTableRow', 'cells' => [PageTableCell, PageTableCell]];
+```  
diff --git a/docs/API_docs/constructors/passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow.md b/docs/API_docs/constructors/passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow.md
new file mode 100644
index 0000000000..b3a55fa223
--- /dev/null
+++ b/docs/API_docs/constructors/passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow.md
@@ -0,0 +1,32 @@
+---
+title: "passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow"
+description: "This key derivation algorithm defines that SRP 2FA login must be used"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+This key derivation algorithm defines that [SRP 2FA login](https://core.telegram.org/api/srp) must be used
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|salt1|[bytes](/API_docs/types/bytes.html) | Yes|One of two salts used by the derivation function (see [SRP 2FA login](https://core.telegram.org/api/srp))|
+|salt2|[bytes](/API_docs/types/bytes.html) | Yes|One of two salts used by the derivation function (see [SRP 2FA login](https://core.telegram.org/api/srp))|
+|g|[int](/API_docs/types/int.html) | Yes|Base (see [SRP 2FA login](https://core.telegram.org/api/srp))|
+|p|[bytes](/API_docs/types/bytes.html) | Yes|2048-bit modulus (see [SRP 2FA login](https://core.telegram.org/api/srp))|
+
+
+
+### Type: [PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html)
+
+
+### Example:
+
+```
+$passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow = ['_' => 'passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow', 'salt1' => 'bytes', 'salt2' => 'bytes', 'g' => int, 'p' => 'bytes'];
+```  
diff --git a/docs/API_docs/constructors/passwordKdfAlgoUnknown.md b/docs/API_docs/constructors/passwordKdfAlgoUnknown.md
new file mode 100644
index 0000000000..5ea3e5272b
--- /dev/null
+++ b/docs/API_docs/constructors/passwordKdfAlgoUnknown.md
@@ -0,0 +1,24 @@
+---
+title: "passwordKdfAlgoUnknown"
+description: "Unknown KDF (most likely, the client is outdated and does not support the specified KDF algorithm)"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: passwordKdfAlgoUnknown  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Unknown KDF (most likely, the client is outdated and does not support the specified KDF algorithm)
+
+
+
+
+### Type: [PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html)
+
+
+### Example:
+
+```
+$passwordKdfAlgoUnknown = ['_' => 'passwordKdfAlgoUnknown'];
+```  
diff --git a/docs/API_docs/constructors/paymentCharge.md b/docs/API_docs/constructors/paymentCharge.md
new file mode 100644
index 0000000000..ff5629fbcb
--- /dev/null
+++ b/docs/API_docs/constructors/paymentCharge.md
@@ -0,0 +1,30 @@
+---
+title: "paymentCharge"
+description: "Payment identifier"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: paymentCharge  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Payment identifier
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|id|[string](/API_docs/types/string.html) | Yes|Telegram payment identifier|
+|provider\_charge\_id|[string](/API_docs/types/string.html) | Yes|Provider payment identifier|
+
+
+
+### Type: [PaymentCharge](/API_docs/types/PaymentCharge.html)
+
+
+### Example:
+
+```
+$paymentCharge = ['_' => 'paymentCharge', 'id' => 'string', 'provider_charge_id' => 'string'];
+```  
diff --git a/docs/API_docs/constructors/paymentFormMethod.md b/docs/API_docs/constructors/paymentFormMethod.md
new file mode 100644
index 0000000000..414e3b579d
--- /dev/null
+++ b/docs/API_docs/constructors/paymentFormMethod.md
@@ -0,0 +1,30 @@
+---
+title: "paymentFormMethod"
+description: "Represents an additional payment method"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: paymentFormMethod  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Represents an additional payment method
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|url|[string](/API_docs/types/string.html) | Yes|URL to open in a webview to process the payment|
+|title|[string](/API_docs/types/string.html) | Yes|Payment method description|
+
+
+
+### Type: [PaymentFormMethod](/API_docs/types/PaymentFormMethod.html)
+
+
+### Example:
+
+```
+$paymentFormMethod = ['_' => 'paymentFormMethod', 'url' => 'string', 'title' => 'string'];
+```  
diff --git a/docs/API_docs/constructors/paymentRequestedInfo.md b/docs/API_docs/constructors/paymentRequestedInfo.md
new file mode 100644
index 0000000000..e504b74777
--- /dev/null
+++ b/docs/API_docs/constructors/paymentRequestedInfo.md
@@ -0,0 +1,32 @@
+---
+title: "paymentRequestedInfo"
+description: "Order info provided by the user"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: paymentRequestedInfo  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Order info provided by the user
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|name|[string](/API_docs/types/string.html) | Optional|User's full name|
+|phone|[string](/API_docs/types/string.html) | Optional|User's phone number|
+|email|[string](/API_docs/types/string.html) | Optional|User's email address|
+|shipping\_address|[PostAddress](/API_docs/types/PostAddress.html) | Optional|User's shipping address|
+
+
+
+### Type: [PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html)
+
+
+### Example:
+
+```
+$paymentRequestedInfo = ['_' => 'paymentRequestedInfo', 'name' => 'string', 'phone' => 'string', 'email' => 'string', 'shipping_address' => PostAddress];
+```  
diff --git a/docs/API_docs/constructors/paymentSavedCredentialsCard.md b/docs/API_docs/constructors/paymentSavedCredentialsCard.md
new file mode 100644
index 0000000000..33168d8daa
--- /dev/null
+++ b/docs/API_docs/constructors/paymentSavedCredentialsCard.md
@@ -0,0 +1,30 @@
+---
+title: "paymentSavedCredentialsCard"
+description: "Saved credit card"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+---
+# Constructor: paymentSavedCredentialsCard  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Saved credit card
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|id|[string](/API_docs/types/string.html) | Yes|Card ID|
+|title|[string](/API_docs/types/string.html) | Yes|Title|
+
+
+
+### Type: [PaymentSavedCredentials](/API_docs/types/PaymentSavedCredentials.html)
+
+
+### Example:
+
+```
+$paymentSavedCredentialsCard = ['_' => 'paymentSavedCredentialsCard', 'id' => 'string', 'title' => 'string'];
+```  
diff --git a/docs/API_docs/constructors/payments.bankCardData.md b/docs/API_docs/constructors/payments.bankCardData.md
new file mode 100644
index 0000000000..2463ed57dd
--- /dev/null
+++ b/docs/API_docs/constructors/payments.bankCardData.md
@@ -0,0 +1,31 @@
+---
+title: "payments.bankCardData"
+description: "Credit card info, provided by the card's bank(s)"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+redirect_from: /API_docs/constructors/payments_bankCardData.html
+---
+# Constructor: payments.bankCardData  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Credit card info, provided by the card's bank(s)
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|title|[string](/API_docs/types/string.html) | Yes|Credit card title|
+|open\_urls|Array of [BankCardOpenUrl](/API_docs/types/BankCardOpenUrl.html) | Yes|Info URL(s) provided by the card's bank(s)|
+
+
+
+### Type: [payments.BankCardData](/API_docs/types/payments.BankCardData.html)
+
+
+### Example:
+
+```
+$payments_bankCardData = ['_' => 'payments.bankCardData', 'title' => 'string', 'open_urls' => [BankCardOpenUrl, BankCardOpenUrl]];
+```  
diff --git a/docs/API_docs/constructors/payments.checkedGiftCode.md b/docs/API_docs/constructors/payments.checkedGiftCode.md
new file mode 100644
index 0000000000..c03305151c
--- /dev/null
+++ b/docs/API_docs/constructors/payments.checkedGiftCode.md
@@ -0,0 +1,38 @@
+---
+title: "payments.checkedGiftCode"
+description: "Contains info about a Telegram Premium giftcode link."
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+redirect_from: /API_docs/constructors/payments_checkedGiftCode.html
+---
+# Constructor: payments.checkedGiftCode  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Contains info about a [Telegram Premium giftcode link](https://core.telegram.org/api/links#premium-giftcode-links).
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|via\_giveaway|[Bool](/API_docs/types/Bool.html) | Optional|Whether this giftcode was created by a [giveaway](https://core.telegram.org/api/giveaways).|
+|from\_id|[Peer](/API_docs/types/Peer.html) | Optional|The peer that created the gift code.|
+|giveaway\_msg\_id|[int](/API_docs/types/int.html) | Optional|Message ID of the giveaway in the channel specified in `from_id`.|
+|to\_id|[long](/API_docs/types/long.html) | Optional|The destination user of the gift.|
+|date|[int](/API_docs/types/int.html) | Yes|Creation date of the gift code.|
+|months|[int](/API_docs/types/int.html) | Yes|Duration in months of the gifted [Telegram Premium](https://core.telegram.org/api/premium) subscription.|
+|used\_date|[int](/API_docs/types/int.html) | Optional|When was the giftcode imported, if it was imported.|
+|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats|
+|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users|
+
+
+
+### Type: [payments.CheckedGiftCode](/API_docs/types/payments.CheckedGiftCode.html)
+
+
+### Example:
+
+```
+$payments_checkedGiftCode = ['_' => 'payments.checkedGiftCode', 'via_giveaway' => Bool, 'from_id' => Peer, 'giveaway_msg_id' => int, 'to_id' => long, 'date' => int, 'months' => int, 'used_date' => int, 'chats' => [Chat, Chat], 'users' => [User, User]];
+```  
diff --git a/docs/API_docs/constructors/payments.exportedInvoice.md b/docs/API_docs/constructors/payments.exportedInvoice.md
new file mode 100644
index 0000000000..a225382a30
--- /dev/null
+++ b/docs/API_docs/constructors/payments.exportedInvoice.md
@@ -0,0 +1,30 @@
+---
+title: "payments.exportedInvoice"
+description: "Exported invoice deep link"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+redirect_from: /API_docs/constructors/payments_exportedInvoice.html
+---
+# Constructor: payments.exportedInvoice  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Exported [invoice deep link](https://core.telegram.org/api/links#invoice-links)
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|url|[string](/API_docs/types/string.html) | Yes|Exported [invoice deep link](https://core.telegram.org/api/links#invoice-links)|
+
+
+
+### Type: [payments.ExportedInvoice](/API_docs/types/payments.ExportedInvoice.html)
+
+
+### Example:
+
+```
+$payments_exportedInvoice = ['_' => 'payments.exportedInvoice', 'url' => 'string'];
+```  
diff --git a/docs/API_docs/constructors/payments.giveawayInfo.md b/docs/API_docs/constructors/payments.giveawayInfo.md
new file mode 100644
index 0000000000..b053e9b209
--- /dev/null
+++ b/docs/API_docs/constructors/payments.giveawayInfo.md
@@ -0,0 +1,37 @@
+---
+title: "payments.giveawayInfo"
+description: "Contains info about an ongoing giveaway."
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+redirect_from: /API_docs/constructors/payments_giveawayInfo.html
+---
+# Constructor: payments.giveawayInfo  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Contains info about an ongoing [giveaway](https://core.telegram.org/api/giveaways).
+
+If neither the `participating`, `joined_too_early_date`, `admin_disallowed_chat_id` or `disallowed_country` flags are set, the user is not currently participating in the giveaway but could participate by joining all the channels specified in the [messageMediaGiveaway](../constructors/messageMediaGiveaway.html).`channels` field.
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|participating|[Bool](/API_docs/types/Bool.html) | Optional|The current user is participating in the giveaway.|
+|preparing\_results|[Bool](/API_docs/types/Bool.html) | Optional|If set, the giveaway has ended and the results are being prepared.|
+|start\_date|[int](/API_docs/types/int.html) | Yes|When was the giveaway started|
+|joined\_too\_early\_date|[int](/API_docs/types/int.html) | Optional|The current user can't participate in the giveaway, because they were already a member of the channel when the giveaway started, and the `only_new_subscribers` was set when starting the giveaway.|
+|admin\_disallowed\_chat\_id|[long](/API_docs/types/long.html) | Optional|If set, the current user can't participate in the giveaway, because they are an administrator in one of the channels (ID specified in this flag) that created the giveaway.|
+|disallowed\_country|[string](/API_docs/types/string.html) | Optional|If set, the current user can't participate in this giveaway, because their phone number is from the specified disallowed country (specified as a two-letter ISO 3166-1 alpha-2 country code).|
+
+
+
+### Type: [payments.GiveawayInfo](/API_docs/types/payments.GiveawayInfo.html)
+
+
+### Example:
+
+```
+$payments_giveawayInfo = ['_' => 'payments.giveawayInfo', 'participating' => Bool, 'preparing_results' => Bool, 'start_date' => int, 'joined_too_early_date' => int, 'admin_disallowed_chat_id' => long, 'disallowed_country' => 'string'];
+```  
diff --git a/docs/API_docs/constructors/payments.giveawayInfoResults.md b/docs/API_docs/constructors/payments.giveawayInfoResults.md
new file mode 100644
index 0000000000..83f61a63a1
--- /dev/null
+++ b/docs/API_docs/constructors/payments.giveawayInfoResults.md
@@ -0,0 +1,36 @@
+---
+title: "payments.giveawayInfoResults"
+description: "A giveaway has ended."
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+redirect_from: /API_docs/constructors/payments_giveawayInfoResults.html
+---
+# Constructor: payments.giveawayInfoResults  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+A [giveaway](https://core.telegram.org/api/giveaways) has ended.
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|winner|[Bool](/API_docs/types/Bool.html) | Optional|Whether we're one of the winners of this giveaway.|
+|refunded|[Bool](/API_docs/types/Bool.html) | Optional|Whether the giveaway was canceled and was fully refunded.|
+|start\_date|[int](/API_docs/types/int.html) | Yes|Start date of the giveaway|
+|gift\_code\_slug|[string](/API_docs/types/string.html) | Optional|If we're one of the winners of this giveaway, contains the [Premium gift code](https://core.telegram.org/api/links#premium-giftcode-links), see [here »](https://core.telegram.org/api/giveaways) for more info on the full giveaway flow.|
+|finish\_date|[int](/API_docs/types/int.html) | Yes|End date of the giveaway. May be bigger than the end date specified in parameters of the giveaway.|
+|winners\_count|[int](/API_docs/types/int.html) | Yes|Number of winners in the giveaway|
+|activated\_count|[int](/API_docs/types/int.html) | Yes|Number of winners, which activated their [gift codes](https://core.telegram.org/api/links#premium-giftcode-links).|
+
+
+
+### Type: [payments.GiveawayInfo](/API_docs/types/payments.GiveawayInfo.html)
+
+
+### Example:
+
+```
+$payments_giveawayInfoResults = ['_' => 'payments.giveawayInfoResults', 'winner' => Bool, 'refunded' => Bool, 'start_date' => int, 'gift_code_slug' => 'string', 'finish_date' => int, 'winners_count' => int, 'activated_count' => int];
+```  
diff --git a/docs/API_docs/constructors/payments.paymentForm.md b/docs/API_docs/constructors/payments.paymentForm.md
new file mode 100644
index 0000000000..dba25d35c4
--- /dev/null
+++ b/docs/API_docs/constructors/payments.paymentForm.md
@@ -0,0 +1,45 @@
+---
+title: "payments.paymentForm"
+description: "Payment form"
+nav_exclude: true
+image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
+redirect_from: /API_docs/constructors/payments_paymentForm.html
+---
+# Constructor: payments.paymentForm  
+[Back to constructors index](/API_docs/constructors/index.html)
+
+
+
+Payment form
+
+### Attributes:
+
+| Name     |    Type       | Required | Description |
+|----------|---------------|----------|-------------|
+|can\_save\_credentials|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user can choose to save credentials.|
+|password\_missing|[Bool](/API_docs/types/Bool.html) | Optional|Indicates that the user can save payment credentials, but only after setting up a [2FA password](https://core.telegram.org/api/srp) (currently the account doesn't have a [2FA password](https://core.telegram.org/api/srp))|
+|form\_id|[long](/API_docs/types/long.html) | Yes|Form ID|
+|bot\_id|[long](/API_docs/types/long.html) | Yes|Bot ID|
+|title|[string](/API_docs/types/string.html) | Yes|Form title|
+|description|[string](/API_docs/types/string.html) | Yes|Description|
+|photo|[WebDocument](/API_docs/types/WebDocument.html) | Optional|Product photo|
+|invoice|[Invoice](/API_docs/types/Invoice.html) | Yes|Invoice|
+|provider\_id|[long](/API_docs/types/long.html) | Yes|Payment provider ID.|
+|url|[string](/API_docs/types/string.html) | Yes|Payment form URL|
+|native\_provider|[string](/API_docs/types/string.html) | Optional|Payment provider name.
One of the following:
\- `stripe`| +|native\_params|[DataJSON](/API_docs/types/DataJSON.html) | Optional|Contains information about the payment provider, if available, to support it natively without the need for opening the URL.
A JSON object that can contain the following fields:

\- `apple_pay_merchant_id`: Apple Pay merchant ID
\- `google_pay_public_key`: Google Pay public key
\- `need_country`: True, if the user country must be provided,
\- `need_zip`: True, if the user ZIP/postal code must be provided,
\- `need_cardholder_name`: True, if the cardholder name must be provided
| +|additional\_methods|Array of [PaymentFormMethod](/API_docs/types/PaymentFormMethod.html) | Optional|Additional payment methods| +|saved\_info|[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) | Optional|Saved server-side order information| +|saved\_credentials|Array of [PaymentSavedCredentials](/API_docs/types/PaymentSavedCredentials.html) | Optional|Contains information about saved card credentials| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [payments.PaymentForm](/API_docs/types/payments.PaymentForm.html) + + +### Example: + +``` +$payments_paymentForm = ['_' => 'payments.paymentForm', 'can_save_credentials' => Bool, 'password_missing' => Bool, 'form_id' => long, 'bot_id' => long, 'title' => 'string', 'description' => 'string', 'photo' => WebDocument, 'invoice' => Invoice, 'provider_id' => long, 'url' => 'string', 'native_provider' => 'string', 'native_params' => DataJSON, 'additional_methods' => [PaymentFormMethod, PaymentFormMethod], 'saved_info' => PaymentRequestedInfo, 'saved_credentials' => [PaymentSavedCredentials, PaymentSavedCredentials], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/payments.paymentReceipt.md b/docs/API_docs/constructors/payments.paymentReceipt.md new file mode 100644 index 0000000000..670712c90c --- /dev/null +++ b/docs/API_docs/constructors/payments.paymentReceipt.md @@ -0,0 +1,43 @@ +--- +title: "payments.paymentReceipt" +description: "Receipt" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/payments_paymentReceipt.html +--- +# Constructor: payments.paymentReceipt +[Back to constructors index](/API_docs/constructors/index.html) + + + +Receipt + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|date|[int](/API_docs/types/int.html) | Yes|Date of generation| +|bot\_id|[long](/API_docs/types/long.html) | Yes|Bot ID| +|provider\_id|[long](/API_docs/types/long.html) | Yes|Provider ID| +|title|[string](/API_docs/types/string.html) | Yes|Title| +|description|[string](/API_docs/types/string.html) | Yes|Description| +|photo|[WebDocument](/API_docs/types/WebDocument.html) | Optional|Photo| +|invoice|[Invoice](/API_docs/types/Invoice.html) | Yes|Invoice| +|info|[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) | Optional|Info| +|shipping|[ShippingOption](/API_docs/types/ShippingOption.html) | Optional|Selected shipping option| +|tip\_amount|[long](/API_docs/types/long.html) | Optional|Tipped amount| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|total\_amount|[long](/API_docs/types/long.html) | Yes|Total amount in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|credentials\_title|[string](/API_docs/types/string.html) | Yes|Payment credential name| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [payments.PaymentReceipt](/API_docs/types/payments.PaymentReceipt.html) + + +### Example: + +``` +$payments_paymentReceipt = ['_' => 'payments.paymentReceipt', 'date' => int, 'bot_id' => long, 'provider_id' => long, 'title' => 'string', 'description' => 'string', 'photo' => WebDocument, 'invoice' => Invoice, 'info' => PaymentRequestedInfo, 'shipping' => ShippingOption, 'tip_amount' => long, 'currency' => 'string', 'total_amount' => long, 'credentials_title' => 'string', 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/payments.paymentResult.md b/docs/API_docs/constructors/payments.paymentResult.md new file mode 100644 index 0000000000..bd01d10907 --- /dev/null +++ b/docs/API_docs/constructors/payments.paymentResult.md @@ -0,0 +1,30 @@ +--- +title: "payments.paymentResult" +description: "Payment result" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/payments_paymentResult.html +--- +# Constructor: payments.paymentResult +[Back to constructors index](/API_docs/constructors/index.html) + + + +Payment result + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|updates|[Updates](/API_docs/types/Updates.html) | Yes|Info about the payment| + + + +### Type: [payments.PaymentResult](/API_docs/types/payments.PaymentResult.html) + + +### Example: + +``` +$payments_paymentResult = ['_' => 'payments.paymentResult', 'updates' => Updates]; +``` diff --git a/docs/API_docs/constructors/payments.paymentVerificationNeeded.md b/docs/API_docs/constructors/payments.paymentVerificationNeeded.md new file mode 100644 index 0000000000..b9b3eb89aa --- /dev/null +++ b/docs/API_docs/constructors/payments.paymentVerificationNeeded.md @@ -0,0 +1,30 @@ +--- +title: "payments.paymentVerificationNeeded" +description: "Payment was not successful, additional verification is needed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/payments_paymentVerificationNeeded.html +--- +# Constructor: payments.paymentVerificationNeeded +[Back to constructors index](/API_docs/constructors/index.html) + + + +Payment was not successful, additional verification is needed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|URL for additional payment credentials verification| + + + +### Type: [payments.PaymentResult](/API_docs/types/payments.PaymentResult.html) + + +### Example: + +``` +$payments_paymentVerificationNeeded = ['_' => 'payments.paymentVerificationNeeded', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/payments.savedInfo.md b/docs/API_docs/constructors/payments.savedInfo.md new file mode 100644 index 0000000000..c2b9270995 --- /dev/null +++ b/docs/API_docs/constructors/payments.savedInfo.md @@ -0,0 +1,31 @@ +--- +title: "payments.savedInfo" +description: "Saved server-side order information" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/payments_savedInfo.html +--- +# Constructor: payments.savedInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Saved server-side order information + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_saved\_credentials|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user has some saved payment credentials| +|saved\_info|[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) | Optional|Saved server-side order information| + + + +### Type: [payments.SavedInfo](/API_docs/types/payments.SavedInfo.html) + + +### Example: + +``` +$payments_savedInfo = ['_' => 'payments.savedInfo', 'has_saved_credentials' => Bool, 'saved_info' => PaymentRequestedInfo]; +``` diff --git a/docs/API_docs/constructors/payments.validatedRequestedInfo.md b/docs/API_docs/constructors/payments.validatedRequestedInfo.md new file mode 100644 index 0000000000..e14c0495d6 --- /dev/null +++ b/docs/API_docs/constructors/payments.validatedRequestedInfo.md @@ -0,0 +1,31 @@ +--- +title: "payments.validatedRequestedInfo" +description: "Validated user-provided info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/payments_validatedRequestedInfo.html +--- +# Constructor: payments.validatedRequestedInfo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Validated user-provided info + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Optional|ID| +|shipping\_options|Array of [ShippingOption](/API_docs/types/ShippingOption.html) | Optional|Shipping options| + + + +### Type: [payments.ValidatedRequestedInfo](/API_docs/types/payments.ValidatedRequestedInfo.html) + + +### Example: + +``` +$payments_validatedRequestedInfo = ['_' => 'payments.validatedRequestedInfo', 'id' => 'string', 'shipping_options' => [ShippingOption, ShippingOption]]; +``` diff --git a/docs/API_docs/constructors/peerBlocked.md b/docs/API_docs/constructors/peerBlocked.md new file mode 100644 index 0000000000..4791141bc1 --- /dev/null +++ b/docs/API_docs/constructors/peerBlocked.md @@ -0,0 +1,30 @@ +--- +title: "peerBlocked" +description: "Information about a blocked peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerBlocked +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about a blocked peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|Peer ID| +|date|[int](/API_docs/types/int.html) | Yes|When was the peer blocked| + + + +### Type: [PeerBlocked](/API_docs/types/PeerBlocked.html) + + +### Example: + +``` +$peerBlocked = ['_' => 'peerBlocked', 'peer_id' => Peer, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/peerChannel.md b/docs/API_docs/constructors/peerChannel.md new file mode 100644 index 0000000000..2c29899495 --- /dev/null +++ b/docs/API_docs/constructors/peerChannel.md @@ -0,0 +1,29 @@ +--- +title: "peerChannel" +description: "Channel/supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +Channel/supergroup + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| + + + +### Type: [Peer](/API_docs/types/Peer.html) + + +### Example: + +``` +$peerChannel = ['_' => 'peerChannel', 'channel_id' => long]; +``` diff --git a/docs/API_docs/constructors/peerChat.md b/docs/API_docs/constructors/peerChat.md new file mode 100644 index 0000000000..c3de55e551 --- /dev/null +++ b/docs/API_docs/constructors/peerChat.md @@ -0,0 +1,29 @@ +--- +title: "peerChat" +description: "Group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Group. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Group identifier| + + + +### Type: [Peer](/API_docs/types/Peer.html) + + +### Example: + +``` +$peerChat = ['_' => 'peerChat', 'chat_id' => long]; +``` diff --git a/docs/API_docs/constructors/peerColor.md b/docs/API_docs/constructors/peerColor.md new file mode 100644 index 0000000000..e152638259 --- /dev/null +++ b/docs/API_docs/constructors/peerColor.md @@ -0,0 +1,30 @@ +--- +title: "peerColor" +description: "Represents a color palette »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerColor +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [color palette »](https://core.telegram.org/api/colors). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|color|[int](/API_docs/types/int.html) | Optional|[Color palette ID, see here »](https://core.telegram.org/api/colors) for more info; if not set, the default palette should be used.| +|background\_emoji\_id|[long](/API_docs/types/long.html) | Optional|Optional [custom emoji ID](https://core.telegram.org/api/custom-emoji) used to generate the pattern.| + + + +### Type: [PeerColor](/API_docs/types/PeerColor.html) + + +### Example: + +``` +$peerColor = ['_' => 'peerColor', 'color' => int, 'background_emoji_id' => long]; +``` diff --git a/docs/API_docs/constructors/peerLocated.md b/docs/API_docs/constructors/peerLocated.md new file mode 100644 index 0000000000..47b8bb2c18 --- /dev/null +++ b/docs/API_docs/constructors/peerLocated.md @@ -0,0 +1,31 @@ +--- +title: "peerLocated" +description: "Peer geolocated nearby" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerLocated +[Back to constructors index](/API_docs/constructors/index.html) + + + +Peer geolocated nearby + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|expires|[int](/API_docs/types/int.html) | Yes|Validity period of current data| +|distance|[int](/API_docs/types/int.html) | Yes|Distance from the peer in meters| + + + +### Type: [PeerLocated](/API_docs/types/PeerLocated.html) + + +### Example: + +``` +$peerLocated = ['_' => 'peerLocated', 'peer' => long, 'expires' => int, 'distance' => int]; +``` diff --git a/docs/API_docs/constructors/peerNotifySettings.md b/docs/API_docs/constructors/peerNotifySettings.md new file mode 100644 index 0000000000..e16999f34a --- /dev/null +++ b/docs/API_docs/constructors/peerNotifySettings.md @@ -0,0 +1,39 @@ +--- +title: "peerNotifySettings" +description: "Notification settings." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerNotifySettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notification settings. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|show\_previews|[Bool](/API_docs/types/Bool.html) | Optional|(Ternary value) If set, indicates whether or not to display previews of messages in notifications; otherwise the default behavior should be used.| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|(Ternary value) If set, indicates whether to mute or unmute the peer; otherwise the default behavior should be used.| +|mute\_until|[int](/API_docs/types/int.html) | Optional|Mute all notifications until this date| +|ios\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Notification sound for the official iOS application| +|android\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Notification sound for the official android application| +|other\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Notification sound for other applications| +|stories\_muted|[Bool](/API_docs/types/Bool.html) | Optional|Whether story notifications should be disabled.| +|stories\_hide\_sender|[Bool](/API_docs/types/Bool.html) | Optional|Whether the sender name should be displayed in story notifications.| +|stories\_ios\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Sound for story notifications on the official iOS application| +|stories\_android\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Sound for story notifications on the official Android application| +|stories\_other\_sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Optional|Sound for story notifications on other applications| + + + +### Type: [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) + + +### Example: + +``` +$peerNotifySettings = ['_' => 'peerNotifySettings', 'show_previews' => Bool, 'silent' => Bool, 'mute_until' => int, 'ios_sound' => NotificationSound, 'android_sound' => NotificationSound, 'other_sound' => NotificationSound, 'stories_muted' => Bool, 'stories_hide_sender' => Bool, 'stories_ios_sound' => NotificationSound, 'stories_android_sound' => NotificationSound, 'stories_other_sound' => NotificationSound]; +``` diff --git a/docs/API_docs/constructors/peerSelfLocated.md b/docs/API_docs/constructors/peerSelfLocated.md new file mode 100644 index 0000000000..5e93dd3bcd --- /dev/null +++ b/docs/API_docs/constructors/peerSelfLocated.md @@ -0,0 +1,29 @@ +--- +title: "peerSelfLocated" +description: "Current peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerSelfLocated +[Back to constructors index](/API_docs/constructors/index.html) + + + +Current peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|expires|[int](/API_docs/types/int.html) | Yes|Expiry of geolocation info for current peer| + + + +### Type: [PeerLocated](/API_docs/types/PeerLocated.html) + + +### Example: + +``` +$peerSelfLocated = ['_' => 'peerSelfLocated', 'expires' => int]; +``` diff --git a/docs/API_docs/constructors/peerSettings.md b/docs/API_docs/constructors/peerSettings.md new file mode 100644 index 0000000000..0cebef7e53 --- /dev/null +++ b/docs/API_docs/constructors/peerSettings.md @@ -0,0 +1,44 @@ +--- +title: "peerSettings" +description: "List of actions that are possible when interacting with this user, to be shown as suggested actions in the chat action bar », see here » for more info." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of actions that are possible when interacting with this user, to be shown as suggested actions in the [chat action bar »](https://core.telegram.org/api/action-bar), see [here »](https://core.telegram.org/api/action-bar) for more info. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|report\_spam|[Bool](/API_docs/types/Bool.html) | Optional|Whether we can still report the user for spam| +|add\_contact|[Bool](/API_docs/types/Bool.html) | Optional|Whether we can add the user as contact| +|block\_contact|[Bool](/API_docs/types/Bool.html) | Optional|Whether we can block the user| +|share\_contact|[Bool](/API_docs/types/Bool.html) | Optional|Whether we can share the user's contact| +|need\_contacts\_exception|[Bool](/API_docs/types/Bool.html) | Optional|Whether a special exception for contacts is needed| +|report\_geo|[Bool](/API_docs/types/Bool.html) | Optional|Whether we can report a geogroup as irrelevant for this location| +|autoarchived|[Bool](/API_docs/types/Bool.html) | Optional|Whether this peer was automatically archived according to [privacy settings](../constructors/globalPrivacySettings.html) and can be unarchived| +|invite\_members|[Bool](/API_docs/types/Bool.html) | Optional|If set, this is a recently created group chat to which new members can be invited| +|request\_chat\_broadcast|[Bool](/API_docs/types/Bool.html) | Optional|This flag is set if `request_chat_title` and `request_chat_date` fields are set and the [join request »](https://core.telegram.org/api/invites#join-requests) is related to a channel (otherwise if only the request fields are set, the [join request »](https://core.telegram.org/api/invites#join-requests) is related to a chat).| +|business\_bot\_paused|[Bool](/API_docs/types/Bool.html) | Optional| +|business\_bot\_can\_reply|[Bool](/API_docs/types/Bool.html) | Optional| +|geo\_distance|[int](/API_docs/types/int.html) | Optional|Distance in meters between us and this peer| +|request\_chat\_title|[string](/API_docs/types/string.html) | Optional|If set, this is a private chat with an administrator of a chat or channel to which the user sent a join request, and this field contains the chat/channel's title.| +|request\_chat\_date|[int](/API_docs/types/int.html) | Optional|If set, this is a private chat with an administrator of a chat or channel to which the user sent a join request, and this field contains the timestamp when the [join request »](https://core.telegram.org/api/invites#join-requests) was sent.| +|business\_bot\_id|[long](/API_docs/types/long.html) | Optional| +|business\_bot\_manage\_url|[string](/API_docs/types/string.html) | Optional| + + + +### Type: [PeerSettings](/API_docs/types/PeerSettings.html) + + +### Example: + +``` +$peerSettings = ['_' => 'peerSettings', 'report_spam' => Bool, 'add_contact' => Bool, 'block_contact' => Bool, 'share_contact' => Bool, 'need_contacts_exception' => Bool, 'report_geo' => Bool, 'autoarchived' => Bool, 'invite_members' => Bool, 'request_chat_broadcast' => Bool, 'business_bot_paused' => Bool, 'business_bot_can_reply' => Bool, 'geo_distance' => int, 'request_chat_title' => 'string', 'request_chat_date' => int, 'business_bot_id' => long, 'business_bot_manage_url' => 'string']; +``` diff --git a/docs/API_docs/constructors/peerStories.md b/docs/API_docs/constructors/peerStories.md new file mode 100644 index 0000000000..7a062ff98d --- /dev/null +++ b/docs/API_docs/constructors/peerStories.md @@ -0,0 +1,31 @@ +--- +title: "peerStories" +description: "Stories associated to a peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerStories +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Stories](https://core.telegram.org/api/stories) associated to a peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer| +|max\_read\_id|[int](/API_docs/types/int.html) | Optional|If set, contains the ID of the maximum read story| +|stories|Array of [StoryItem](/API_docs/types/StoryItem.html) | Yes|Stories| + + + +### Type: [PeerStories](/API_docs/types/PeerStories.html) + + +### Example: + +``` +$peerStories = ['_' => 'peerStories', 'peer' => long, 'max_read_id' => int, 'stories' => [StoryItem, StoryItem]]; +``` diff --git a/docs/API_docs/constructors/peerUser.md b/docs/API_docs/constructors/peerUser.md new file mode 100644 index 0000000000..86036d76e4 --- /dev/null +++ b/docs/API_docs/constructors/peerUser.md @@ -0,0 +1,29 @@ +--- +title: "peerUser" +description: "Chat partner" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: peerUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat partner + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| + + + +### Type: [Peer](/API_docs/types/Peer.html) + + +### Example: + +``` +$peerUser = ['_' => 'peerUser', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/phone.exportedGroupCallInvite.md b/docs/API_docs/constructors/phone.exportedGroupCallInvite.md new file mode 100644 index 0000000000..9a295f4c69 --- /dev/null +++ b/docs/API_docs/constructors/phone.exportedGroupCallInvite.md @@ -0,0 +1,30 @@ +--- +title: "phone.exportedGroupCallInvite" +description: "An invite to a group call or livestream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_exportedGroupCallInvite.html +--- +# Constructor: phone.exportedGroupCallInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +An invite to a group call or livestream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|link|[string](/API_docs/types/string.html) | Yes|Invite link| + + + +### Type: [phone.ExportedGroupCallInvite](/API_docs/types/phone.ExportedGroupCallInvite.html) + + +### Example: + +``` +$phone_exportedGroupCallInvite = ['_' => 'phone.exportedGroupCallInvite', 'link' => 'string']; +``` diff --git a/docs/API_docs/constructors/phone.groupCall.md b/docs/API_docs/constructors/phone.groupCall.md new file mode 100644 index 0000000000..b68cae0b52 --- /dev/null +++ b/docs/API_docs/constructors/phone.groupCall.md @@ -0,0 +1,34 @@ +--- +title: "phone.groupCall" +description: "Contains info about a group call, and partial info about its participants." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_groupCall.html +--- +# Constructor: phone.groupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a group call, and partial info about its participants. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[GroupCall](/API_docs/types/GroupCall.html) | Yes|Info about the group call| +|participants|Array of [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) | Yes|A partial list of participants.| +|participants\_next\_offset|[string](/API_docs/types/string.html) | Yes|Next offset to use when fetching the remaining participants using [phone.getGroupParticipants](../methods/phone.getGroupParticipants.html)| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in the participants vector| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the participants vector| + + + +### Type: [phone.GroupCall](/API_docs/types/phone.GroupCall.html) + + +### Example: + +``` +$phone_groupCall = ['_' => 'phone.groupCall', 'call' => GroupCall, 'participants' => [GroupCallParticipant, GroupCallParticipant], 'participants_next_offset' => 'string', 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/phone.groupCallStreamChannels.md b/docs/API_docs/constructors/phone.groupCallStreamChannels.md new file mode 100644 index 0000000000..581fec43b1 --- /dev/null +++ b/docs/API_docs/constructors/phone.groupCallStreamChannels.md @@ -0,0 +1,30 @@ +--- +title: "phone.groupCallStreamChannels" +description: "Info about RTMP streams in a group call or livestream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_groupCallStreamChannels.html +--- +# Constructor: phone.groupCallStreamChannels +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about RTMP streams in a group call or livestream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channels|Array of [GroupCallStreamChannel](/API_docs/types/GroupCallStreamChannel.html) | Yes|RTMP streams| + + + +### Type: [phone.GroupCallStreamChannels](/API_docs/types/phone.GroupCallStreamChannels.html) + + +### Example: + +``` +$phone_groupCallStreamChannels = ['_' => 'phone.groupCallStreamChannels', 'channels' => [GroupCallStreamChannel, GroupCallStreamChannel]]; +``` diff --git a/docs/API_docs/constructors/phone.groupCallStreamRtmpUrl.md b/docs/API_docs/constructors/phone.groupCallStreamRtmpUrl.md new file mode 100644 index 0000000000..08a566207d --- /dev/null +++ b/docs/API_docs/constructors/phone.groupCallStreamRtmpUrl.md @@ -0,0 +1,31 @@ +--- +title: "phone.groupCallStreamRtmpUrl" +description: "RTMP URL and stream key to be used in streaming software" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_groupCallStreamRtmpUrl.html +--- +# Constructor: phone.groupCallStreamRtmpUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +RTMP URL and stream key to be used in streaming software + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|RTMP URL| +|key|[string](/API_docs/types/string.html) | Yes|Stream key| + + + +### Type: [phone.GroupCallStreamRtmpUrl](/API_docs/types/phone.GroupCallStreamRtmpUrl.html) + + +### Example: + +``` +$phone_groupCallStreamRtmpUrl = ['_' => 'phone.groupCallStreamRtmpUrl', 'url' => 'string', 'key' => 'string']; +``` diff --git a/docs/API_docs/constructors/phone.groupParticipants.md b/docs/API_docs/constructors/phone.groupParticipants.md new file mode 100644 index 0000000000..7216ec7129 --- /dev/null +++ b/docs/API_docs/constructors/phone.groupParticipants.md @@ -0,0 +1,35 @@ +--- +title: "phone.groupParticipants" +description: "Info about the participants of a group call or livestream" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_groupParticipants.html +--- +# Constructor: phone.groupParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about the participants of a group call or livestream + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Number of participants| +|participants|Array of [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) | Yes|List of participants| +|next\_offset|[string](/API_docs/types/string.html) | Yes|If not empty, the specified list of participants is partial, and more participants can be fetched specifying this parameter as `offset` in [phone.getGroupParticipants](../methods/phone.getGroupParticipants.html).| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| +|version|[int](/API_docs/types/int.html) | Yes|Version info| + + + +### Type: [phone.GroupParticipants](/API_docs/types/phone.GroupParticipants.html) + + +### Example: + +``` +$phone_groupParticipants = ['_' => 'phone.groupParticipants', 'count' => int, 'participants' => [GroupCallParticipant, GroupCallParticipant], 'next_offset' => 'string', 'chats' => [Chat, Chat], 'users' => [User, User], 'version' => int]; +``` diff --git a/docs/API_docs/constructors/phone.joinAsPeers.md b/docs/API_docs/constructors/phone.joinAsPeers.md new file mode 100644 index 0000000000..613218ad84 --- /dev/null +++ b/docs/API_docs/constructors/phone.joinAsPeers.md @@ -0,0 +1,32 @@ +--- +title: "phone.joinAsPeers" +description: "A list of peers that can be used to join a group call, presenting yourself as a specific user/channel." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_joinAsPeers.html +--- +# Constructor: phone.joinAsPeers +[Back to constructors index](/API_docs/constructors/index.html) + + + +A list of peers that can be used to join a group call, presenting yourself as a specific user/channel. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peers|Array of [Peer](/API_docs/types/Peer.html) | Yes|Peers| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats mentioned in the peers vector| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users mentioned in the peers vector| + + + +### Type: [phone.JoinAsPeers](/API_docs/types/phone.JoinAsPeers.html) + + +### Example: + +``` +$phone_joinAsPeers = ['_' => 'phone.joinAsPeers', 'peers' => [Peer, Peer], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/phone.phoneCall.md b/docs/API_docs/constructors/phone.phoneCall.md new file mode 100644 index 0000000000..ef9049ee34 --- /dev/null +++ b/docs/API_docs/constructors/phone.phoneCall.md @@ -0,0 +1,31 @@ +--- +title: "phone.phoneCall" +description: "A VoIP phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/phone_phoneCall.html +--- +# Constructor: phone.phoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +A VoIP phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_call|[PhoneCall](/API_docs/types/PhoneCall.html) | Optional|The VoIP phone call| +|users|Array of [User](/API_docs/types/User.html) | Yes|VoIP phone call participants| + + + +### Type: [phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + + +### Example: + +``` +$phone_phoneCall = ['_' => 'phone.phoneCall', 'phone_call' => PhoneCall, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/phoneCall.md b/docs/API_docs/constructors/phoneCall.md new file mode 100644 index 0000000000..2e10c2c3de --- /dev/null +++ b/docs/API_docs/constructors/phoneCall.md @@ -0,0 +1,41 @@ +--- +title: "phoneCall" +description: "Phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|p2p\_allowed|[Bool](/API_docs/types/Bool.html) | Optional|Whether P2P connection to the other peer is allowed| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a video call| +|id|[long](/API_docs/types/long.html) | Yes|Call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|date|[int](/API_docs/types/int.html) | Yes|Date of creation of the call| +|admin\_id|[long](/API_docs/types/long.html) | Yes|User ID of the creator of the call| +|participant\_id|[long](/API_docs/types/long.html) | Yes|User ID of the other participant in the call| +|g\_a\_or\_b|[bytes](/API_docs/types/bytes.html) | Yes|[Parameter for key exchange](https://core.telegram.org/api/end-to-end/voice-calls)| +|key\_fingerprint|[long](/API_docs/types/long.html) | Yes|[Key fingerprint](https://core.telegram.org/api/end-to-end/voice-calls)| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Yes|Call protocol info to be passed to libtgvoip| +|connections|Array of [PhoneConnection](/API_docs/types/PhoneConnection.html) | Yes|List of endpoints the user can connect to to exchange call data| +|start\_date|[int](/API_docs/types/int.html) | Yes|When was the call actually started| +|custom\_parameters|[DataJSON](/API_docs/types/DataJSON.html) | Optional| + + + +### Type: [PhoneCall](/API_docs/types/PhoneCall.html) + + +### Example: + +``` +$phoneCall = ['_' => 'phoneCall', 'p2p_allowed' => Bool, 'video' => Bool, 'id' => long, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long, 'g_a_or_b' => 'bytes', 'key_fingerprint' => long, 'protocol' => PhoneCallProtocol, 'connections' => [PhoneConnection, PhoneConnection], 'start_date' => int, 'custom_parameters' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/phoneCallAccepted.md b/docs/API_docs/constructors/phoneCallAccepted.md new file mode 100644 index 0000000000..b485a8626c --- /dev/null +++ b/docs/API_docs/constructors/phoneCallAccepted.md @@ -0,0 +1,36 @@ +--- +title: "phoneCallAccepted" +description: "An accepted phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallAccepted +[Back to constructors index](/API_docs/constructors/index.html) + + + +An accepted phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a video call| +|id|[long](/API_docs/types/long.html) | Yes|ID of accepted phone call| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash of phone call| +|date|[int](/API_docs/types/int.html) | Yes|When was the call accepted| +|admin\_id|[long](/API_docs/types/long.html) | Yes|ID of the call creator| +|participant\_id|[long](/API_docs/types/long.html) | Yes|ID of the other user in the call| +|g\_b|[bytes](/API_docs/types/bytes.html) | Yes|B parameter for [secure E2E phone call key exchange](https://core.telegram.org/api/end-to-end/voice-calls)| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Yes|Protocol to use for phone call| + + + +### Type: [PhoneCall](/API_docs/types/PhoneCall.html) + + +### Example: + +``` +$phoneCallAccepted = ['_' => 'phoneCallAccepted', 'video' => Bool, 'id' => long, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long, 'g_b' => 'bytes', 'protocol' => PhoneCallProtocol]; +``` diff --git a/docs/API_docs/constructors/phoneCallDiscardReasonBusy.md b/docs/API_docs/constructors/phoneCallDiscardReasonBusy.md new file mode 100644 index 0000000000..48aafccc6f --- /dev/null +++ b/docs/API_docs/constructors/phoneCallDiscardReasonBusy.md @@ -0,0 +1,24 @@ +--- +title: "phoneCallDiscardReasonBusy" +description: "The phone call was discarded because the user is busy in another call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallDiscardReasonBusy +[Back to constructors index](/API_docs/constructors/index.html) + + + +The phone call was discarded because the user is busy in another call + + + + +### Type: [PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) + + +### Example: + +``` +$phoneCallDiscardReasonBusy = ['_' => 'phoneCallDiscardReasonBusy']; +``` diff --git a/docs/API_docs/constructors/phoneCallDiscardReasonDisconnect.md b/docs/API_docs/constructors/phoneCallDiscardReasonDisconnect.md new file mode 100644 index 0000000000..e539b9ca27 --- /dev/null +++ b/docs/API_docs/constructors/phoneCallDiscardReasonDisconnect.md @@ -0,0 +1,24 @@ +--- +title: "phoneCallDiscardReasonDisconnect" +description: "The phone call was disconnected" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallDiscardReasonDisconnect +[Back to constructors index](/API_docs/constructors/index.html) + + + +The phone call was disconnected + + + + +### Type: [PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) + + +### Example: + +``` +$phoneCallDiscardReasonDisconnect = ['_' => 'phoneCallDiscardReasonDisconnect']; +``` diff --git a/docs/API_docs/constructors/phoneCallDiscardReasonHangup.md b/docs/API_docs/constructors/phoneCallDiscardReasonHangup.md new file mode 100644 index 0000000000..988131da54 --- /dev/null +++ b/docs/API_docs/constructors/phoneCallDiscardReasonHangup.md @@ -0,0 +1,24 @@ +--- +title: "phoneCallDiscardReasonHangup" +description: "The phone call was ended normally" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallDiscardReasonHangup +[Back to constructors index](/API_docs/constructors/index.html) + + + +The phone call was ended normally + + + + +### Type: [PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) + + +### Example: + +``` +$phoneCallDiscardReasonHangup = ['_' => 'phoneCallDiscardReasonHangup']; +``` diff --git a/docs/API_docs/constructors/phoneCallDiscardReasonMissed.md b/docs/API_docs/constructors/phoneCallDiscardReasonMissed.md new file mode 100644 index 0000000000..a17e97ddbb --- /dev/null +++ b/docs/API_docs/constructors/phoneCallDiscardReasonMissed.md @@ -0,0 +1,24 @@ +--- +title: "phoneCallDiscardReasonMissed" +description: "The phone call was missed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallDiscardReasonMissed +[Back to constructors index](/API_docs/constructors/index.html) + + + +The phone call was missed + + + + +### Type: [PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) + + +### Example: + +``` +$phoneCallDiscardReasonMissed = ['_' => 'phoneCallDiscardReasonMissed']; +``` diff --git a/docs/API_docs/constructors/phoneCallDiscarded.md b/docs/API_docs/constructors/phoneCallDiscarded.md new file mode 100644 index 0000000000..661a98a762 --- /dev/null +++ b/docs/API_docs/constructors/phoneCallDiscarded.md @@ -0,0 +1,34 @@ +--- +title: "phoneCallDiscarded" +description: "Indicates a discarded phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallDiscarded +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a discarded phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|need\_rating|[Bool](/API_docs/types/Bool.html) | Optional|Whether the server required the user to [rate](../methods/phone.setCallRating.html) the call| +|need\_debug|[Bool](/API_docs/types/Bool.html) | Optional|Whether the server required the client to [send](../methods/phone.saveCallDebug.html) the libtgvoip call debug data| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Whether the call was a video call| +|id|[long](/API_docs/types/long.html) | Yes|Call ID| +|reason|[PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) | Optional|Why was the phone call discarded| +|duration|[int](/API_docs/types/int.html) | Optional|Duration of the phone call in seconds| + + + +### Type: [PhoneCall](/API_docs/types/PhoneCall.html) + + +### Example: + +``` +$phoneCallDiscarded = ['_' => 'phoneCallDiscarded', 'need_rating' => Bool, 'need_debug' => Bool, 'video' => Bool, 'id' => long, 'reason' => PhoneCallDiscardReason, 'duration' => int]; +``` diff --git a/docs/API_docs/constructors/phoneCallEmpty.md b/docs/API_docs/constructors/phoneCallEmpty.md new file mode 100644 index 0000000000..544b726cae --- /dev/null +++ b/docs/API_docs/constructors/phoneCallEmpty.md @@ -0,0 +1,29 @@ +--- +title: "phoneCallEmpty" +description: "Empty constructor" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Call ID| + + + +### Type: [PhoneCall](/API_docs/types/PhoneCall.html) + + +### Example: + +``` +$phoneCallEmpty = ['_' => 'phoneCallEmpty', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/phoneCallProtocol.md b/docs/API_docs/constructors/phoneCallProtocol.md new file mode 100644 index 0000000000..9a3b017551 --- /dev/null +++ b/docs/API_docs/constructors/phoneCallProtocol.md @@ -0,0 +1,33 @@ +--- +title: "phoneCallProtocol" +description: "Protocol info for libtgvoip" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallProtocol +[Back to constructors index](/API_docs/constructors/index.html) + + + +Protocol info for libtgvoip + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|udp\_p2p|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow P2P connection to the other participant| +|udp\_reflector|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow connection to the other participants through the reflector servers| +|min\_layer|[int](/API_docs/types/int.html) | Yes|Minimum layer for remote libtgvoip| +|max\_layer|[int](/API_docs/types/int.html) | Yes|Maximum layer for remote libtgvoip| +|library\_versions|Array of [string](/API_docs/types/string.html) | Yes|When using [phone.requestCall](../methods/phone.requestCall.html) and [phone.acceptCall](../methods/phone.acceptCall.html), specify all library versions supported by the client.
The server will merge and choose the best library version supported by both peers, returning only the best value in the result of the callee's [phone.acceptCall](../methods/phone.acceptCall.html) and in the [phoneCallAccepted](../constructors/phoneCallAccepted.html) update received by the caller.| + + + +### Type: [PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) + + +### Example: + +``` +$phoneCallProtocol = ['_' => 'phoneCallProtocol', 'udp_p2p' => Bool, 'udp_reflector' => Bool, 'min_layer' => int, 'max_layer' => int, 'library_versions' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/phoneCallRequested.md b/docs/API_docs/constructors/phoneCallRequested.md new file mode 100644 index 0000000000..804480af0f --- /dev/null +++ b/docs/API_docs/constructors/phoneCallRequested.md @@ -0,0 +1,36 @@ +--- +title: "phoneCallRequested" +description: "Requested phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallRequested +[Back to constructors index](/API_docs/constructors/index.html) + + + +Requested phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a video call| +|id|[long](/API_docs/types/long.html) | Yes|Phone call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|date|[int](/API_docs/types/int.html) | Yes|When was the phone call created| +|admin\_id|[long](/API_docs/types/long.html) | Yes|ID of the creator of the phone call| +|participant\_id|[long](/API_docs/types/long.html) | Yes|ID of the other participant of the phone call| +|g\_a\_hash|[bytes](/API_docs/types/bytes.html) | Yes|[Parameter for key exchange](https://core.telegram.org/api/end-to-end/voice-calls)| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Yes|Call protocol info to be passed to libtgvoip| + + + +### Type: [PhoneCall](/API_docs/types/PhoneCall.html) + + +### Example: + +``` +$phoneCallRequested = ['_' => 'phoneCallRequested', 'video' => Bool, 'id' => long, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long, 'g_a_hash' => 'bytes', 'protocol' => PhoneCallProtocol]; +``` diff --git a/docs/API_docs/constructors/phoneCallWaiting.md b/docs/API_docs/constructors/phoneCallWaiting.md new file mode 100644 index 0000000000..fc8402cd61 --- /dev/null +++ b/docs/API_docs/constructors/phoneCallWaiting.md @@ -0,0 +1,36 @@ +--- +title: "phoneCallWaiting" +description: "Incoming phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneCallWaiting +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incoming phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|video|[Bool](/API_docs/types/Bool.html) | Optional|Is this a video call| +|id|[long](/API_docs/types/long.html) | Yes|Call ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|date|[int](/API_docs/types/int.html) | Yes|Date| +|admin\_id|[long](/API_docs/types/long.html) | Yes|Admin ID| +|participant\_id|[long](/API_docs/types/long.html) | Yes|Participant ID| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Yes|Phone call protocol info| +|receive\_date|[int](/API_docs/types/int.html) | Optional|When was the phone call received| + + + +### Type: [PhoneCall](/API_docs/types/PhoneCall.html) + + +### Example: + +``` +$phoneCallWaiting = ['_' => 'phoneCallWaiting', 'video' => Bool, 'id' => long, 'access_hash' => long, 'date' => int, 'admin_id' => long, 'participant_id' => long, 'protocol' => PhoneCallProtocol, 'receive_date' => int]; +``` diff --git a/docs/API_docs/constructors/phoneConnection.md b/docs/API_docs/constructors/phoneConnection.md new file mode 100644 index 0000000000..34e40f7890 --- /dev/null +++ b/docs/API_docs/constructors/phoneConnection.md @@ -0,0 +1,34 @@ +--- +title: "phoneConnection" +description: "Identifies an endpoint that can be used to connect to the other user in a phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneConnection +[Back to constructors index](/API_docs/constructors/index.html) + + + +Identifies an endpoint that can be used to connect to the other user in a phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|tcp|[Bool](/API_docs/types/Bool.html) | Optional|Whether TCP should be used| +|id|[long](/API_docs/types/long.html) | Yes|Endpoint ID| +|ip|[string](/API_docs/types/string.html) | Yes|IP address of endpoint| +|ipv6|[string](/API_docs/types/string.html) | Yes|IPv6 address of endpoint| +|port|[int](/API_docs/types/int.html) | Yes|Port ID| +|peer\_tag|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [PhoneConnection](/API_docs/types/PhoneConnection.html) + + +### Example: + +``` +$phoneConnection = ['_' => 'phoneConnection', 'tcp' => Bool, 'id' => long, 'ip' => 'string', 'ipv6' => 'string', 'port' => int, 'peer_tag' => 'string']; +``` diff --git a/docs/API_docs/constructors/phoneConnectionWebrtc.md b/docs/API_docs/constructors/phoneConnectionWebrtc.md new file mode 100644 index 0000000000..1696c197dc --- /dev/null +++ b/docs/API_docs/constructors/phoneConnectionWebrtc.md @@ -0,0 +1,36 @@ +--- +title: "phoneConnectionWebrtc" +description: "WebRTC connection parameters" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: phoneConnectionWebrtc +[Back to constructors index](/API_docs/constructors/index.html) + + + +WebRTC connection parameters + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|turn|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a TURN endpoint| +|stun|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a STUN endpoint| +|id|[long](/API_docs/types/long.html) | Yes|Endpoint ID| +|ip|[string](/API_docs/types/string.html) | Yes|IP address| +|ipv6|[string](/API_docs/types/string.html) | Yes|IPv6 address| +|port|[int](/API_docs/types/int.html) | Yes|Port| +|username|[string](/API_docs/types/string.html) | Yes|Username| +|password|[string](/API_docs/types/string.html) | Yes|Password| + + + +### Type: [PhoneConnection](/API_docs/types/PhoneConnection.html) + + +### Example: + +``` +$phoneConnectionWebrtc = ['_' => 'phoneConnectionWebrtc', 'turn' => Bool, 'stun' => Bool, 'id' => long, 'ip' => 'string', 'ipv6' => 'string', 'port' => int, 'username' => 'string', 'password' => 'string']; +``` diff --git a/docs/API_docs/constructors/photo.md b/docs/API_docs/constructors/photo.md new file mode 100644 index 0000000000..0b76244ee3 --- /dev/null +++ b/docs/API_docs/constructors/photo.md @@ -0,0 +1,36 @@ +--- +title: "photo" +description: "Photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_stickers|[Bool](/API_docs/types/Bool.html) | Optional|Whether the photo has mask stickers attached to it| +|id|[long](/API_docs/types/long.html) | Yes|ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|file\_reference|[bytes](/API_docs/types/bytes.html) | Yes|[file reference](https://core.telegram.org/api/file_reference)| +|date|[int](/API_docs/types/int.html) | Yes|Date of upload| +|sizes|Array of [PhotoSize](/API_docs/types/PhotoSize.html) | Yes|Available sizes for download| +|video\_sizes|Array of [VideoSize](/API_docs/types/VideoSize.html) | Optional|[For animated profiles](https://core.telegram.org/api/files#animated-profile-pictures), the MPEG4 videos| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID to use for download| + + + +### Type: [Photo](/API_docs/types/Photo.html) + + +### Example: + +``` +$photo = ['_' => 'photo', 'has_stickers' => Bool, 'id' => long, 'access_hash' => long, 'file_reference' => 'bytes', 'date' => int, 'sizes' => [PhotoSize, PhotoSize], 'video_sizes' => [VideoSize, VideoSize], 'dc_id' => int]; +``` diff --git a/docs/API_docs/constructors/photoCachedSize.md b/docs/API_docs/constructors/photoCachedSize.md new file mode 100644 index 0000000000..4f62161c2c --- /dev/null +++ b/docs/API_docs/constructors/photoCachedSize.md @@ -0,0 +1,32 @@ +--- +title: "photoCachedSize" +description: "Description of an image and its content." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoCachedSize +[Back to constructors index](/API_docs/constructors/index.html) + + + +Description of an image and its content. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|Thumbnail type| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|Binary data, file content| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoCachedSize = ['_' => 'photoCachedSize', 'type' => 'string', 'w' => int, 'h' => int, 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/photoCachedSize_23.md b/docs/API_docs/constructors/photoCachedSize_23.md new file mode 100644 index 0000000000..d74ba34f4a --- /dev/null +++ b/docs/API_docs/constructors/photoCachedSize_23.md @@ -0,0 +1,33 @@ +--- +title: "photoCachedSize" +description: "Description of an image and its content." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoCachedSize\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Description of an image and its content. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|Thumbnail type| +|location|[FileLocation](/API_docs/types/FileLocation.html) | Yes| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|Binary data, file content| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoCachedSize_23 = ['_' => 'photoCachedSize', 'type' => 'string', 'location' => FileLocation, 'w' => int, 'h' => int, 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/photoEmpty.md b/docs/API_docs/constructors/photoEmpty.md new file mode 100644 index 0000000000..d59e29e39c --- /dev/null +++ b/docs/API_docs/constructors/photoEmpty.md @@ -0,0 +1,29 @@ +--- +title: "photoEmpty" +description: "Empty constructor, non-existent photo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, non-existent photo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Photo identifier| + + + +### Type: [Photo](/API_docs/types/Photo.html) + + +### Example: + +``` +$photoEmpty = ['_' => 'photoEmpty', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/photoPathSize.md b/docs/API_docs/constructors/photoPathSize.md new file mode 100644 index 0000000000..fc5b9fa885 --- /dev/null +++ b/docs/API_docs/constructors/photoPathSize.md @@ -0,0 +1,30 @@ +--- +title: "photoPathSize" +description: "Messages with animated stickers can have a compressed svg (< 300 bytes) to show the outline of the sticker before fetching the actual lottie animation." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoPathSize +[Back to constructors index](/API_docs/constructors/index.html) + + + +Messages with animated stickers can have a compressed svg (< 300 bytes) to show the outline of the sticker before fetching the actual lottie animation. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|Always `j`| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|Compressed SVG path payload, [see here for decompression instructions](https://core.telegram.org/api/files#vector-thumbnails)| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoPathSize = ['_' => 'photoPathSize', 'type' => 'string', 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/photoSize.md b/docs/API_docs/constructors/photoSize.md new file mode 100644 index 0000000000..75f36681a4 --- /dev/null +++ b/docs/API_docs/constructors/photoSize.md @@ -0,0 +1,32 @@ +--- +title: "photoSize" +description: "Image description." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoSize +[Back to constructors index](/API_docs/constructors/index.html) + + + +Image description. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|[Thumbnail type »](https://core.telegram.org/api/files#image-thumbnail-types)| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|size|[int](/API_docs/types/int.html) | Yes|File size| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoSize = ['_' => 'photoSize', 'type' => 'string', 'w' => int, 'h' => int, 'size' => int]; +``` diff --git a/docs/API_docs/constructors/photoSizeEmpty.md b/docs/API_docs/constructors/photoSizeEmpty.md new file mode 100644 index 0000000000..439002d6bc --- /dev/null +++ b/docs/API_docs/constructors/photoSizeEmpty.md @@ -0,0 +1,29 @@ +--- +title: "photoSizeEmpty" +description: "Empty constructor. Image with this thumbnail is unavailable." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoSizeEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor. Image with this thumbnail is unavailable. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|[Thumbnail type »](https://core.telegram.org/api/files#image-thumbnail-types)| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoSizeEmpty = ['_' => 'photoSizeEmpty', 'type' => 'string']; +``` diff --git a/docs/API_docs/constructors/photoSizeProgressive.md b/docs/API_docs/constructors/photoSizeProgressive.md new file mode 100644 index 0000000000..19015c0dd0 --- /dev/null +++ b/docs/API_docs/constructors/photoSizeProgressive.md @@ -0,0 +1,32 @@ +--- +title: "photoSizeProgressive" +description: "Progressively encoded photosize" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoSizeProgressive +[Back to constructors index](/API_docs/constructors/index.html) + + + +Progressively encoded photosize + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|[Photosize type »](https://core.telegram.org/api/files#image-thumbnail-types)| +|w|[int](/API_docs/types/int.html) | Yes|Photo width| +|h|[int](/API_docs/types/int.html) | Yes|Photo height| +|sizes|Array of [int](/API_docs/types/int.html) | Yes|Sizes of progressive JPEG file prefixes, which can be used to preliminarily show the image.| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoSizeProgressive = ['_' => 'photoSizeProgressive', 'type' => 'string', 'w' => int, 'h' => int, 'sizes' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/photoSize_23.md b/docs/API_docs/constructors/photoSize_23.md new file mode 100644 index 0000000000..038bf06520 --- /dev/null +++ b/docs/API_docs/constructors/photoSize_23.md @@ -0,0 +1,33 @@ +--- +title: "photoSize" +description: "Image description." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoSize\_23 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Image description. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|[Thumbnail type »](https://core.telegram.org/api/files#image-thumbnail-types)| +|location|[FileLocation](/API_docs/types/FileLocation.html) | Yes| +|w|[int](/API_docs/types/int.html) | Yes|Image width| +|h|[int](/API_docs/types/int.html) | Yes|Image height| +|size|[int](/API_docs/types/int.html) | Yes|File size| + + + +### Type: [PhotoSize](/API_docs/types/PhotoSize.html) + + +### Example: + +``` +$photoSize_23 = ['_' => 'photoSize', 'type' => 'string', 'location' => FileLocation, 'w' => int, 'h' => int, 'size' => int]; +``` diff --git a/docs/API_docs/constructors/photoStrippedSize.md b/docs/API_docs/constructors/photoStrippedSize.md new file mode 100644 index 0000000000..9608d86d79 --- /dev/null +++ b/docs/API_docs/constructors/photoStrippedSize.md @@ -0,0 +1,35 @@ +--- +title: photoStrippedSize +description: Just the image's content +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoStrippedSize +[Back to constructors index](index.html) + + + +Just the image's content + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](../types/string.html) | Yes|Thumbnail type| +|bytes|[bytes](../types/bytes.html) | Yes|Thumbnail data| +|inflated|[bytes](../types/bytes.html) | Yes|JPG image data| + + + +### Type: [PhotoSize](../types/PhotoSize.html) + + +### Example: + +```php +$photoStrippedSize = ['_' => 'photoStrippedSize', 'type' => 'string', 'bytes' => 'bytes']; +``` + + + + diff --git a/docs/API_docs/constructors/photos.photo.md b/docs/API_docs/constructors/photos.photo.md new file mode 100644 index 0000000000..d46a2ddbbf --- /dev/null +++ b/docs/API_docs/constructors/photos.photo.md @@ -0,0 +1,31 @@ +--- +title: "photos.photo" +description: "Photo with auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/photos_photo.html +--- +# Constructor: photos.photo +[Back to constructors index](/API_docs/constructors/index.html) + + + +Photo with auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|Photo| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [photos.Photo](/API_docs/types/photos.Photo.html) + + +### Example: + +``` +$photos_photo = ['_' => 'photos.photo', 'photo' => Photo, 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/photos.photos.md b/docs/API_docs/constructors/photos.photos.md new file mode 100644 index 0000000000..4ac3fe5b3a --- /dev/null +++ b/docs/API_docs/constructors/photos.photos.md @@ -0,0 +1,31 @@ +--- +title: "photos.photos" +description: "Full list of photos with auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/photos_photos.html +--- +# Constructor: photos.photos +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full list of photos with auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|photos|Array of [Photo](/API_docs/types/Photo.html) | Yes|List of photos| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of mentioned users| + + + +### Type: [photos.Photos](/API_docs/types/photos.Photos.html) + + +### Example: + +``` +$photos_photos = ['_' => 'photos.photos', 'photos' => [Photo, Photo], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/photos.photosSlice.md b/docs/API_docs/constructors/photos.photosSlice.md new file mode 100644 index 0000000000..a7b262d729 --- /dev/null +++ b/docs/API_docs/constructors/photos.photosSlice.md @@ -0,0 +1,32 @@ +--- +title: "photos.photosSlice" +description: "Incomplete list of photos with auxiliary data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/photos_photosSlice.html +--- +# Constructor: photos.photosSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incomplete list of photos with auxiliary data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of photos| +|photos|Array of [Photo](/API_docs/types/Photo.html) | Yes|List of photos| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of mentioned users| + + + +### Type: [photos.Photos](/API_docs/types/photos.Photos.html) + + +### Example: + +``` +$photos_photosSlice = ['_' => 'photos.photosSlice', 'count' => int, 'photos' => [Photo, Photo], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/poll.md b/docs/API_docs/constructors/poll.md new file mode 100644 index 0000000000..06b32f382d --- /dev/null +++ b/docs/API_docs/constructors/poll.md @@ -0,0 +1,37 @@ +--- +title: "poll" +description: "Poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: poll +[Back to constructors index](/API_docs/constructors/index.html) + + + +Poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|ID of the poll| +|closed|[Bool](/API_docs/types/Bool.html) | Optional|Whether the poll is closed and doesn't accept any more answers| +|public\_voters|[Bool](/API_docs/types/Bool.html) | Optional|Whether cast votes are publicly visible to all users (non-anonymous poll)| +|multiple\_choice|[Bool](/API_docs/types/Bool.html) | Optional|Whether multiple options can be chosen as answer| +|quiz|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a quiz (with wrong and correct answers, results shown in the return type)| +|question|[TextWithEntities](/API_docs/types/TextWithEntities.html) | Yes| +|answers|Array of [PollAnswer](/API_docs/types/PollAnswer.html) | Yes|The possible answers, vote using [messages.sendVote](../methods/messages.sendVote.html).| +|close\_period|[int](/API_docs/types/int.html) | Optional|Amount of time in seconds the poll will be active after creation, 5-600. Can't be used together with close\_date.| +|close\_date|[int](/API_docs/types/int.html) | Optional|Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future; can't be used together with close\_period.| + + + +### Type: [Poll](/API_docs/types/Poll.html) + + +### Example: + +``` +$poll = ['_' => 'poll', 'id' => long, 'closed' => Bool, 'public_voters' => Bool, 'multiple_choice' => Bool, 'quiz' => Bool, 'question' => TextWithEntities, 'answers' => [PollAnswer, PollAnswer], 'close_period' => int, 'close_date' => int]; +``` diff --git a/docs/API_docs/constructors/pollAnswer.md b/docs/API_docs/constructors/pollAnswer.md new file mode 100644 index 0000000000..a89cf68462 --- /dev/null +++ b/docs/API_docs/constructors/pollAnswer.md @@ -0,0 +1,30 @@ +--- +title: "pollAnswer" +description: "A possible answer of a poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pollAnswer +[Back to constructors index](/API_docs/constructors/index.html) + + + +A possible answer of a poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[TextWithEntities](/API_docs/types/TextWithEntities.html) | Yes| +|option|[bytes](/API_docs/types/bytes.html) | Yes|The param that has to be passed to [messages.sendVote](../methods/messages.sendVote.html).| + + + +### Type: [PollAnswer](/API_docs/types/PollAnswer.html) + + +### Example: + +``` +$pollAnswer = ['_' => 'pollAnswer', 'text' => TextWithEntities, 'option' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/pollAnswerVoters.md b/docs/API_docs/constructors/pollAnswerVoters.md new file mode 100644 index 0000000000..d9710d8a60 --- /dev/null +++ b/docs/API_docs/constructors/pollAnswerVoters.md @@ -0,0 +1,32 @@ +--- +title: "pollAnswerVoters" +description: "A poll answer, and how users voted on it" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pollAnswerVoters +[Back to constructors index](/API_docs/constructors/index.html) + + + +A poll answer, and how users voted on it + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chosen|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have chosen this answer| +|correct|[Bool](/API_docs/types/Bool.html) | Optional|For quizzes, whether the option we have chosen is correct| +|option|[bytes](/API_docs/types/bytes.html) | Yes|The param that has to be passed to [messages.sendVote](../methods/messages.sendVote.html).| +|voters|[int](/API_docs/types/int.html) | Yes|How many users voted for this option| + + + +### Type: [PollAnswerVoters](/API_docs/types/PollAnswerVoters.html) + + +### Example: + +``` +$pollAnswerVoters = ['_' => 'pollAnswerVoters', 'chosen' => Bool, 'correct' => Bool, 'option' => 'bytes', 'voters' => int]; +``` diff --git a/docs/API_docs/constructors/pollResults.md b/docs/API_docs/constructors/pollResults.md new file mode 100644 index 0000000000..00fb64ca16 --- /dev/null +++ b/docs/API_docs/constructors/pollResults.md @@ -0,0 +1,34 @@ +--- +title: "pollResults" +description: "Results of poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: pollResults +[Back to constructors index](/API_docs/constructors/index.html) + + + +Results of poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|min|[Bool](/API_docs/types/Bool.html) | Optional|Similar to [min](https://core.telegram.org/api/min) objects, used for poll constructors that are the same for all users so they don't have the option chosen by the current user (you can use [messages.getPollResults](../methods/messages.getPollResults.html) to get the full poll results).| +|results|Array of [PollAnswerVoters](/API_docs/types/PollAnswerVoters.html) | Optional|Poll results| +|total\_voters|[int](/API_docs/types/int.html) | Optional|Total number of people that voted in the poll| +|recent\_voters|Array of [Peer](/API_docs/types/Peer.html) | Optional|IDs of the last users that recently voted in the poll| +|solution|[string](/API_docs/types/string.html) | Optional|Explanation of quiz solution| +|solution\_entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text in quiz solution](https://core.telegram.org/api/entities)| + + + +### Type: [PollResults](/API_docs/types/PollResults.html) + + +### Example: + +``` +$pollResults = ['_' => 'pollResults', 'min' => Bool, 'results' => [PollAnswerVoters, PollAnswerVoters], 'total_voters' => int, 'recent_voters' => [Peer, Peer], 'solution' => 'string', 'solution_entities' => [MessageEntity, MessageEntity]]; +``` diff --git a/docs/API_docs/constructors/popularContact.md b/docs/API_docs/constructors/popularContact.md new file mode 100644 index 0000000000..f892c3389f --- /dev/null +++ b/docs/API_docs/constructors/popularContact.md @@ -0,0 +1,30 @@ +--- +title: "popularContact" +description: "Popular contact" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: popularContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Popular contact + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|client\_id|[long](/API_docs/types/long.html) | Yes|Contact identifier| +|importers|[int](/API_docs/types/int.html) | Yes|How many people imported this contact| + + + +### Type: [PopularContact](/API_docs/types/PopularContact.html) + + +### Example: + +``` +$popularContact = ['_' => 'popularContact', 'client_id' => long, 'importers' => int]; +``` diff --git a/docs/API_docs/constructors/postAddress.md b/docs/API_docs/constructors/postAddress.md new file mode 100644 index 0000000000..6122b5be82 --- /dev/null +++ b/docs/API_docs/constructors/postAddress.md @@ -0,0 +1,34 @@ +--- +title: "postAddress" +description: "Shipping address" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: postAddress +[Back to constructors index](/API_docs/constructors/index.html) + + + +Shipping address + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|street\_line1|[string](/API_docs/types/string.html) | Yes|First line for the address| +|street\_line2|[string](/API_docs/types/string.html) | Yes|Second line for the address| +|city|[string](/API_docs/types/string.html) | Yes|City| +|state|[string](/API_docs/types/string.html) | Yes|State, if applicable (empty otherwise)| +|country\_iso2|[string](/API_docs/types/string.html) | Yes|ISO 3166-1 alpha-2 country code| +|post\_code|[string](/API_docs/types/string.html) | Yes|Address post code| + + + +### Type: [PostAddress](/API_docs/types/PostAddress.html) + + +### Example: + +``` +$postAddress = ['_' => 'postAddress', 'street_line1' => 'string', 'street_line2' => 'string', 'city' => 'string', 'state' => 'string', 'country_iso2' => 'string', 'post_code' => 'string']; +``` diff --git a/docs/API_docs/constructors/postInteractionCountersMessage.md b/docs/API_docs/constructors/postInteractionCountersMessage.md new file mode 100644 index 0000000000..5f494e326b --- /dev/null +++ b/docs/API_docs/constructors/postInteractionCountersMessage.md @@ -0,0 +1,32 @@ +--- +title: "postInteractionCountersMessage" +description: "Interaction counters for a message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: postInteractionCountersMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Interaction counters for a message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID| +|views|[int](/API_docs/types/int.html) | Yes|Number of views| +|forwards|[int](/API_docs/types/int.html) | Yes|Number of forwards to public channels| +|reactions|[int](/API_docs/types/int.html) | Yes|Number of reactions| + + + +### Type: [PostInteractionCounters](/API_docs/types/PostInteractionCounters.html) + + +### Example: + +``` +$postInteractionCountersMessage = ['_' => 'postInteractionCountersMessage', 'msg_id' => int, 'views' => int, 'forwards' => int, 'reactions' => int]; +``` diff --git a/docs/API_docs/constructors/postInteractionCountersStory.md b/docs/API_docs/constructors/postInteractionCountersStory.md new file mode 100644 index 0000000000..46c086583d --- /dev/null +++ b/docs/API_docs/constructors/postInteractionCountersStory.md @@ -0,0 +1,32 @@ +--- +title: "postInteractionCountersStory" +description: "Interaction counters for a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: postInteractionCountersStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Interaction counters for a story. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|story\_id|[int](/API_docs/types/int.html) | Yes|Story ID| +|views|[int](/API_docs/types/int.html) | Yes|Number of views| +|forwards|[int](/API_docs/types/int.html) | Yes|Number of forwards and reposts to public chats and channels| +|reactions|[int](/API_docs/types/int.html) | Yes|Number of reactions| + + + +### Type: [PostInteractionCounters](/API_docs/types/PostInteractionCounters.html) + + +### Example: + +``` +$postInteractionCountersStory = ['_' => 'postInteractionCountersStory', 'story_id' => int, 'views' => int, 'forwards' => int, 'reactions' => int]; +``` diff --git a/docs/API_docs/constructors/premium.boostsList.md b/docs/API_docs/constructors/premium.boostsList.md new file mode 100644 index 0000000000..4b74791de0 --- /dev/null +++ b/docs/API_docs/constructors/premium.boostsList.md @@ -0,0 +1,33 @@ +--- +title: "premium.boostsList" +description: "List of boosts that were applied to a peer by multiple users." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/premium_boostsList.html +--- +# Constructor: premium.boostsList +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of [boosts](https://core.telegram.org/api/boost) that were applied to a peer by multiple users. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of results| +|boosts|Array of [Boost](/API_docs/types/Boost.html) | Yes|[Boosts](https://core.telegram.org/api/boost)| +|next\_offset|[string](/API_docs/types/string.html) | Optional|Offset that can be used for [pagination](https://core.telegram.org/api/offsets).| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [premium.BoostsList](/API_docs/types/premium.BoostsList.html) + + +### Example: + +``` +$premium_boostsList = ['_' => 'premium.boostsList', 'count' => int, 'boosts' => [Boost, Boost], 'next_offset' => 'string', 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/premium.boostsStatus.md b/docs/API_docs/constructors/premium.boostsStatus.md new file mode 100644 index 0000000000..261c6ab008 --- /dev/null +++ b/docs/API_docs/constructors/premium.boostsStatus.md @@ -0,0 +1,39 @@ +--- +title: "premium.boostsStatus" +description: "Contains info about the current boost status of a peer." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/premium_boostsStatus.html +--- +# Constructor: premium.boostsStatus +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about the current [boost status](https://core.telegram.org/api/boost) of a peer. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|my\_boost|[Bool](/API_docs/types/Bool.html) | Optional|Whether we're currently boosting this channel, `my_boost_slots` will also be set.| +|level|[int](/API_docs/types/int.html) | Yes|The current boost level of the channel.| +|current\_level\_boosts|[int](/API_docs/types/int.html) | Yes|The number of boosts acquired so far in the current level.| +|boosts|[int](/API_docs/types/int.html) | Yes|Total number of boosts acquired so far.| +|gift\_boosts|[int](/API_docs/types/int.html) | Optional|The number of boosts acquired from created Telegram Premium [gift codes](https://core.telegram.org/api/giveaways) and [giveaways](https://core.telegram.org/api/giveaways); only returned to channel admins.| +|next\_level\_boosts|[int](/API_docs/types/int.html) | Optional|Total number of boosts needed to reach the next level; if absent, the next level isn't available.| +|premium\_audience|[StatsPercentValue](/API_docs/types/StatsPercentValue.html) | Optional|Only returned to channel admins: contains the approximated number of Premium users subscribed to the channel, related to the total number of subscribers.| +|boost\_url|[string](/API_docs/types/string.html) | Yes|[Boost deep link »](https://core.telegram.org/api/links#boost-links) that can be used to boost the chat.| +|prepaid\_giveaways|Array of [PrepaidGiveaway](/API_docs/types/PrepaidGiveaway.html) | Optional|A list of prepaid [giveaways](https://core.telegram.org/api/giveaways) available for the chat; only returned to channel admins.| +|my\_boost\_slots|Array of [int](/API_docs/types/int.html) | Optional|Indicates which of our [boost slots](https://core.telegram.org/api/boost) we've assigned to this peer (populated if `my_boost` is set).| + + + +### Type: [premium.BoostsStatus](/API_docs/types/premium.BoostsStatus.html) + + +### Example: + +``` +$premium_boostsStatus = ['_' => 'premium.boostsStatus', 'my_boost' => Bool, 'level' => int, 'current_level_boosts' => int, 'boosts' => int, 'gift_boosts' => int, 'next_level_boosts' => int, 'premium_audience' => StatsPercentValue, 'boost_url' => 'string', 'prepaid_giveaways' => [PrepaidGiveaway, PrepaidGiveaway], 'my_boost_slots' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/premium.myBoosts.md b/docs/API_docs/constructors/premium.myBoosts.md new file mode 100644 index 0000000000..2376fb7a34 --- /dev/null +++ b/docs/API_docs/constructors/premium.myBoosts.md @@ -0,0 +1,32 @@ +--- +title: "premium.myBoosts" +description: "A list of peers we are currently boosting, and how many boost slots we have left." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/premium_myBoosts.html +--- +# Constructor: premium.myBoosts +[Back to constructors index](/API_docs/constructors/index.html) + + + +A list of peers we are currently [boosting](https://core.telegram.org/api/boost), and how many [boost slots](https://core.telegram.org/api/boost) we have left. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|my\_boosts|Array of [MyBoost](/API_docs/types/MyBoost.html) | Yes|Info about boosted peers and remaining boost slots.| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Referenced chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Referenced users| + + + +### Type: [premium.MyBoosts](/API_docs/types/premium.MyBoosts.html) + + +### Example: + +``` +$premium_myBoosts = ['_' => 'premium.myBoosts', 'my_boosts' => [MyBoost, MyBoost], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/premiumGiftCodeOption.md b/docs/API_docs/constructors/premiumGiftCodeOption.md new file mode 100644 index 0000000000..be2706fddb --- /dev/null +++ b/docs/API_docs/constructors/premiumGiftCodeOption.md @@ -0,0 +1,34 @@ +--- +title: "premiumGiftCodeOption" +description: "Contains info about a giveaway/gift option." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: premiumGiftCodeOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a [giveaway/gift](https://core.telegram.org/api/giveaways) option. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|[int](/API_docs/types/int.html) | Yes|Number of users which will be able to activate the gift codes.| +|months|[int](/API_docs/types/int.html) | Yes|Duration in months of each gifted [Telegram Premium](https://core.telegram.org/api/premium) subscription.| +|store\_product|[string](/API_docs/types/string.html) | Optional|Identifier of the store product associated with the option, official apps only.| +|store\_quantity|[int](/API_docs/types/int.html) | Optional|Number of times the store product must be paid| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| + + + +### Type: [PremiumGiftCodeOption](/API_docs/types/PremiumGiftCodeOption.html) + + +### Example: + +``` +$premiumGiftCodeOption = ['_' => 'premiumGiftCodeOption', 'users' => int, 'months' => int, 'store_product' => 'string', 'store_quantity' => int, 'currency' => 'string', 'amount' => long]; +``` diff --git a/docs/API_docs/constructors/premiumGiftOption.md b/docs/API_docs/constructors/premiumGiftOption.md new file mode 100644 index 0000000000..b0dd3d1d57 --- /dev/null +++ b/docs/API_docs/constructors/premiumGiftOption.md @@ -0,0 +1,33 @@ +--- +title: "premiumGiftOption" +description: "Telegram Premium gift option" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: premiumGiftOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Telegram Premium gift option + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|months|[int](/API_docs/types/int.html) | Yes|Duration of gifted Telegram Premium subscription| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|bot\_url|[string](/API_docs/types/string.html) | Yes|An [invoice deep link »](https://core.telegram.org/api/links#invoice-links) to an invoice for in-app payment, using the official Premium bot; may be empty if direct payment isn't available.| +|store\_product|[string](/API_docs/types/string.html) | Optional|An identifier for the App Store/Play Store product associated with the Premium gift.| + + + +### Type: [PremiumGiftOption](/API_docs/types/PremiumGiftOption.html) + + +### Example: + +``` +$premiumGiftOption = ['_' => 'premiumGiftOption', 'months' => int, 'currency' => 'string', 'amount' => long, 'bot_url' => 'string', 'store_product' => 'string']; +``` diff --git a/docs/API_docs/constructors/premiumSubscriptionOption.md b/docs/API_docs/constructors/premiumSubscriptionOption.md new file mode 100644 index 0000000000..b274c4c694 --- /dev/null +++ b/docs/API_docs/constructors/premiumSubscriptionOption.md @@ -0,0 +1,36 @@ +--- +title: "premiumSubscriptionOption" +description: "Describes a Telegram Premium subscription option" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: premiumSubscriptionOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Describes a Telegram Premium subscription option + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|current|[Bool](/API_docs/types/Bool.html) | Optional|Whether this subscription option is currently in use.| +|can\_purchase\_upgrade|[Bool](/API_docs/types/Bool.html) | Optional|Whether this subscription option can be used to upgrade the existing Telegram Premium subscription. When upgrading Telegram Premium subscriptions bought through stores, make sure that the store transaction ID is equal to `transaction`, to avoid upgrading someone else's account, if the client is currently logged into multiple accounts.| +|transaction|[string](/API_docs/types/string.html) | Optional|Identifier of the last in-store transaction for the currently used subscription on the current account.| +|months|[int](/API_docs/types/int.html) | Yes|Duration of subscription in months| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|amount|[long](/API_docs/types/long.html) | Yes|Total price in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| +|bot\_url|[string](/API_docs/types/string.html) | Yes|[Deep link](https://core.telegram.org/api/links) used to initiate payment| +|store\_product|[string](/API_docs/types/string.html) | Optional|Store product ID, only for official apps| + + + +### Type: [PremiumSubscriptionOption](/API_docs/types/PremiumSubscriptionOption.html) + + +### Example: + +``` +$premiumSubscriptionOption = ['_' => 'premiumSubscriptionOption', 'current' => Bool, 'can_purchase_upgrade' => Bool, 'transaction' => 'string', 'months' => int, 'currency' => 'string', 'amount' => long, 'bot_url' => 'string', 'store_product' => 'string']; +``` diff --git a/docs/API_docs/constructors/prepaidGiveaway.md b/docs/API_docs/constructors/prepaidGiveaway.md new file mode 100644 index 0000000000..8800198c2a --- /dev/null +++ b/docs/API_docs/constructors/prepaidGiveaway.md @@ -0,0 +1,32 @@ +--- +title: "prepaidGiveaway" +description: "Contains info about a prepaid giveaway »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: prepaidGiveaway +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a [prepaid giveaway »](https://core.telegram.org/api/giveaways). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Prepaid giveaway ID.| +|months|[int](/API_docs/types/int.html) | Yes|Duration in months of each gifted [Telegram Premium](https://core.telegram.org/api/premium) subscription.| +|quantity|[int](/API_docs/types/int.html) | Yes|Number of given away [Telegram Premium](https://core.telegram.org/api/premium) subscriptions.| +|date|[int](/API_docs/types/int.html) | Yes|Payment date.| + + + +### Type: [PrepaidGiveaway](/API_docs/types/PrepaidGiveaway.html) + + +### Example: + +``` +$prepaidGiveaway = ['_' => 'prepaidGiveaway', 'id' => long, 'months' => int, 'quantity' => int, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/privacyKeyAbout.md b/docs/API_docs/constructors/privacyKeyAbout.md new file mode 100644 index 0000000000..74d9977d83 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyAbout.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyAbout" +description: "Whether people can see your bio" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyAbout +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether people can see your bio + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyAbout = ['_' => 'privacyKeyAbout']; +``` diff --git a/docs/API_docs/constructors/privacyKeyAddedByPhone.md b/docs/API_docs/constructors/privacyKeyAddedByPhone.md new file mode 100644 index 0000000000..8456980619 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyAddedByPhone.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyAddedByPhone" +description: "Whether this user can be added to our contact list by their phone number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyAddedByPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether this user can be added to our contact list by their phone number + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyAddedByPhone = ['_' => 'privacyKeyAddedByPhone']; +``` diff --git a/docs/API_docs/constructors/privacyKeyBirthday.md b/docs/API_docs/constructors/privacyKeyBirthday.md new file mode 100644 index 0000000000..3baa5e5e54 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyBirthday.md @@ -0,0 +1,22 @@ +--- +title: "privacyKeyBirthday" +description: "privacyKeyBirthday attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyBirthday +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyBirthday = ['_' => 'privacyKeyBirthday']; +``` diff --git a/docs/API_docs/constructors/privacyKeyChatInvite.md b/docs/API_docs/constructors/privacyKeyChatInvite.md new file mode 100644 index 0000000000..c271340105 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyChatInvite.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyChatInvite" +description: "Whether the user can be invited to chats" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyChatInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether the user can be invited to chats + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyChatInvite = ['_' => 'privacyKeyChatInvite']; +``` diff --git a/docs/API_docs/constructors/privacyKeyForwards.md b/docs/API_docs/constructors/privacyKeyForwards.md new file mode 100644 index 0000000000..9d664d3c39 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyForwards.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyForwards" +description: "Whether messages forwarded from the user will be anonymously forwarded" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyForwards +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether messages forwarded from the user will be [anonymously forwarded](https://telegram.org/blog/unsend-privacy-emoji#anonymous-forwarding) + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyForwards = ['_' => 'privacyKeyForwards']; +``` diff --git a/docs/API_docs/constructors/privacyKeyPhoneCall.md b/docs/API_docs/constructors/privacyKeyPhoneCall.md new file mode 100644 index 0000000000..2706c52831 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyPhoneCall.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyPhoneCall" +description: "Whether the user accepts phone calls" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyPhoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether the user accepts phone calls + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyPhoneCall = ['_' => 'privacyKeyPhoneCall']; +``` diff --git a/docs/API_docs/constructors/privacyKeyPhoneNumber.md b/docs/API_docs/constructors/privacyKeyPhoneNumber.md new file mode 100644 index 0000000000..64df2d3bd9 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyPhoneNumber.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyPhoneNumber" +description: "Whether the user allows us to see his phone number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyPhoneNumber +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether the user allows us to see his phone number + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyPhoneNumber = ['_' => 'privacyKeyPhoneNumber']; +``` diff --git a/docs/API_docs/constructors/privacyKeyPhoneP2P.md b/docs/API_docs/constructors/privacyKeyPhoneP2P.md new file mode 100644 index 0000000000..bd6bbdc293 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyPhoneP2P.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyPhoneP2P" +description: "Whether P2P connections in phone calls with this user are allowed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyPhoneP2P +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether P2P connections in phone calls with this user are allowed + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyPhoneP2P = ['_' => 'privacyKeyPhoneP2P']; +``` diff --git a/docs/API_docs/constructors/privacyKeyProfilePhoto.md b/docs/API_docs/constructors/privacyKeyProfilePhoto.md new file mode 100644 index 0000000000..89bf6d01ae --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyProfilePhoto.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyProfilePhoto" +description: "Whether the profile picture of the user is visible" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyProfilePhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether the profile picture of the user is visible + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyProfilePhoto = ['_' => 'privacyKeyProfilePhoto']; +``` diff --git a/docs/API_docs/constructors/privacyKeyStatusTimestamp.md b/docs/API_docs/constructors/privacyKeyStatusTimestamp.md new file mode 100644 index 0000000000..3711eac911 --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyStatusTimestamp.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyStatusTimestamp" +description: "Whether we can see the last online timestamp of this user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyStatusTimestamp +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether we can see the last online timestamp of this user + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyStatusTimestamp = ['_' => 'privacyKeyStatusTimestamp']; +``` diff --git a/docs/API_docs/constructors/privacyKeyVoiceMessages.md b/docs/API_docs/constructors/privacyKeyVoiceMessages.md new file mode 100644 index 0000000000..af98b77dfe --- /dev/null +++ b/docs/API_docs/constructors/privacyKeyVoiceMessages.md @@ -0,0 +1,24 @@ +--- +title: "privacyKeyVoiceMessages" +description: "Whether the user accepts voice messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyKeyVoiceMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Whether the user accepts voice messages + + + + +### Type: [PrivacyKey](/API_docs/types/PrivacyKey.html) + + +### Example: + +``` +$privacyKeyVoiceMessages = ['_' => 'privacyKeyVoiceMessages']; +``` diff --git a/docs/API_docs/constructors/privacyValueAllowAll.md b/docs/API_docs/constructors/privacyValueAllowAll.md new file mode 100644 index 0000000000..a961efbd7b --- /dev/null +++ b/docs/API_docs/constructors/privacyValueAllowAll.md @@ -0,0 +1,24 @@ +--- +title: "privacyValueAllowAll" +description: "Allow all users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueAllowAll +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow all users + + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueAllowAll = ['_' => 'privacyValueAllowAll']; +``` diff --git a/docs/API_docs/constructors/privacyValueAllowChatParticipants.md b/docs/API_docs/constructors/privacyValueAllowChatParticipants.md new file mode 100644 index 0000000000..74c94ebd54 --- /dev/null +++ b/docs/API_docs/constructors/privacyValueAllowChatParticipants.md @@ -0,0 +1,29 @@ +--- +title: "privacyValueAllowChatParticipants" +description: "Allow all participants of certain chats" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueAllowChatParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow all participants of certain chats + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chats|Array of [long](/API_docs/types/long.html) | Yes|Allowed chats| + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueAllowChatParticipants = ['_' => 'privacyValueAllowChatParticipants', 'chats' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/privacyValueAllowCloseFriends.md b/docs/API_docs/constructors/privacyValueAllowCloseFriends.md new file mode 100644 index 0000000000..c5f3003558 --- /dev/null +++ b/docs/API_docs/constructors/privacyValueAllowCloseFriends.md @@ -0,0 +1,24 @@ +--- +title: "privacyValueAllowCloseFriends" +description: "Allow only close friends »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueAllowCloseFriends +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow only [close friends »](https://core.telegram.org/api/privacy) + + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueAllowCloseFriends = ['_' => 'privacyValueAllowCloseFriends']; +``` diff --git a/docs/API_docs/constructors/privacyValueAllowContacts.md b/docs/API_docs/constructors/privacyValueAllowContacts.md new file mode 100644 index 0000000000..60160d2d34 --- /dev/null +++ b/docs/API_docs/constructors/privacyValueAllowContacts.md @@ -0,0 +1,24 @@ +--- +title: "privacyValueAllowContacts" +description: "Allow all contacts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueAllowContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow all contacts + + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueAllowContacts = ['_' => 'privacyValueAllowContacts']; +``` diff --git a/docs/API_docs/constructors/privacyValueAllowPremium.md b/docs/API_docs/constructors/privacyValueAllowPremium.md new file mode 100644 index 0000000000..d5c963bb1b --- /dev/null +++ b/docs/API_docs/constructors/privacyValueAllowPremium.md @@ -0,0 +1,22 @@ +--- +title: "privacyValueAllowPremium" +description: "privacyValueAllowPremium attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueAllowPremium +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueAllowPremium = ['_' => 'privacyValueAllowPremium']; +``` diff --git a/docs/API_docs/constructors/privacyValueAllowUsers.md b/docs/API_docs/constructors/privacyValueAllowUsers.md new file mode 100644 index 0000000000..87b3602c4c --- /dev/null +++ b/docs/API_docs/constructors/privacyValueAllowUsers.md @@ -0,0 +1,29 @@ +--- +title: "privacyValueAllowUsers" +description: "Allow only certain users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueAllowUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Allow only certain users + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|Array of [long](/API_docs/types/long.html) | Yes|Allowed users| + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueAllowUsers = ['_' => 'privacyValueAllowUsers', 'users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/privacyValueDisallowAll.md b/docs/API_docs/constructors/privacyValueDisallowAll.md new file mode 100644 index 0000000000..8618b9c2b4 --- /dev/null +++ b/docs/API_docs/constructors/privacyValueDisallowAll.md @@ -0,0 +1,24 @@ +--- +title: "privacyValueDisallowAll" +description: "Disallow all users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueDisallowAll +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow all users + + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueDisallowAll = ['_' => 'privacyValueDisallowAll']; +``` diff --git a/docs/API_docs/constructors/privacyValueDisallowChatParticipants.md b/docs/API_docs/constructors/privacyValueDisallowChatParticipants.md new file mode 100644 index 0000000000..3a220f4d93 --- /dev/null +++ b/docs/API_docs/constructors/privacyValueDisallowChatParticipants.md @@ -0,0 +1,29 @@ +--- +title: "privacyValueDisallowChatParticipants" +description: "Disallow only participants of certain chats" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueDisallowChatParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow only participants of certain chats + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chats|Array of [long](/API_docs/types/long.html) | Yes|Disallowed chats| + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueDisallowChatParticipants = ['_' => 'privacyValueDisallowChatParticipants', 'chats' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/privacyValueDisallowContacts.md b/docs/API_docs/constructors/privacyValueDisallowContacts.md new file mode 100644 index 0000000000..619845b60c --- /dev/null +++ b/docs/API_docs/constructors/privacyValueDisallowContacts.md @@ -0,0 +1,24 @@ +--- +title: "privacyValueDisallowContacts" +description: "Disallow only contacts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueDisallowContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow only contacts + + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueDisallowContacts = ['_' => 'privacyValueDisallowContacts']; +``` diff --git a/docs/API_docs/constructors/privacyValueDisallowUsers.md b/docs/API_docs/constructors/privacyValueDisallowUsers.md new file mode 100644 index 0000000000..afe4d0854e --- /dev/null +++ b/docs/API_docs/constructors/privacyValueDisallowUsers.md @@ -0,0 +1,29 @@ +--- +title: "privacyValueDisallowUsers" +description: "Disallow only certain users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: privacyValueDisallowUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Disallow only certain users + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|users|Array of [long](/API_docs/types/long.html) | Yes|Disallowed users| + + + +### Type: [PrivacyRule](/API_docs/types/PrivacyRule.html) + + +### Example: + +``` +$privacyValueDisallowUsers = ['_' => 'privacyValueDisallowUsers', 'users' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/publicForwardMessage.md b/docs/API_docs/constructors/publicForwardMessage.md new file mode 100644 index 0000000000..b276ff7e62 --- /dev/null +++ b/docs/API_docs/constructors/publicForwardMessage.md @@ -0,0 +1,29 @@ +--- +title: "publicForwardMessage" +description: "Contains info about a forward of a story as a message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: publicForwardMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a forward of a [story](https://core.telegram.org/api/stories) as a message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|Info about the message with the reposted story.| + + + +### Type: [PublicForward](/API_docs/types/PublicForward.html) + + +### Example: + +``` +$publicForwardMessage = ['_' => 'publicForwardMessage', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/publicForwardStory.md b/docs/API_docs/constructors/publicForwardStory.md new file mode 100644 index 0000000000..af04d06872 --- /dev/null +++ b/docs/API_docs/constructors/publicForwardStory.md @@ -0,0 +1,30 @@ +--- +title: "publicForwardStory" +description: "Contains info about a forward of a story as a repost by a public channel." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: publicForwardStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about a forward of a [story](https://core.telegram.org/api/stories) as a repost by a public channel. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The channel that reposted the story.| +|story|[StoryItem](/API_docs/types/StoryItem.html) | Yes|The reposted story (may be different from the original story).| + + + +### Type: [PublicForward](/API_docs/types/PublicForward.html) + + +### Example: + +``` +$publicForwardStory = ['_' => 'publicForwardStory', 'peer' => long, 'story' => StoryItem]; +``` diff --git a/docs/API_docs/constructors/quickReply.md b/docs/API_docs/constructors/quickReply.md new file mode 100644 index 0000000000..46ad48eef6 --- /dev/null +++ b/docs/API_docs/constructors/quickReply.md @@ -0,0 +1,30 @@ +--- +title: "quickReply" +description: "quickReply attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: quickReply +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| +|shortcut|[string](/API_docs/types/string.html) | Yes| +|top\_message|[int](/API_docs/types/int.html) | Yes| +|count|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [QuickReply](/API_docs/types/QuickReply.html) + + +### Example: + +``` +$quickReply = ['_' => 'quickReply', 'shortcut_id' => int, 'shortcut' => 'string', 'top_message' => int, 'count' => int]; +``` diff --git a/docs/API_docs/constructors/reactionCount.md b/docs/API_docs/constructors/reactionCount.md new file mode 100644 index 0000000000..53fd6331b4 --- /dev/null +++ b/docs/API_docs/constructors/reactionCount.md @@ -0,0 +1,31 @@ +--- +title: "reactionCount" +description: "Reactions" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionCount +[Back to constructors index](/API_docs/constructors/index.html) + + + +Reactions + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chosen\_order|[int](/API_docs/types/int.html) | Optional|If set, indicates that the current user also sent this reaction.
The integer value indicates when was the reaction added: the bigger the value, the newer the reaction.| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|The reaction.| +|count|[int](/API_docs/types/int.html) | Yes|Number of users that reacted with this emoji.| + + + +### Type: [ReactionCount](/API_docs/types/ReactionCount.html) + + +### Example: + +``` +$reactionCount = ['_' => 'reactionCount', 'chosen_order' => int, 'reaction' => Reaction, 'count' => int]; +``` diff --git a/docs/API_docs/constructors/reactionCustomEmoji.md b/docs/API_docs/constructors/reactionCustomEmoji.md new file mode 100644 index 0000000000..49f83a6ef7 --- /dev/null +++ b/docs/API_docs/constructors/reactionCustomEmoji.md @@ -0,0 +1,29 @@ +--- +title: "reactionCustomEmoji" +description: "Custom emoji message reaction" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionCustomEmoji +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Custom emoji](https://core.telegram.org/api/custom-emoji) message reaction + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document\_id|[long](/API_docs/types/long.html) | Yes|[Custom emoji document ID](https://core.telegram.org/api/custom-emoji)| + + + +### Type: [Reaction](/API_docs/types/Reaction.html) + + +### Example: + +``` +$reactionCustomEmoji = ['_' => 'reactionCustomEmoji', 'document_id' => long]; +``` diff --git a/docs/API_docs/constructors/reactionEmoji.md b/docs/API_docs/constructors/reactionEmoji.md new file mode 100644 index 0000000000..a35f4ee818 --- /dev/null +++ b/docs/API_docs/constructors/reactionEmoji.md @@ -0,0 +1,29 @@ +--- +title: "reactionEmoji" +description: "Normal emoji message reaction" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionEmoji +[Back to constructors index](/API_docs/constructors/index.html) + + + +Normal emoji message reaction + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|Emoji| + + + +### Type: [Reaction](/API_docs/types/Reaction.html) + + +### Example: + +``` +$reactionEmoji = ['_' => 'reactionEmoji', 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/reactionEmpty.md b/docs/API_docs/constructors/reactionEmpty.md new file mode 100644 index 0000000000..cbaa00bae6 --- /dev/null +++ b/docs/API_docs/constructors/reactionEmpty.md @@ -0,0 +1,24 @@ +--- +title: "reactionEmpty" +description: "No reaction" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No reaction + + + + +### Type: [Reaction](/API_docs/types/Reaction.html) + + +### Example: + +``` +$reactionEmpty = ['_' => 'reactionEmpty']; +``` diff --git a/docs/API_docs/constructors/reactionNotificationsFromAll.md b/docs/API_docs/constructors/reactionNotificationsFromAll.md new file mode 100644 index 0000000000..d6b3571b81 --- /dev/null +++ b/docs/API_docs/constructors/reactionNotificationsFromAll.md @@ -0,0 +1,22 @@ +--- +title: "reactionNotificationsFromAll" +description: "reactionNotificationsFromAll attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionNotificationsFromAll +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html) + + +### Example: + +``` +$reactionNotificationsFromAll = ['_' => 'reactionNotificationsFromAll']; +``` diff --git a/docs/API_docs/constructors/reactionNotificationsFromContacts.md b/docs/API_docs/constructors/reactionNotificationsFromContacts.md new file mode 100644 index 0000000000..26bdbed70b --- /dev/null +++ b/docs/API_docs/constructors/reactionNotificationsFromContacts.md @@ -0,0 +1,22 @@ +--- +title: "reactionNotificationsFromContacts" +description: "reactionNotificationsFromContacts attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionNotificationsFromContacts +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html) + + +### Example: + +``` +$reactionNotificationsFromContacts = ['_' => 'reactionNotificationsFromContacts']; +``` diff --git a/docs/API_docs/constructors/reactionsNotifySettings.md b/docs/API_docs/constructors/reactionsNotifySettings.md new file mode 100644 index 0000000000..1233a8a4a1 --- /dev/null +++ b/docs/API_docs/constructors/reactionsNotifySettings.md @@ -0,0 +1,30 @@ +--- +title: "reactionsNotifySettings" +description: "reactionsNotifySettings attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: reactionsNotifySettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|messages\_notify\_from|[ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html) | Optional| +|stories\_notify\_from|[ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html) | Optional| +|sound|[NotificationSound](/API_docs/types/NotificationSound.html) | Yes| +|show\_previews|[Bool](/API_docs/types/Bool.html) | Yes| + + + +### Type: [ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) + + +### Example: + +``` +$reactionsNotifySettings = ['_' => 'reactionsNotifySettings', 'messages_notify_from' => ReactionNotificationsFrom, 'stories_notify_from' => ReactionNotificationsFrom, 'sound' => NotificationSound, 'show_previews' => Bool]; +``` diff --git a/docs/API_docs/constructors/readParticipantDate.md b/docs/API_docs/constructors/readParticipantDate.md new file mode 100644 index 0000000000..5c442723ec --- /dev/null +++ b/docs/API_docs/constructors/readParticipantDate.md @@ -0,0 +1,30 @@ +--- +title: "readParticipantDate" +description: "Contains info about when a certain participant has read a message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: readParticipantDate +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about when a certain participant has read a message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|date|[int](/API_docs/types/int.html) | Yes|When the user read the message| + + + +### Type: [ReadParticipantDate](/API_docs/types/ReadParticipantDate.html) + + +### Example: + +``` +$readParticipantDate = ['_' => 'readParticipantDate', 'user_id' => long, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/receivedNotifyMessage.md b/docs/API_docs/constructors/receivedNotifyMessage.md new file mode 100644 index 0000000000..aaeb6294a9 --- /dev/null +++ b/docs/API_docs/constructors/receivedNotifyMessage.md @@ -0,0 +1,29 @@ +--- +title: "receivedNotifyMessage" +description: "Message ID, for which PUSH-notifications were cancelled." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: receivedNotifyMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message ID, for which PUSH-notifications were cancelled. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Message ID, for which PUSH-notifications were canceled| + + + +### Type: [ReceivedNotifyMessage](/API_docs/types/ReceivedNotifyMessage.html) + + +### Example: + +``` +$receivedNotifyMessage = ['_' => 'receivedNotifyMessage', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/recentMeUrlChat.md b/docs/API_docs/constructors/recentMeUrlChat.md new file mode 100644 index 0000000000..fd36f6b4eb --- /dev/null +++ b/docs/API_docs/constructors/recentMeUrlChat.md @@ -0,0 +1,30 @@ +--- +title: "recentMeUrlChat" +description: "Recent t.me link to a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: recentMeUrlChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recent t.me link to a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|t.me URL| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Chat ID| + + + +### Type: [RecentMeUrl](/API_docs/types/RecentMeUrl.html) + + +### Example: + +``` +$recentMeUrlChat = ['_' => 'recentMeUrlChat', 'url' => 'string', 'chat_id' => long]; +``` diff --git a/docs/API_docs/constructors/recentMeUrlChatInvite.md b/docs/API_docs/constructors/recentMeUrlChatInvite.md new file mode 100644 index 0000000000..ae1db20452 --- /dev/null +++ b/docs/API_docs/constructors/recentMeUrlChatInvite.md @@ -0,0 +1,30 @@ +--- +title: "recentMeUrlChatInvite" +description: "Recent t.me invite link to a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: recentMeUrlChatInvite +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recent t.me invite link to a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|t.me URL| +|chat\_invite|[ChatInvite](/API_docs/types/ChatInvite.html) | Yes|Chat invitation| + + + +### Type: [RecentMeUrl](/API_docs/types/RecentMeUrl.html) + + +### Example: + +``` +$recentMeUrlChatInvite = ['_' => 'recentMeUrlChatInvite', 'url' => 'string', 'chat_invite' => ChatInvite]; +``` diff --git a/docs/API_docs/constructors/recentMeUrlStickerSet.md b/docs/API_docs/constructors/recentMeUrlStickerSet.md new file mode 100644 index 0000000000..fb5695fe94 --- /dev/null +++ b/docs/API_docs/constructors/recentMeUrlStickerSet.md @@ -0,0 +1,30 @@ +--- +title: "recentMeUrlStickerSet" +description: "Recent t.me stickerset installation URL" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: recentMeUrlStickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recent t.me stickerset installation URL + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|t.me URL| +|set|[StickerSetCovered](/API_docs/types/StickerSetCovered.html) | Yes|Stickerset| + + + +### Type: [RecentMeUrl](/API_docs/types/RecentMeUrl.html) + + +### Example: + +``` +$recentMeUrlStickerSet = ['_' => 'recentMeUrlStickerSet', 'url' => 'string', 'set' => StickerSetCovered]; +``` diff --git a/docs/API_docs/constructors/recentMeUrlUnknown.md b/docs/API_docs/constructors/recentMeUrlUnknown.md new file mode 100644 index 0000000000..cd1b657222 --- /dev/null +++ b/docs/API_docs/constructors/recentMeUrlUnknown.md @@ -0,0 +1,29 @@ +--- +title: "recentMeUrlUnknown" +description: "Unknown t.me url" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: recentMeUrlUnknown +[Back to constructors index](/API_docs/constructors/index.html) + + + +Unknown t.me url + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|URL| + + + +### Type: [RecentMeUrl](/API_docs/types/RecentMeUrl.html) + + +### Example: + +``` +$recentMeUrlUnknown = ['_' => 'recentMeUrlUnknown', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/recentMeUrlUser.md b/docs/API_docs/constructors/recentMeUrlUser.md new file mode 100644 index 0000000000..e196defa00 --- /dev/null +++ b/docs/API_docs/constructors/recentMeUrlUser.md @@ -0,0 +1,30 @@ +--- +title: "recentMeUrlUser" +description: "Recent t.me link to a user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: recentMeUrlUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +Recent t.me link to a user + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|URL| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| + + + +### Type: [RecentMeUrl](/API_docs/types/RecentMeUrl.html) + + +### Example: + +``` +$recentMeUrlUser = ['_' => 'recentMeUrlUser', 'url' => 'string', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/replyInlineMarkup.md b/docs/API_docs/constructors/replyInlineMarkup.md new file mode 100644 index 0000000000..4b681d736a --- /dev/null +++ b/docs/API_docs/constructors/replyInlineMarkup.md @@ -0,0 +1,29 @@ +--- +title: "replyInlineMarkup" +description: "Bot or inline keyboard" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: replyInlineMarkup +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bot or inline keyboard + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|rows|Array of [KeyboardButtonRow](/API_docs/types/KeyboardButtonRow.html) | Yes|Bot or inline keyboard rows| + + + +### Type: [ReplyMarkup](/API_docs/types/ReplyMarkup.html) + + +### Example: + +``` +$replyInlineMarkup = ['_' => 'replyInlineMarkup', 'rows' => [KeyboardButtonRow, KeyboardButtonRow]]; +``` diff --git a/docs/API_docs/constructors/replyKeyboardForceReply.md b/docs/API_docs/constructors/replyKeyboardForceReply.md new file mode 100644 index 0000000000..e0caa88b7d --- /dev/null +++ b/docs/API_docs/constructors/replyKeyboardForceReply.md @@ -0,0 +1,31 @@ +--- +title: "replyKeyboardForceReply" +description: "Force the user to send a reply" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: replyKeyboardForceReply +[Back to constructors index](/API_docs/constructors/index.html) + + + +Force the user to send a reply + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|single\_use|[Bool](/API_docs/types/Bool.html) | Optional|Requests clients to hide the keyboard as soon as it's been used. The keyboard will still be available, but clients will automatically display the usual letter-keyboard in the chat – the user can press a special button in the input field to see the custom keyboard again.| +|selective|[Bool](/API_docs/types/Bool.html) | Optional|Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply\_to\_message\_id), sender of the original message.
Example: A user requests to change the bot's language, bot replies to the request with a keyboard to select the new language. Other users in the group don't see the keyboard.| +|placeholder|[string](/API_docs/types/string.html) | Optional|The placeholder to be shown in the input field when the keyboard is active; 1-64 characters.| + + + +### Type: [ReplyMarkup](/API_docs/types/ReplyMarkup.html) + + +### Example: + +``` +$replyKeyboardForceReply = ['_' => 'replyKeyboardForceReply', 'single_use' => Bool, 'selective' => Bool, 'placeholder' => 'string']; +``` diff --git a/docs/API_docs/constructors/replyKeyboardHide.md b/docs/API_docs/constructors/replyKeyboardHide.md new file mode 100644 index 0000000000..23727b2489 --- /dev/null +++ b/docs/API_docs/constructors/replyKeyboardHide.md @@ -0,0 +1,29 @@ +--- +title: "replyKeyboardHide" +description: "Hide sent bot keyboard" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: replyKeyboardHide +[Back to constructors index](/API_docs/constructors/index.html) + + + +Hide sent bot keyboard + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|selective|[Bool](/API_docs/types/Bool.html) | Optional|Use this flag if you want to remove the keyboard for specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply\_to\_message\_id), sender of the original message.

Example: A user votes in a poll, bot returns confirmation message in reply to the vote and removes the keyboard for that user, while still showing the keyboard with poll options to users who haven't voted yet| + + + +### Type: [ReplyMarkup](/API_docs/types/ReplyMarkup.html) + + +### Example: + +``` +$replyKeyboardHide = ['_' => 'replyKeyboardHide', 'selective' => Bool]; +``` diff --git a/docs/API_docs/constructors/replyKeyboardMarkup.md b/docs/API_docs/constructors/replyKeyboardMarkup.md new file mode 100644 index 0000000000..ee47c3f2e2 --- /dev/null +++ b/docs/API_docs/constructors/replyKeyboardMarkup.md @@ -0,0 +1,34 @@ +--- +title: "replyKeyboardMarkup" +description: "Bot keyboard" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: replyKeyboardMarkup +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bot keyboard + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|resize|[Bool](/API_docs/types/Bool.html) | Optional|Requests clients to resize the keyboard vertically for optimal fit (e.g., make the keyboard smaller if there are just two rows of buttons). If not set, the custom keyboard is always of the same height as the app's standard keyboard.| +|single\_use|[Bool](/API_docs/types/Bool.html) | Optional|Requests clients to hide the keyboard as soon as it's been used. The keyboard will still be available, but clients will automatically display the usual letter-keyboard in the chat – the user can press a special button in the input field to see the custom keyboard again.| +|selective|[Bool](/API_docs/types/Bool.html) | Optional|Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot's message is a reply (has reply\_to\_message\_id), sender of the original message.

Example: A user requests to change the bot's language, bot replies to the request with a keyboard to select the new language. Other users in the group don't see the keyboard.| +|persistent|[Bool](/API_docs/types/Bool.html) | Optional|Requests clients to always show the keyboard when the regular keyboard is hidden.| +|rows|Array of [KeyboardButtonRow](/API_docs/types/KeyboardButtonRow.html) | Yes|Button row| +|placeholder|[string](/API_docs/types/string.html) | Optional|The placeholder to be shown in the input field when the keyboard is active; 1-64 characters.| + + + +### Type: [ReplyMarkup](/API_docs/types/ReplyMarkup.html) + + +### Example: + +``` +$replyKeyboardMarkup = ['_' => 'replyKeyboardMarkup', 'resize' => Bool, 'single_use' => Bool, 'selective' => Bool, 'persistent' => Bool, 'rows' => [KeyboardButtonRow, KeyboardButtonRow], 'placeholder' => 'string']; +``` diff --git a/docs/API_docs/constructors/requestPeerTypeBroadcast.md b/docs/API_docs/constructors/requestPeerTypeBroadcast.md new file mode 100644 index 0000000000..0aecd46062 --- /dev/null +++ b/docs/API_docs/constructors/requestPeerTypeBroadcast.md @@ -0,0 +1,32 @@ +--- +title: "requestPeerTypeBroadcast" +description: "Choose a channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: requestPeerTypeBroadcast +[Back to constructors index](/API_docs/constructors/index.html) + + + +Choose a channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|creator|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow only choosing channels that were created by the current user.| +|has\_username|[Bool](/API_docs/types/Bool.html) | Optional|If specified, allows only choosing channels with or without a username, according to the value of [Bool](../types/Bool.html).| +|user\_admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|If specified, allows only choosing channels where the current user is an admin with at least the specified admin rights.| +|bot\_admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|If specified, allows only choosing channels where the bot is an admin with at least the specified admin rights.| + + + +### Type: [RequestPeerType](/API_docs/types/RequestPeerType.html) + + +### Example: + +``` +$requestPeerTypeBroadcast = ['_' => 'requestPeerTypeBroadcast', 'creator' => Bool, 'has_username' => Bool, 'user_admin_rights' => ChatAdminRights, 'bot_admin_rights' => ChatAdminRights]; +``` diff --git a/docs/API_docs/constructors/requestPeerTypeChat.md b/docs/API_docs/constructors/requestPeerTypeChat.md new file mode 100644 index 0000000000..f16b2067f7 --- /dev/null +++ b/docs/API_docs/constructors/requestPeerTypeChat.md @@ -0,0 +1,34 @@ +--- +title: "requestPeerTypeChat" +description: "Choose a chat or supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: requestPeerTypeChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Choose a chat or supergroup + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|creator|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow only choosing chats or supergroups that were created by the current user.| +|bot\_participant|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow only choosing chats or supergroups where the bot is a participant.| +|has\_username|[Bool](/API_docs/types/Bool.html) | Optional|If specified, allows only choosing channels with or without a username, according to the value of [Bool](../types/Bool.html).| +|forum|[Bool](/API_docs/types/Bool.html) | Optional|If specified, allows only choosing chats or supergroups that are or aren't [forums](https://core.telegram.org/api/forum), according to the value of [Bool](../types/Bool.html).| +|user\_admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|If specified, allows only choosing chats or supergroups where the current user is an admin with at least the specified admin rights.| +|bot\_admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|If specified, allows only choosing chats or supergroups where the bot is an admin with at least the specified admin rights.| + + + +### Type: [RequestPeerType](/API_docs/types/RequestPeerType.html) + + +### Example: + +``` +$requestPeerTypeChat = ['_' => 'requestPeerTypeChat', 'creator' => Bool, 'bot_participant' => Bool, 'has_username' => Bool, 'forum' => Bool, 'user_admin_rights' => ChatAdminRights, 'bot_admin_rights' => ChatAdminRights]; +``` diff --git a/docs/API_docs/constructors/requestPeerTypeUser.md b/docs/API_docs/constructors/requestPeerTypeUser.md new file mode 100644 index 0000000000..0b2c15065e --- /dev/null +++ b/docs/API_docs/constructors/requestPeerTypeUser.md @@ -0,0 +1,30 @@ +--- +title: "requestPeerTypeUser" +description: "Choose a user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: requestPeerTypeUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +Choose a user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|bot|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow choosing only bots.| +|premium|[Bool](/API_docs/types/Bool.html) | Optional|Whether to allow choosing only [Premium](https://core.telegram.org/api/premium) users.| + + + +### Type: [RequestPeerType](/API_docs/types/RequestPeerType.html) + + +### Example: + +``` +$requestPeerTypeUser = ['_' => 'requestPeerTypeUser', 'bot' => Bool, 'premium' => Bool]; +``` diff --git a/docs/API_docs/constructors/requestedPeerChannel.md b/docs/API_docs/constructors/requestedPeerChannel.md new file mode 100644 index 0000000000..d7291ea31c --- /dev/null +++ b/docs/API_docs/constructors/requestedPeerChannel.md @@ -0,0 +1,30 @@ +--- +title: "requestedPeerChannel" +description: "requestedPeerChannel attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: requestedPeerChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|channel\_id|[long](/API_docs/types/long.html) | Yes| +|title|[string](/API_docs/types/string.html) | Optional| +|username|[string](/API_docs/types/string.html) | Optional| +|photo|[Photo](/API_docs/types/Photo.html) | Optional| + + + +### Type: [RequestedPeer](/API_docs/types/RequestedPeer.html) + + +### Example: + +``` +$requestedPeerChannel = ['_' => 'requestedPeerChannel', 'channel_id' => long, 'title' => 'string', 'username' => 'string', 'photo' => Photo]; +``` diff --git a/docs/API_docs/constructors/requestedPeerChat.md b/docs/API_docs/constructors/requestedPeerChat.md new file mode 100644 index 0000000000..2c7e6dac52 --- /dev/null +++ b/docs/API_docs/constructors/requestedPeerChat.md @@ -0,0 +1,29 @@ +--- +title: "requestedPeerChat" +description: "requestedPeerChat attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: requestedPeerChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|chat\_id|[long](/API_docs/types/long.html) | Yes| +|title|[string](/API_docs/types/string.html) | Optional| +|photo|[Photo](/API_docs/types/Photo.html) | Optional| + + + +### Type: [RequestedPeer](/API_docs/types/RequestedPeer.html) + + +### Example: + +``` +$requestedPeerChat = ['_' => 'requestedPeerChat', 'chat_id' => long, 'title' => 'string', 'photo' => Photo]; +``` diff --git a/docs/API_docs/constructors/requestedPeerUser.md b/docs/API_docs/constructors/requestedPeerUser.md new file mode 100644 index 0000000000..0986415d74 --- /dev/null +++ b/docs/API_docs/constructors/requestedPeerUser.md @@ -0,0 +1,31 @@ +--- +title: "requestedPeerUser" +description: "requestedPeerUser attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: requestedPeerUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|user\_id|[long](/API_docs/types/long.html) | Yes| +|first\_name|[string](/API_docs/types/string.html) | Optional| +|last\_name|[string](/API_docs/types/string.html) | Optional| +|username|[string](/API_docs/types/string.html) | Optional| +|photo|[Photo](/API_docs/types/Photo.html) | Optional| + + + +### Type: [RequestedPeer](/API_docs/types/RequestedPeer.html) + + +### Example: + +``` +$requestedPeerUser = ['_' => 'requestedPeerUser', 'user_id' => long, 'first_name' => 'string', 'last_name' => 'string', 'username' => 'string', 'photo' => Photo]; +``` diff --git a/docs/API_docs/constructors/restrictionReason.md b/docs/API_docs/constructors/restrictionReason.md new file mode 100644 index 0000000000..d1edd68c4e --- /dev/null +++ b/docs/API_docs/constructors/restrictionReason.md @@ -0,0 +1,33 @@ +--- +title: "restrictionReason" +description: "Restriction reason." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: restrictionReason +[Back to constructors index](/API_docs/constructors/index.html) + + + +Restriction reason. + +Contains the reason why access to a certain object must be restricted. Clients are supposed to deny access to the channel if the `platform` field is equal to `all` or to the current platform (`ios`, `android`, `wp`, etc.). Platforms can be concatenated (`ios-android`, `ios-wp`), unknown platforms are to be ignored. The `text` is the error message that should be shown to the user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|platform|[string](/API_docs/types/string.html) | Yes|Platform identifier (ios, android, wp, all, etc.), can be concatenated with a dash as separator (`android-ios`, `ios-wp`, etc)| +|reason|[string](/API_docs/types/string.html) | Yes|Restriction reason (`porno`, `terms`, etc.)| +|text|[string](/API_docs/types/string.html) | Yes|Error message to be shown to the user| + + + +### Type: [RestrictionReason](/API_docs/types/RestrictionReason.html) + + +### Example: + +``` +$restrictionReason = ['_' => 'restrictionReason', 'platform' => 'string', 'reason' => 'string', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/savedDialog.md b/docs/API_docs/constructors/savedDialog.md new file mode 100644 index 0000000000..212f5bbc7a --- /dev/null +++ b/docs/API_docs/constructors/savedDialog.md @@ -0,0 +1,31 @@ +--- +title: "savedDialog" +description: "Represents a saved dialog »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: savedDialog +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [saved dialog »](https://core.telegram.org/api/saved-messages). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Is the dialog pinned| +|peer|[long](/API_docs/types/long.html) | Yes|The dialog| +|top\_message|[int](/API_docs/types/int.html) | Yes|The latest message ID| + + + +### Type: [SavedDialog](/API_docs/types/SavedDialog.html) + + +### Example: + +``` +$savedDialog = ['_' => 'savedDialog', 'pinned' => Bool, 'peer' => long, 'top_message' => int]; +``` diff --git a/docs/API_docs/constructors/savedPhoneContact.md b/docs/API_docs/constructors/savedPhoneContact.md new file mode 100644 index 0000000000..d2e3d003e3 --- /dev/null +++ b/docs/API_docs/constructors/savedPhoneContact.md @@ -0,0 +1,32 @@ +--- +title: "savedPhoneContact" +description: "Saved contact" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: savedPhoneContact +[Back to constructors index](/API_docs/constructors/index.html) + + + +Saved contact + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone|[string](/API_docs/types/string.html) | Yes|Phone number| +|first\_name|[string](/API_docs/types/string.html) | Yes|First name| +|last\_name|[string](/API_docs/types/string.html) | Yes|Last name| +|date|[int](/API_docs/types/int.html) | Yes|Date added| + + + +### Type: [SavedContact](/API_docs/types/SavedContact.html) + + +### Example: + +``` +$savedPhoneContact = ['_' => 'savedPhoneContact', 'phone' => 'string', 'first_name' => 'string', 'last_name' => 'string', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/savedReactionTag.md b/docs/API_docs/constructors/savedReactionTag.md new file mode 100644 index 0000000000..8ffa116016 --- /dev/null +++ b/docs/API_docs/constructors/savedReactionTag.md @@ -0,0 +1,29 @@ +--- +title: "savedReactionTag" +description: "savedReactionTag attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: savedReactionTag +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional| +|title|[string](/API_docs/types/string.html) | Optional| +|count|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [SavedReactionTag](/API_docs/types/SavedReactionTag.html) + + +### Example: + +``` +$savedReactionTag = ['_' => 'savedReactionTag', 'reaction' => Reaction, 'title' => 'string', 'count' => int]; +``` diff --git a/docs/API_docs/constructors/searchResultPosition.md b/docs/API_docs/constructors/searchResultPosition.md new file mode 100644 index 0000000000..a6ffaefb3b --- /dev/null +++ b/docs/API_docs/constructors/searchResultPosition.md @@ -0,0 +1,31 @@ +--- +title: "searchResultPosition" +description: "Information about a message in a specific position" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: searchResultPosition +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about a message in a specific position + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID| +|date|[int](/API_docs/types/int.html) | Yes|When was the message sent| +|offset|[int](/API_docs/types/int.html) | Yes|0-based message position in the full list of suitable messages| + + + +### Type: [SearchResultsPosition](/API_docs/types/SearchResultsPosition.html) + + +### Example: + +``` +$searchResultPosition = ['_' => 'searchResultPosition', 'msg_id' => int, 'date' => int, 'offset' => int]; +``` diff --git a/docs/API_docs/constructors/searchResultsCalendarPeriod.md b/docs/API_docs/constructors/searchResultsCalendarPeriod.md new file mode 100644 index 0000000000..0bcd23529b --- /dev/null +++ b/docs/API_docs/constructors/searchResultsCalendarPeriod.md @@ -0,0 +1,34 @@ +--- +title: "searchResultsCalendarPeriod" +description: "Information about found messages sent on a specific day, used to split the messages in messages.searchResultsCalendar constructors by days." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: searchResultsCalendarPeriod +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about found messages sent on a specific day, used to split the `messages` in [messages.searchResultsCalendar](../constructors/messages.searchResultsCalendar.html) constructors by days. + +Multiple searchResultsCalendarPeriod constructors are returned in [messages.searchResultsCalendar](../constructors/messages.searchResultsCalendar.html), each containing information about the first, last and total number of messages matching the filter that were sent on a specific day. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|date|[int](/API_docs/types/int.html) | Yes|The day this object is referring to.| +|min\_msg\_id|[int](/API_docs/types/int.html) | Yes|First message ID that was sent on this day.| +|max\_msg\_id|[int](/API_docs/types/int.html) | Yes|Last message ID that was sent on this day.| +|count|[int](/API_docs/types/int.html) | Yes|All messages that were sent on this day.| + + + +### Type: [SearchResultsCalendarPeriod](/API_docs/types/SearchResultsCalendarPeriod.html) + + +### Example: + +``` +$searchResultsCalendarPeriod = ['_' => 'searchResultsCalendarPeriod', 'date' => int, 'min_msg_id' => int, 'max_msg_id' => int, 'count' => int]; +``` diff --git a/docs/API_docs/constructors/secureCredentialsEncrypted.md b/docs/API_docs/constructors/secureCredentialsEncrypted.md new file mode 100644 index 0000000000..fc1cc68881 --- /dev/null +++ b/docs/API_docs/constructors/secureCredentialsEncrypted.md @@ -0,0 +1,31 @@ +--- +title: "secureCredentialsEncrypted" +description: "Encrypted credentials required to decrypt telegram passport data." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureCredentialsEncrypted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Encrypted credentials required to decrypt [telegram passport](https://core.telegram.org/passport) data. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|data|[bytes](/API_docs/types/bytes.html) | Yes|Encrypted JSON-serialized data with unique user's payload, data hashes and secrets required for EncryptedPassportElement decryption and authentication, as described in [decrypting data »](https://core.telegram.org/passport#decrypting-data)| +|hash|[bytes](/API_docs/types/bytes.html) | Yes|Data hash for data authentication as described in [decrypting data »](https://core.telegram.org/passport#decrypting-data)| +|secret|[bytes](/API_docs/types/bytes.html) | Yes|Secret, encrypted with the bot's public RSA key, required for data decryption as described in [decrypting data »](https://core.telegram.org/passport#decrypting-data)| + + + +### Type: [SecureCredentialsEncrypted](/API_docs/types/SecureCredentialsEncrypted.html) + + +### Example: + +``` +$secureCredentialsEncrypted = ['_' => 'secureCredentialsEncrypted', 'data' => 'bytes', 'hash' => 'bytes', 'secret' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/secureData.md b/docs/API_docs/constructors/secureData.md new file mode 100644 index 0000000000..d897b54a38 --- /dev/null +++ b/docs/API_docs/constructors/secureData.md @@ -0,0 +1,31 @@ +--- +title: "secureData" +description: "Secure passport data, for more info see the passport docs »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureData +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure [passport](https://core.telegram.org/passport) data, for more info [see the passport docs »](https://core.telegram.org/passport/encryption#securedata) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|data|[bytes](/API_docs/types/bytes.html) | Yes|Data| +|data\_hash|[bytes](/API_docs/types/bytes.html) | Yes|Data hash| +|secret|[bytes](/API_docs/types/bytes.html) | Yes|Secret| + + + +### Type: [SecureData](/API_docs/types/SecureData.html) + + +### Example: + +``` +$secureData = ['_' => 'secureData', 'data' => 'bytes', 'data_hash' => 'bytes', 'secret' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/secureFile.md b/docs/API_docs/constructors/secureFile.md new file mode 100644 index 0000000000..3dcf16be79 --- /dev/null +++ b/docs/API_docs/constructors/secureFile.md @@ -0,0 +1,35 @@ +--- +title: "secureFile" +description: "Secure passport file, for more info see the passport docs »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure [passport](https://core.telegram.org/passport) file, for more info [see the passport docs »](https://core.telegram.org/passport/encryption#inputsecurefile) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|size|[long](/API_docs/types/long.html) | Yes|File size| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID| +|date|[int](/API_docs/types/int.html) | Yes|Date of upload| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|secret|[bytes](/API_docs/types/bytes.html) | Yes|Secret| + + + +### Type: [SecureFile](/API_docs/types/SecureFile.html) + + +### Example: + +``` +$secureFile = ['_' => 'secureFile', 'id' => long, 'access_hash' => long, 'size' => long, 'dc_id' => int, 'date' => int, 'file_hash' => 'bytes', 'secret' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/secureFileEmpty.md b/docs/API_docs/constructors/secureFileEmpty.md new file mode 100644 index 0000000000..85e73c2b8c --- /dev/null +++ b/docs/API_docs/constructors/secureFileEmpty.md @@ -0,0 +1,24 @@ +--- +title: "secureFileEmpty" +description: "Empty constructor" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureFileEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor + + + + +### Type: [SecureFile](/API_docs/types/SecureFile.html) + + +### Example: + +``` +$secureFileEmpty = ['_' => 'secureFileEmpty']; +``` diff --git a/docs/API_docs/constructors/securePasswordKdfAlgoPBKDF2HMACSHA512iter100000.md b/docs/API_docs/constructors/securePasswordKdfAlgoPBKDF2HMACSHA512iter100000.md new file mode 100644 index 0000000000..07270248f8 --- /dev/null +++ b/docs/API_docs/constructors/securePasswordKdfAlgoPBKDF2HMACSHA512iter100000.md @@ -0,0 +1,29 @@ +--- +title: "securePasswordKdfAlgoPBKDF2HMACSHA512iter100000" +description: "PBKDF2 with SHA512 and 100000 iterations KDF algo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: securePasswordKdfAlgoPBKDF2HMACSHA512iter100000 +[Back to constructors index](/API_docs/constructors/index.html) + + + +PBKDF2 with SHA512 and 100000 iterations KDF algo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|salt|[bytes](/API_docs/types/bytes.html) | Yes|Salt| + + + +### Type: [SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html) + + +### Example: + +``` +$securePasswordKdfAlgoPBKDF2HMACSHA512iter100000 = ['_' => 'securePasswordKdfAlgoPBKDF2HMACSHA512iter100000', 'salt' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/securePasswordKdfAlgoSHA512.md b/docs/API_docs/constructors/securePasswordKdfAlgoSHA512.md new file mode 100644 index 0000000000..20a67bffc1 --- /dev/null +++ b/docs/API_docs/constructors/securePasswordKdfAlgoSHA512.md @@ -0,0 +1,29 @@ +--- +title: "securePasswordKdfAlgoSHA512" +description: "SHA512 KDF algo" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: securePasswordKdfAlgoSHA512 +[Back to constructors index](/API_docs/constructors/index.html) + + + +SHA512 KDF algo + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|salt|[bytes](/API_docs/types/bytes.html) | Yes|Salt| + + + +### Type: [SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html) + + +### Example: + +``` +$securePasswordKdfAlgoSHA512 = ['_' => 'securePasswordKdfAlgoSHA512', 'salt' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/securePasswordKdfAlgoUnknown.md b/docs/API_docs/constructors/securePasswordKdfAlgoUnknown.md new file mode 100644 index 0000000000..52a1c5a852 --- /dev/null +++ b/docs/API_docs/constructors/securePasswordKdfAlgoUnknown.md @@ -0,0 +1,24 @@ +--- +title: "securePasswordKdfAlgoUnknown" +description: "Unknown KDF algo (most likely the client has to be updated)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: securePasswordKdfAlgoUnknown +[Back to constructors index](/API_docs/constructors/index.html) + + + +Unknown KDF algo (most likely the client has to be updated) + + + + +### Type: [SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html) + + +### Example: + +``` +$securePasswordKdfAlgoUnknown = ['_' => 'securePasswordKdfAlgoUnknown']; +``` diff --git a/docs/API_docs/constructors/securePlainEmail.md b/docs/API_docs/constructors/securePlainEmail.md new file mode 100644 index 0000000000..8706375587 --- /dev/null +++ b/docs/API_docs/constructors/securePlainEmail.md @@ -0,0 +1,29 @@ +--- +title: "securePlainEmail" +description: "Email address to use in telegram passport: it must be verified, first »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: securePlainEmail +[Back to constructors index](/API_docs/constructors/index.html) + + + +Email address to use in [telegram passport](https://core.telegram.org/passport): [it must be verified, first »](https://core.telegram.org/passport/encryption#secureplaindata). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|email|[string](/API_docs/types/string.html) | Yes|Email address| + + + +### Type: [SecurePlainData](/API_docs/types/SecurePlainData.html) + + +### Example: + +``` +$securePlainEmail = ['_' => 'securePlainEmail', 'email' => 'string']; +``` diff --git a/docs/API_docs/constructors/securePlainPhone.md b/docs/API_docs/constructors/securePlainPhone.md new file mode 100644 index 0000000000..9b45b9c120 --- /dev/null +++ b/docs/API_docs/constructors/securePlainPhone.md @@ -0,0 +1,29 @@ +--- +title: "securePlainPhone" +description: "Phone number to use in telegram passport: it must be verified, first »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: securePlainPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Phone number to use in [telegram passport](https://core.telegram.org/passport): [it must be verified, first »](https://core.telegram.org/passport/encryption#secureplaindata). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone|[string](/API_docs/types/string.html) | Yes|Phone number| + + + +### Type: [SecurePlainData](/API_docs/types/SecurePlainData.html) + + +### Example: + +``` +$securePlainPhone = ['_' => 'securePlainPhone', 'phone' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureRequiredType.md b/docs/API_docs/constructors/secureRequiredType.md new file mode 100644 index 0000000000..5cb9eedc91 --- /dev/null +++ b/docs/API_docs/constructors/secureRequiredType.md @@ -0,0 +1,32 @@ +--- +title: "secureRequiredType" +description: "Required type" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureRequiredType +[Back to constructors index](/API_docs/constructors/index.html) + + + +Required type + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|native\_names|[Bool](/API_docs/types/Bool.html) | Optional|Native names| +|selfie\_required|[Bool](/API_docs/types/Bool.html) | Optional|Is a selfie required| +|translation\_required|[Bool](/API_docs/types/Bool.html) | Optional|Is a translation required| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|Secure value type| + + + +### Type: [SecureRequiredType](/API_docs/types/SecureRequiredType.html) + + +### Example: + +``` +$secureRequiredType = ['_' => 'secureRequiredType', 'native_names' => Bool, 'selfie_required' => Bool, 'translation_required' => Bool, 'type' => SecureValueType]; +``` diff --git a/docs/API_docs/constructors/secureRequiredTypeOneOf.md b/docs/API_docs/constructors/secureRequiredTypeOneOf.md new file mode 100644 index 0000000000..384ce17fa7 --- /dev/null +++ b/docs/API_docs/constructors/secureRequiredTypeOneOf.md @@ -0,0 +1,29 @@ +--- +title: "secureRequiredTypeOneOf" +description: "One of" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureRequiredTypeOneOf +[Back to constructors index](/API_docs/constructors/index.html) + + + +One of + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|types|Array of [SecureRequiredType](/API_docs/types/SecureRequiredType.html) | Yes|Secure required value types| + + + +### Type: [SecureRequiredType](/API_docs/types/SecureRequiredType.html) + + +### Example: + +``` +$secureRequiredTypeOneOf = ['_' => 'secureRequiredTypeOneOf', 'types' => [SecureRequiredType, SecureRequiredType]]; +``` diff --git a/docs/API_docs/constructors/secureSecretSettings.md b/docs/API_docs/constructors/secureSecretSettings.md new file mode 100644 index 0000000000..d1d4eb3286 --- /dev/null +++ b/docs/API_docs/constructors/secureSecretSettings.md @@ -0,0 +1,31 @@ +--- +title: "secureSecretSettings" +description: "Secure settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureSecretSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|secure\_algo|[SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html) | Yes|Secure KDF algo| +|secure\_secret|[bytes](/API_docs/types/bytes.html) | Yes|Secure secret| +|secure\_secret\_id|[long](/API_docs/types/long.html) | Yes|Secret ID| + + + +### Type: [SecureSecretSettings](/API_docs/types/SecureSecretSettings.html) + + +### Example: + +``` +$secureSecretSettings = ['_' => 'secureSecretSettings', 'secure_algo' => SecurePasswordKdfAlgo, 'secure_secret' => 'bytes', 'secure_secret_id' => long]; +``` diff --git a/docs/API_docs/constructors/secureValue.md b/docs/API_docs/constructors/secureValue.md new file mode 100644 index 0000000000..8eba340b68 --- /dev/null +++ b/docs/API_docs/constructors/secureValue.md @@ -0,0 +1,37 @@ +--- +title: "secureValue" +description: "Secure value" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValue +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure value + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|Secure [passport](https://core.telegram.org/passport) value type| +|data|[SecureData](/API_docs/types/SecureData.html) | Optional|Encrypted [Telegram Passport](https://core.telegram.org/passport) element data| +|front\_side|[SecureFile](/API_docs/types/SecureFile.html) | Optional|Encrypted [passport](https://core.telegram.org/passport) file with the front side of the document| +|reverse\_side|[SecureFile](/API_docs/types/SecureFile.html) | Optional|Encrypted [passport](https://core.telegram.org/passport) file with the reverse side of the document| +|selfie|[SecureFile](/API_docs/types/SecureFile.html) | Optional|Encrypted [passport](https://core.telegram.org/passport) file with a selfie of the user holding the document| +|translation|Array of [SecureFile](/API_docs/types/SecureFile.html) | Optional|Array of encrypted [passport](https://core.telegram.org/passport) files with translated versions of the provided documents| +|files|Array of [SecureFile](/API_docs/types/SecureFile.html) | Optional|Array of encrypted [passport](https://core.telegram.org/passport) files with photos the of the documents| +|plain\_data|[SecurePlainData](/API_docs/types/SecurePlainData.html) | Optional|Plaintext verified [passport](https://core.telegram.org/passport) data| +|hash|[bytes](/API_docs/types/bytes.html) | Yes|Data hash| + + + +### Type: [SecureValue](/API_docs/types/SecureValue.html) + + +### Example: + +``` +$secureValue = ['_' => 'secureValue', 'type' => SecureValueType, 'data' => SecureData, 'front_side' => SecureFile, 'reverse_side' => SecureFile, 'selfie' => SecureFile, 'translation' => [SecureFile, SecureFile], 'files' => [SecureFile, SecureFile], 'plain_data' => SecurePlainData, 'hash' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/secureValueError.md b/docs/API_docs/constructors/secureValueError.md new file mode 100644 index 0000000000..8719b7c609 --- /dev/null +++ b/docs/API_docs/constructors/secureValueError.md @@ -0,0 +1,31 @@ +--- +title: "secureValueError" +description: "Secure value error" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueError +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure value error + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|Type of element which has the issue| +|hash|[bytes](/API_docs/types/bytes.html) | Yes|Hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueError = ['_' => 'secureValueError', 'type' => SecureValueType, 'hash' => 'bytes', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorData.md b/docs/API_docs/constructors/secureValueErrorData.md new file mode 100644 index 0000000000..135756a59d --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorData.md @@ -0,0 +1,32 @@ +--- +title: "secureValueErrorData" +description: "Represents an issue in one of the data fields that was provided by the user. The error is considered resolved when the field's value changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorData +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue in one of the data fields that was provided by the user. The error is considered resolved when the field's value changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|The section of the user's Telegram Passport which has the error, one of [secureValueTypePersonalDetails](../constructors/secureValueTypePersonalDetails.html), [secureValueTypePassport](../constructors/secureValueTypePassport.html), [secureValueTypeDriverLicense](../constructors/secureValueTypeDriverLicense.html), [secureValueTypeIdentityCard](../constructors/secureValueTypeIdentityCard.html), [secureValueTypeInternalPassport](../constructors/secureValueTypeInternalPassport.html), [secureValueTypeAddress](../constructors/secureValueTypeAddress.html)| +|data\_hash|[bytes](/API_docs/types/bytes.html) | Yes|Data hash| +|field|[string](/API_docs/types/string.html) | Yes|Name of the data field which has the error| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorData = ['_' => 'secureValueErrorData', 'type' => SecureValueType, 'data_hash' => 'bytes', 'field' => 'string', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorFile.md b/docs/API_docs/constructors/secureValueErrorFile.md new file mode 100644 index 0000000000..e3ee262d3a --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorFile.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorFile" +description: "Represents an issue with a document scan. The error is considered resolved when the file with the document scan changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with a document scan. The error is considered resolved when the file with the document scan changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypeUtilityBill](../constructors/secureValueTypeUtilityBill.html), [secureValueTypeBankStatement](../constructors/secureValueTypeBankStatement.html), [secureValueTypeRentalAgreement](../constructors/secureValueTypeRentalAgreement.html), [secureValueTypePassportRegistration](../constructors/secureValueTypePassportRegistration.html), [secureValueTypeTemporaryRegistration](../constructors/secureValueTypeTemporaryRegistration.html)| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorFile = ['_' => 'secureValueErrorFile', 'type' => SecureValueType, 'file_hash' => 'bytes', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorFiles.md b/docs/API_docs/constructors/secureValueErrorFiles.md new file mode 100644 index 0000000000..45b9c0467f --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorFiles.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorFiles" +description: "Represents an issue with a list of scans. The error is considered resolved when the list of files containing the scans changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorFiles +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with a list of scans. The error is considered resolved when the list of files containing the scans changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypeUtilityBill](../constructors/secureValueTypeUtilityBill.html), [secureValueTypeBankStatement](../constructors/secureValueTypeBankStatement.html), [secureValueTypeRentalAgreement](../constructors/secureValueTypeRentalAgreement.html), [secureValueTypePassportRegistration](../constructors/secureValueTypePassportRegistration.html), [secureValueTypeTemporaryRegistration](../constructors/secureValueTypeTemporaryRegistration.html)| +|file\_hash|Array of [bytes](/API_docs/types/bytes.html) | Yes|File hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorFiles = ['_' => 'secureValueErrorFiles', 'type' => SecureValueType, 'file_hash' => ['bytes', 'bytes'], 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorFrontSide.md b/docs/API_docs/constructors/secureValueErrorFrontSide.md new file mode 100644 index 0000000000..029f001664 --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorFrontSide.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorFrontSide" +description: "Represents an issue with the front side of a document. The error is considered resolved when the file with the front side of the document changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorFrontSide +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with the front side of a document. The error is considered resolved when the file with the front side of the document changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypePassport](../constructors/secureValueTypePassport.html), [secureValueTypeDriverLicense](../constructors/secureValueTypeDriverLicense.html), [secureValueTypeIdentityCard](../constructors/secureValueTypeIdentityCard.html), [secureValueTypeInternalPassport](../constructors/secureValueTypeInternalPassport.html)| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorFrontSide = ['_' => 'secureValueErrorFrontSide', 'type' => SecureValueType, 'file_hash' => 'bytes', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorReverseSide.md b/docs/API_docs/constructors/secureValueErrorReverseSide.md new file mode 100644 index 0000000000..549e542c1f --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorReverseSide.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorReverseSide" +description: "Represents an issue with the reverse side of a document. The error is considered resolved when the file with reverse side of the document changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorReverseSide +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with the reverse side of a document. The error is considered resolved when the file with reverse side of the document changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypeDriverLicense](../constructors/secureValueTypeDriverLicense.html), [secureValueTypeIdentityCard](../constructors/secureValueTypeIdentityCard.html)| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorReverseSide = ['_' => 'secureValueErrorReverseSide', 'type' => SecureValueType, 'file_hash' => 'bytes', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorSelfie.md b/docs/API_docs/constructors/secureValueErrorSelfie.md new file mode 100644 index 0000000000..d078da6c21 --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorSelfie.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorSelfie" +description: "Represents an issue with the selfie with a document. The error is considered resolved when the file with the selfie changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorSelfie +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with the selfie with a document. The error is considered resolved when the file with the selfie changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypePassport](../constructors/secureValueTypePassport.html), [secureValueTypeDriverLicense](../constructors/secureValueTypeDriverLicense.html), [secureValueTypeIdentityCard](../constructors/secureValueTypeIdentityCard.html), [secureValueTypeInternalPassport](../constructors/secureValueTypeInternalPassport.html)| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorSelfie = ['_' => 'secureValueErrorSelfie', 'type' => SecureValueType, 'file_hash' => 'bytes', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorTranslationFile.md b/docs/API_docs/constructors/secureValueErrorTranslationFile.md new file mode 100644 index 0000000000..deb363e70b --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorTranslationFile.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorTranslationFile" +description: "Represents an issue with one of the files that constitute the translation of a document. The error is considered resolved when the file changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorTranslationFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with one of the files that constitute the translation of a document. The error is considered resolved when the file changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypePersonalDetails](../constructors/secureValueTypePersonalDetails.html), [secureValueTypePassport](../constructors/secureValueTypePassport.html), [secureValueTypeDriverLicense](../constructors/secureValueTypeDriverLicense.html), [secureValueTypeIdentityCard](../constructors/secureValueTypeIdentityCard.html), [secureValueTypeInternalPassport](../constructors/secureValueTypeInternalPassport.html), [secureValueTypeUtilityBill](../constructors/secureValueTypeUtilityBill.html), [secureValueTypeBankStatement](../constructors/secureValueTypeBankStatement.html), [secureValueTypeRentalAgreement](../constructors/secureValueTypeRentalAgreement.html), [secureValueTypePassportRegistration](../constructors/secureValueTypePassportRegistration.html), [secureValueTypeTemporaryRegistration](../constructors/secureValueTypeTemporaryRegistration.html)| +|file\_hash|[bytes](/API_docs/types/bytes.html) | Yes|File hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorTranslationFile = ['_' => 'secureValueErrorTranslationFile', 'type' => SecureValueType, 'file_hash' => 'bytes', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueErrorTranslationFiles.md b/docs/API_docs/constructors/secureValueErrorTranslationFiles.md new file mode 100644 index 0000000000..cde9639dd8 --- /dev/null +++ b/docs/API_docs/constructors/secureValueErrorTranslationFiles.md @@ -0,0 +1,31 @@ +--- +title: "secureValueErrorTranslationFiles" +description: "Represents an issue with the translated version of a document. The error is considered resolved when a file with the document translation changes." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueErrorTranslationFiles +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an issue with the translated version of a document. The error is considered resolved when a file with the document translation changes. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|One of [secureValueTypePersonalDetails](../constructors/secureValueTypePersonalDetails.html), [secureValueTypePassport](../constructors/secureValueTypePassport.html), [secureValueTypeDriverLicense](../constructors/secureValueTypeDriverLicense.html), [secureValueTypeIdentityCard](../constructors/secureValueTypeIdentityCard.html), [secureValueTypeInternalPassport](../constructors/secureValueTypeInternalPassport.html), [secureValueTypeUtilityBill](../constructors/secureValueTypeUtilityBill.html), [secureValueTypeBankStatement](../constructors/secureValueTypeBankStatement.html), [secureValueTypeRentalAgreement](../constructors/secureValueTypeRentalAgreement.html), [secureValueTypePassportRegistration](../constructors/secureValueTypePassportRegistration.html), [secureValueTypeTemporaryRegistration](../constructors/secureValueTypeTemporaryRegistration.html)| +|file\_hash|Array of [bytes](/API_docs/types/bytes.html) | Yes|Hash| +|text|[string](/API_docs/types/string.html) | Yes|Error message| + + + +### Type: [SecureValueError](/API_docs/types/SecureValueError.html) + + +### Example: + +``` +$secureValueErrorTranslationFiles = ['_' => 'secureValueErrorTranslationFiles', 'type' => SecureValueType, 'file_hash' => ['bytes', 'bytes'], 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/secureValueHash.md b/docs/API_docs/constructors/secureValueHash.md new file mode 100644 index 0000000000..c00ade334e --- /dev/null +++ b/docs/API_docs/constructors/secureValueHash.md @@ -0,0 +1,30 @@ +--- +title: "secureValueHash" +description: "Secure value hash" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueHash +[Back to constructors index](/API_docs/constructors/index.html) + + + +Secure value hash + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[SecureValueType](/API_docs/types/SecureValueType.html) | Yes|Secure value type| +|hash|[bytes](/API_docs/types/bytes.html) | Yes|Hash| + + + +### Type: [SecureValueHash](/API_docs/types/SecureValueHash.html) + + +### Example: + +``` +$secureValueHash = ['_' => 'secureValueHash', 'type' => SecureValueType, 'hash' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeAddress.md b/docs/API_docs/constructors/secureValueTypeAddress.md new file mode 100644 index 0000000000..26842e16f4 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeAddress.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeAddress" +description: "Address" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeAddress +[Back to constructors index](/API_docs/constructors/index.html) + + + +Address + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeAddress = ['_' => 'secureValueTypeAddress']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeBankStatement.md b/docs/API_docs/constructors/secureValueTypeBankStatement.md new file mode 100644 index 0000000000..54e271d43d --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeBankStatement.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeBankStatement" +description: "Bank statement" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeBankStatement +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bank statement + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeBankStatement = ['_' => 'secureValueTypeBankStatement']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeDriverLicense.md b/docs/API_docs/constructors/secureValueTypeDriverLicense.md new file mode 100644 index 0000000000..734e2b3567 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeDriverLicense.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeDriverLicense" +description: "Driver's license" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeDriverLicense +[Back to constructors index](/API_docs/constructors/index.html) + + + +Driver's license + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeDriverLicense = ['_' => 'secureValueTypeDriverLicense']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeEmail.md b/docs/API_docs/constructors/secureValueTypeEmail.md new file mode 100644 index 0000000000..d2560bc330 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeEmail.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeEmail" +description: "Email" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeEmail +[Back to constructors index](/API_docs/constructors/index.html) + + + +Email + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeEmail = ['_' => 'secureValueTypeEmail']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeIdentityCard.md b/docs/API_docs/constructors/secureValueTypeIdentityCard.md new file mode 100644 index 0000000000..eced8df26c --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeIdentityCard.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeIdentityCard" +description: "Identity card" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeIdentityCard +[Back to constructors index](/API_docs/constructors/index.html) + + + +Identity card + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeIdentityCard = ['_' => 'secureValueTypeIdentityCard']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeInternalPassport.md b/docs/API_docs/constructors/secureValueTypeInternalPassport.md new file mode 100644 index 0000000000..63e816cafb --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeInternalPassport.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeInternalPassport" +description: "Internal passport" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeInternalPassport +[Back to constructors index](/API_docs/constructors/index.html) + + + +Internal [passport](https://core.telegram.org/passport) + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeInternalPassport = ['_' => 'secureValueTypeInternalPassport']; +``` diff --git a/docs/API_docs/constructors/secureValueTypePassport.md b/docs/API_docs/constructors/secureValueTypePassport.md new file mode 100644 index 0000000000..0fac01b6c5 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypePassport.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypePassport" +description: "Passport" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypePassport +[Back to constructors index](/API_docs/constructors/index.html) + + + +Passport + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypePassport = ['_' => 'secureValueTypePassport']; +``` diff --git a/docs/API_docs/constructors/secureValueTypePassportRegistration.md b/docs/API_docs/constructors/secureValueTypePassportRegistration.md new file mode 100644 index 0000000000..b0637e63bf --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypePassportRegistration.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypePassportRegistration" +description: "Internal registration passport" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypePassportRegistration +[Back to constructors index](/API_docs/constructors/index.html) + + + +Internal registration [passport](https://core.telegram.org/passport) + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypePassportRegistration = ['_' => 'secureValueTypePassportRegistration']; +``` diff --git a/docs/API_docs/constructors/secureValueTypePersonalDetails.md b/docs/API_docs/constructors/secureValueTypePersonalDetails.md new file mode 100644 index 0000000000..53299c6ed2 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypePersonalDetails.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypePersonalDetails" +description: "Personal details" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypePersonalDetails +[Back to constructors index](/API_docs/constructors/index.html) + + + +Personal details + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypePersonalDetails = ['_' => 'secureValueTypePersonalDetails']; +``` diff --git a/docs/API_docs/constructors/secureValueTypePhone.md b/docs/API_docs/constructors/secureValueTypePhone.md new file mode 100644 index 0000000000..f1675e0d63 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypePhone.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypePhone" +description: "Phone" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypePhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Phone + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypePhone = ['_' => 'secureValueTypePhone']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeRentalAgreement.md b/docs/API_docs/constructors/secureValueTypeRentalAgreement.md new file mode 100644 index 0000000000..421cb15272 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeRentalAgreement.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeRentalAgreement" +description: "Rental agreement" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeRentalAgreement +[Back to constructors index](/API_docs/constructors/index.html) + + + +Rental agreement + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeRentalAgreement = ['_' => 'secureValueTypeRentalAgreement']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeTemporaryRegistration.md b/docs/API_docs/constructors/secureValueTypeTemporaryRegistration.md new file mode 100644 index 0000000000..a62df5d010 --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeTemporaryRegistration.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeTemporaryRegistration" +description: "Temporary registration" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeTemporaryRegistration +[Back to constructors index](/API_docs/constructors/index.html) + + + +Temporary registration + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeTemporaryRegistration = ['_' => 'secureValueTypeTemporaryRegistration']; +``` diff --git a/docs/API_docs/constructors/secureValueTypeUtilityBill.md b/docs/API_docs/constructors/secureValueTypeUtilityBill.md new file mode 100644 index 0000000000..989ef68b9b --- /dev/null +++ b/docs/API_docs/constructors/secureValueTypeUtilityBill.md @@ -0,0 +1,24 @@ +--- +title: "secureValueTypeUtilityBill" +description: "Utility bill" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: secureValueTypeUtilityBill +[Back to constructors index](/API_docs/constructors/index.html) + + + +Utility bill + + + + +### Type: [SecureValueType](/API_docs/types/SecureValueType.html) + + +### Example: + +``` +$secureValueTypeUtilityBill = ['_' => 'secureValueTypeUtilityBill']; +``` diff --git a/docs/API_docs/constructors/sendAsPeer.md b/docs/API_docs/constructors/sendAsPeer.md new file mode 100644 index 0000000000..665c1025f1 --- /dev/null +++ b/docs/API_docs/constructors/sendAsPeer.md @@ -0,0 +1,30 @@ +--- +title: "sendAsPeer" +description: "Indicates a peer that can be used to send messages" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendAsPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates a peer that can be used to send messages + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|premium\_required|[Bool](/API_docs/types/Bool.html) | Optional|Whether a Telegram Premium account is required to send messages as this peer| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| + + + +### Type: [SendAsPeer](/API_docs/types/SendAsPeer.html) + + +### Example: + +``` +$sendAsPeer = ['_' => 'sendAsPeer', 'premium_required' => Bool, 'peer' => long]; +``` diff --git a/docs/API_docs/constructors/sendMessageCancelAction.md b/docs/API_docs/constructors/sendMessageCancelAction.md new file mode 100644 index 0000000000..0f780a7401 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageCancelAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageCancelAction" +description: "Invalidate all previous action updates. E.g. when user deletes entered text or aborts a video upload." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageCancelAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Invalidate all previous action updates. E.g. when user deletes entered text or aborts a video upload. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageCancelAction = ['_' => 'sendMessageCancelAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageChooseContactAction.md b/docs/API_docs/constructors/sendMessageChooseContactAction.md new file mode 100644 index 0000000000..322735dfb3 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageChooseContactAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageChooseContactAction" +description: "User is selecting a contact to share." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageChooseContactAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is selecting a contact to share. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageChooseContactAction = ['_' => 'sendMessageChooseContactAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageChooseStickerAction.md b/docs/API_docs/constructors/sendMessageChooseStickerAction.md new file mode 100644 index 0000000000..ea5ef4d286 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageChooseStickerAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageChooseStickerAction" +description: "User is choosing a sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageChooseStickerAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is choosing a sticker + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageChooseStickerAction = ['_' => 'sendMessageChooseStickerAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageEmojiInteraction.md b/docs/API_docs/constructors/sendMessageEmojiInteraction.md new file mode 100644 index 0000000000..7f8e060422 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageEmojiInteraction.md @@ -0,0 +1,31 @@ +--- +title: "sendMessageEmojiInteraction" +description: "User has clicked on an animated emoji triggering a reaction, click here for more info »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageEmojiInteraction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User has clicked on an animated emoji triggering a [reaction, click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|Emoji| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID of the animated emoji that was clicked| +|interaction|[DataJSON](/API_docs/types/DataJSON.html) | Yes|A JSON object with interaction info, [click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions)| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageEmojiInteraction = ['_' => 'sendMessageEmojiInteraction', 'emoticon' => 'string', 'msg_id' => int, 'interaction' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/sendMessageEmojiInteractionSeen.md b/docs/API_docs/constructors/sendMessageEmojiInteractionSeen.md new file mode 100644 index 0000000000..7b4ce2c0df --- /dev/null +++ b/docs/API_docs/constructors/sendMessageEmojiInteractionSeen.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageEmojiInteractionSeen" +description: "User is watching an animated emoji reaction triggered by another user, click here for more info »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageEmojiInteractionSeen +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is watching an animated emoji reaction triggered by another user, [click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|Emoji| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageEmojiInteractionSeen = ['_' => 'sendMessageEmojiInteractionSeen', 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/sendMessageGamePlayAction.md b/docs/API_docs/constructors/sendMessageGamePlayAction.md new file mode 100644 index 0000000000..06d311c6c8 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageGamePlayAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageGamePlayAction" +description: "User is playing a game" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageGamePlayAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is playing a game + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageGamePlayAction = ['_' => 'sendMessageGamePlayAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageGeoLocationAction.md b/docs/API_docs/constructors/sendMessageGeoLocationAction.md new file mode 100644 index 0000000000..e00d6a53b7 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageGeoLocationAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageGeoLocationAction" +description: "User is selecting a location to share." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageGeoLocationAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is selecting a location to share. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageGeoLocationAction = ['_' => 'sendMessageGeoLocationAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageHistoryImportAction.md b/docs/API_docs/constructors/sendMessageHistoryImportAction.md new file mode 100644 index 0000000000..8aa6a8bcc4 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageHistoryImportAction.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageHistoryImportAction" +description: "Chat history is being imported" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageHistoryImportAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chat history is being imported + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|progress|[int](/API_docs/types/int.html) | Yes|Progress percentage| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageHistoryImportAction = ['_' => 'sendMessageHistoryImportAction', 'progress' => int]; +``` diff --git a/docs/API_docs/constructors/sendMessageRecordAudioAction.md b/docs/API_docs/constructors/sendMessageRecordAudioAction.md new file mode 100644 index 0000000000..b1cc08e9ef --- /dev/null +++ b/docs/API_docs/constructors/sendMessageRecordAudioAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageRecordAudioAction" +description: "User is recording a voice message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageRecordAudioAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is recording a voice message. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageRecordAudioAction = ['_' => 'sendMessageRecordAudioAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageRecordRoundAction.md b/docs/API_docs/constructors/sendMessageRecordRoundAction.md new file mode 100644 index 0000000000..292d36499f --- /dev/null +++ b/docs/API_docs/constructors/sendMessageRecordRoundAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageRecordRoundAction" +description: "User is recording a round video to share" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageRecordRoundAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is recording a round video to share + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageRecordRoundAction = ['_' => 'sendMessageRecordRoundAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageRecordVideoAction.md b/docs/API_docs/constructors/sendMessageRecordVideoAction.md new file mode 100644 index 0000000000..9458d3c408 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageRecordVideoAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageRecordVideoAction" +description: "User is recording a video." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageRecordVideoAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is recording a video. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageRecordVideoAction = ['_' => 'sendMessageRecordVideoAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageTypingAction.md b/docs/API_docs/constructors/sendMessageTypingAction.md new file mode 100644 index 0000000000..2a90e6bd01 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageTypingAction.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageTypingAction" +description: "User is typing." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageTypingAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is typing. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageTypingAction = ['_' => 'sendMessageTypingAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadAudioAction.md b/docs/API_docs/constructors/sendMessageUploadAudioAction.md new file mode 100644 index 0000000000..f45ff259f0 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadAudioAction.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageUploadAudioAction" +description: "User is uploading a voice message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadAudioAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a voice message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|progress|[int](/API_docs/types/int.html) | Yes|Progress percentage| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadAudioAction = ['_' => 'sendMessageUploadAudioAction', 'progress' => int]; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadAudioAction_17.md b/docs/API_docs/constructors/sendMessageUploadAudioAction_17.md new file mode 100644 index 0000000000..f368cc0398 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadAudioAction_17.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageUploadAudioAction" +description: "User is uploading a voice message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadAudioAction\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a voice message. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadAudioAction_17 = ['_' => 'sendMessageUploadAudioAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadDocumentAction.md b/docs/API_docs/constructors/sendMessageUploadDocumentAction.md new file mode 100644 index 0000000000..e33c170016 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadDocumentAction.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageUploadDocumentAction" +description: "User is uploading a file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadDocumentAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a file. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|progress|[int](/API_docs/types/int.html) | Yes|Progress percentage| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadDocumentAction = ['_' => 'sendMessageUploadDocumentAction', 'progress' => int]; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadDocumentAction_17.md b/docs/API_docs/constructors/sendMessageUploadDocumentAction_17.md new file mode 100644 index 0000000000..d84d6c76bd --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadDocumentAction_17.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageUploadDocumentAction" +description: "User is uploading a file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadDocumentAction\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a file. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadDocumentAction_17 = ['_' => 'sendMessageUploadDocumentAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadPhotoAction.md b/docs/API_docs/constructors/sendMessageUploadPhotoAction.md new file mode 100644 index 0000000000..54ca2a3847 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadPhotoAction.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageUploadPhotoAction" +description: "User is uploading a photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadPhotoAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a photo. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|progress|[int](/API_docs/types/int.html) | Yes|Progress percentage| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadPhotoAction = ['_' => 'sendMessageUploadPhotoAction', 'progress' => int]; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadPhotoAction_17.md b/docs/API_docs/constructors/sendMessageUploadPhotoAction_17.md new file mode 100644 index 0000000000..33ec341d02 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadPhotoAction_17.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageUploadPhotoAction" +description: "User is uploading a photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadPhotoAction\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a photo. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadPhotoAction_17 = ['_' => 'sendMessageUploadPhotoAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadRoundAction.md b/docs/API_docs/constructors/sendMessageUploadRoundAction.md new file mode 100644 index 0000000000..59b1d2d707 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadRoundAction.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageUploadRoundAction" +description: "User is uploading a round video" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadRoundAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a round video + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|progress|[int](/API_docs/types/int.html) | Yes|Progress percentage| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadRoundAction = ['_' => 'sendMessageUploadRoundAction', 'progress' => int]; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadRoundAction_66.md b/docs/API_docs/constructors/sendMessageUploadRoundAction_66.md new file mode 100644 index 0000000000..92cb038073 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadRoundAction_66.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageUploadRoundAction" +description: "User is uploading a round video" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadRoundAction\_66 +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a round video + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadRoundAction_66 = ['_' => 'sendMessageUploadRoundAction']; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadVideoAction.md b/docs/API_docs/constructors/sendMessageUploadVideoAction.md new file mode 100644 index 0000000000..644fe4f0e6 --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadVideoAction.md @@ -0,0 +1,29 @@ +--- +title: "sendMessageUploadVideoAction" +description: "User is uploading a video." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadVideoAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a video. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|progress|[int](/API_docs/types/int.html) | Yes|Progress percentage| + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadVideoAction = ['_' => 'sendMessageUploadVideoAction', 'progress' => int]; +``` diff --git a/docs/API_docs/constructors/sendMessageUploadVideoAction_17.md b/docs/API_docs/constructors/sendMessageUploadVideoAction_17.md new file mode 100644 index 0000000000..61e60330fe --- /dev/null +++ b/docs/API_docs/constructors/sendMessageUploadVideoAction_17.md @@ -0,0 +1,24 @@ +--- +title: "sendMessageUploadVideoAction" +description: "User is uploading a video." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sendMessageUploadVideoAction\_17 +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is uploading a video. + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$sendMessageUploadVideoAction_17 = ['_' => 'sendMessageUploadVideoAction']; +``` diff --git a/docs/API_docs/constructors/shippingOption.md b/docs/API_docs/constructors/shippingOption.md new file mode 100644 index 0000000000..c9ddb6dfb3 --- /dev/null +++ b/docs/API_docs/constructors/shippingOption.md @@ -0,0 +1,31 @@ +--- +title: "shippingOption" +description: "Shipping option" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: shippingOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Shipping option + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[string](/API_docs/types/string.html) | Yes|Option ID| +|title|[string](/API_docs/types/string.html) | Yes|Title| +|prices|Array of [LabeledPrice](/API_docs/types/LabeledPrice.html) | Yes|List of price portions| + + + +### Type: [ShippingOption](/API_docs/types/ShippingOption.html) + + +### Example: + +``` +$shippingOption = ['_' => 'shippingOption', 'id' => 'string', 'title' => 'string', 'prices' => [LabeledPrice, LabeledPrice]]; +``` diff --git a/docs/API_docs/constructors/simpleWebViewResultUrl.md b/docs/API_docs/constructors/simpleWebViewResultUrl.md new file mode 100644 index 0000000000..31e2cc389e --- /dev/null +++ b/docs/API_docs/constructors/simpleWebViewResultUrl.md @@ -0,0 +1,29 @@ +--- +title: "simpleWebViewResultUrl" +description: "Contains the webview URL with appropriate theme parameters added" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: simpleWebViewResultUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains the webview URL with appropriate theme parameters added + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|URL| + + + +### Type: [SimpleWebViewResult](/API_docs/types/SimpleWebViewResult.html) + + +### Example: + +``` +$simpleWebViewResultUrl = ['_' => 'simpleWebViewResultUrl', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/smsJob.md b/docs/API_docs/constructors/smsJob.md new file mode 100644 index 0000000000..5a950152c7 --- /dev/null +++ b/docs/API_docs/constructors/smsJob.md @@ -0,0 +1,29 @@ +--- +title: "smsJob" +description: "smsJob attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: smsJob +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|job\_id|[string](/API_docs/types/string.html) | Yes| +|phone\_number|[string](/API_docs/types/string.html) | Yes| +|text|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [SmsJob](/API_docs/types/SmsJob.html) + + +### Example: + +``` +$smsJob = ['_' => 'smsJob', 'job_id' => 'string', 'phone_number' => 'string', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/smsjobs.eligibleToJoin.md b/docs/API_docs/constructors/smsjobs.eligibleToJoin.md new file mode 100644 index 0000000000..61eb3d0f7c --- /dev/null +++ b/docs/API_docs/constructors/smsjobs.eligibleToJoin.md @@ -0,0 +1,29 @@ +--- +title: "smsjobs.eligibleToJoin" +description: "smsjobs.eligibleToJoin attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/smsjobs_eligibleToJoin.html +--- +# Constructor: smsjobs.eligibleToJoin +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|terms\_url|[string](/API_docs/types/string.html) | Yes| +|monthly\_sent\_sms|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [smsjobs.EligibilityToJoin](/API_docs/types/smsjobs.EligibilityToJoin.html) + + +### Example: + +``` +$smsjobs_eligibleToJoin = ['_' => 'smsjobs.eligibleToJoin', 'terms_url' => 'string', 'monthly_sent_sms' => int]; +``` diff --git a/docs/API_docs/constructors/smsjobs.status.md b/docs/API_docs/constructors/smsjobs.status.md new file mode 100644 index 0000000000..a57afc6c77 --- /dev/null +++ b/docs/API_docs/constructors/smsjobs.status.md @@ -0,0 +1,35 @@ +--- +title: "smsjobs.status" +description: "smsjobs.status attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/smsjobs_status.html +--- +# Constructor: smsjobs.status +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|allow\_international|[Bool](/API_docs/types/Bool.html) | Optional| +|recent\_sent|[int](/API_docs/types/int.html) | Yes| +|recent\_since|[int](/API_docs/types/int.html) | Yes| +|recent\_remains|[int](/API_docs/types/int.html) | Yes| +|total\_sent|[int](/API_docs/types/int.html) | Yes| +|total\_since|[int](/API_docs/types/int.html) | Yes| +|last\_gift\_slug|[string](/API_docs/types/string.html) | Optional| +|terms\_url|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [smsjobs.Status](/API_docs/types/smsjobs.Status.html) + + +### Example: + +``` +$smsjobs_status = ['_' => 'smsjobs.status', 'allow_international' => Bool, 'recent_sent' => int, 'recent_since' => int, 'recent_remains' => int, 'total_sent' => int, 'total_since' => int, 'last_gift_slug' => 'string', 'terms_url' => 'string']; +``` diff --git a/docs/API_docs/constructors/speakingInGroupCallAction.md b/docs/API_docs/constructors/speakingInGroupCallAction.md new file mode 100644 index 0000000000..79d1afe330 --- /dev/null +++ b/docs/API_docs/constructors/speakingInGroupCallAction.md @@ -0,0 +1,24 @@ +--- +title: "speakingInGroupCallAction" +description: "User is currently speaking in the group call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: speakingInGroupCallAction +[Back to constructors index](/API_docs/constructors/index.html) + + + +User is currently speaking in the group call + + + + +### Type: [SendMessageAction](/API_docs/types/SendMessageAction.html) + + +### Example: + +``` +$speakingInGroupCallAction = ['_' => 'speakingInGroupCallAction']; +``` diff --git a/docs/API_docs/constructors/sponsoredMessage.md b/docs/API_docs/constructors/sponsoredMessage.md new file mode 100644 index 0000000000..0b88a31f51 --- /dev/null +++ b/docs/API_docs/constructors/sponsoredMessage.md @@ -0,0 +1,100 @@ +--- +title: "sponsoredMessage" +description: "A sponsored message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sponsoredMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [sponsored message](https://core.telegram.org/api/sponsored-messages). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|recommended|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message needs to be labeled as "recommended" instead of "sponsored"| +|can\_report|[Bool](/API_docs/types/Bool.html) | Optional| +|url|[string](/API_docs/types/string.html) | Yes| +|title|[string](/API_docs/types/string.html) | Yes| +|message|[string](/API_docs/types/string.html) | Yes|Sponsored message| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|photo|[Photo](/API_docs/types/Photo.html) | Optional| +|color|[PeerColor](/API_docs/types/PeerColor.html) | Optional| +|button\_text|[string](/API_docs/types/string.html) | Yes|Text of the sponsored message button.| +|sponsor\_info|[string](/API_docs/types/string.html) | Optional|If set, contains additional information about the sponsor to be shown along with the message.| +|additional\_info|[string](/API_docs/types/string.html) | Optional|If set, contains additional information about the sponsored message to be shown along with the message.| + + + +### Type: [SponsoredMessage](/API_docs/types/SponsoredMessage.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$sponsoredMessage = ['_' => 'sponsoredMessage', 'recommended' => Bool, 'can_report' => Bool, 'url' => 'string', 'title' => 'string', 'message' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'photo' => Photo, 'color' => PeerColor, 'button_text' => 'string', 'sponsor_info' => 'string', 'additional_info' => 'string']; +``` diff --git a/docs/API_docs/constructors/sponsoredMessageReportOption.md b/docs/API_docs/constructors/sponsoredMessageReportOption.md new file mode 100644 index 0000000000..442f908e6b --- /dev/null +++ b/docs/API_docs/constructors/sponsoredMessageReportOption.md @@ -0,0 +1,28 @@ +--- +title: "sponsoredMessageReportOption" +description: "sponsoredMessageReportOption attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: sponsoredMessageReportOption +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|text|[string](/API_docs/types/string.html) | Yes| +|option|[bytes](/API_docs/types/bytes.html) | Yes| + + + +### Type: [SponsoredMessageReportOption](/API_docs/types/SponsoredMessageReportOption.html) + + +### Example: + +``` +$sponsoredMessageReportOption = ['_' => 'sponsoredMessageReportOption', 'text' => 'string', 'option' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/stats.broadcastRevenueStats.md b/docs/API_docs/constructors/stats.broadcastRevenueStats.md new file mode 100644 index 0000000000..f61ecbf012 --- /dev/null +++ b/docs/API_docs/constructors/stats.broadcastRevenueStats.md @@ -0,0 +1,31 @@ +--- +title: "stats.broadcastRevenueStats" +description: "stats.broadcastRevenueStats attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_broadcastRevenueStats.html +--- +# Constructor: stats.broadcastRevenueStats +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|top\_hours\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes| +|revenue\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes| +|balances|[BroadcastRevenueBalances](/API_docs/types/BroadcastRevenueBalances.html) | Yes| +|usd\_rate|[double](/API_docs/types/double.html) | Yes| + + + +### Type: [stats.BroadcastRevenueStats](/API_docs/types/stats.BroadcastRevenueStats.html) + + +### Example: + +``` +$stats_broadcastRevenueStats = ['_' => 'stats.broadcastRevenueStats', 'top_hours_graph' => StatsGraph, 'revenue_graph' => StatsGraph, 'balances' => BroadcastRevenueBalances, 'usd_rate' => double]; +``` diff --git a/docs/API_docs/constructors/stats.broadcastRevenueTransactions.md b/docs/API_docs/constructors/stats.broadcastRevenueTransactions.md new file mode 100644 index 0000000000..788138406c --- /dev/null +++ b/docs/API_docs/constructors/stats.broadcastRevenueTransactions.md @@ -0,0 +1,29 @@ +--- +title: "stats.broadcastRevenueTransactions" +description: "stats.broadcastRevenueTransactions attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_broadcastRevenueTransactions.html +--- +# Constructor: stats.broadcastRevenueTransactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|count|[int](/API_docs/types/int.html) | Yes| +|transactions|Array of [BroadcastRevenueTransaction](/API_docs/types/BroadcastRevenueTransaction.html) | Yes| + + + +### Type: [stats.BroadcastRevenueTransactions](/API_docs/types/stats.BroadcastRevenueTransactions.html) + + +### Example: + +``` +$stats_broadcastRevenueTransactions = ['_' => 'stats.broadcastRevenueTransactions', 'count' => int, 'transactions' => [BroadcastRevenueTransaction, BroadcastRevenueTransaction]]; +``` diff --git a/docs/API_docs/constructors/stats.broadcastRevenueWithdrawalUrl.md b/docs/API_docs/constructors/stats.broadcastRevenueWithdrawalUrl.md new file mode 100644 index 0000000000..8ad96c9aee --- /dev/null +++ b/docs/API_docs/constructors/stats.broadcastRevenueWithdrawalUrl.md @@ -0,0 +1,28 @@ +--- +title: "stats.broadcastRevenueWithdrawalUrl" +description: "stats.broadcastRevenueWithdrawalUrl attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_broadcastRevenueWithdrawalUrl.html +--- +# Constructor: stats.broadcastRevenueWithdrawalUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|url|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [stats.BroadcastRevenueWithdrawalUrl](/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.html) + + +### Example: + +``` +$stats_broadcastRevenueWithdrawalUrl = ['_' => 'stats.broadcastRevenueWithdrawalUrl', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/stats.broadcastStats.md b/docs/API_docs/constructors/stats.broadcastStats.md new file mode 100644 index 0000000000..5e80b2d7b6 --- /dev/null +++ b/docs/API_docs/constructors/stats.broadcastStats.md @@ -0,0 +1,51 @@ +--- +title: "stats.broadcastStats" +description: "Channel statistics." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_broadcastStats.html +--- +# Constructor: stats.broadcastStats +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Channel statistics](https://core.telegram.org/api/stats). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|period|[StatsDateRangeDays](/API_docs/types/StatsDateRangeDays.html) | Yes|Period in consideration| +|followers|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|Follower count change for period in consideration| +|views\_per\_post|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|`total_viewcount/postcount`, for posts posted during the period in consideration.
Note that in this case, `current` refers to the `period` in consideration (`min_date` till `max_date`), and `prev` refers to the previous period (`(min_date - (max_date - min_date))` till `min_date`).| +|shares\_per\_post|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|`total_sharecount/postcount`, for posts posted during the period in consideration.
Note that in this case, `current` refers to the `period` in consideration (`min_date` till `max_date`), and `prev` refers to the previous period (`(min_date - (max_date - min_date))` till `min_date`)| +|reactions\_per\_post|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|`total_reactions/postcount`, for posts posted during the period in consideration.
Note that in this case, `current` refers to the `period` in consideration (`min_date` till `max_date`), and `prev` refers to the previous period (`(min_date - (max_date - min_date))` till `min_date`)| +|views\_per\_story|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|`total_views/storycount`, for posts posted during the period in consideration.
Note that in this case, `current` refers to the `period` in consideration (`min_date` till `max_date`), and `prev` refers to the previous period (`(min_date - (max_date - min_date))` till `min_date`)| +|shares\_per\_story|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|`total_shares/storycount`, for posts posted during the period in consideration.
Note that in this case, `current` refers to the `period` in consideration (`min_date` till `max_date`), and `prev` refers to the previous period (`(min_date - (max_date - min_date))` till `min_date`)| +|reactions\_per\_story|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|`total_reactions/storycount`, for posts posted during the period in consideration.
Note that in this case, `current` refers to the `period` in consideration (`min_date` till `max_date`), and `prev` refers to the previous period (`(min_date - (max_date - min_date))` till `min_date`)| +|enabled\_notifications|[StatsPercentValue](/API_docs/types/StatsPercentValue.html) | Yes|Percentage of subscribers with enabled notifications| +|growth\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Channel growth graph (absolute subscriber count)| +|followers\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Followers growth graph (relative subscriber count)| +|mute\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Muted users graph (relative)| +|top\_hours\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Views per hour graph (absolute)| +|interactions\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Interactions graph (absolute)| +|iv\_interactions\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|IV interactions graph (absolute)| +|views\_by\_source\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Views by source graph (absolute)| +|new\_followers\_by\_source\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|New followers by source graph (absolute)| +|languages\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Subscriber language graph (pie chart)| +|reactions\_by\_emotion\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|A graph containing the number of reactions on posts categorized by emotion| +|story\_interactions\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|A graph containing the number of story views and shares| +|story\_reactions\_by\_emotion\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|A graph containing the number of reactions on stories categorized by emotion| +|recent\_posts\_interactions|Array of [PostInteractionCounters](/API_docs/types/PostInteractionCounters.html) | Yes|Detailed statistics about number of views and shares of recently sent messages and stories| + + + +### Type: [stats.BroadcastStats](/API_docs/types/stats.BroadcastStats.html) + + +### Example: + +``` +$stats_broadcastStats = ['_' => 'stats.broadcastStats', 'period' => StatsDateRangeDays, 'followers' => StatsAbsValueAndPrev, 'views_per_post' => StatsAbsValueAndPrev, 'shares_per_post' => StatsAbsValueAndPrev, 'reactions_per_post' => StatsAbsValueAndPrev, 'views_per_story' => StatsAbsValueAndPrev, 'shares_per_story' => StatsAbsValueAndPrev, 'reactions_per_story' => StatsAbsValueAndPrev, 'enabled_notifications' => StatsPercentValue, 'growth_graph' => StatsGraph, 'followers_graph' => StatsGraph, 'mute_graph' => StatsGraph, 'top_hours_graph' => StatsGraph, 'interactions_graph' => StatsGraph, 'iv_interactions_graph' => StatsGraph, 'views_by_source_graph' => StatsGraph, 'new_followers_by_source_graph' => StatsGraph, 'languages_graph' => StatsGraph, 'reactions_by_emotion_graph' => StatsGraph, 'story_interactions_graph' => StatsGraph, 'story_reactions_by_emotion_graph' => StatsGraph, 'recent_posts_interactions' => [PostInteractionCounters, PostInteractionCounters]]; +``` diff --git a/docs/API_docs/constructors/stats.megagroupStats.md b/docs/API_docs/constructors/stats.megagroupStats.md new file mode 100644 index 0000000000..d9cef3082a --- /dev/null +++ b/docs/API_docs/constructors/stats.megagroupStats.md @@ -0,0 +1,46 @@ +--- +title: "stats.megagroupStats" +description: "Supergroup statistics" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_megagroupStats.html +--- +# Constructor: stats.megagroupStats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Supergroup [statistics](https://core.telegram.org/api/stats) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|period|[StatsDateRangeDays](/API_docs/types/StatsDateRangeDays.html) | Yes|Period in consideration| +|members|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|Member count change for period in consideration| +|messages|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|Message number change for period in consideration| +|viewers|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|Number of users that viewed messages, for range in consideration| +|posters|[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) | Yes|Number of users that posted messages, for range in consideration| +|growth\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Supergroup growth graph (absolute subscriber count)| +|members\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Members growth (relative subscriber count)| +|new\_members\_by\_source\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|New members by source graph| +|languages\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Subscriber language graph (pie chart)| +|messages\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Message activity graph (stacked bar graph, message type)| +|actions\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Group activity graph (deleted, modified messages, blocked users)| +|top\_hours\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Activity per hour graph (absolute)| +|weekdays\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Activity per day of week graph (absolute)| +|top\_posters|Array of [StatsGroupTopPoster](/API_docs/types/StatsGroupTopPoster.html) | Yes|Info about most active group members| +|top\_admins|Array of [StatsGroupTopAdmin](/API_docs/types/StatsGroupTopAdmin.html) | Yes|Info about most active group admins| +|top\_inviters|Array of [StatsGroupTopInviter](/API_docs/types/StatsGroupTopInviter.html) | Yes|Info about most active group inviters| +|users|Array of [User](/API_docs/types/User.html) | Yes|Info about users mentioned in statistics| + + + +### Type: [stats.MegagroupStats](/API_docs/types/stats.MegagroupStats.html) + + +### Example: + +``` +$stats_megagroupStats = ['_' => 'stats.megagroupStats', 'period' => StatsDateRangeDays, 'members' => StatsAbsValueAndPrev, 'messages' => StatsAbsValueAndPrev, 'viewers' => StatsAbsValueAndPrev, 'posters' => StatsAbsValueAndPrev, 'growth_graph' => StatsGraph, 'members_graph' => StatsGraph, 'new_members_by_source_graph' => StatsGraph, 'languages_graph' => StatsGraph, 'messages_graph' => StatsGraph, 'actions_graph' => StatsGraph, 'top_hours_graph' => StatsGraph, 'weekdays_graph' => StatsGraph, 'top_posters' => [StatsGroupTopPoster, StatsGroupTopPoster], 'top_admins' => [StatsGroupTopAdmin, StatsGroupTopAdmin], 'top_inviters' => [StatsGroupTopInviter, StatsGroupTopInviter], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/stats.messageStats.md b/docs/API_docs/constructors/stats.messageStats.md new file mode 100644 index 0000000000..a7261ddab4 --- /dev/null +++ b/docs/API_docs/constructors/stats.messageStats.md @@ -0,0 +1,31 @@ +--- +title: "stats.messageStats" +description: "Message statistics" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_messageStats.html +--- +# Constructor: stats.messageStats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Message statistics + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|views\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|Message view graph| +|reactions\_by\_emotion\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|A graph containing the number of reactions on stories categorized by emotion| + + + +### Type: [stats.MessageStats](/API_docs/types/stats.MessageStats.html) + + +### Example: + +``` +$stats_messageStats = ['_' => 'stats.messageStats', 'views_graph' => StatsGraph, 'reactions_by_emotion_graph' => StatsGraph]; +``` diff --git a/docs/API_docs/constructors/stats.publicForwards.md b/docs/API_docs/constructors/stats.publicForwards.md new file mode 100644 index 0000000000..e863bdff11 --- /dev/null +++ b/docs/API_docs/constructors/stats.publicForwards.md @@ -0,0 +1,34 @@ +--- +title: "stats.publicForwards" +description: "Contains info about the forwards of a story as a message to public chats and reposts by public channels." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_publicForwards.html +--- +# Constructor: stats.publicForwards +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about the forwards of a [story](https://core.telegram.org/api/stories) as a message to public chats and reposts by public channels. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of results| +|forwards|Array of [PublicForward](/API_docs/types/PublicForward.html) | Yes|Info about the forwards of a story.| +|next\_offset|[string](/API_docs/types/string.html) | Optional|Offset used for [pagination](https://core.telegram.org/api/offsets).| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [stats.PublicForwards](/API_docs/types/stats.PublicForwards.html) + + +### Example: + +``` +$stats_publicForwards = ['_' => 'stats.publicForwards', 'count' => int, 'forwards' => [PublicForward, PublicForward], 'next_offset' => 'string', 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/stats.storyStats.md b/docs/API_docs/constructors/stats.storyStats.md new file mode 100644 index 0000000000..93242eea0e --- /dev/null +++ b/docs/API_docs/constructors/stats.storyStats.md @@ -0,0 +1,31 @@ +--- +title: "stats.storyStats" +description: "Contains statistics about a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stats_storyStats.html +--- +# Constructor: stats.storyStats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains [statistics](https://core.telegram.org/api/stats) about a [story](https://core.telegram.org/api/stories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|views\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|A graph containing the number of story views and shares| +|reactions\_by\_emotion\_graph|[StatsGraph](/API_docs/types/StatsGraph.html) | Yes|A bar graph containing the number of story reactions categorized by "emotion" (i.e. Positive, Negative, Other, etc...)| + + + +### Type: [stats.StoryStats](/API_docs/types/stats.StoryStats.html) + + +### Example: + +``` +$stats_storyStats = ['_' => 'stats.storyStats', 'views_graph' => StatsGraph, 'reactions_by_emotion_graph' => StatsGraph]; +``` diff --git a/docs/API_docs/constructors/statsAbsValueAndPrev.md b/docs/API_docs/constructors/statsAbsValueAndPrev.md new file mode 100644 index 0000000000..3e3cbe900c --- /dev/null +++ b/docs/API_docs/constructors/statsAbsValueAndPrev.md @@ -0,0 +1,30 @@ +--- +title: "statsAbsValueAndPrev" +description: "Statistics value couple; initial and final value for period of time currently in consideration" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsAbsValueAndPrev +[Back to constructors index](/API_docs/constructors/index.html) + + + +Statistics value couple; initial and final value for period of time currently in consideration + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|current|[double](/API_docs/types/double.html) | Yes|Current value| +|previous|[double](/API_docs/types/double.html) | Yes|Previous value| + + + +### Type: [StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) + + +### Example: + +``` +$statsAbsValueAndPrev = ['_' => 'statsAbsValueAndPrev', 'current' => double, 'previous' => double]; +``` diff --git a/docs/API_docs/constructors/statsDateRangeDays.md b/docs/API_docs/constructors/statsDateRangeDays.md new file mode 100644 index 0000000000..66d1ce30c8 --- /dev/null +++ b/docs/API_docs/constructors/statsDateRangeDays.md @@ -0,0 +1,30 @@ +--- +title: "statsDateRangeDays" +description: "Channel statistics date range" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsDateRangeDays +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Channel statistics](https://core.telegram.org/api/stats) date range + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|min\_date|[int](/API_docs/types/int.html) | Yes|Initial date| +|max\_date|[int](/API_docs/types/int.html) | Yes|Final date| + + + +### Type: [StatsDateRangeDays](/API_docs/types/StatsDateRangeDays.html) + + +### Example: + +``` +$statsDateRangeDays = ['_' => 'statsDateRangeDays', 'min_date' => int, 'max_date' => int]; +``` diff --git a/docs/API_docs/constructors/statsGraph.md b/docs/API_docs/constructors/statsGraph.md new file mode 100644 index 0000000000..7f0a8a3c92 --- /dev/null +++ b/docs/API_docs/constructors/statsGraph.md @@ -0,0 +1,30 @@ +--- +title: "statsGraph" +description: "Channel statistics graph" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsGraph +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Channel statistics graph](https://core.telegram.org/api/stats) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|json|[DataJSON](/API_docs/types/DataJSON.html) | Yes|Statistics data| +|zoom\_token|[string](/API_docs/types/string.html) | Optional|Zoom token| + + + +### Type: [StatsGraph](/API_docs/types/StatsGraph.html) + + +### Example: + +``` +$statsGraph = ['_' => 'statsGraph', 'json' => DataJSON, 'zoom_token' => 'string']; +``` diff --git a/docs/API_docs/constructors/statsGraphAsync.md b/docs/API_docs/constructors/statsGraphAsync.md new file mode 100644 index 0000000000..5d744f2f7f --- /dev/null +++ b/docs/API_docs/constructors/statsGraphAsync.md @@ -0,0 +1,29 @@ +--- +title: "statsGraphAsync" +description: "This channel statistics graph must be generated asynchronously using stats.loadAsyncGraph to reduce server load" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsGraphAsync +[Back to constructors index](/API_docs/constructors/index.html) + + + +This [channel statistics graph](https://core.telegram.org/api/stats) must be generated asynchronously using [stats.loadAsyncGraph](../methods/stats.loadAsyncGraph.html) to reduce server load + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|token|[string](/API_docs/types/string.html) | Yes|Token to use for fetching the async graph| + + + +### Type: [StatsGraph](/API_docs/types/StatsGraph.html) + + +### Example: + +``` +$statsGraphAsync = ['_' => 'statsGraphAsync', 'token' => 'string']; +``` diff --git a/docs/API_docs/constructors/statsGraphError.md b/docs/API_docs/constructors/statsGraphError.md new file mode 100644 index 0000000000..0cec64674d --- /dev/null +++ b/docs/API_docs/constructors/statsGraphError.md @@ -0,0 +1,29 @@ +--- +title: "statsGraphError" +description: "An error occurred while generating the statistics graph" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsGraphError +[Back to constructors index](/API_docs/constructors/index.html) + + + +An error occurred while generating the [statistics graph](https://core.telegram.org/api/stats) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|error|[string](/API_docs/types/string.html) | Yes|The error| + + + +### Type: [StatsGraph](/API_docs/types/StatsGraph.html) + + +### Example: + +``` +$statsGraphError = ['_' => 'statsGraphError', 'error' => 'string']; +``` diff --git a/docs/API_docs/constructors/statsGroupTopAdmin.md b/docs/API_docs/constructors/statsGroupTopAdmin.md new file mode 100644 index 0000000000..45418bc7d4 --- /dev/null +++ b/docs/API_docs/constructors/statsGroupTopAdmin.md @@ -0,0 +1,32 @@ +--- +title: "statsGroupTopAdmin" +description: "Information about an active admin in a supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsGroupTopAdmin +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about an active admin in a supergroup + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|deleted|[int](/API_docs/types/int.html) | Yes|Number of deleted messages for [statistics](https://core.telegram.org/api/stats) period in consideration| +|kicked|[int](/API_docs/types/int.html) | Yes|Number of kicked users for [statistics](https://core.telegram.org/api/stats) period in consideration| +|banned|[int](/API_docs/types/int.html) | Yes|Number of banned users for [statistics](https://core.telegram.org/api/stats) period in consideration| + + + +### Type: [StatsGroupTopAdmin](/API_docs/types/StatsGroupTopAdmin.html) + + +### Example: + +``` +$statsGroupTopAdmin = ['_' => 'statsGroupTopAdmin', 'user_id' => long, 'deleted' => int, 'kicked' => int, 'banned' => int]; +``` diff --git a/docs/API_docs/constructors/statsGroupTopInviter.md b/docs/API_docs/constructors/statsGroupTopInviter.md new file mode 100644 index 0000000000..a504eb351b --- /dev/null +++ b/docs/API_docs/constructors/statsGroupTopInviter.md @@ -0,0 +1,30 @@ +--- +title: "statsGroupTopInviter" +description: "Information about an active supergroup inviter" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsGroupTopInviter +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about an active supergroup inviter + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|invitations|[int](/API_docs/types/int.html) | Yes|Number of invitations for [statistics](https://core.telegram.org/api/stats) period in consideration| + + + +### Type: [StatsGroupTopInviter](/API_docs/types/StatsGroupTopInviter.html) + + +### Example: + +``` +$statsGroupTopInviter = ['_' => 'statsGroupTopInviter', 'user_id' => long, 'invitations' => int]; +``` diff --git a/docs/API_docs/constructors/statsGroupTopPoster.md b/docs/API_docs/constructors/statsGroupTopPoster.md new file mode 100644 index 0000000000..6f072438e3 --- /dev/null +++ b/docs/API_docs/constructors/statsGroupTopPoster.md @@ -0,0 +1,31 @@ +--- +title: "statsGroupTopPoster" +description: "Information about an active user in a supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsGroupTopPoster +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about an active user in a supergroup + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|messages|[int](/API_docs/types/int.html) | Yes|Number of messages for [statistics](https://core.telegram.org/api/stats) period in consideration| +|avg\_chars|[int](/API_docs/types/int.html) | Yes|Average number of characters per message| + + + +### Type: [StatsGroupTopPoster](/API_docs/types/StatsGroupTopPoster.html) + + +### Example: + +``` +$statsGroupTopPoster = ['_' => 'statsGroupTopPoster', 'user_id' => long, 'messages' => int, 'avg_chars' => int]; +``` diff --git a/docs/API_docs/constructors/statsPercentValue.md b/docs/API_docs/constructors/statsPercentValue.md new file mode 100644 index 0000000000..bf2d8a72e5 --- /dev/null +++ b/docs/API_docs/constructors/statsPercentValue.md @@ -0,0 +1,31 @@ +--- +title: "statsPercentValue" +description: "Channel statistics percentage." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsPercentValue +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Channel statistics percentage](https://core.telegram.org/api/stats). +Compute the percentage simply by doing `part * total / 100` + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|part|[double](/API_docs/types/double.html) | Yes|Partial value| +|total|[double](/API_docs/types/double.html) | Yes|Total value| + + + +### Type: [StatsPercentValue](/API_docs/types/StatsPercentValue.html) + + +### Example: + +``` +$statsPercentValue = ['_' => 'statsPercentValue', 'part' => double, 'total' => double]; +``` diff --git a/docs/API_docs/constructors/statsURL.md b/docs/API_docs/constructors/statsURL.md new file mode 100644 index 0000000000..fe91054454 --- /dev/null +++ b/docs/API_docs/constructors/statsURL.md @@ -0,0 +1,29 @@ +--- +title: "statsURL" +description: "URL with chat statistics" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: statsURL +[Back to constructors index](/API_docs/constructors/index.html) + + + +URL with chat statistics + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Chat statistics| + + + +### Type: [StatsURL](/API_docs/types/StatsURL.html) + + +### Example: + +``` +$statsURL = ['_' => 'statsURL', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/stickerKeyword.md b/docs/API_docs/constructors/stickerKeyword.md new file mode 100644 index 0000000000..5ed6c61670 --- /dev/null +++ b/docs/API_docs/constructors/stickerKeyword.md @@ -0,0 +1,30 @@ +--- +title: "stickerKeyword" +description: "Keywords for a certain sticker" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerKeyword +[Back to constructors index](/API_docs/constructors/index.html) + + + +Keywords for a certain sticker + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document\_id|[long](/API_docs/types/long.html) | Yes|Sticker ID| +|keyword|Array of [string](/API_docs/types/string.html) | Yes|Keywords| + + + +### Type: [StickerKeyword](/API_docs/types/StickerKeyword.html) + + +### Example: + +``` +$stickerKeyword = ['_' => 'stickerKeyword', 'document_id' => long, 'keyword' => ['string', 'string']]; +``` diff --git a/docs/API_docs/constructors/stickerPack.md b/docs/API_docs/constructors/stickerPack.md new file mode 100644 index 0000000000..1e1e1b87b6 --- /dev/null +++ b/docs/API_docs/constructors/stickerPack.md @@ -0,0 +1,31 @@ +--- +title: "stickerPack" +description: "A stickerpack is a group of stickers associated to the same emoji." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerPack +[Back to constructors index](/API_docs/constructors/index.html) + + + +A stickerpack is a group of stickers associated to the same emoji. +It is **not** a sticker pack the way it is usually intended, you may be looking for a [StickerSet](../types/StickerSet.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoticon|[string](/API_docs/types/string.html) | Yes|Emoji| +|documents|Array of [long](/API_docs/types/long.html) | Yes|Stickers| + + + +### Type: [StickerPack](/API_docs/types/StickerPack.html) + + +### Example: + +``` +$stickerPack = ['_' => 'stickerPack', 'emoticon' => 'string', 'documents' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/stickerSet.md b/docs/API_docs/constructors/stickerSet.md new file mode 100644 index 0000000000..fcfc7ed04f --- /dev/null +++ b/docs/API_docs/constructors/stickerSet.md @@ -0,0 +1,46 @@ +--- +title: "stickerSet" +description: "Represents a stickerset (stickerpack)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a stickerset (stickerpack) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|archived|[Bool](/API_docs/types/Bool.html) | Optional|Whether this stickerset was archived (due to too many saved stickers in the current account)| +|official|[Bool](/API_docs/types/Bool.html) | Optional|Is this stickerset official| +|masks|[Bool](/API_docs/types/Bool.html) | Optional|Is this a mask stickerset| +|emojis|[Bool](/API_docs/types/Bool.html) | Optional|This is a custom emoji stickerset| +|text\_color|[Bool](/API_docs/types/Bool.html) | Optional|Whether the color of this TGS custom emoji stickerset should be changed to the text color when used in messages, the accent color if used as emoji status, white on chat photos, or another appropriate color based on context.| +|channel\_emoji\_status|[Bool](/API_docs/types/Bool.html) | Optional|If set, this custom emoji stickerset can be used in [channel emoji statuses](https://core.telegram.org/api/emoji-status).| +|creator|[Bool](/API_docs/types/Bool.html) | Optional| +|installed\_date|[int](/API_docs/types/int.html) | Optional|When was this stickerset installed| +|id|[long](/API_docs/types/long.html) | Yes|ID of the stickerset| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash of stickerset| +|title|[string](/API_docs/types/string.html) | Yes|Title of stickerset| +|short\_name|[string](/API_docs/types/string.html) | Yes|Short name of stickerset, used when sharing stickerset using [stickerset deep links](https://core.telegram.org/api/links#stickerset-links).| +|thumbs|Array of [PhotoSize](/API_docs/types/PhotoSize.html) | Optional|Stickerset thumbnail| +|thumb\_dc\_id|[int](/API_docs/types/int.html) | Optional|DC ID of thumbnail| +|thumb\_version|[int](/API_docs/types/int.html) | Optional|Thumbnail version| +|thumb\_document\_id|[long](/API_docs/types/long.html) | Optional|Document ID of custom emoji thumbnail, fetch the document using [messages.getCustomEmojiDocuments](../methods/messages.getCustomEmojiDocuments.html)| +|count|[int](/API_docs/types/int.html) | Yes|Number of stickers in pack| +|hash|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [StickerSet](/API_docs/types/StickerSet.html) + + +### Example: + +``` +$stickerSet = ['_' => 'stickerSet', 'archived' => Bool, 'official' => Bool, 'masks' => Bool, 'emojis' => Bool, 'text_color' => Bool, 'channel_emoji_status' => Bool, 'creator' => Bool, 'installed_date' => int, 'id' => long, 'access_hash' => long, 'title' => 'string', 'short_name' => 'string', 'thumbs' => [PhotoSize, PhotoSize], 'thumb_dc_id' => int, 'thumb_version' => int, 'thumb_document_id' => long, 'count' => int, 'hash' => int]; +``` diff --git a/docs/API_docs/constructors/stickerSetCovered.md b/docs/API_docs/constructors/stickerSetCovered.md new file mode 100644 index 0000000000..d136e9a651 --- /dev/null +++ b/docs/API_docs/constructors/stickerSetCovered.md @@ -0,0 +1,30 @@ +--- +title: "stickerSetCovered" +description: "Stickerset with a single sticker as preview" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerSetCovered +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickerset with a single sticker as preview + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|set|[StickerSet](/API_docs/types/StickerSet.html) | Yes|Stickerset| +|cover|[Document](/API_docs/types/Document.html) | Optional|Preview| + + + +### Type: [StickerSetCovered](/API_docs/types/StickerSetCovered.html) + + +### Example: + +``` +$stickerSetCovered = ['_' => 'stickerSetCovered', 'set' => StickerSet, 'cover' => Document]; +``` diff --git a/docs/API_docs/constructors/stickerSetFullCovered.md b/docs/API_docs/constructors/stickerSetFullCovered.md new file mode 100644 index 0000000000..d0932de67a --- /dev/null +++ b/docs/API_docs/constructors/stickerSetFullCovered.md @@ -0,0 +1,33 @@ +--- +title: "stickerSetFullCovered" +description: "Stickerset preview with all stickers of the stickerset included." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerSetFullCovered +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickerset preview with all stickers of the stickerset included. +Currently used only for [custom emoji stickersets](https://core.telegram.org/api/custom-emoji), to avoid a further call to [messages.getStickerSet](../methods/messages.getStickerSet.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|set|[StickerSet](/API_docs/types/StickerSet.html) | Yes|Stickerset| +|packs|Array of [StickerPack](/API_docs/types/StickerPack.html) | Yes|Emoji information about every sticker in the stickerset| +|keywords|Array of [StickerKeyword](/API_docs/types/StickerKeyword.html) | Yes|Keywords for some or every sticker in the stickerset.| +|documents|Array of [Document](/API_docs/types/Document.html) | Yes|Stickers| + + + +### Type: [StickerSetCovered](/API_docs/types/StickerSetCovered.html) + + +### Example: + +``` +$stickerSetFullCovered = ['_' => 'stickerSetFullCovered', 'set' => StickerSet, 'packs' => [StickerPack, StickerPack], 'keywords' => [StickerKeyword, StickerKeyword], 'documents' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/stickerSetMultiCovered.md b/docs/API_docs/constructors/stickerSetMultiCovered.md new file mode 100644 index 0000000000..872bf966f8 --- /dev/null +++ b/docs/API_docs/constructors/stickerSetMultiCovered.md @@ -0,0 +1,30 @@ +--- +title: "stickerSetMultiCovered" +description: "Stickerset, with multiple stickers as preview" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerSetMultiCovered +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stickerset, with multiple stickers as preview + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|set|[StickerSet](/API_docs/types/StickerSet.html) | Yes|Stickerset| +|covers|Array of [Document](/API_docs/types/Document.html) | Yes|Preview stickers| + + + +### Type: [StickerSetCovered](/API_docs/types/StickerSetCovered.html) + + +### Example: + +``` +$stickerSetMultiCovered = ['_' => 'stickerSetMultiCovered', 'set' => StickerSet, 'covers' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/stickerSetNoCovered.md b/docs/API_docs/constructors/stickerSetNoCovered.md new file mode 100644 index 0000000000..0be4c9c538 --- /dev/null +++ b/docs/API_docs/constructors/stickerSetNoCovered.md @@ -0,0 +1,29 @@ +--- +title: "stickerSetNoCovered" +description: "Just the stickerset information, with no previews." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: stickerSetNoCovered +[Back to constructors index](/API_docs/constructors/index.html) + + + +Just the stickerset information, with no previews. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|set|[StickerSet](/API_docs/types/StickerSet.html) | Yes|Stickerset information.| + + + +### Type: [StickerSetCovered](/API_docs/types/StickerSetCovered.html) + + +### Example: + +``` +$stickerSetNoCovered = ['_' => 'stickerSetNoCovered', 'set' => StickerSet]; +``` diff --git a/docs/API_docs/constructors/stickers.suggestedShortName.md b/docs/API_docs/constructors/stickers.suggestedShortName.md new file mode 100644 index 0000000000..5653657f71 --- /dev/null +++ b/docs/API_docs/constructors/stickers.suggestedShortName.md @@ -0,0 +1,30 @@ +--- +title: "stickers.suggestedShortName" +description: "A suggested short name for a stickerpack" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stickers_suggestedShortName.html +--- +# Constructor: stickers.suggestedShortName +[Back to constructors index](/API_docs/constructors/index.html) + + + +A suggested short name for a stickerpack + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|short\_name|[string](/API_docs/types/string.html) | Yes|Suggested short name| + + + +### Type: [stickers.SuggestedShortName](/API_docs/types/stickers.SuggestedShortName.html) + + +### Example: + +``` +$stickers_suggestedShortName = ['_' => 'stickers.suggestedShortName', 'short_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/storage.fileGif.md b/docs/API_docs/constructors/storage.fileGif.md new file mode 100644 index 0000000000..120716d2af --- /dev/null +++ b/docs/API_docs/constructors/storage.fileGif.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileGif" +description: "GIF image. MIME type: image/gif." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileGif.html +--- +# Constructor: storage.fileGif +[Back to constructors index](/API_docs/constructors/index.html) + + + +GIF image. MIME type: `image/gif`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileGif = ['_' => 'storage.fileGif']; +``` diff --git a/docs/API_docs/constructors/storage.fileJpeg.md b/docs/API_docs/constructors/storage.fileJpeg.md new file mode 100644 index 0000000000..3d38150faf --- /dev/null +++ b/docs/API_docs/constructors/storage.fileJpeg.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileJpeg" +description: "JPEG image. MIME type: image/jpeg." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileJpeg.html +--- +# Constructor: storage.fileJpeg +[Back to constructors index](/API_docs/constructors/index.html) + + + +JPEG image. MIME type: `image/jpeg`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileJpeg = ['_' => 'storage.fileJpeg']; +``` diff --git a/docs/API_docs/constructors/storage.fileMov.md b/docs/API_docs/constructors/storage.fileMov.md new file mode 100644 index 0000000000..63d4820e70 --- /dev/null +++ b/docs/API_docs/constructors/storage.fileMov.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileMov" +description: "Quicktime video. MIME type: video/quicktime." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileMov.html +--- +# Constructor: storage.fileMov +[Back to constructors index](/API_docs/constructors/index.html) + + + +Quicktime video. MIME type: `video/quicktime`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileMov = ['_' => 'storage.fileMov']; +``` diff --git a/docs/API_docs/constructors/storage.fileMp3.md b/docs/API_docs/constructors/storage.fileMp3.md new file mode 100644 index 0000000000..81febd49f7 --- /dev/null +++ b/docs/API_docs/constructors/storage.fileMp3.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileMp3" +description: "Mp3 audio. MIME type: audio/mpeg." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileMp3.html +--- +# Constructor: storage.fileMp3 +[Back to constructors index](/API_docs/constructors/index.html) + + + +Mp3 audio. MIME type: `audio/mpeg`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileMp3 = ['_' => 'storage.fileMp3']; +``` diff --git a/docs/API_docs/constructors/storage.fileMp4.md b/docs/API_docs/constructors/storage.fileMp4.md new file mode 100644 index 0000000000..1c3e37c814 --- /dev/null +++ b/docs/API_docs/constructors/storage.fileMp4.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileMp4" +description: "MPEG-4 video. MIME type: video/mp4." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileMp4.html +--- +# Constructor: storage.fileMp4 +[Back to constructors index](/API_docs/constructors/index.html) + + + +MPEG-4 video. MIME type: `video/mp4`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileMp4 = ['_' => 'storage.fileMp4']; +``` diff --git a/docs/API_docs/constructors/storage.filePartial.md b/docs/API_docs/constructors/storage.filePartial.md new file mode 100644 index 0000000000..978955bfbe --- /dev/null +++ b/docs/API_docs/constructors/storage.filePartial.md @@ -0,0 +1,25 @@ +--- +title: "storage.filePartial" +description: "Part of a bigger file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_filePartial.html +--- +# Constructor: storage.filePartial +[Back to constructors index](/API_docs/constructors/index.html) + + + +Part of a bigger file. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_filePartial = ['_' => 'storage.filePartial']; +``` diff --git a/docs/API_docs/constructors/storage.filePdf.md b/docs/API_docs/constructors/storage.filePdf.md new file mode 100644 index 0000000000..aa41875f57 --- /dev/null +++ b/docs/API_docs/constructors/storage.filePdf.md @@ -0,0 +1,25 @@ +--- +title: "storage.filePdf" +description: "PDF document image. MIME type: application/pdf." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_filePdf.html +--- +# Constructor: storage.filePdf +[Back to constructors index](/API_docs/constructors/index.html) + + + +PDF document image. MIME type: `application/pdf`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_filePdf = ['_' => 'storage.filePdf']; +``` diff --git a/docs/API_docs/constructors/storage.filePng.md b/docs/API_docs/constructors/storage.filePng.md new file mode 100644 index 0000000000..6d3a178b68 --- /dev/null +++ b/docs/API_docs/constructors/storage.filePng.md @@ -0,0 +1,25 @@ +--- +title: "storage.filePng" +description: "PNG image. MIME type: image/png." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_filePng.html +--- +# Constructor: storage.filePng +[Back to constructors index](/API_docs/constructors/index.html) + + + +PNG image. MIME type: `image/png`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_filePng = ['_' => 'storage.filePng']; +``` diff --git a/docs/API_docs/constructors/storage.fileUnknown.md b/docs/API_docs/constructors/storage.fileUnknown.md new file mode 100644 index 0000000000..9d89b01ae9 --- /dev/null +++ b/docs/API_docs/constructors/storage.fileUnknown.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileUnknown" +description: "Unknown type." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileUnknown.html +--- +# Constructor: storage.fileUnknown +[Back to constructors index](/API_docs/constructors/index.html) + + + +Unknown type. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileUnknown = ['_' => 'storage.fileUnknown']; +``` diff --git a/docs/API_docs/constructors/storage.fileWebp.md b/docs/API_docs/constructors/storage.fileWebp.md new file mode 100644 index 0000000000..0b3892d5e8 --- /dev/null +++ b/docs/API_docs/constructors/storage.fileWebp.md @@ -0,0 +1,25 @@ +--- +title: "storage.fileWebp" +description: "WEBP image. MIME type: image/webp." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/storage_fileWebp.html +--- +# Constructor: storage.fileWebp +[Back to constructors index](/API_docs/constructors/index.html) + + + +WEBP image. MIME type: `image/webp`. + + + + +### Type: [storage.FileType](/API_docs/types/storage.FileType.html) + + +### Example: + +``` +$storage_fileWebp = ['_' => 'storage.fileWebp']; +``` diff --git a/docs/API_docs/constructors/stories.allStories.md b/docs/API_docs/constructors/stories.allStories.md new file mode 100644 index 0000000000..a6113bbe3a --- /dev/null +++ b/docs/API_docs/constructors/stories.allStories.md @@ -0,0 +1,36 @@ +--- +title: "stories.allStories" +description: "Full list of active (or active and hidden) stories." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_allStories.html +--- +# Constructor: stories.allStories +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full list of active (or active and hidden) [stories](https://core.telegram.org/api/stories#watching-stories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_more|[Bool](/API_docs/types/Bool.html) | Optional|Whether more results can be fetched as [described here »](https://core.telegram.org/api/stories#watching-stories).| +|count|[int](/API_docs/types/int.html) | Yes|Total number of active (or active and hidden) stories| +|state|[string](/API_docs/types/string.html) | Yes|State to use for pagination| +|peer\_stories|Array of [PeerStories](/API_docs/types/PeerStories.html) | Yes|Stories| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| +|stealth\_mode|[StoriesStealthMode](/API_docs/types/StoriesStealthMode.html) | Yes|Current [stealth mode](https://core.telegram.org/api/stories#stealth-mode) information| + + + +### Type: [stories.AllStories](/API_docs/types/stories.AllStories.html) + + +### Example: + +``` +$stories_allStories = ['_' => 'stories.allStories', 'has_more' => Bool, 'count' => int, 'state' => 'string', 'peer_stories' => [PeerStories, PeerStories], 'chats' => [Chat, Chat], 'users' => [User, User], 'stealth_mode' => StoriesStealthMode]; +``` diff --git a/docs/API_docs/constructors/stories.allStoriesNotModified.md b/docs/API_docs/constructors/stories.allStoriesNotModified.md new file mode 100644 index 0000000000..0fa8b7dcf7 --- /dev/null +++ b/docs/API_docs/constructors/stories.allStoriesNotModified.md @@ -0,0 +1,31 @@ +--- +title: "stories.allStoriesNotModified" +description: "The list of active (or active and hidden) stories has not changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_allStoriesNotModified.html +--- +# Constructor: stories.allStoriesNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of active (or active and hidden) [stories](https://core.telegram.org/api/stories#watching-stories) has not changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|state|[string](/API_docs/types/string.html) | Yes|State to use to ask for updates| +|stealth\_mode|[StoriesStealthMode](/API_docs/types/StoriesStealthMode.html) | Yes|Current [stealth mode](https://core.telegram.org/api/stories#stealth-mode) information| + + + +### Type: [stories.AllStories](/API_docs/types/stories.AllStories.html) + + +### Example: + +``` +$stories_allStoriesNotModified = ['_' => 'stories.allStoriesNotModified', 'state' => 'string', 'stealth_mode' => StoriesStealthMode]; +``` diff --git a/docs/API_docs/constructors/stories.peerStories.md b/docs/API_docs/constructors/stories.peerStories.md new file mode 100644 index 0000000000..ee5f527ad6 --- /dev/null +++ b/docs/API_docs/constructors/stories.peerStories.md @@ -0,0 +1,32 @@ +--- +title: "stories.peerStories" +description: "Active story list of a specific peer." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_peerStories.html +--- +# Constructor: stories.peerStories +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Active story list](https://core.telegram.org/api/stories#watching-stories) of a specific peer. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|stories|[PeerStories](/API_docs/types/PeerStories.html) | Yes|Stories| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [stories.PeerStories](/API_docs/types/stories.PeerStories.html) + + +### Example: + +``` +$stories_peerStories = ['_' => 'stories.peerStories', 'stories' => PeerStories, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/stories.stories.md b/docs/API_docs/constructors/stories.stories.md new file mode 100644 index 0000000000..06a6e0122e --- /dev/null +++ b/docs/API_docs/constructors/stories.stories.md @@ -0,0 +1,34 @@ +--- +title: "stories.stories" +description: "List of stories" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_stories.html +--- +# Constructor: stories.stories +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of [stories](https://core.telegram.org/api/stories#pinned-or-archived-stories) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of stories that can be fetched| +|stories|Array of [StoryItem](/API_docs/types/StoryItem.html) | Yes|Stories| +|pinned\_to\_top|Array of [int](/API_docs/types/int.html) | Optional| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [stories.Stories](/API_docs/types/stories.Stories.html) + + +### Example: + +``` +$stories_stories = ['_' => 'stories.stories', 'count' => int, 'stories' => [StoryItem, StoryItem], 'pinned_to_top' => [int, int], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/stories.storyReactionsList.md b/docs/API_docs/constructors/stories.storyReactionsList.md new file mode 100644 index 0000000000..e8368a94b9 --- /dev/null +++ b/docs/API_docs/constructors/stories.storyReactionsList.md @@ -0,0 +1,34 @@ +--- +title: "stories.storyReactionsList" +description: "List of peers that reacted to or intercated with a specific story" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_storyReactionsList.html +--- +# Constructor: stories.storyReactionsList +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of peers that reacted to or intercated with a specific [story](https://core.telegram.org/api/stories) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of reactions matching query| +|reactions|Array of [StoryReaction](/API_docs/types/StoryReaction.html) | Yes|List of peers that reacted to or interacted with a specific story| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| +|next\_offset|[string](/API_docs/types/string.html) | Optional|If set, indicates the next offset to use to load more results by invoking [stories.getStoryReactionsList](../methods/stories.getStoryReactionsList.html).| + + + +### Type: [stories.StoryReactionsList](/API_docs/types/stories.StoryReactionsList.html) + + +### Example: + +``` +$stories_storyReactionsList = ['_' => 'stories.storyReactionsList', 'count' => int, 'reactions' => [StoryReaction, StoryReaction], 'chats' => [Chat, Chat], 'users' => [User, User], 'next_offset' => 'string']; +``` diff --git a/docs/API_docs/constructors/stories.storyViews.md b/docs/API_docs/constructors/stories.storyViews.md new file mode 100644 index 0000000000..34057f6acf --- /dev/null +++ b/docs/API_docs/constructors/stories.storyViews.md @@ -0,0 +1,31 @@ +--- +title: "stories.storyViews" +description: "Reaction and view counters for a list of stories" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_storyViews.html +--- +# Constructor: stories.storyViews +[Back to constructors index](/API_docs/constructors/index.html) + + + +Reaction and view counters for a list of [stories](https://core.telegram.org/api/stories) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|views|Array of [StoryViews](/API_docs/types/StoryViews.html) | Yes|View date and reaction information of multiple stories| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [stories.StoryViews](/API_docs/types/stories.StoryViews.html) + + +### Example: + +``` +$stories_storyViews = ['_' => 'stories.storyViews', 'views' => [StoryViews, StoryViews], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/stories.storyViewsList.md b/docs/API_docs/constructors/stories.storyViewsList.md new file mode 100644 index 0000000000..9afec63dfb --- /dev/null +++ b/docs/API_docs/constructors/stories.storyViewsList.md @@ -0,0 +1,37 @@ +--- +title: "stories.storyViewsList" +description: "Reaction and view counters for a story" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/stories_storyViewsList.html +--- +# Constructor: stories.storyViewsList +[Back to constructors index](/API_docs/constructors/index.html) + + + +Reaction and view counters for a [story](https://core.telegram.org/api/stories) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|count|[int](/API_docs/types/int.html) | Yes|Total number of results that can be fetched| +|views\_count|[int](/API_docs/types/int.html) | Yes|Total number of story views| +|forwards\_count|[int](/API_docs/types/int.html) | Yes|Total number of story forwards/reposts| +|reactions\_count|[int](/API_docs/types/int.html) | Yes|Number of reactions that were added to the story| +|views|Array of [StoryView](/API_docs/types/StoryView.html) | Yes|Story view date and reaction information| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| +|next\_offset|[string](/API_docs/types/string.html) | Optional|Offset for pagination| + + + +### Type: [stories.StoryViewsList](/API_docs/types/stories.StoryViewsList.html) + + +### Example: + +``` +$stories_storyViewsList = ['_' => 'stories.storyViewsList', 'count' => int, 'views_count' => int, 'forwards_count' => int, 'reactions_count' => int, 'views' => [StoryView, StoryView], 'chats' => [Chat, Chat], 'users' => [User, User], 'next_offset' => 'string']; +``` diff --git a/docs/API_docs/constructors/storiesStealthMode.md b/docs/API_docs/constructors/storiesStealthMode.md new file mode 100644 index 0000000000..d6cbe7e7c8 --- /dev/null +++ b/docs/API_docs/constructors/storiesStealthMode.md @@ -0,0 +1,30 @@ +--- +title: "storiesStealthMode" +description: "Information about the current stealth mode session." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storiesStealthMode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Information about the current [stealth mode](https://core.telegram.org/api/stories#stealth-mode) session. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|active\_until\_date|[int](/API_docs/types/int.html) | Optional|The date up to which stealth mode will be active.| +|cooldown\_until\_date|[int](/API_docs/types/int.html) | Optional|The date starting from which the user will be allowed to re-enable stealth mode again.| + + + +### Type: [StoriesStealthMode](/API_docs/types/StoriesStealthMode.html) + + +### Example: + +``` +$storiesStealthMode = ['_' => 'storiesStealthMode', 'active_until_date' => int, 'cooldown_until_date' => int]; +``` diff --git a/docs/API_docs/constructors/storyFwdHeader.md b/docs/API_docs/constructors/storyFwdHeader.md new file mode 100644 index 0000000000..51cd62b03c --- /dev/null +++ b/docs/API_docs/constructors/storyFwdHeader.md @@ -0,0 +1,32 @@ +--- +title: "storyFwdHeader" +description: "Contains info about the original poster of a reposted story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyFwdHeader +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains info about the original poster of a reposted story. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|modified|[Bool](/API_docs/types/Bool.html) | Optional|Whether the story media was modified before reposting it (for example by overlaying a round video with a reaction).| +|from|[Peer](/API_docs/types/Peer.html) | Optional|Peer that originally posted the story; will be empty for stories forwarded from a user with forwards privacy enabled, in which case `from_name` will be set, instead.| +|from\_name|[string](/API_docs/types/string.html) | Optional|Will be set for stories forwarded from a user with forwards privacy enabled, in which case `from` will also be empty.| +|story\_id|[int](/API_docs/types/int.html) | Optional|, contains the story ID| + + + +### Type: [StoryFwdHeader](/API_docs/types/StoryFwdHeader.html) + + +### Example: + +``` +$storyFwdHeader = ['_' => 'storyFwdHeader', 'modified' => Bool, 'from' => Peer, 'from_name' => 'string', 'story_id' => int]; +``` diff --git a/docs/API_docs/constructors/storyItem.md b/docs/API_docs/constructors/storyItem.md new file mode 100644 index 0000000000..ac8cc1e68a --- /dev/null +++ b/docs/API_docs/constructors/storyItem.md @@ -0,0 +1,110 @@ +--- +title: "storyItem" +description: "Represents a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyItem +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [story](https://core.telegram.org/api/stories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story is pinned on the user's profile| +|public|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story is public and can be viewed by everyone| +|close\_friends|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story can only be viewed by [our close friends, see here »](https://core.telegram.org/api/privacy) for more info| +|min|[Bool](/API_docs/types/Bool.html) | Optional|Full information about this story was omitted for space and performance reasons; use [stories.getStoriesByID](../methods/stories.getStoriesByID.html) to fetch full info about this story when and if needed.| +|noforwards|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story is [protected](https://telegram.org/blog/protected-content-delete-by-date-and-more) and thus cannot be forwarded; clients should also prevent users from saving attached media (i.e. videos should only be streamed, photos should be kept in RAM, et cetera).| +|edited|[Bool](/API_docs/types/Bool.html) | Optional|Indicates whether the story was edited.| +|contacts|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story can only be viewed by our contacts| +|selected\_contacts|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story can only be viewed by a select list of our contacts| +|out|[Bool](/API_docs/types/Bool.html) | Optional|indicates whether we sent this story.| +|id|[int](/API_docs/types/int.html) | Yes|ID of the story.| +|date|[int](/API_docs/types/int.html) | Yes|When was the story posted.| +|from\_id|[Peer](/API_docs/types/Peer.html) | Optional| +|fwd\_from|[StoryFwdHeader](/API_docs/types/StoryFwdHeader.html) | Optional|For [reposted stories »](https://core.telegram.org/api/stories#reposting-stories), contains info about the original story.| +|expire\_date|[int](/API_docs/types/int.html) | Yes|When does the story expire.| +|caption|[string](/API_docs/types/string.html) | Optional|Story caption.| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|media|[MessageMedia](/API_docs/types/MessageMedia.html) | Optional|Story media.| +|media\_areas|Array of [MediaArea](/API_docs/types/MediaArea.html) | Optional|List of media areas, see [here »](https://core.telegram.org/api/stories#media-areas) for more info on media areas.| +|privacy|Array of [PrivacyRule](/API_docs/types/PrivacyRule.html) | Optional|[Privacy rules](https://core.telegram.org/api/privacy) indicating who can and can't view this story| +|views|[StoryViews](/API_docs/types/StoryViews.html) | Optional|View date and reaction information| +|sent\_reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|The reaction we sent.| + + + +### Type: [StoryItem](/API_docs/types/StoryItem.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$storyItem = ['_' => 'storyItem', 'pinned' => Bool, 'public' => Bool, 'close_friends' => Bool, 'min' => Bool, 'noforwards' => Bool, 'edited' => Bool, 'contacts' => Bool, 'selected_contacts' => Bool, 'out' => Bool, 'id' => int, 'date' => int, 'from_id' => Peer, 'fwd_from' => StoryFwdHeader, 'expire_date' => int, 'caption' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'media' => MessageMedia, 'media_areas' => [MediaArea, MediaArea], 'privacy' => [PrivacyRule, PrivacyRule], 'views' => StoryViews, 'sent_reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/storyItemDeleted.md b/docs/API_docs/constructors/storyItemDeleted.md new file mode 100644 index 0000000000..1fadb6e4b6 --- /dev/null +++ b/docs/API_docs/constructors/storyItemDeleted.md @@ -0,0 +1,29 @@ +--- +title: "storyItemDeleted" +description: "Represents a previously active story, that was deleted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyItemDeleted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a previously active story, that was deleted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|Story ID| + + + +### Type: [StoryItem](/API_docs/types/StoryItem.html) + + +### Example: + +``` +$storyItemDeleted = ['_' => 'storyItemDeleted', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/storyItemSkipped.md b/docs/API_docs/constructors/storyItemSkipped.md new file mode 100644 index 0000000000..6e168bd2ee --- /dev/null +++ b/docs/API_docs/constructors/storyItemSkipped.md @@ -0,0 +1,32 @@ +--- +title: "storyItemSkipped" +description: "Represents an active story, whose full information was omitted for space and performance reasons; use stories.getStoriesByID to fetch full info about the skipped story when and if needed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyItemSkipped +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents an active story, whose full information was omitted for space and performance reasons; use [stories.getStoriesByID](../methods/stories.getStoriesByID.html) to fetch full info about the skipped story when and if needed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|close\_friends|[Bool](/API_docs/types/Bool.html) | Optional|Whether this story can only be viewed by [our close friends, see here »](https://core.telegram.org/api/privacy) for more info| +|id|[int](/API_docs/types/int.html) | Yes|Story ID| +|date|[int](/API_docs/types/int.html) | Yes|When was the story posted.| +|expire\_date|[int](/API_docs/types/int.html) | Yes|When does the story expire.| + + + +### Type: [StoryItem](/API_docs/types/StoryItem.html) + + +### Example: + +``` +$storyItemSkipped = ['_' => 'storyItemSkipped', 'close_friends' => Bool, 'id' => int, 'date' => int, 'expire_date' => int]; +``` diff --git a/docs/API_docs/constructors/storyReaction.md b/docs/API_docs/constructors/storyReaction.md new file mode 100644 index 0000000000..587e574fcd --- /dev/null +++ b/docs/API_docs/constructors/storyReaction.md @@ -0,0 +1,31 @@ +--- +title: "storyReaction" +description: "How a certain peer reacted to a story" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +How a certain peer reacted to a story + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|The peer| +|date|[int](/API_docs/types/int.html) | Yes|Reaction date| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|The reaction| + + + +### Type: [StoryReaction](/API_docs/types/StoryReaction.html) + + +### Example: + +``` +$storyReaction = ['_' => 'storyReaction', 'peer_id' => Peer, 'date' => int, 'reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/storyReactionPublicForward.md b/docs/API_docs/constructors/storyReactionPublicForward.md new file mode 100644 index 0000000000..7f0b24a24d --- /dev/null +++ b/docs/API_docs/constructors/storyReactionPublicForward.md @@ -0,0 +1,29 @@ +--- +title: "storyReactionPublicForward" +description: "A certain peer has forwarded the story as a message to a public chat or channel." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyReactionPublicForward +[Back to constructors index](/API_docs/constructors/index.html) + + + +A certain peer has forwarded the story as a message to a public chat or channel. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The message with the forwarded story.| + + + +### Type: [StoryReaction](/API_docs/types/StoryReaction.html) + + +### Example: + +``` +$storyReactionPublicForward = ['_' => 'storyReactionPublicForward', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/storyReactionPublicRepost.md b/docs/API_docs/constructors/storyReactionPublicRepost.md new file mode 100644 index 0000000000..97949b2fdb --- /dev/null +++ b/docs/API_docs/constructors/storyReactionPublicRepost.md @@ -0,0 +1,30 @@ +--- +title: "storyReactionPublicRepost" +description: "A certain peer has reposted the story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyReactionPublicRepost +[Back to constructors index](/API_docs/constructors/index.html) + + + +A certain peer has reposted the story. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|The peer that reposted the story.| +|story|[StoryItem](/API_docs/types/StoryItem.html) | Yes|The reposted story.| + + + +### Type: [StoryReaction](/API_docs/types/StoryReaction.html) + + +### Example: + +``` +$storyReactionPublicRepost = ['_' => 'storyReactionPublicRepost', 'peer_id' => Peer, 'story' => StoryItem]; +``` diff --git a/docs/API_docs/constructors/storyView.md b/docs/API_docs/constructors/storyView.md new file mode 100644 index 0000000000..12cf832a01 --- /dev/null +++ b/docs/API_docs/constructors/storyView.md @@ -0,0 +1,33 @@ +--- +title: "storyView" +description: "Story view date and reaction information" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyView +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Story](https://core.telegram.org/api/stories) view date and reaction information + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blocked|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have [completely blocked](https://core.telegram.org/api/block) this user, including from viewing more of our stories.| +|blocked\_my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have [blocked](https://core.telegram.org/api/block) this user from viewing more of our stories.| +|user\_id|[long](/API_docs/types/long.html) | Yes|The user that viewed the story| +|date|[int](/API_docs/types/int.html) | Yes|When did the user view the story| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|If present, contains the reaction that the user left on the story| + + + +### Type: [StoryView](/API_docs/types/StoryView.html) + + +### Example: + +``` +$storyView = ['_' => 'storyView', 'blocked' => Bool, 'blocked_my_stories_from' => Bool, 'user_id' => long, 'date' => int, 'reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/storyViewPublicForward.md b/docs/API_docs/constructors/storyViewPublicForward.md new file mode 100644 index 0000000000..7ec48156fc --- /dev/null +++ b/docs/API_docs/constructors/storyViewPublicForward.md @@ -0,0 +1,31 @@ +--- +title: "storyViewPublicForward" +description: "A certain peer has forwarded the story as a message to a public chat or channel." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyViewPublicForward +[Back to constructors index](/API_docs/constructors/index.html) + + + +A certain peer has forwarded the story as a message to a public chat or channel. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blocked|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have [completely blocked](https://core.telegram.org/api/block) this user, including from viewing more of our stories.| +|blocked\_my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have [blocked](https://core.telegram.org/api/block) this user from viewing more of our stories.| +|message|[Message](/API_docs/types/Message.html) | Optional|The message with the forwarded story.| + + + +### Type: [StoryView](/API_docs/types/StoryView.html) + + +### Example: + +``` +$storyViewPublicForward = ['_' => 'storyViewPublicForward', 'blocked' => Bool, 'blocked_my_stories_from' => Bool, 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/storyViewPublicRepost.md b/docs/API_docs/constructors/storyViewPublicRepost.md new file mode 100644 index 0000000000..30ed561ce6 --- /dev/null +++ b/docs/API_docs/constructors/storyViewPublicRepost.md @@ -0,0 +1,32 @@ +--- +title: "storyViewPublicRepost" +description: "A certain peer has reposted the story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyViewPublicRepost +[Back to constructors index](/API_docs/constructors/index.html) + + + +A certain peer has reposted the story. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blocked|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have [completely blocked](https://core.telegram.org/api/block) this user, including from viewing more of our stories.| +|blocked\_my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Optional|Whether we have [blocked](https://core.telegram.org/api/block) this user from viewing more of our stories.| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|The peer that reposted the story.| +|story|[StoryItem](/API_docs/types/StoryItem.html) | Yes|The reposted story.| + + + +### Type: [StoryView](/API_docs/types/StoryView.html) + + +### Example: + +``` +$storyViewPublicRepost = ['_' => 'storyViewPublicRepost', 'blocked' => Bool, 'blocked_my_stories_from' => Bool, 'peer_id' => Peer, 'story' => StoryItem]; +``` diff --git a/docs/API_docs/constructors/storyViews.md b/docs/API_docs/constructors/storyViews.md new file mode 100644 index 0000000000..2328e4d0fe --- /dev/null +++ b/docs/API_docs/constructors/storyViews.md @@ -0,0 +1,34 @@ +--- +title: "storyViews" +description: "Aggregated view and reaction information of a story." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: storyViews +[Back to constructors index](/API_docs/constructors/index.html) + + + +Aggregated view and reaction information of a [story](https://core.telegram.org/api/stories). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_viewers|[Bool](/API_docs/types/Bool.html) | Optional|If set, indicates that the viewers list is currently viewable, and was not yet deleted because the story has expired while the user didn't have a [Premium](https://core.telegram.org/api/premium) account.| +|views\_count|[int](/API_docs/types/int.html) | Yes|View counter of the story| +|forwards\_count|[int](/API_docs/types/int.html) | Optional|Forward counter of the story| +|reactions|Array of [ReactionCount](/API_docs/types/ReactionCount.html) | Optional|All reactions sent to this story| +|reactions\_count|[int](/API_docs/types/int.html) | Optional|Number of reactions added to the story| +|recent\_viewers|Array of [long](/API_docs/types/long.html) | Optional|User IDs of some recent viewers of the story| + + + +### Type: [StoryViews](/API_docs/types/StoryViews.html) + + +### Example: + +``` +$storyViews = ['_' => 'storyViews', 'has_viewers' => Bool, 'views_count' => int, 'forwards_count' => int, 'reactions' => [ReactionCount, ReactionCount], 'reactions_count' => int, 'recent_viewers' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/textAnchor.md b/docs/API_docs/constructors/textAnchor.md new file mode 100644 index 0000000000..6c39a66ce7 --- /dev/null +++ b/docs/API_docs/constructors/textAnchor.md @@ -0,0 +1,30 @@ +--- +title: "textAnchor" +description: "Text linking to another section of the page" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textAnchor +[Back to constructors index](/API_docs/constructors/index.html) + + + +Text linking to another section of the page + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| +|name|[string](/API_docs/types/string.html) | Yes|Section name| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textAnchor = ['_' => 'textAnchor', 'text' => RichText, 'name' => 'string']; +``` diff --git a/docs/API_docs/constructors/textBold.md b/docs/API_docs/constructors/textBold.md new file mode 100644 index 0000000000..195b445aa5 --- /dev/null +++ b/docs/API_docs/constructors/textBold.md @@ -0,0 +1,29 @@ +--- +title: "textBold" +description: "Bold text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textBold +[Back to constructors index](/API_docs/constructors/index.html) + + + +**Bold** text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textBold = ['_' => 'textBold', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textConcat.md b/docs/API_docs/constructors/textConcat.md new file mode 100644 index 0000000000..704b10009c --- /dev/null +++ b/docs/API_docs/constructors/textConcat.md @@ -0,0 +1,29 @@ +--- +title: "textConcat" +description: "Concatenation of rich texts" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textConcat +[Back to constructors index](/API_docs/constructors/index.html) + + + +Concatenation of rich texts + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|texts|Array of [RichText](/API_docs/types/RichText.html) | Yes|Concatenated rich texts| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textConcat = ['_' => 'textConcat', 'texts' => [RichText, RichText]]; +``` diff --git a/docs/API_docs/constructors/textEmail.md b/docs/API_docs/constructors/textEmail.md new file mode 100644 index 0000000000..e104c5c958 --- /dev/null +++ b/docs/API_docs/constructors/textEmail.md @@ -0,0 +1,30 @@ +--- +title: "textEmail" +description: "Rich text email link" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textEmail +[Back to constructors index](/API_docs/constructors/index.html) + + + +Rich text email link + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Link text| +|email|[string](/API_docs/types/string.html) | Yes|Email address| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textEmail = ['_' => 'textEmail', 'text' => RichText, 'email' => 'string']; +``` diff --git a/docs/API_docs/constructors/textEmpty.md b/docs/API_docs/constructors/textEmpty.md new file mode 100644 index 0000000000..7cccc57fc0 --- /dev/null +++ b/docs/API_docs/constructors/textEmpty.md @@ -0,0 +1,24 @@ +--- +title: "textEmpty" +description: "Empty rich text element" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty rich text element + + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textEmpty = ['_' => 'textEmpty']; +``` diff --git a/docs/API_docs/constructors/textFixed.md b/docs/API_docs/constructors/textFixed.md new file mode 100644 index 0000000000..94f46a49bd --- /dev/null +++ b/docs/API_docs/constructors/textFixed.md @@ -0,0 +1,29 @@ +--- +title: "textFixed" +description: "fixed-width rich text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textFixed +[Back to constructors index](/API_docs/constructors/index.html) + + + +`fixed-width` rich text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textFixed = ['_' => 'textFixed', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textImage.md b/docs/API_docs/constructors/textImage.md new file mode 100644 index 0000000000..8bc83e8cd3 --- /dev/null +++ b/docs/API_docs/constructors/textImage.md @@ -0,0 +1,31 @@ +--- +title: "textImage" +description: "Inline image" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textImage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Inline image + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|document\_id|[long](/API_docs/types/long.html) | Yes|Document ID| +|w|[int](/API_docs/types/int.html) | Yes|Width| +|h|[int](/API_docs/types/int.html) | Yes|Height| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textImage = ['_' => 'textImage', 'document_id' => long, 'w' => int, 'h' => int]; +``` diff --git a/docs/API_docs/constructors/textItalic.md b/docs/API_docs/constructors/textItalic.md new file mode 100644 index 0000000000..ef9dbae16d --- /dev/null +++ b/docs/API_docs/constructors/textItalic.md @@ -0,0 +1,29 @@ +--- +title: "textItalic" +description: "Italic text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textItalic +[Back to constructors index](/API_docs/constructors/index.html) + + + +*Italic* text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textItalic = ['_' => 'textItalic', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textMarked.md b/docs/API_docs/constructors/textMarked.md new file mode 100644 index 0000000000..6cd3a2d84b --- /dev/null +++ b/docs/API_docs/constructors/textMarked.md @@ -0,0 +1,29 @@ +--- +title: "textMarked" +description: "Highlighted text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textMarked +[Back to constructors index](/API_docs/constructors/index.html) + + + +Highlighted text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textMarked = ['_' => 'textMarked', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textPhone.md b/docs/API_docs/constructors/textPhone.md new file mode 100644 index 0000000000..3bb26a6aa7 --- /dev/null +++ b/docs/API_docs/constructors/textPhone.md @@ -0,0 +1,30 @@ +--- +title: "textPhone" +description: "Rich text linked to a phone number" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +Rich text linked to a phone number + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| +|phone|[string](/API_docs/types/string.html) | Yes|Phone number| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textPhone = ['_' => 'textPhone', 'text' => RichText, 'phone' => 'string']; +``` diff --git a/docs/API_docs/constructors/textPlain.md b/docs/API_docs/constructors/textPlain.md new file mode 100644 index 0000000000..ad46b2550c --- /dev/null +++ b/docs/API_docs/constructors/textPlain.md @@ -0,0 +1,29 @@ +--- +title: "textPlain" +description: "Plain text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textPlain +[Back to constructors index](/API_docs/constructors/index.html) + + + +Plain text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textPlain = ['_' => 'textPlain', 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/textStrike.md b/docs/API_docs/constructors/textStrike.md new file mode 100644 index 0000000000..981fddc534 --- /dev/null +++ b/docs/API_docs/constructors/textStrike.md @@ -0,0 +1,29 @@ +--- +title: "textStrike" +description: "Strikethrough text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textStrike +[Back to constructors index](/API_docs/constructors/index.html) + + + +Strikethrough text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textStrike = ['_' => 'textStrike', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textSubscript.md b/docs/API_docs/constructors/textSubscript.md new file mode 100644 index 0000000000..b666c24f0f --- /dev/null +++ b/docs/API_docs/constructors/textSubscript.md @@ -0,0 +1,29 @@ +--- +title: "textSubscript" +description: "Subscript text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textSubscript +[Back to constructors index](/API_docs/constructors/index.html) + + + +Subscript text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textSubscript = ['_' => 'textSubscript', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textSuperscript.md b/docs/API_docs/constructors/textSuperscript.md new file mode 100644 index 0000000000..8a768a3071 --- /dev/null +++ b/docs/API_docs/constructors/textSuperscript.md @@ -0,0 +1,29 @@ +--- +title: "textSuperscript" +description: "Superscript text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textSuperscript +[Back to constructors index](/API_docs/constructors/index.html) + + + +Superscript text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textSuperscript = ['_' => 'textSuperscript', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textUnderline.md b/docs/API_docs/constructors/textUnderline.md new file mode 100644 index 0000000000..f4cff6f2bb --- /dev/null +++ b/docs/API_docs/constructors/textUnderline.md @@ -0,0 +1,29 @@ +--- +title: "textUnderline" +description: "Underlined text" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textUnderline +[Back to constructors index](/API_docs/constructors/index.html) + + + +Underlined text + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textUnderline = ['_' => 'textUnderline', 'text' => RichText]; +``` diff --git a/docs/API_docs/constructors/textUrl.md b/docs/API_docs/constructors/textUrl.md new file mode 100644 index 0000000000..06aae0101b --- /dev/null +++ b/docs/API_docs/constructors/textUrl.md @@ -0,0 +1,31 @@ +--- +title: "textUrl" +description: "Link" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Link + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[RichText](/API_docs/types/RichText.html) | Yes|Text of link| +|url|[string](/API_docs/types/string.html) | Yes|Webpage HTTP URL| +|webpage\_id|[long](/API_docs/types/long.html) | Yes|If a preview was already generated for the page, the page ID| + + + +### Type: [RichText](/API_docs/types/RichText.html) + + +### Example: + +``` +$textUrl = ['_' => 'textUrl', 'text' => RichText, 'url' => 'string', 'webpage_id' => long]; +``` diff --git a/docs/API_docs/constructors/textWithEntities.md b/docs/API_docs/constructors/textWithEntities.md new file mode 100644 index 0000000000..d8aac38fdb --- /dev/null +++ b/docs/API_docs/constructors/textWithEntities.md @@ -0,0 +1,91 @@ +--- +title: "textWithEntities" +description: "Styled text with message entities" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: textWithEntities +[Back to constructors index](/API_docs/constructors/index.html) + + + +Styled text with [message entities](https://core.telegram.org/api/entities) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|text|[string](/API_docs/types/string.html) | Yes|Text| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Yes|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + + +### Type: [TextWithEntities](/API_docs/types/TextWithEntities.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$textWithEntities = ['_' => 'textWithEntities', 'text' => 'string', 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', ]; +``` diff --git a/docs/API_docs/constructors/theme.md b/docs/API_docs/constructors/theme.md new file mode 100644 index 0000000000..b9f688b1ef --- /dev/null +++ b/docs/API_docs/constructors/theme.md @@ -0,0 +1,39 @@ +--- +title: "theme" +description: "Theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: theme +[Back to constructors index](/API_docs/constructors/index.html) + + + +Theme + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|creator|[Bool](/API_docs/types/Bool.html) | Optional|Whether the current user is the creator of this theme| +|default|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is the default theme| +|for\_chat|[Bool](/API_docs/types/Bool.html) | Optional|Whether this theme is meant to be used as a [chat theme](https://telegram.org/blog/chat-themes-interactive-emoji-read-receipts)| +|id|[long](/API_docs/types/long.html) | Yes|Theme ID| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Theme access hash| +|slug|[string](/API_docs/types/string.html) | Yes|Unique theme ID| +|title|[string](/API_docs/types/string.html) | Yes|Theme name| +|document|[Document](/API_docs/types/Document.html) | Optional|Theme| +|settings|Array of [ThemeSettings](/API_docs/types/ThemeSettings.html) | Optional|Theme settings| +|emoticon|[string](/API_docs/types/string.html) | Optional|Theme emoji| +|installs\_count|[int](/API_docs/types/int.html) | Optional|Installation count| + + + +### Type: [Theme](/API_docs/types/Theme.html) + + +### Example: + +``` +$theme = ['_' => 'theme', 'creator' => Bool, 'default' => Bool, 'for_chat' => Bool, 'id' => long, 'access_hash' => long, 'slug' => 'string', 'title' => 'string', 'document' => Document, 'settings' => [ThemeSettings, ThemeSettings], 'emoticon' => 'string', 'installs_count' => int]; +``` diff --git a/docs/API_docs/constructors/themeSettings.md b/docs/API_docs/constructors/themeSettings.md new file mode 100644 index 0000000000..8f8732216f --- /dev/null +++ b/docs/API_docs/constructors/themeSettings.md @@ -0,0 +1,34 @@ +--- +title: "themeSettings" +description: "Theme settings" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: themeSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Theme settings + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message\_colors\_animated|[Bool](/API_docs/types/Bool.html) | Optional|If set, the freeform gradient fill needs to be animated on every sent message.| +|base\_theme|[BaseTheme](/API_docs/types/BaseTheme.html) | Yes|Base theme| +|accent\_color|[int](/API_docs/types/int.html) | Yes|Accent color, ARGB format| +|outbox\_accent\_color|[int](/API_docs/types/int.html) | Optional|Accent color of outgoing messages in ARGB format| +|message\_colors|Array of [int](/API_docs/types/int.html) | Optional|The fill to be used as a background for outgoing messages, in RGB24 format.
If just one or two equal colors are provided, describes a solid fill of a background.
If two different colors are provided, describes the top and bottom colors of a 0-degree gradient.
If three or four colors are provided, describes a freeform gradient fill of a background.| +|wallpaper|[WallPaper](/API_docs/types/WallPaper.html) | Optional|[Wallpaper](https://core.telegram.org/api/wallpapers)| + + + +### Type: [ThemeSettings](/API_docs/types/ThemeSettings.html) + + +### Example: + +``` +$themeSettings = ['_' => 'themeSettings', 'message_colors_animated' => Bool, 'base_theme' => BaseTheme, 'accent_color' => int, 'outbox_accent_color' => int, 'message_colors' => [int, int], 'wallpaper' => WallPaper]; +``` diff --git a/docs/API_docs/constructors/timezone.md b/docs/API_docs/constructors/timezone.md new file mode 100644 index 0000000000..ae541820c5 --- /dev/null +++ b/docs/API_docs/constructors/timezone.md @@ -0,0 +1,29 @@ +--- +title: "timezone" +description: "timezone attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: timezone +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|id|[string](/API_docs/types/string.html) | Yes| +|name|[string](/API_docs/types/string.html) | Yes| +|utc\_offset|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [Timezone](/API_docs/types/Timezone.html) + + +### Example: + +``` +$timezone = ['_' => 'timezone', 'id' => 'string', 'name' => 'string', 'utc_offset' => int]; +``` diff --git a/docs/API_docs/constructors/topPeer.md b/docs/API_docs/constructors/topPeer.md new file mode 100644 index 0000000000..b5b9acb4ec --- /dev/null +++ b/docs/API_docs/constructors/topPeer.md @@ -0,0 +1,30 @@ +--- +title: "topPeer" +description: "Top peer" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeer +[Back to constructors index](/API_docs/constructors/index.html) + + + +Top peer + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|rating|[double](/API_docs/types/double.html) | Yes|Rating as computed in [top peer rating »](https://core.telegram.org/api/top-rating)| + + + +### Type: [TopPeer](/API_docs/types/TopPeer.html) + + +### Example: + +``` +$topPeer = ['_' => 'topPeer', 'peer' => long, 'rating' => double]; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryBotsInline.md b/docs/API_docs/constructors/topPeerCategoryBotsInline.md new file mode 100644 index 0000000000..b3d6d6d7fc --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryBotsInline.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryBotsInline" +description: "Most used inline bots" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryBotsInline +[Back to constructors index](/API_docs/constructors/index.html) + + + +Most used inline bots + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryBotsInline = ['_' => 'topPeerCategoryBotsInline']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryBotsPM.md b/docs/API_docs/constructors/topPeerCategoryBotsPM.md new file mode 100644 index 0000000000..81c291e02d --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryBotsPM.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryBotsPM" +description: "Most used bots" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryBotsPM +[Back to constructors index](/API_docs/constructors/index.html) + + + +Most used bots + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryBotsPM = ['_' => 'topPeerCategoryBotsPM']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryChannels.md b/docs/API_docs/constructors/topPeerCategoryChannels.md new file mode 100644 index 0000000000..7ccca42779 --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryChannels.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryChannels" +description: "Most frequently visited channels" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryChannels +[Back to constructors index](/API_docs/constructors/index.html) + + + +Most frequently visited channels + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryChannels = ['_' => 'topPeerCategoryChannels']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryCorrespondents.md b/docs/API_docs/constructors/topPeerCategoryCorrespondents.md new file mode 100644 index 0000000000..90e0f78e42 --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryCorrespondents.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryCorrespondents" +description: "Users we've chatted most frequently with" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryCorrespondents +[Back to constructors index](/API_docs/constructors/index.html) + + + +Users we've chatted most frequently with + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryCorrespondents = ['_' => 'topPeerCategoryCorrespondents']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryForwardChats.md b/docs/API_docs/constructors/topPeerCategoryForwardChats.md new file mode 100644 index 0000000000..54ff1cf25d --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryForwardChats.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryForwardChats" +description: "Chats to which the users often forwards messages to" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryForwardChats +[Back to constructors index](/API_docs/constructors/index.html) + + + +Chats to which the users often forwards messages to + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryForwardChats = ['_' => 'topPeerCategoryForwardChats']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryForwardUsers.md b/docs/API_docs/constructors/topPeerCategoryForwardUsers.md new file mode 100644 index 0000000000..0ec5ed56fc --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryForwardUsers.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryForwardUsers" +description: "Users to which the users often forwards messages to" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryForwardUsers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Users to which the users often forwards messages to + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryForwardUsers = ['_' => 'topPeerCategoryForwardUsers']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryGroups.md b/docs/API_docs/constructors/topPeerCategoryGroups.md new file mode 100644 index 0000000000..c69809d0cc --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryGroups.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryGroups" +description: "Often-opened groups and supergroups" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryGroups +[Back to constructors index](/API_docs/constructors/index.html) + + + +Often-opened groups and supergroups + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryGroups = ['_' => 'topPeerCategoryGroups']; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryPeers.md b/docs/API_docs/constructors/topPeerCategoryPeers.md new file mode 100644 index 0000000000..422b875663 --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryPeers.md @@ -0,0 +1,31 @@ +--- +title: "topPeerCategoryPeers" +description: "Top peer category" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryPeers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Top peer category + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|category|[TopPeerCategory](/API_docs/types/TopPeerCategory.html) | Yes|Top peer category of peers| +|count|[int](/API_docs/types/int.html) | Yes|Count of peers| +|peers|Array of [TopPeer](/API_docs/types/TopPeer.html) | Yes|Peers| + + + +### Type: [TopPeerCategoryPeers](/API_docs/types/TopPeerCategoryPeers.html) + + +### Example: + +``` +$topPeerCategoryPeers = ['_' => 'topPeerCategoryPeers', 'category' => TopPeerCategory, 'count' => int, 'peers' => [TopPeer, TopPeer]]; +``` diff --git a/docs/API_docs/constructors/topPeerCategoryPhoneCalls.md b/docs/API_docs/constructors/topPeerCategoryPhoneCalls.md new file mode 100644 index 0000000000..3daa468c59 --- /dev/null +++ b/docs/API_docs/constructors/topPeerCategoryPhoneCalls.md @@ -0,0 +1,24 @@ +--- +title: "topPeerCategoryPhoneCalls" +description: "Most frequently called users" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: topPeerCategoryPhoneCalls +[Back to constructors index](/API_docs/constructors/index.html) + + + +Most frequently called users + + + + +### Type: [TopPeerCategory](/API_docs/types/TopPeerCategory.html) + + +### Example: + +``` +$topPeerCategoryPhoneCalls = ['_' => 'topPeerCategoryPhoneCalls']; +``` diff --git a/docs/API_docs/constructors/true.md b/docs/API_docs/constructors/true.md new file mode 100644 index 0000000000..8cc5e61df5 --- /dev/null +++ b/docs/API_docs/constructors/true.md @@ -0,0 +1,24 @@ +--- +title: "true" +description: "See predefined identifiers." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: true +[Back to constructors index](/API_docs/constructors/index.html) + + + +See [predefined identifiers](https://core.telegram.org/mtproto/TL-formal#predefined-identifiers). + + + + +### Type: [True](/API_docs/types/True.html) + + +### Example: + +``` +$true = ['_' => 'true']; +``` diff --git a/docs/API_docs/constructors/updateAttachMenuBots.md b/docs/API_docs/constructors/updateAttachMenuBots.md new file mode 100644 index 0000000000..3eac53d9c3 --- /dev/null +++ b/docs/API_docs/constructors/updateAttachMenuBots.md @@ -0,0 +1,24 @@ +--- +title: "updateAttachMenuBots" +description: "The list of installed attachment menu entries » has changed, use messages.getAttachMenuBots to fetch the updated list." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateAttachMenuBots +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of installed [attachment menu entries »](https://core.telegram.org/api/bots/attach) has changed, use [messages.getAttachMenuBots](../methods/messages.getAttachMenuBots.html) to fetch the updated list. + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateAttachMenuBots = ['_' => 'updateAttachMenuBots']; +``` diff --git a/docs/API_docs/constructors/updateAutoSaveSettings.md b/docs/API_docs/constructors/updateAutoSaveSettings.md new file mode 100644 index 0000000000..75c841e223 --- /dev/null +++ b/docs/API_docs/constructors/updateAutoSaveSettings.md @@ -0,0 +1,24 @@ +--- +title: "updateAutoSaveSettings" +description: "Media autosave settings have changed and must be refetched using account.getAutoSaveSettings." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateAutoSaveSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Media autosave settings have changed and must be refetched using [account.getAutoSaveSettings](../methods/account.getAutoSaveSettings.html). + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateAutoSaveSettings = ['_' => 'updateAutoSaveSettings']; +``` diff --git a/docs/API_docs/constructors/updateBotBusinessConnect.md b/docs/API_docs/constructors/updateBotBusinessConnect.md new file mode 100644 index 0000000000..89806bb12f --- /dev/null +++ b/docs/API_docs/constructors/updateBotBusinessConnect.md @@ -0,0 +1,28 @@ +--- +title: "updateBotBusinessConnect" +description: "updateBotBusinessConnect attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotBusinessConnect +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|connection|[BotBusinessConnection](/API_docs/types/BotBusinessConnection.html) | Yes| +|qts|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotBusinessConnect = ['_' => 'updateBotBusinessConnect', 'connection' => BotBusinessConnection, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotCallbackQuery.md b/docs/API_docs/constructors/updateBotCallbackQuery.md new file mode 100644 index 0000000000..d4956bd73a --- /dev/null +++ b/docs/API_docs/constructors/updateBotCallbackQuery.md @@ -0,0 +1,35 @@ +--- +title: "updateBotCallbackQuery" +description: "A callback button was pressed, and the button data was sent to the bot that created the button" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotCallbackQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +A callback button was pressed, and the button data was sent to the bot that created the button + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Query ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of the user that pressed the button| +|peer|[long](/API_docs/types/long.html) | Yes|Chat where the inline keyboard was sent| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID| +|chat\_instance|[long](/API_docs/types/long.html) | Yes|Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games.| +|data|[bytes](/API_docs/types/bytes.html) | Optional|Callback data| +|game\_short\_name|[string](/API_docs/types/string.html) | Optional|Short name of a Game to be returned, serves as the unique identifier for the game| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotCallbackQuery = ['_' => 'updateBotCallbackQuery', 'query_id' => long, 'user_id' => long, 'peer' => long, 'msg_id' => int, 'chat_instance' => long, 'data' => 'bytes', 'game_short_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateBotChatBoost.md b/docs/API_docs/constructors/updateBotChatBoost.md new file mode 100644 index 0000000000..85b57bc140 --- /dev/null +++ b/docs/API_docs/constructors/updateBotChatBoost.md @@ -0,0 +1,31 @@ +--- +title: "updateBotChatBoost" +description: "A channel boost has changed (bots only)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotChatBoost +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [channel boost](https://core.telegram.org/api/boost) has changed (bots only) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Channel| +|boost|[Boost](/API_docs/types/Boost.html) | Yes|New boost information| +|qts|[int](/API_docs/types/int.html) | Yes|[QTS](https://core.telegram.org/api/updates) event sequence identifier| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotChatBoost = ['_' => 'updateBotChatBoost', 'peer' => long, 'boost' => Boost, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotChatInviteRequester.md b/docs/API_docs/constructors/updateBotChatInviteRequester.md new file mode 100644 index 0000000000..4d8dfcc9d5 --- /dev/null +++ b/docs/API_docs/constructors/updateBotChatInviteRequester.md @@ -0,0 +1,34 @@ +--- +title: "updateBotChatInviteRequester" +description: "Someone has requested to join a chat or channel (bots only, users will receive an updatePendingJoinRequests, instead)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotChatInviteRequester +[Back to constructors index](/API_docs/constructors/index.html) + + + +Someone has requested to join a chat or channel (bots only, users will receive an [updatePendingJoinRequests](../constructors/updatePendingJoinRequests.html), instead) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The chat or channel in question| +|date|[int](/API_docs/types/int.html) | Yes|When was the [join request »](https://core.telegram.org/api/invites#join-requests) made| +|user\_id|[long](/API_docs/types/long.html) | Yes|The user ID that is asking to join the chat or channel| +|about|[string](/API_docs/types/string.html) | Yes|Bio of the user| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Yes|Chat invite link that was used by the user to send the [join request »](https://core.telegram.org/api/invites#join-requests)| +|qts|[int](/API_docs/types/int.html) | Yes|[QTS](https://core.telegram.org/api/updates) event sequence identifier| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotChatInviteRequester = ['_' => 'updateBotChatInviteRequester', 'peer' => long, 'date' => int, 'user_id' => long, 'about' => 'string', 'invite' => ExportedChatInvite, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotCommands.md b/docs/API_docs/constructors/updateBotCommands.md new file mode 100644 index 0000000000..44a0eccd9f --- /dev/null +++ b/docs/API_docs/constructors/updateBotCommands.md @@ -0,0 +1,31 @@ +--- +title: "updateBotCommands" +description: "The command set of a certain bot in a certain chat has changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotCommands +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The affected chat| +|bot\_id|[long](/API_docs/types/long.html) | Yes|ID of the bot that changed its command set| +|commands|Array of [BotCommand](/API_docs/types/BotCommand.html) | Yes|New bot commands| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotCommands = ['_' => 'updateBotCommands', 'peer' => long, 'bot_id' => long, 'commands' => [BotCommand, BotCommand]]; +``` diff --git a/docs/API_docs/constructors/updateBotDeleteBusinessMessage.md b/docs/API_docs/constructors/updateBotDeleteBusinessMessage.md new file mode 100644 index 0000000000..c8a782d722 --- /dev/null +++ b/docs/API_docs/constructors/updateBotDeleteBusinessMessage.md @@ -0,0 +1,30 @@ +--- +title: "updateBotDeleteBusinessMessage" +description: "updateBotDeleteBusinessMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotDeleteBusinessMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|connection\_id|[string](/API_docs/types/string.html) | Yes| +|peer|[long](/API_docs/types/long.html) | Yes| +|messages|Array of [int](/API_docs/types/int.html) | Yes| +|qts|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotDeleteBusinessMessage = ['_' => 'updateBotDeleteBusinessMessage', 'connection_id' => 'string', 'peer' => long, 'messages' => [int, int], 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotEditBusinessMessage.md b/docs/API_docs/constructors/updateBotEditBusinessMessage.md new file mode 100644 index 0000000000..a5e38ee977 --- /dev/null +++ b/docs/API_docs/constructors/updateBotEditBusinessMessage.md @@ -0,0 +1,30 @@ +--- +title: "updateBotEditBusinessMessage" +description: "updateBotEditBusinessMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotEditBusinessMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|connection\_id|[string](/API_docs/types/string.html) | Yes| +|message|[Message](/API_docs/types/Message.html) | Optional| +|reply\_to\_message|[Message](/API_docs/types/Message.html) | Optional| +|qts|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotEditBusinessMessage = ['_' => 'updateBotEditBusinessMessage', 'connection_id' => 'string', 'message' => Message, 'reply_to_message' => Message, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotInlineQuery.md b/docs/API_docs/constructors/updateBotInlineQuery.md new file mode 100644 index 0000000000..13852ae9f5 --- /dev/null +++ b/docs/API_docs/constructors/updateBotInlineQuery.md @@ -0,0 +1,34 @@ +--- +title: "updateBotInlineQuery" +description: "An incoming inline query" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotInlineQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +An incoming inline query + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Query ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|User that sent the query| +|query|[string](/API_docs/types/string.html) | Yes|Text of query| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Attached geolocation| +|peer\_type|[InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) | Optional|Type of the chat from which the inline query was sent.| +|offset|[string](/API_docs/types/string.html) | Yes|Offset to navigate through results| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotInlineQuery = ['_' => 'updateBotInlineQuery', 'query_id' => long, 'user_id' => long, 'query' => 'string', 'geo' => GeoPoint, 'peer_type' => InlineQueryPeerType, 'offset' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateBotInlineSend.md b/docs/API_docs/constructors/updateBotInlineSend.md new file mode 100644 index 0000000000..3915cfea73 --- /dev/null +++ b/docs/API_docs/constructors/updateBotInlineSend.md @@ -0,0 +1,33 @@ +--- +title: "updateBotInlineSend" +description: "The result of an inline query that was chosen by a user and sent to their chat partner. Please see our documentation on the feedback collecting for details on how to enable these updates for your bot." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotInlineSend +[Back to constructors index](/API_docs/constructors/index.html) + + + +The result of an inline query that was chosen by a user and sent to their chat partner. Please see our documentation on the [feedback collecting](https://core.telegram.org/bots/inline#collecting-feedback) for details on how to enable these updates for your bot. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|The user that chose the result| +|query|[string](/API_docs/types/string.html) | Yes|The query that was used to obtain the result| +|geo|[GeoPoint](/API_docs/types/GeoPoint.html) | Optional|Optional. Sender location, only for bots that require user location| +|id|[string](/API_docs/types/string.html) | Yes|The unique identifier for the result that was chosen| +|msg\_id|[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) | Optional|Identifier of the sent inline message. Available only if there is an inline keyboard attached to the message. Will be also received in callback queries and can be used to edit the message.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotInlineSend = ['_' => 'updateBotInlineSend', 'user_id' => long, 'query' => 'string', 'geo' => GeoPoint, 'id' => 'string', 'msg_id' => InputBotInlineMessageID]; +``` diff --git a/docs/API_docs/constructors/updateBotMenuButton.md b/docs/API_docs/constructors/updateBotMenuButton.md new file mode 100644 index 0000000000..44d6bf5ec4 --- /dev/null +++ b/docs/API_docs/constructors/updateBotMenuButton.md @@ -0,0 +1,30 @@ +--- +title: "updateBotMenuButton" +description: "The menu button behavior for the specified bot has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotMenuButton +[Back to constructors index](/API_docs/constructors/index.html) + + + +The menu button behavior for the specified bot has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|bot\_id|[long](/API_docs/types/long.html) | Yes|Bot ID| +|button|[BotMenuButton](/API_docs/types/BotMenuButton.html) | Yes|New menu button| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotMenuButton = ['_' => 'updateBotMenuButton', 'bot_id' => long, 'button' => BotMenuButton]; +``` diff --git a/docs/API_docs/constructors/updateBotMessageReaction.md b/docs/API_docs/constructors/updateBotMessageReaction.md new file mode 100644 index 0000000000..6d70ebef14 --- /dev/null +++ b/docs/API_docs/constructors/updateBotMessageReaction.md @@ -0,0 +1,35 @@ +--- +title: "updateBotMessageReaction" +description: "Bots only: a user has changed their reactions on a message with public reactions." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotMessageReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bots only: a user has changed their reactions on a message with public reactions. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer of the reacted-to message.| +|msg\_id|[int](/API_docs/types/int.html) | Yes|ID of the reacted-to message.| +|date|[int](/API_docs/types/int.html) | Yes|Date of the change.| +|actor|[Peer](/API_docs/types/Peer.html) | Yes|The user that (un)reacted to the message.| +|old\_reactions|Array of [Reaction](/API_docs/types/Reaction.html) | Yes|Old reactions| +|new\_reactions|Array of [Reaction](/API_docs/types/Reaction.html) | Yes|New reactions| +|qts|[int](/API_docs/types/int.html) | Yes|[QTS](https://core.telegram.org/api/updates) event sequence identifier| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotMessageReaction = ['_' => 'updateBotMessageReaction', 'peer' => long, 'msg_id' => int, 'date' => int, 'actor' => Peer, 'old_reactions' => [Reaction, Reaction], 'new_reactions' => [Reaction, Reaction], 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotMessageReactions.md b/docs/API_docs/constructors/updateBotMessageReactions.md new file mode 100644 index 0000000000..815e7e1701 --- /dev/null +++ b/docs/API_docs/constructors/updateBotMessageReactions.md @@ -0,0 +1,33 @@ +--- +title: "updateBotMessageReactions" +description: "Bots only: the number of reactions on a message with anonymous reactions has changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotMessageReactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +Bots only: the number of reactions on a message with anonymous reactions has changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer of the reacted-to message.| +|msg\_id|[int](/API_docs/types/int.html) | Yes|ID of the reacted-to message.| +|date|[int](/API_docs/types/int.html) | Yes|Date of the change.| +|reactions|Array of [ReactionCount](/API_docs/types/ReactionCount.html) | Yes|New reaction counters.| +|qts|[int](/API_docs/types/int.html) | Yes|[QTS](https://core.telegram.org/api/updates) event sequence identifier| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotMessageReactions = ['_' => 'updateBotMessageReactions', 'peer' => long, 'msg_id' => int, 'date' => int, 'reactions' => [ReactionCount, ReactionCount], 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotNewBusinessMessage.md b/docs/API_docs/constructors/updateBotNewBusinessMessage.md new file mode 100644 index 0000000000..a96c294c16 --- /dev/null +++ b/docs/API_docs/constructors/updateBotNewBusinessMessage.md @@ -0,0 +1,30 @@ +--- +title: "updateBotNewBusinessMessage" +description: "updateBotNewBusinessMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotNewBusinessMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|connection\_id|[string](/API_docs/types/string.html) | Yes| +|message|[Message](/API_docs/types/Message.html) | Optional| +|reply\_to\_message|[Message](/API_docs/types/Message.html) | Optional| +|qts|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotNewBusinessMessage = ['_' => 'updateBotNewBusinessMessage', 'connection_id' => 'string', 'message' => Message, 'reply_to_message' => Message, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotPrecheckoutQuery.md b/docs/API_docs/constructors/updateBotPrecheckoutQuery.md new file mode 100644 index 0000000000..22b38ea865 --- /dev/null +++ b/docs/API_docs/constructors/updateBotPrecheckoutQuery.md @@ -0,0 +1,35 @@ +--- +title: "updateBotPrecheckoutQuery" +description: "This object contains information about an incoming pre-checkout query." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotPrecheckoutQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +This object contains information about an incoming pre-checkout query. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Unique query identifier| +|user\_id|[long](/API_docs/types/long.html) | Yes|User who sent the query| +|payload|[bytes](/API_docs/types/bytes.html) | Yes|Bot specified invoice payload| +|info|[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) | Optional|Order info provided by the user| +|shipping\_option\_id|[string](/API_docs/types/string.html) | Optional|Identifier of the shipping option chosen by the user| +|currency|[string](/API_docs/types/string.html) | Yes|Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code| +|total\_amount|[long](/API_docs/types/long.html) | Yes|Total amount in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotPrecheckoutQuery = ['_' => 'updateBotPrecheckoutQuery', 'query_id' => long, 'user_id' => long, 'payload' => 'bytes', 'info' => PaymentRequestedInfo, 'shipping_option_id' => 'string', 'currency' => 'string', 'total_amount' => long]; +``` diff --git a/docs/API_docs/constructors/updateBotShippingQuery.md b/docs/API_docs/constructors/updateBotShippingQuery.md new file mode 100644 index 0000000000..dd510985cd --- /dev/null +++ b/docs/API_docs/constructors/updateBotShippingQuery.md @@ -0,0 +1,32 @@ +--- +title: "updateBotShippingQuery" +description: "This object contains information about an incoming shipping query." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotShippingQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +This object contains information about an incoming shipping query. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Unique query identifier| +|user\_id|[long](/API_docs/types/long.html) | Yes|User who sent the query| +|payload|[bytes](/API_docs/types/bytes.html) | Yes|Bot specified invoice payload| +|shipping\_address|[PostAddress](/API_docs/types/PostAddress.html) | Yes|User specified shipping address| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotShippingQuery = ['_' => 'updateBotShippingQuery', 'query_id' => long, 'user_id' => long, 'payload' => 'bytes', 'shipping_address' => PostAddress]; +``` diff --git a/docs/API_docs/constructors/updateBotStopped.md b/docs/API_docs/constructors/updateBotStopped.md new file mode 100644 index 0000000000..3d8c1c04fa --- /dev/null +++ b/docs/API_docs/constructors/updateBotStopped.md @@ -0,0 +1,32 @@ +--- +title: "updateBotStopped" +description: "A bot was stopped or re-started." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotStopped +[Back to constructors index](/API_docs/constructors/index.html) + + + +A bot was stopped or re-started. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|The user ID| +|date|[int](/API_docs/types/int.html) | Yes|When did this action occur| +|stopped|[Bool](/API_docs/types/Bool.html) | Yes|Whether the bot was stopped or started| +|qts|[int](/API_docs/types/int.html) | Yes|New **qts** value, see [updates »](https://core.telegram.org/api/updates) for more info.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotStopped = ['_' => 'updateBotStopped', 'user_id' => long, 'date' => int, 'stopped' => Bool, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateBotWebhookJSON.md b/docs/API_docs/constructors/updateBotWebhookJSON.md new file mode 100644 index 0000000000..dfcd452880 --- /dev/null +++ b/docs/API_docs/constructors/updateBotWebhookJSON.md @@ -0,0 +1,29 @@ +--- +title: "updateBotWebhookJSON" +description: "A new incoming event; for bots only" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotWebhookJSON +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new incoming event; for bots only + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|data|[DataJSON](/API_docs/types/DataJSON.html) | Yes|The event| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotWebhookJSON = ['_' => 'updateBotWebhookJSON', 'data' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/updateBotWebhookJSONQuery.md b/docs/API_docs/constructors/updateBotWebhookJSONQuery.md new file mode 100644 index 0000000000..07990476a4 --- /dev/null +++ b/docs/API_docs/constructors/updateBotWebhookJSONQuery.md @@ -0,0 +1,31 @@ +--- +title: "updateBotWebhookJSONQuery" +description: "A new incoming query; for bots only" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateBotWebhookJSONQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new incoming query; for bots only + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Query identifier| +|data|[DataJSON](/API_docs/types/DataJSON.html) | Yes|Query data| +|timeout|[int](/API_docs/types/int.html) | Yes|Query timeout| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateBotWebhookJSONQuery = ['_' => 'updateBotWebhookJSONQuery', 'query_id' => long, 'data' => DataJSON, 'timeout' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannel.md b/docs/API_docs/constructors/updateChannel.md new file mode 100644 index 0000000000..7a0079a4ab --- /dev/null +++ b/docs/API_docs/constructors/updateChannel.md @@ -0,0 +1,29 @@ +--- +title: "updateChannel" +description: "A new channel or supergroup is available, or info about an existing channel has changed and must be refeteched." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannel +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new channel or supergroup is available, or info about an existing channel has changed and must be refeteched. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannel = ['_' => 'updateChannel', 'channel_id' => long]; +``` diff --git a/docs/API_docs/constructors/updateChannelAvailableMessages.md b/docs/API_docs/constructors/updateChannelAvailableMessages.md new file mode 100644 index 0000000000..d6460a6fd4 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelAvailableMessages.md @@ -0,0 +1,30 @@ +--- +title: "updateChannelAvailableMessages" +description: "The history of a channel/supergroup was hidden." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelAvailableMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +The history of a [channel/supergroup](https://core.telegram.org/api/channel) was hidden. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel/supergroup ID| +|available\_min\_id|[int](/API_docs/types/int.html) | Yes|Identifier of a maximum unavailable message in a channel due to hidden history.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelAvailableMessages = ['_' => 'updateChannelAvailableMessages', 'channel_id' => long, 'available_min_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannelMessageForwards.md b/docs/API_docs/constructors/updateChannelMessageForwards.md new file mode 100644 index 0000000000..3ee9e872ff --- /dev/null +++ b/docs/API_docs/constructors/updateChannelMessageForwards.md @@ -0,0 +1,31 @@ +--- +title: "updateChannelMessageForwards" +description: "The forward counter of a message in a channel has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelMessageForwards +[Back to constructors index](/API_docs/constructors/index.html) + + + +The forward counter of a message in a channel has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|id|[int](/API_docs/types/int.html) | Yes|ID of the message| +|forwards|[int](/API_docs/types/int.html) | Yes|New forward counter| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelMessageForwards = ['_' => 'updateChannelMessageForwards', 'channel_id' => long, 'id' => int, 'forwards' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannelMessageViews.md b/docs/API_docs/constructors/updateChannelMessageViews.md new file mode 100644 index 0000000000..82955d3000 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelMessageViews.md @@ -0,0 +1,31 @@ +--- +title: "updateChannelMessageViews" +description: "The view counter of a message in a channel has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelMessageViews +[Back to constructors index](/API_docs/constructors/index.html) + + + +The view counter of a message in a channel has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|id|[int](/API_docs/types/int.html) | Yes|ID of the message| +|views|[int](/API_docs/types/int.html) | Yes|New view counter| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelMessageViews = ['_' => 'updateChannelMessageViews', 'channel_id' => long, 'id' => int, 'views' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannelParticipant.md b/docs/API_docs/constructors/updateChannelParticipant.md new file mode 100644 index 0000000000..cee897e5a6 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelParticipant.md @@ -0,0 +1,37 @@ +--- +title: "updateChannelParticipant" +description: "A participant has left, joined, was banned or admined in a channel or supergroup." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelParticipant +[Back to constructors index](/API_docs/constructors/index.html) + + + +A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|via\_chatlist|[Bool](/API_docs/types/Bool.html) | Optional|Whether the participant joined using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links).| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|date|[int](/API_docs/types/int.html) | Yes|Date of the event| +|actor\_id|[long](/API_docs/types/long.html) | Yes|User that triggered the change (inviter, admin that kicked the user, or the even the **user\_id** itself)| +|user\_id|[long](/API_docs/types/long.html) | Yes|User that was affected by the change| +|prev\_participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Optional|Previous participant status| +|new\_participant|[ChannelParticipant](/API_docs/types/ChannelParticipant.html) | Optional|New participant status| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Optional|Chat invite used to join the [channel/supergroup](https://core.telegram.org/api/channel)| +|qts|[int](/API_docs/types/int.html) | Yes|New **qts** value, see [updates »](https://core.telegram.org/api/updates) for more info.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelParticipant = ['_' => 'updateChannelParticipant', 'via_chatlist' => Bool, 'channel_id' => long, 'date' => int, 'actor_id' => long, 'user_id' => long, 'prev_participant' => ChannelParticipant, 'new_participant' => ChannelParticipant, 'invite' => ExportedChatInvite, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannelPinnedTopic.md b/docs/API_docs/constructors/updateChannelPinnedTopic.md new file mode 100644 index 0000000000..57d8465fb2 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelPinnedTopic.md @@ -0,0 +1,31 @@ +--- +title: "updateChannelPinnedTopic" +description: "A forum topic » was pinned or unpinned." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelPinnedTopic +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [forum topic »](https://core.telegram.org/api/forum#forum-topics) was pinned or unpinned. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether the topic was pinned or unpinned| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The forum ID| +|topic\_id|[int](/API_docs/types/int.html) | Yes|The topic ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelPinnedTopic = ['_' => 'updateChannelPinnedTopic', 'pinned' => Bool, 'channel_id' => long, 'topic_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannelPinnedTopics.md b/docs/API_docs/constructors/updateChannelPinnedTopics.md new file mode 100644 index 0000000000..d9e9bd036e --- /dev/null +++ b/docs/API_docs/constructors/updateChannelPinnedTopics.md @@ -0,0 +1,30 @@ +--- +title: "updateChannelPinnedTopics" +description: "The pinned topics of a forum have changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelPinnedTopics +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [pinned topics](https://core.telegram.org/api/forum#forum-topics) of a forum have changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Forum ID.| +|order|Array of [int](/API_docs/types/int.html) | Optional|Ordered list containing the IDs of all pinned topics.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelPinnedTopics = ['_' => 'updateChannelPinnedTopics', 'channel_id' => long, 'order' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/updateChannelReadMessagesContents.md b/docs/API_docs/constructors/updateChannelReadMessagesContents.md new file mode 100644 index 0000000000..f8f5fc4e42 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelReadMessagesContents.md @@ -0,0 +1,31 @@ +--- +title: "updateChannelReadMessagesContents" +description: "The specified channel/supergroup messages were read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelReadMessagesContents +[Back to constructors index](/API_docs/constructors/index.html) + + + +The specified [channel/supergroup](https://core.telegram.org/api/channel) messages were read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|[Channel/supergroup](https://core.telegram.org/api/channel) ID| +|top\_msg\_id|[int](/API_docs/types/int.html) | Optional|[Forum topic ID](https://core.telegram.org/api/forum#forum-topics).| +|messages|Array of [int](/API_docs/types/int.html) | Yes|IDs of messages that were read| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelReadMessagesContents = ['_' => 'updateChannelReadMessagesContents', 'channel_id' => long, 'top_msg_id' => int, 'messages' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/updateChannelTooLong.md b/docs/API_docs/constructors/updateChannelTooLong.md new file mode 100644 index 0000000000..4a3f15c672 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelTooLong.md @@ -0,0 +1,31 @@ +--- +title: "updateChannelTooLong" +description: "There are new updates in the specified channel, the client must fetch them." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelTooLong +[Back to constructors index](/API_docs/constructors/index.html) + + + +There are new updates in the specified channel, the client must fetch them. +If the difference is too long or if the channel isn't currently in the states, start fetching from the specified pts. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The channel| +|pts|[int](/API_docs/types/int.html) | Optional|The [PTS](https://core.telegram.org/api/updates).| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelTooLong = ['_' => 'updateChannelTooLong', 'channel_id' => long, 'pts' => int]; +``` diff --git a/docs/API_docs/constructors/updateChannelUserTyping.md b/docs/API_docs/constructors/updateChannelUserTyping.md new file mode 100644 index 0000000000..03aafb363a --- /dev/null +++ b/docs/API_docs/constructors/updateChannelUserTyping.md @@ -0,0 +1,32 @@ +--- +title: "updateChannelUserTyping" +description: "A user is typing in a supergroup, channel or message thread" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelUserTyping +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user is typing in a [supergroup, channel](https://core.telegram.org/api/channel) or [message thread](https://core.telegram.org/api/threads) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|top\_msg\_id|[int](/API_docs/types/int.html) | Optional|[Thread ID](https://core.telegram.org/api/threads)| +|from\_id|[Peer](/API_docs/types/Peer.html) | Yes|The peer that is typing| +|action|[SendMessageAction](/API_docs/types/SendMessageAction.html) | Yes|Whether the user is typing, sending a media or doing something else| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelUserTyping = ['_' => 'updateChannelUserTyping', 'channel_id' => long, 'top_msg_id' => int, 'from_id' => Peer, 'action' => SendMessageAction]; +``` diff --git a/docs/API_docs/constructors/updateChannelViewForumAsMessages.md b/docs/API_docs/constructors/updateChannelViewForumAsMessages.md new file mode 100644 index 0000000000..86c9100f78 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelViewForumAsMessages.md @@ -0,0 +1,31 @@ +--- +title: "updateChannelViewForumAsMessages" +description: "Users may also choose to display messages from all topics as if they were sent to a normal group, using a 'View as messages' setting in the local client." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelViewForumAsMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Users may also choose to display messages from all topics as if they were sent to a normal group, using a "View as messages" setting in the local client. +This setting only affects the current account, and is synced to other logged in sessions using the [channels.toggleViewForumAsMessages](../methods/channels.toggleViewForumAsMessages.html) method; invoking this method will update the value of the `view_forum_as_messages` flag of [channelFull](../constructors/channelFull.html) or [dialog](../constructors/dialog.html) and emit an [updateChannelViewForumAsMessages](../constructors/updateChannelViewForumAsMessages.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|The forum ID| +|enabled|[Bool](/API_docs/types/Bool.html) | Yes|The new value of the toggle.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelViewForumAsMessages = ['_' => 'updateChannelViewForumAsMessages', 'channel_id' => long, 'enabled' => Bool]; +``` diff --git a/docs/API_docs/constructors/updateChannelWebPage.md b/docs/API_docs/constructors/updateChannelWebPage.md new file mode 100644 index 0000000000..1dccfd9f96 --- /dev/null +++ b/docs/API_docs/constructors/updateChannelWebPage.md @@ -0,0 +1,32 @@ +--- +title: "updateChannelWebPage" +description: "A webpage preview of a link in a channel/supergroup message was generated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChannelWebPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A webpage preview of a link in a [channel/supergroup](https://core.telegram.org/api/channel) message was generated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|[Channel/supergroup](https://core.telegram.org/api/channel) ID| +|webpage|[WebPage](/API_docs/types/WebPage.html) | Optional|Generated webpage preview| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChannelWebPage = ['_' => 'updateChannelWebPage', 'channel_id' => long, 'webpage' => WebPage, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateChat.md b/docs/API_docs/constructors/updateChat.md new file mode 100644 index 0000000000..86b42479df --- /dev/null +++ b/docs/API_docs/constructors/updateChat.md @@ -0,0 +1,29 @@ +--- +title: "updateChat" +description: "A new chat is available" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChat +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new chat is available + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Chat ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChat = ['_' => 'updateChat', 'chat_id' => long]; +``` diff --git a/docs/API_docs/constructors/updateChatDefaultBannedRights.md b/docs/API_docs/constructors/updateChatDefaultBannedRights.md new file mode 100644 index 0000000000..1296b5a28a --- /dev/null +++ b/docs/API_docs/constructors/updateChatDefaultBannedRights.md @@ -0,0 +1,31 @@ +--- +title: "updateChatDefaultBannedRights" +description: "Default banned rights in a normal chat were updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatDefaultBannedRights +[Back to constructors index](/API_docs/constructors/index.html) + + + +Default banned rights in a [normal chat](https://core.telegram.org/api/channel) were updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The chat| +|default\_banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | Yes|New default banned rights| +|version|[int](/API_docs/types/int.html) | Yes|Version| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatDefaultBannedRights = ['_' => 'updateChatDefaultBannedRights', 'peer' => long, 'default_banned_rights' => ChatBannedRights, 'version' => int]; +``` diff --git a/docs/API_docs/constructors/updateChatParticipant.md b/docs/API_docs/constructors/updateChatParticipant.md new file mode 100644 index 0000000000..a5d32b7e97 --- /dev/null +++ b/docs/API_docs/constructors/updateChatParticipant.md @@ -0,0 +1,36 @@ +--- +title: "updateChatParticipant" +description: "A user has joined or left a specific chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatParticipant +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user has joined or left a specific chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|[Chat](https://core.telegram.org/api/channel) ID| +|date|[int](/API_docs/types/int.html) | Yes|When did this event occur| +|actor\_id|[long](/API_docs/types/long.html) | Yes|User that triggered the change (inviter, admin that kicked the user, or the even the **user\_id** itself)| +|user\_id|[long](/API_docs/types/long.html) | Yes|User that was affected by the change| +|prev\_participant|[ChatParticipant](/API_docs/types/ChatParticipant.html) | Optional|Previous participant info (empty if this participant just joined)| +|new\_participant|[ChatParticipant](/API_docs/types/ChatParticipant.html) | Optional|New participant info (empty if this participant just left)| +|invite|[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) | Optional|The invite that was used to join the group| +|qts|[int](/API_docs/types/int.html) | Yes|New **qts** value, see [updates »](https://core.telegram.org/api/updates) for more info.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatParticipant = ['_' => 'updateChatParticipant', 'chat_id' => long, 'date' => int, 'actor_id' => long, 'user_id' => long, 'prev_participant' => ChatParticipant, 'new_participant' => ChatParticipant, 'invite' => ExportedChatInvite, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateChatParticipantAdd.md b/docs/API_docs/constructors/updateChatParticipantAdd.md new file mode 100644 index 0000000000..72dc65d177 --- /dev/null +++ b/docs/API_docs/constructors/updateChatParticipantAdd.md @@ -0,0 +1,33 @@ +--- +title: "updateChatParticipantAdd" +description: "New group member." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatParticipantAdd +[Back to constructors index](/API_docs/constructors/index.html) + + + +New group member. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Group ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of the new member| +|inviter\_id|[long](/API_docs/types/long.html) | Yes|ID of the user, who added member to the group| +|date|[int](/API_docs/types/int.html) | Yes|When was the participant added| +|version|[int](/API_docs/types/int.html) | Yes|Chat version number| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatParticipantAdd = ['_' => 'updateChatParticipantAdd', 'chat_id' => long, 'user_id' => long, 'inviter_id' => long, 'date' => int, 'version' => int]; +``` diff --git a/docs/API_docs/constructors/updateChatParticipantAdmin.md b/docs/API_docs/constructors/updateChatParticipantAdmin.md new file mode 100644 index 0000000000..56f7cf7d06 --- /dev/null +++ b/docs/API_docs/constructors/updateChatParticipantAdmin.md @@ -0,0 +1,32 @@ +--- +title: "updateChatParticipantAdmin" +description: "Admin permissions of a user in a basic group were changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatParticipantAdmin +[Back to constructors index](/API_docs/constructors/index.html) + + + +Admin permissions of a user in a [basic group](https://core.telegram.org/api/channel#basic-groups) were changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Chat ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of the (de)admined user| +|is\_admin|[Bool](/API_docs/types/Bool.html) | Yes|Whether the user was rendered admin| +|version|[int](/API_docs/types/int.html) | Yes|Used in basic groups to reorder updates and make sure that all of them was received.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatParticipantAdmin = ['_' => 'updateChatParticipantAdmin', 'chat_id' => long, 'user_id' => long, 'is_admin' => Bool, 'version' => int]; +``` diff --git a/docs/API_docs/constructors/updateChatParticipantDelete.md b/docs/API_docs/constructors/updateChatParticipantDelete.md new file mode 100644 index 0000000000..6072a06316 --- /dev/null +++ b/docs/API_docs/constructors/updateChatParticipantDelete.md @@ -0,0 +1,31 @@ +--- +title: "updateChatParticipantDelete" +description: "A member has left the group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatParticipantDelete +[Back to constructors index](/API_docs/constructors/index.html) + + + +A member has left the group. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Group ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of the user| +|version|[int](/API_docs/types/int.html) | Yes|Used in basic groups to reorder updates and make sure that all of them was received.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatParticipantDelete = ['_' => 'updateChatParticipantDelete', 'chat_id' => long, 'user_id' => long, 'version' => int]; +``` diff --git a/docs/API_docs/constructors/updateChatParticipants.md b/docs/API_docs/constructors/updateChatParticipants.md new file mode 100644 index 0000000000..903adae909 --- /dev/null +++ b/docs/API_docs/constructors/updateChatParticipants.md @@ -0,0 +1,29 @@ +--- +title: "updateChatParticipants" +description: "Composition of chat participants changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +Composition of chat participants changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|participants|[ChatParticipants](/API_docs/types/ChatParticipants.html) | Yes|Updated chat participants| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatParticipants = ['_' => 'updateChatParticipants', 'participants' => ChatParticipants]; +``` diff --git a/docs/API_docs/constructors/updateChatUserTyping.md b/docs/API_docs/constructors/updateChatUserTyping.md new file mode 100644 index 0000000000..f00040eea2 --- /dev/null +++ b/docs/API_docs/constructors/updateChatUserTyping.md @@ -0,0 +1,31 @@ +--- +title: "updateChatUserTyping" +description: "The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateChatUserTyping +[Back to constructors index](/API_docs/constructors/index.html) + + + +The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|Group id| +|from\_id|[Peer](/API_docs/types/Peer.html) | Yes|Peer that started typing (can be the chat itself, in case of anonymous admins).| +|action|[SendMessageAction](/API_docs/types/SendMessageAction.html) | Yes|Type of action| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateChatUserTyping = ['_' => 'updateChatUserTyping', 'chat_id' => long, 'from_id' => Peer, 'action' => SendMessageAction]; +``` diff --git a/docs/API_docs/constructors/updateConfig.md b/docs/API_docs/constructors/updateConfig.md new file mode 100644 index 0000000000..8b9128d2dd --- /dev/null +++ b/docs/API_docs/constructors/updateConfig.md @@ -0,0 +1,24 @@ +--- +title: "updateConfig" +description: "The server-side configuration has changed; the client should re-fetch the config using help.getConfig" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateConfig +[Back to constructors index](/API_docs/constructors/index.html) + + + +The server-side configuration has changed; the client should re-fetch the config using [help.getConfig](../methods/help.getConfig.html) + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateConfig = ['_' => 'updateConfig']; +``` diff --git a/docs/API_docs/constructors/updateContactsReset.md b/docs/API_docs/constructors/updateContactsReset.md new file mode 100644 index 0000000000..f839ca7f3f --- /dev/null +++ b/docs/API_docs/constructors/updateContactsReset.md @@ -0,0 +1,24 @@ +--- +title: "updateContactsReset" +description: "All contacts were deleted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateContactsReset +[Back to constructors index](/API_docs/constructors/index.html) + + + +All contacts were deleted + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateContactsReset = ['_' => 'updateContactsReset']; +``` diff --git a/docs/API_docs/constructors/updateDcOptions.md b/docs/API_docs/constructors/updateDcOptions.md new file mode 100644 index 0000000000..0809effb52 --- /dev/null +++ b/docs/API_docs/constructors/updateDcOptions.md @@ -0,0 +1,29 @@ +--- +title: "updateDcOptions" +description: "Changes in the data center configuration options." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDcOptions +[Back to constructors index](/API_docs/constructors/index.html) + + + +Changes in the data center configuration options. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dc\_options|Array of [DcOption](/API_docs/types/DcOption.html) | Yes|New connection options| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDcOptions = ['_' => 'updateDcOptions', 'dc_options' => [DcOption, DcOption]]; +``` diff --git a/docs/API_docs/constructors/updateDeleteChannelMessages.md b/docs/API_docs/constructors/updateDeleteChannelMessages.md new file mode 100644 index 0000000000..19844fc659 --- /dev/null +++ b/docs/API_docs/constructors/updateDeleteChannelMessages.md @@ -0,0 +1,32 @@ +--- +title: "updateDeleteChannelMessages" +description: "Some messages in a supergroup/channel were deleted" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDeleteChannelMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|messages|Array of [int](/API_docs/types/int.html) | Yes|IDs of messages that were deleted| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDeleteChannelMessages = ['_' => 'updateDeleteChannelMessages', 'channel_id' => long, 'messages' => [int, int], 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateDeleteMessages.md b/docs/API_docs/constructors/updateDeleteMessages.md new file mode 100644 index 0000000000..7661ce18cd --- /dev/null +++ b/docs/API_docs/constructors/updateDeleteMessages.md @@ -0,0 +1,31 @@ +--- +title: "updateDeleteMessages" +description: "Messages were deleted." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDeleteMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Messages were deleted. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|messages|Array of [int](/API_docs/types/int.html) | Yes|List of identifiers of deleted messages| +|pts|[int](/API_docs/types/int.html) | Yes|New quality of actions in a message box| +|pts\_count|[int](/API_docs/types/int.html) | Yes|Number of generated [events](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDeleteMessages = ['_' => 'updateDeleteMessages', 'messages' => [int, int], 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateDeleteQuickReply.md b/docs/API_docs/constructors/updateDeleteQuickReply.md new file mode 100644 index 0000000000..a2a0b327aa --- /dev/null +++ b/docs/API_docs/constructors/updateDeleteQuickReply.md @@ -0,0 +1,27 @@ +--- +title: "updateDeleteQuickReply" +description: "updateDeleteQuickReply attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDeleteQuickReply +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDeleteQuickReply = ['_' => 'updateDeleteQuickReply', 'shortcut_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateDeleteQuickReplyMessages.md b/docs/API_docs/constructors/updateDeleteQuickReplyMessages.md new file mode 100644 index 0000000000..2233646a79 --- /dev/null +++ b/docs/API_docs/constructors/updateDeleteQuickReplyMessages.md @@ -0,0 +1,28 @@ +--- +title: "updateDeleteQuickReplyMessages" +description: "updateDeleteQuickReplyMessages attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDeleteQuickReplyMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Yes| +|messages|Array of [int](/API_docs/types/int.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDeleteQuickReplyMessages = ['_' => 'updateDeleteQuickReplyMessages', 'shortcut_id' => int, 'messages' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/updateDeleteScheduledMessages.md b/docs/API_docs/constructors/updateDeleteScheduledMessages.md new file mode 100644 index 0000000000..3bd9ab8ca5 --- /dev/null +++ b/docs/API_docs/constructors/updateDeleteScheduledMessages.md @@ -0,0 +1,30 @@ +--- +title: "updateDeleteScheduledMessages" +description: "Some scheduled messages were deleted from the schedule queue of a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDeleteScheduledMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|messages|Array of [int](/API_docs/types/int.html) | Yes|Deleted scheduled messages| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDeleteScheduledMessages = ['_' => 'updateDeleteScheduledMessages', 'peer' => long, 'messages' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/updateDialogFilter.md b/docs/API_docs/constructors/updateDialogFilter.md new file mode 100644 index 0000000000..ec40b4bc6f --- /dev/null +++ b/docs/API_docs/constructors/updateDialogFilter.md @@ -0,0 +1,30 @@ +--- +title: "updateDialogFilter" +description: "A new folder was added" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDialogFilter +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new [folder](https://core.telegram.org/api/folders) was added + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|[Folder](https://core.telegram.org/api/folders) ID| +|filter|[DialogFilter](/API_docs/types/DialogFilter.html) | Optional|[Folder](https://core.telegram.org/api/folders) info| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDialogFilter = ['_' => 'updateDialogFilter', 'id' => int, 'filter' => DialogFilter]; +``` diff --git a/docs/API_docs/constructors/updateDialogFilterOrder.md b/docs/API_docs/constructors/updateDialogFilterOrder.md new file mode 100644 index 0000000000..ab8a1b80df --- /dev/null +++ b/docs/API_docs/constructors/updateDialogFilterOrder.md @@ -0,0 +1,29 @@ +--- +title: "updateDialogFilterOrder" +description: "New folder order" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDialogFilterOrder +[Back to constructors index](/API_docs/constructors/index.html) + + + +New [folder](https://core.telegram.org/api/folders) order + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|order|Array of [int](/API_docs/types/int.html) | Yes|Ordered [folder IDs](https://core.telegram.org/api/folders)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDialogFilterOrder = ['_' => 'updateDialogFilterOrder', 'order' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/updateDialogFilters.md b/docs/API_docs/constructors/updateDialogFilters.md new file mode 100644 index 0000000000..bd9fbeb9e0 --- /dev/null +++ b/docs/API_docs/constructors/updateDialogFilters.md @@ -0,0 +1,24 @@ +--- +title: "updateDialogFilters" +description: "Clients should update folder info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDialogFilters +[Back to constructors index](/API_docs/constructors/index.html) + + + +Clients should update [folder](https://core.telegram.org/api/folders) info + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDialogFilters = ['_' => 'updateDialogFilters']; +``` diff --git a/docs/API_docs/constructors/updateDialogPinned.md b/docs/API_docs/constructors/updateDialogPinned.md new file mode 100644 index 0000000000..6f6cfa6794 --- /dev/null +++ b/docs/API_docs/constructors/updateDialogPinned.md @@ -0,0 +1,31 @@ +--- +title: "updateDialogPinned" +description: "A dialog was pinned/unpinned" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDialogPinned +[Back to constructors index](/API_docs/constructors/index.html) + + + +A dialog was pinned/unpinned + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether the dialog was pinned| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|peer|[DialogPeer](/API_docs/types/DialogPeer.html) | Yes|The dialog| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDialogPinned = ['_' => 'updateDialogPinned', 'pinned' => Bool, 'folder_id' => int, 'peer' => DialogPeer]; +``` diff --git a/docs/API_docs/constructors/updateDialogUnreadMark.md b/docs/API_docs/constructors/updateDialogUnreadMark.md new file mode 100644 index 0000000000..4c7d4e8ea8 --- /dev/null +++ b/docs/API_docs/constructors/updateDialogUnreadMark.md @@ -0,0 +1,30 @@ +--- +title: "updateDialogUnreadMark" +description: "The manual unread mark of a chat was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDialogUnreadMark +[Back to constructors index](/API_docs/constructors/index.html) + + + +The manual unread mark of a chat was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|unread|[Bool](/API_docs/types/Bool.html) | Optional|Was the chat marked or unmarked as read| +|peer|[DialogPeer](/API_docs/types/DialogPeer.html) | Yes|The dialog| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDialogUnreadMark = ['_' => 'updateDialogUnreadMark', 'unread' => Bool, 'peer' => DialogPeer]; +``` diff --git a/docs/API_docs/constructors/updateDraftMessage.md b/docs/API_docs/constructors/updateDraftMessage.md new file mode 100644 index 0000000000..2e933fba32 --- /dev/null +++ b/docs/API_docs/constructors/updateDraftMessage.md @@ -0,0 +1,31 @@ +--- +title: "updateDraftMessage" +description: "Notifies a change of a message draft." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateDraftMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Notifies a change of a message [draft](https://core.telegram.org/api/drafts). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer to which the draft is associated| +|top\_msg\_id|[int](/API_docs/types/int.html) | Optional|ID of the [forum topic](https://core.telegram.org/api/forum#forum-topics) to which the draft is associated| +|draft|[DraftMessage](/API_docs/types/DraftMessage.html) | Optional|The draft| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateDraftMessage = ['_' => 'updateDraftMessage', 'peer' => long, 'top_msg_id' => int, 'draft' => DraftMessage]; +``` diff --git a/docs/API_docs/constructors/updateEditChannelMessage.md b/docs/API_docs/constructors/updateEditChannelMessage.md new file mode 100644 index 0000000000..bfc0d43c80 --- /dev/null +++ b/docs/API_docs/constructors/updateEditChannelMessage.md @@ -0,0 +1,31 @@ +--- +title: "updateEditChannelMessage" +description: "A message was edited in a channel/supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateEditChannelMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was edited in a [channel/supergroup](https://core.telegram.org/api/channel) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The new message| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateEditChannelMessage = ['_' => 'updateEditChannelMessage', 'message' => Message, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateEditMessage.md b/docs/API_docs/constructors/updateEditMessage.md new file mode 100644 index 0000000000..4ffb817772 --- /dev/null +++ b/docs/API_docs/constructors/updateEditMessage.md @@ -0,0 +1,31 @@ +--- +title: "updateEditMessage" +description: "A message was edited" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateEditMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was edited + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|The new edited message| +|pts|[int](/API_docs/types/int.html) | Yes|[PTS](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[PTS count](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateEditMessage = ['_' => 'updateEditMessage', 'message' => Message, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateEncryptedChatTyping.md b/docs/API_docs/constructors/updateEncryptedChatTyping.md new file mode 100644 index 0000000000..43bca11fa8 --- /dev/null +++ b/docs/API_docs/constructors/updateEncryptedChatTyping.md @@ -0,0 +1,29 @@ +--- +title: "updateEncryptedChatTyping" +description: "Interlocutor is typing a message in an encrypted chat. Update period is 6 second. If upon this time there is no repeated update, it shall be considered that the interlocutor stopped typing." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateEncryptedChatTyping +[Back to constructors index](/API_docs/constructors/index.html) + + + +Interlocutor is typing a message in an encrypted chat. Update period is 6 second. If upon this time there is no repeated update, it shall be considered that the interlocutor stopped typing. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[int](/API_docs/types/int.html) | Yes|Chat ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateEncryptedChatTyping = ['_' => 'updateEncryptedChatTyping', 'chat_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateEncryptedMessagesRead.md b/docs/API_docs/constructors/updateEncryptedMessagesRead.md new file mode 100644 index 0000000000..85685f05d7 --- /dev/null +++ b/docs/API_docs/constructors/updateEncryptedMessagesRead.md @@ -0,0 +1,31 @@ +--- +title: "updateEncryptedMessagesRead" +description: "Communication history in an encrypted chat was marked as read." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateEncryptedMessagesRead +[Back to constructors index](/API_docs/constructors/index.html) + + + +Communication history in an encrypted chat was marked as read. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[int](/API_docs/types/int.html) | Yes|Chat ID| +|max\_date|[int](/API_docs/types/int.html) | Yes|Maximum value of data for read messages| +|date|[int](/API_docs/types/int.html) | Yes|Time when messages were read| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateEncryptedMessagesRead = ['_' => 'updateEncryptedMessagesRead', 'chat_id' => int, 'max_date' => int, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/updateEncryption.md b/docs/API_docs/constructors/updateEncryption.md new file mode 100644 index 0000000000..7e0fb975c0 --- /dev/null +++ b/docs/API_docs/constructors/updateEncryption.md @@ -0,0 +1,30 @@ +--- +title: "updateEncryption" +description: "Change of state in an encrypted chat." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateEncryption +[Back to constructors index](/API_docs/constructors/index.html) + + + +Change of state in an encrypted chat. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat|[EncryptedChat](/API_docs/types/EncryptedChat.html) | Optional|Encrypted chat| +|date|[int](/API_docs/types/int.html) | Yes|Date of change| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateEncryption = ['_' => 'updateEncryption', 'chat' => EncryptedChat, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/updateFavedStickers.md b/docs/API_docs/constructors/updateFavedStickers.md new file mode 100644 index 0000000000..2dc190586d --- /dev/null +++ b/docs/API_docs/constructors/updateFavedStickers.md @@ -0,0 +1,24 @@ +--- +title: "updateFavedStickers" +description: "The list of favorited stickers was changed, the client should call messages.getFavedStickers to refetch the new list" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateFavedStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of favorited stickers was changed, the client should call [messages.getFavedStickers](../methods/messages.getFavedStickers.html) to refetch the new list + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateFavedStickers = ['_' => 'updateFavedStickers']; +``` diff --git a/docs/API_docs/constructors/updateFolderPeers.md b/docs/API_docs/constructors/updateFolderPeers.md new file mode 100644 index 0000000000..d7b0b9ea8e --- /dev/null +++ b/docs/API_docs/constructors/updateFolderPeers.md @@ -0,0 +1,31 @@ +--- +title: "updateFolderPeers" +description: "The peer list of a peer folder was updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateFolderPeers +[Back to constructors index](/API_docs/constructors/index.html) + + + +The peer list of a [peer folder](https://core.telegram.org/api/folders#peer-folders) was updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_peers|Array of [FolderPeer](/API_docs/types/FolderPeer.html) | Yes|New peer list| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateFolderPeers = ['_' => 'updateFolderPeers', 'folder_peers' => [FolderPeer, FolderPeer], 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateGeoLiveViewed.md b/docs/API_docs/constructors/updateGeoLiveViewed.md new file mode 100644 index 0000000000..f550e29be4 --- /dev/null +++ b/docs/API_docs/constructors/updateGeoLiveViewed.md @@ -0,0 +1,30 @@ +--- +title: "updateGeoLiveViewed" +description: "Live geoposition message was viewed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateGeoLiveViewed +[Back to constructors index](/API_docs/constructors/index.html) + + + +Live geoposition message was viewed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The user that viewed the live geoposition| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID of geoposition message| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateGeoLiveViewed = ['_' => 'updateGeoLiveViewed', 'peer' => long, 'msg_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateGroupCall.md b/docs/API_docs/constructors/updateGroupCall.md new file mode 100644 index 0000000000..9a45de1f63 --- /dev/null +++ b/docs/API_docs/constructors/updateGroupCall.md @@ -0,0 +1,30 @@ +--- +title: "updateGroupCall" +description: "A new groupcall was started" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateGroupCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new groupcall was started + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|chat\_id|[long](/API_docs/types/long.html) | Yes|The [channel/supergroup](https://core.telegram.org/api/channel) where this group call or livestream takes place| +|call|[GroupCall](/API_docs/types/GroupCall.html) | Yes|Info about the group call or livestream| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateGroupCall = ['_' => 'updateGroupCall', 'chat_id' => long, 'call' => GroupCall]; +``` diff --git a/docs/API_docs/constructors/updateGroupCallConnection.md b/docs/API_docs/constructors/updateGroupCallConnection.md new file mode 100644 index 0000000000..0639e467ea --- /dev/null +++ b/docs/API_docs/constructors/updateGroupCallConnection.md @@ -0,0 +1,30 @@ +--- +title: "updateGroupCallConnection" +description: "New WebRTC parameters" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateGroupCallConnection +[Back to constructors index](/API_docs/constructors/index.html) + + + +New WebRTC parameters + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|presentation|[Bool](/API_docs/types/Bool.html) | Optional|Are these parameters related to the screen capture session currently in progress?| +|params|[DataJSON](/API_docs/types/DataJSON.html) | Yes|WebRTC parameters| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateGroupCallConnection = ['_' => 'updateGroupCallConnection', 'presentation' => Bool, 'params' => DataJSON]; +``` diff --git a/docs/API_docs/constructors/updateGroupCallParticipants.md b/docs/API_docs/constructors/updateGroupCallParticipants.md new file mode 100644 index 0000000000..92a9ef6843 --- /dev/null +++ b/docs/API_docs/constructors/updateGroupCallParticipants.md @@ -0,0 +1,31 @@ +--- +title: "updateGroupCallParticipants" +description: "The participant list of a certain group call has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateGroupCallParticipants +[Back to constructors index](/API_docs/constructors/index.html) + + + +The participant list of a certain group call has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Yes|Group call| +|participants|Array of [GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) | Yes|New participant list| +|version|[int](/API_docs/types/int.html) | Yes|Version| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateGroupCallParticipants = ['_' => 'updateGroupCallParticipants', 'call' => InputGroupCall, 'participants' => [GroupCallParticipant, GroupCallParticipant], 'version' => int]; +``` diff --git a/docs/API_docs/constructors/updateInlineBotCallbackQuery.md b/docs/API_docs/constructors/updateInlineBotCallbackQuery.md new file mode 100644 index 0000000000..2e5dffd12b --- /dev/null +++ b/docs/API_docs/constructors/updateInlineBotCallbackQuery.md @@ -0,0 +1,34 @@ +--- +title: "updateInlineBotCallbackQuery" +description: "This notification is received by bots when a button is pressed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateInlineBotCallbackQuery +[Back to constructors index](/API_docs/constructors/index.html) + + + +This notification is received by bots when a button is pressed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Query ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|ID of the user that pressed the button| +|msg\_id|[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) | Yes|ID of the inline message with the button| +|chat\_instance|[long](/API_docs/types/long.html) | Yes|Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games.| +|data|[bytes](/API_docs/types/bytes.html) | Optional|Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field.| +|game\_short\_name|[string](/API_docs/types/string.html) | Optional|Short name of a Game to be returned, serves as the unique identifier for the game| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateInlineBotCallbackQuery = ['_' => 'updateInlineBotCallbackQuery', 'query_id' => long, 'user_id' => long, 'msg_id' => InputBotInlineMessageID, 'chat_instance' => long, 'data' => 'bytes', 'game_short_name' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateLangPack.md b/docs/API_docs/constructors/updateLangPack.md new file mode 100644 index 0000000000..13249df94a --- /dev/null +++ b/docs/API_docs/constructors/updateLangPack.md @@ -0,0 +1,29 @@ +--- +title: "updateLangPack" +description: "Language pack updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateLangPack +[Back to constructors index](/API_docs/constructors/index.html) + + + +Language pack updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|difference|[LangPackDifference](/API_docs/types/LangPackDifference.html) | Yes|Changed strings| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateLangPack = ['_' => 'updateLangPack', 'difference' => LangPackDifference]; +``` diff --git a/docs/API_docs/constructors/updateLangPackTooLong.md b/docs/API_docs/constructors/updateLangPackTooLong.md new file mode 100644 index 0000000000..199dde31d0 --- /dev/null +++ b/docs/API_docs/constructors/updateLangPackTooLong.md @@ -0,0 +1,29 @@ +--- +title: "updateLangPackTooLong" +description: "A language pack has changed, the client should manually fetch the changed strings using langpack.getDifference" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateLangPackTooLong +[Back to constructors index](/API_docs/constructors/index.html) + + + +A language pack has changed, the client should manually fetch the changed strings using [langpack.getDifference](../methods/langpack.getDifference.html) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|lang\_code|[string](/API_docs/types/string.html) | Yes|Language code| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateLangPackTooLong = ['_' => 'updateLangPackTooLong', 'lang_code' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateLoginToken.md b/docs/API_docs/constructors/updateLoginToken.md new file mode 100644 index 0000000000..140e888af8 --- /dev/null +++ b/docs/API_docs/constructors/updateLoginToken.md @@ -0,0 +1,24 @@ +--- +title: "updateLoginToken" +description: "A login token (for login via QR code) was accepted." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateLoginToken +[Back to constructors index](/API_docs/constructors/index.html) + + + +A login token (for login via QR code) was accepted. + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateLoginToken = ['_' => 'updateLoginToken']; +``` diff --git a/docs/API_docs/constructors/updateMessageExtendedMedia.md b/docs/API_docs/constructors/updateMessageExtendedMedia.md new file mode 100644 index 0000000000..fc397a9270 --- /dev/null +++ b/docs/API_docs/constructors/updateMessageExtendedMedia.md @@ -0,0 +1,31 @@ +--- +title: "updateMessageExtendedMedia" +description: "Extended media update" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateMessageExtendedMedia +[Back to constructors index](/API_docs/constructors/index.html) + + + +Extended media update + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID| +|extended\_media|[MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html) | Yes|Extended media| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateMessageExtendedMedia = ['_' => 'updateMessageExtendedMedia', 'peer' => long, 'msg_id' => int, 'extended_media' => MessageExtendedMedia]; +``` diff --git a/docs/API_docs/constructors/updateMessageID.md b/docs/API_docs/constructors/updateMessageID.md new file mode 100644 index 0000000000..6895b6f8d8 --- /dev/null +++ b/docs/API_docs/constructors/updateMessageID.md @@ -0,0 +1,29 @@ +--- +title: "updateMessageID" +description: "Sent message with random_id client identifier was assigned an identifier." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateMessageID +[Back to constructors index](/API_docs/constructors/index.html) + + + +Sent message with **random\_id** client identifier was assigned an identifier. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|**id** identifier of a respective [Message](../types/Message.html)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateMessageID = ['_' => 'updateMessageID', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/updateMessagePoll.md b/docs/API_docs/constructors/updateMessagePoll.md new file mode 100644 index 0000000000..e7f60f66c9 --- /dev/null +++ b/docs/API_docs/constructors/updateMessagePoll.md @@ -0,0 +1,31 @@ +--- +title: "updateMessagePoll" +description: "The results of a poll have changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateMessagePoll +[Back to constructors index](/API_docs/constructors/index.html) + + + +The results of a poll have changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|poll\_id|[long](/API_docs/types/long.html) | Yes|Poll ID| +|poll|[Poll](/API_docs/types/Poll.html) | Optional|If the server knows the client hasn't cached this poll yet, the poll itself| +|results|[PollResults](/API_docs/types/PollResults.html) | Yes|New poll results| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateMessagePoll = ['_' => 'updateMessagePoll', 'poll_id' => long, 'poll' => Poll, 'results' => PollResults]; +``` diff --git a/docs/API_docs/constructors/updateMessagePollVote.md b/docs/API_docs/constructors/updateMessagePollVote.md new file mode 100644 index 0000000000..c6229da398 --- /dev/null +++ b/docs/API_docs/constructors/updateMessagePollVote.md @@ -0,0 +1,32 @@ +--- +title: "updateMessagePollVote" +description: "A specific peer has voted in a poll" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateMessagePollVote +[Back to constructors index](/API_docs/constructors/index.html) + + + +A specific peer has voted in a poll + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|poll\_id|[long](/API_docs/types/long.html) | Yes|Poll ID| +|peer|[long](/API_docs/types/long.html) | Yes|The peer that voted in the poll| +|options|Array of [bytes](/API_docs/types/bytes.html) | Yes|Chosen option(s)| +|qts|[int](/API_docs/types/int.html) | Yes|New **qts** value, see [updates »](https://core.telegram.org/api/updates) for more info.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateMessagePollVote = ['_' => 'updateMessagePollVote', 'poll_id' => long, 'peer' => long, 'options' => ['bytes', 'bytes'], 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateMessageReactions.md b/docs/API_docs/constructors/updateMessageReactions.md new file mode 100644 index 0000000000..f982795d83 --- /dev/null +++ b/docs/API_docs/constructors/updateMessageReactions.md @@ -0,0 +1,32 @@ +--- +title: "updateMessageReactions" +description: "New message reactions » are available" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateMessageReactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +New [message reactions »](https://core.telegram.org/api/reactions) are available + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Message ID| +|top\_msg\_id|[int](/API_docs/types/int.html) | Optional|[Forum topic ID](https://core.telegram.org/api/forum#forum-topics)| +|reactions|[MessageReactions](/API_docs/types/MessageReactions.html) | Yes|Reactions| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateMessageReactions = ['_' => 'updateMessageReactions', 'peer' => long, 'msg_id' => int, 'top_msg_id' => int, 'reactions' => MessageReactions]; +``` diff --git a/docs/API_docs/constructors/updateMoveStickerSetToTop.md b/docs/API_docs/constructors/updateMoveStickerSetToTop.md new file mode 100644 index 0000000000..e03703ad0a --- /dev/null +++ b/docs/API_docs/constructors/updateMoveStickerSetToTop.md @@ -0,0 +1,31 @@ +--- +title: "updateMoveStickerSetToTop" +description: "A stickerset was just moved to top, see here for more info »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateMoveStickerSetToTop +[Back to constructors index](/API_docs/constructors/index.html) + + + +A stickerset was just moved to top, [see here for more info »](https://core.telegram.org/api/stickers#recent-stickersets) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|masks|[Bool](/API_docs/types/Bool.html) | Optional|This update is referring to a [mask stickerset](https://core.telegram.org/api/stickers#mask-stickers)| +|emojis|[Bool](/API_docs/types/Bool.html) | Optional|This update is referring to a [custom emoji stickerset](https://core.telegram.org/api/custom-emoji)| +|stickerset|[long](/API_docs/types/long.html) | Yes|[Stickerset](https://core.telegram.org/api/stickers) ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateMoveStickerSetToTop = ['_' => 'updateMoveStickerSetToTop', 'masks' => Bool, 'emojis' => Bool, 'stickerset' => long]; +``` diff --git a/docs/API_docs/constructors/updateNewAuthorization.md b/docs/API_docs/constructors/updateNewAuthorization.md new file mode 100644 index 0000000000..f2f5ca4839 --- /dev/null +++ b/docs/API_docs/constructors/updateNewAuthorization.md @@ -0,0 +1,33 @@ +--- +title: "updateNewAuthorization" +description: "A new session logged into the current user's account through an unknown device." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewAuthorization +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new session logged into the current user's account through an unknown device. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|unconfirmed|[Bool](/API_docs/types/Bool.html) | Optional|Whether the session is [unconfirmed, see here »](https://core.telegram.org/api/auth#confirming-login) for more info.| +|hash|[long](/API_docs/types/long.html) | Yes|[Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation)| +|date|[int](/API_docs/types/int.html) | Optional|Authorization date| +|device|[string](/API_docs/types/string.html) | Optional|Name of device, for example *Android*| +|location|[string](/API_docs/types/string.html) | Optional|Location, for example *USA, NY (IP=1.2.3.4)*| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewAuthorization = ['_' => 'updateNewAuthorization', 'unconfirmed' => Bool, 'hash' => long, 'date' => int, 'device' => 'string', 'location' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateNewChannelMessage.md b/docs/API_docs/constructors/updateNewChannelMessage.md new file mode 100644 index 0000000000..aa8f0c4f0a --- /dev/null +++ b/docs/API_docs/constructors/updateNewChannelMessage.md @@ -0,0 +1,31 @@ +--- +title: "updateNewChannelMessage" +description: "A new message was sent in a channel/supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewChannelMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new message was sent in a [channel/supergroup](https://core.telegram.org/api/channel) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|New message| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewChannelMessage = ['_' => 'updateNewChannelMessage', 'message' => Message, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateNewEncryptedMessage.md b/docs/API_docs/constructors/updateNewEncryptedMessage.md new file mode 100644 index 0000000000..b6e6651291 --- /dev/null +++ b/docs/API_docs/constructors/updateNewEncryptedMessage.md @@ -0,0 +1,30 @@ +--- +title: "updateNewEncryptedMessage" +description: "New encrypted message." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewEncryptedMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +New encrypted message. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[EncryptedMessage](/API_docs/types/EncryptedMessage.html) | Yes|Message| +|qts|[int](/API_docs/types/int.html) | Yes|New **qts** value, see [updates »](https://core.telegram.org/api/updates) for more info.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewEncryptedMessage = ['_' => 'updateNewEncryptedMessage', 'message' => EncryptedMessage, 'qts' => int]; +``` diff --git a/docs/API_docs/constructors/updateNewMessage.md b/docs/API_docs/constructors/updateNewMessage.md new file mode 100644 index 0000000000..72579a3032 --- /dev/null +++ b/docs/API_docs/constructors/updateNewMessage.md @@ -0,0 +1,31 @@ +--- +title: "updateNewMessage" +description: "New message in a private chat or in a basic group." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +New message in a private chat or in a [basic group](https://core.telegram.org/api/channel#basic-groups). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|Message| +|pts|[int](/API_docs/types/int.html) | Yes|New quantity of actions in a message box| +|pts\_count|[int](/API_docs/types/int.html) | Yes|Number of generated events| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewMessage = ['_' => 'updateNewMessage', 'message' => Message, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateNewQuickReply.md b/docs/API_docs/constructors/updateNewQuickReply.md new file mode 100644 index 0000000000..507974b158 --- /dev/null +++ b/docs/API_docs/constructors/updateNewQuickReply.md @@ -0,0 +1,27 @@ +--- +title: "updateNewQuickReply" +description: "updateNewQuickReply attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewQuickReply +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|quick\_reply|[QuickReply](/API_docs/types/QuickReply.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewQuickReply = ['_' => 'updateNewQuickReply', 'quick_reply' => QuickReply]; +``` diff --git a/docs/API_docs/constructors/updateNewScheduledMessage.md b/docs/API_docs/constructors/updateNewScheduledMessage.md new file mode 100644 index 0000000000..24a2c42fc4 --- /dev/null +++ b/docs/API_docs/constructors/updateNewScheduledMessage.md @@ -0,0 +1,29 @@ +--- +title: "updateNewScheduledMessage" +description: "A message was added to the schedule queue of a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewScheduledMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +A message was added to the [schedule queue of a chat](https://core.telegram.org/api/scheduled-messages) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|message|[Message](/API_docs/types/Message.html) | Optional|Message| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewScheduledMessage = ['_' => 'updateNewScheduledMessage', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/updateNewStickerSet.md b/docs/API_docs/constructors/updateNewStickerSet.md new file mode 100644 index 0000000000..c54969c853 --- /dev/null +++ b/docs/API_docs/constructors/updateNewStickerSet.md @@ -0,0 +1,29 @@ +--- +title: "updateNewStickerSet" +description: "A new stickerset was installed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewStickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new stickerset was installed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|stickerset|[messages.StickerSet](/API_docs/constructors/messages.StickerSet.html) | Yes|The installed stickerset| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewStickerSet = ['_' => 'updateNewStickerSet', 'stickerset' => messages.StickerSet]; +``` diff --git a/docs/API_docs/constructors/updateNewStoryReaction.md b/docs/API_docs/constructors/updateNewStoryReaction.md new file mode 100644 index 0000000000..d22b7cb429 --- /dev/null +++ b/docs/API_docs/constructors/updateNewStoryReaction.md @@ -0,0 +1,29 @@ +--- +title: "updateNewStoryReaction" +description: "updateNewStoryReaction attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNewStoryReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|story\_id|[int](/API_docs/types/int.html) | Yes| +|peer|[long](/API_docs/types/long.html) | Yes| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNewStoryReaction = ['_' => 'updateNewStoryReaction', 'story_id' => int, 'peer' => long, 'reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/updateNotifySettings.md b/docs/API_docs/constructors/updateNotifySettings.md new file mode 100644 index 0000000000..096ff84a5a --- /dev/null +++ b/docs/API_docs/constructors/updateNotifySettings.md @@ -0,0 +1,30 @@ +--- +title: "updateNotifySettings" +description: "Changes in notification settings." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateNotifySettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Changes in notification settings. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[NotifyPeer](/API_docs/types/NotifyPeer.html) | Yes|Notification source| +|notify\_settings|[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) | Yes|New notification settings| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateNotifySettings = ['_' => 'updateNotifySettings', 'peer' => NotifyPeer, 'notify_settings' => PeerNotifySettings]; +``` diff --git a/docs/API_docs/constructors/updatePeerBlocked.md b/docs/API_docs/constructors/updatePeerBlocked.md new file mode 100644 index 0000000000..dc4dbc66b7 --- /dev/null +++ b/docs/API_docs/constructors/updatePeerBlocked.md @@ -0,0 +1,31 @@ +--- +title: "updatePeerBlocked" +description: "We blocked a peer, see here » for more info on blocklists." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePeerBlocked +[Back to constructors index](/API_docs/constructors/index.html) + + + +We blocked a peer, see [here »](https://core.telegram.org/api/block) for more info on blocklists. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blocked|[Bool](/API_docs/types/Bool.html) | Optional|Whether the peer was blocked or unblocked| +|blocked\_my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Optional|Whether the peer was added/removed to/from the story blocklist; if not set, this update affects the main blocklist, see [here »](https://core.telegram.org/api/block) for more info.| +|peer\_id|[Peer](/API_docs/types/Peer.html) | Yes|The (un)blocked peer| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePeerBlocked = ['_' => 'updatePeerBlocked', 'blocked' => Bool, 'blocked_my_stories_from' => Bool, 'peer_id' => Peer]; +``` diff --git a/docs/API_docs/constructors/updatePeerHistoryTTL.md b/docs/API_docs/constructors/updatePeerHistoryTTL.md new file mode 100644 index 0000000000..cf47fe0044 --- /dev/null +++ b/docs/API_docs/constructors/updatePeerHistoryTTL.md @@ -0,0 +1,30 @@ +--- +title: "updatePeerHistoryTTL" +description: "The Time-To-Live for messages sent by the current user in a specific chat has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePeerHistoryTTL +[Back to constructors index](/API_docs/constructors/index.html) + + + +The Time-To-Live for messages sent by the current user in a specific chat has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The chat| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|The new Time-To-Live| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePeerHistoryTTL = ['_' => 'updatePeerHistoryTTL', 'peer' => long, 'ttl_period' => int]; +``` diff --git a/docs/API_docs/constructors/updatePeerLocated.md b/docs/API_docs/constructors/updatePeerLocated.md new file mode 100644 index 0000000000..3204b1a63f --- /dev/null +++ b/docs/API_docs/constructors/updatePeerLocated.md @@ -0,0 +1,29 @@ +--- +title: "updatePeerLocated" +description: "List of peers near you was updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePeerLocated +[Back to constructors index](/API_docs/constructors/index.html) + + + +List of peers near you was updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peers|Array of [PeerLocated](/API_docs/types/PeerLocated.html) | Yes|Geolocated peer list update| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePeerLocated = ['_' => 'updatePeerLocated', 'peers' => [PeerLocated, PeerLocated]]; +``` diff --git a/docs/API_docs/constructors/updatePeerSettings.md b/docs/API_docs/constructors/updatePeerSettings.md new file mode 100644 index 0000000000..15e212238a --- /dev/null +++ b/docs/API_docs/constructors/updatePeerSettings.md @@ -0,0 +1,30 @@ +--- +title: "updatePeerSettings" +description: "Settings of a certain peer have changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePeerSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +Settings of a certain peer have changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer| +|settings|[PeerSettings](/API_docs/types/PeerSettings.html) | Yes|Associated peer settings| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePeerSettings = ['_' => 'updatePeerSettings', 'peer' => long, 'settings' => PeerSettings]; +``` diff --git a/docs/API_docs/constructors/updatePeerWallpaper.md b/docs/API_docs/constructors/updatePeerWallpaper.md new file mode 100644 index 0000000000..3e58e20057 --- /dev/null +++ b/docs/API_docs/constructors/updatePeerWallpaper.md @@ -0,0 +1,31 @@ +--- +title: "updatePeerWallpaper" +description: "The wallpaper » of a given peer has changed." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePeerWallpaper +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [wallpaper »](https://core.telegram.org/api/wallpapers) of a given peer has changed. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|wallpaper\_overridden|[Bool](/API_docs/types/Bool.html) | Optional|Whether the other user has chosen a custom wallpaper for us using [messages.setChatWallPaper](../methods/messages.setChatWallPaper.html) and the `for_both` flag, see [here »](https://core.telegram.org/api/wallpapers#installing-wallpapers-in-a-specific-chat-or-channel) for more info.| +|peer|[long](/API_docs/types/long.html) | Yes|The peer where the wallpaper has changed.| +|wallpaper|[WallPaper](/API_docs/types/WallPaper.html) | Optional|The new wallpaper, if none the wallpaper was removed and the default wallpaper should be used.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePeerWallpaper = ['_' => 'updatePeerWallpaper', 'wallpaper_overridden' => Bool, 'peer' => long, 'wallpaper' => WallPaper]; +``` diff --git a/docs/API_docs/constructors/updatePendingJoinRequests.md b/docs/API_docs/constructors/updatePendingJoinRequests.md new file mode 100644 index 0000000000..ba29406ff7 --- /dev/null +++ b/docs/API_docs/constructors/updatePendingJoinRequests.md @@ -0,0 +1,31 @@ +--- +title: "updatePendingJoinRequests" +description: "Someone has requested to join a chat or channel" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePendingJoinRequests +[Back to constructors index](/API_docs/constructors/index.html) + + + +Someone has requested to join a chat or channel + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Chat or channel| +|requests\_pending|[int](/API_docs/types/int.html) | Yes|Number of pending [join requests »](https://core.telegram.org/api/invites#join-requests) for the chat or channel| +|recent\_requesters|Array of [long](/API_docs/types/long.html) | Yes|IDs of users that have recently requested to join| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePendingJoinRequests = ['_' => 'updatePendingJoinRequests', 'peer' => long, 'requests_pending' => int, 'recent_requesters' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/updatePhoneCall.md b/docs/API_docs/constructors/updatePhoneCall.md new file mode 100644 index 0000000000..e1ec72ce82 --- /dev/null +++ b/docs/API_docs/constructors/updatePhoneCall.md @@ -0,0 +1,29 @@ +--- +title: "updatePhoneCall" +description: "An incoming phone call" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePhoneCall +[Back to constructors index](/API_docs/constructors/index.html) + + + +An incoming phone call + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_call|[PhoneCall](/API_docs/types/PhoneCall.html) | Optional|Phone call| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePhoneCall = ['_' => 'updatePhoneCall', 'phone_call' => PhoneCall]; +``` diff --git a/docs/API_docs/constructors/updatePhoneCallSignalingData.md b/docs/API_docs/constructors/updatePhoneCallSignalingData.md new file mode 100644 index 0000000000..00d42475b2 --- /dev/null +++ b/docs/API_docs/constructors/updatePhoneCallSignalingData.md @@ -0,0 +1,30 @@ +--- +title: "updatePhoneCallSignalingData" +description: "Incoming phone call signaling payload" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePhoneCallSignalingData +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incoming phone call signaling payload + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|phone\_call\_id|[long](/API_docs/types/long.html) | Yes|Phone call ID| +|data|[bytes](/API_docs/types/bytes.html) | Yes|Signaling payload| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePhoneCallSignalingData = ['_' => 'updatePhoneCallSignalingData', 'phone_call_id' => long, 'data' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/updatePinnedChannelMessages.md b/docs/API_docs/constructors/updatePinnedChannelMessages.md new file mode 100644 index 0000000000..9586a8a575 --- /dev/null +++ b/docs/API_docs/constructors/updatePinnedChannelMessages.md @@ -0,0 +1,33 @@ +--- +title: "updatePinnedChannelMessages" +description: "Messages were pinned/unpinned in a channel/supergroup" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePinnedChannelMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Messages were pinned/unpinned in a [channel/supergroup](https://core.telegram.org/api/channel) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether the messages were pinned or unpinned| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel ID| +|messages|Array of [int](/API_docs/types/int.html) | Yes|Messages| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePinnedChannelMessages = ['_' => 'updatePinnedChannelMessages', 'pinned' => Bool, 'channel_id' => long, 'messages' => [int, int], 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updatePinnedDialogs.md b/docs/API_docs/constructors/updatePinnedDialogs.md new file mode 100644 index 0000000000..651a64a76b --- /dev/null +++ b/docs/API_docs/constructors/updatePinnedDialogs.md @@ -0,0 +1,30 @@ +--- +title: "updatePinnedDialogs" +description: "Pinned dialogs were updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePinnedDialogs +[Back to constructors index](/API_docs/constructors/index.html) + + + +Pinned dialogs were updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|order|Array of [DialogPeer](/API_docs/types/DialogPeer.html) | Optional|New order of pinned dialogs| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePinnedDialogs = ['_' => 'updatePinnedDialogs', 'folder_id' => int, 'order' => [DialogPeer, DialogPeer]]; +``` diff --git a/docs/API_docs/constructors/updatePinnedMessages.md b/docs/API_docs/constructors/updatePinnedMessages.md new file mode 100644 index 0000000000..0ab2c893c9 --- /dev/null +++ b/docs/API_docs/constructors/updatePinnedMessages.md @@ -0,0 +1,33 @@ +--- +title: "updatePinnedMessages" +description: "Some messages were pinned in a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePinnedMessages +[Back to constructors index](/API_docs/constructors/index.html) + + + +Some messages were pinned in a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether the messages were pinned or unpinned| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|messages|Array of [int](/API_docs/types/int.html) | Yes|Message IDs| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePinnedMessages = ['_' => 'updatePinnedMessages', 'pinned' => Bool, 'peer' => long, 'messages' => [int, int], 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updatePinnedSavedDialogs.md b/docs/API_docs/constructors/updatePinnedSavedDialogs.md new file mode 100644 index 0000000000..183ae7dcc8 --- /dev/null +++ b/docs/API_docs/constructors/updatePinnedSavedDialogs.md @@ -0,0 +1,29 @@ +--- +title: "updatePinnedSavedDialogs" +description: "Pinned saved dialogs » were updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePinnedSavedDialogs +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Pinned saved dialogs »](https://core.telegram.org/api/saved-messages) were updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|order|Array of [DialogPeer](/API_docs/types/DialogPeer.html) | Optional|New order of pinned saved dialogs| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePinnedSavedDialogs = ['_' => 'updatePinnedSavedDialogs', 'order' => [DialogPeer, DialogPeer]]; +``` diff --git a/docs/API_docs/constructors/updatePrivacy.md b/docs/API_docs/constructors/updatePrivacy.md new file mode 100644 index 0000000000..59a420a2e5 --- /dev/null +++ b/docs/API_docs/constructors/updatePrivacy.md @@ -0,0 +1,30 @@ +--- +title: "updatePrivacy" +description: "Privacy rules were changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePrivacy +[Back to constructors index](/API_docs/constructors/index.html) + + + +Privacy rules were changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|key|[PrivacyKey](/API_docs/types/PrivacyKey.html) | Yes|Peers to which the privacy rules apply| +|rules|Array of [PrivacyRule](/API_docs/types/PrivacyRule.html) | Yes|New privacy rules| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePrivacy = ['_' => 'updatePrivacy', 'key' => PrivacyKey, 'rules' => [PrivacyRule, PrivacyRule]]; +``` diff --git a/docs/API_docs/constructors/updatePtsChanged.md b/docs/API_docs/constructors/updatePtsChanged.md new file mode 100644 index 0000000000..b790cdbf1d --- /dev/null +++ b/docs/API_docs/constructors/updatePtsChanged.md @@ -0,0 +1,24 @@ +--- +title: "updatePtsChanged" +description: "Common message box sequence PTS has changed, state has to be refetched using updates.getState" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatePtsChanged +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Common message box sequence PTS](https://core.telegram.org/api/updates) has changed, [state has to be refetched using updates.getState](https://core.telegram.org/api/updates#fetching-state) + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updatePtsChanged = ['_' => 'updatePtsChanged']; +``` diff --git a/docs/API_docs/constructors/updateQuickReplies.md b/docs/API_docs/constructors/updateQuickReplies.md new file mode 100644 index 0000000000..4beeadc9ce --- /dev/null +++ b/docs/API_docs/constructors/updateQuickReplies.md @@ -0,0 +1,27 @@ +--- +title: "updateQuickReplies" +description: "updateQuickReplies attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateQuickReplies +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|quick\_replies|Array of [QuickReply](/API_docs/types/QuickReply.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateQuickReplies = ['_' => 'updateQuickReplies', 'quick_replies' => [QuickReply, QuickReply]]; +``` diff --git a/docs/API_docs/constructors/updateQuickReplyMessage.md b/docs/API_docs/constructors/updateQuickReplyMessage.md new file mode 100644 index 0000000000..28f7fe70ad --- /dev/null +++ b/docs/API_docs/constructors/updateQuickReplyMessage.md @@ -0,0 +1,27 @@ +--- +title: "updateQuickReplyMessage" +description: "updateQuickReplyMessage attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateQuickReplyMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|message|[Message](/API_docs/types/Message.html) | Optional| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateQuickReplyMessage = ['_' => 'updateQuickReplyMessage', 'message' => Message]; +``` diff --git a/docs/API_docs/constructors/updateReadChannelDiscussionInbox.md b/docs/API_docs/constructors/updateReadChannelDiscussionInbox.md new file mode 100644 index 0000000000..d38561e021 --- /dev/null +++ b/docs/API_docs/constructors/updateReadChannelDiscussionInbox.md @@ -0,0 +1,33 @@ +--- +title: "updateReadChannelDiscussionInbox" +description: "Incoming comments in a discussion thread were marked as read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadChannelDiscussionInbox +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incoming comments in a [discussion thread](https://core.telegram.org/api/threads) were marked as read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|[Discussion group ID](https://core.telegram.org/api/channel)| +|top\_msg\_id|[int](/API_docs/types/int.html) | Yes|ID of the group message that started the [thread](https://core.telegram.org/api/threads) (message in linked discussion group)| +|read\_max\_id|[int](/API_docs/types/int.html) | Yes|Message ID of latest read incoming message for this [thread](https://core.telegram.org/api/threads)| +|broadcast\_id|[long](/API_docs/types/long.html) | Optional|If set, contains the ID of the [channel](https://core.telegram.org/api/channel) that contains the post that started the [comment thread](https://core.telegram.org/api/threads) in the discussion group (`channel_id`)| +|broadcast\_post|[int](/API_docs/types/int.html) | Optional|If set, contains the ID of the channel post that started the [comment thread](https://core.telegram.org/api/threads)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadChannelDiscussionInbox = ['_' => 'updateReadChannelDiscussionInbox', 'channel_id' => long, 'top_msg_id' => int, 'read_max_id' => int, 'broadcast_id' => long, 'broadcast_post' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadChannelDiscussionOutbox.md b/docs/API_docs/constructors/updateReadChannelDiscussionOutbox.md new file mode 100644 index 0000000000..2ac19f9005 --- /dev/null +++ b/docs/API_docs/constructors/updateReadChannelDiscussionOutbox.md @@ -0,0 +1,31 @@ +--- +title: "updateReadChannelDiscussionOutbox" +description: "Outgoing comments in a discussion thread were marked as read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadChannelDiscussionOutbox +[Back to constructors index](/API_docs/constructors/index.html) + + + +Outgoing comments in a [discussion thread](https://core.telegram.org/api/threads) were marked as read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|[Supergroup ID](https://core.telegram.org/api/channel)| +|top\_msg\_id|[int](/API_docs/types/int.html) | Yes|ID of the group message that started the [thread](https://core.telegram.org/api/threads)| +|read\_max\_id|[int](/API_docs/types/int.html) | Yes|Message ID of latest read outgoing message for this [thread](https://core.telegram.org/api/threads)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadChannelDiscussionOutbox = ['_' => 'updateReadChannelDiscussionOutbox', 'channel_id' => long, 'top_msg_id' => int, 'read_max_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadChannelInbox.md b/docs/API_docs/constructors/updateReadChannelInbox.md new file mode 100644 index 0000000000..50ce479924 --- /dev/null +++ b/docs/API_docs/constructors/updateReadChannelInbox.md @@ -0,0 +1,33 @@ +--- +title: "updateReadChannelInbox" +description: "Incoming messages in a channel/supergroup were read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadChannelInbox +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incoming messages in a [channel/supergroup](https://core.telegram.org/api/channel) were read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel/supergroup ID| +|max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all incoming messages are read.| +|still\_unread\_count|[int](/API_docs/types/int.html) | Yes|Count of messages weren't read yet| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadChannelInbox = ['_' => 'updateReadChannelInbox', 'folder_id' => int, 'channel_id' => long, 'max_id' => int, 'still_unread_count' => int, 'pts' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadChannelOutbox.md b/docs/API_docs/constructors/updateReadChannelOutbox.md new file mode 100644 index 0000000000..e19111a1ca --- /dev/null +++ b/docs/API_docs/constructors/updateReadChannelOutbox.md @@ -0,0 +1,30 @@ +--- +title: "updateReadChannelOutbox" +description: "Outgoing messages in a channel/supergroup were read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadChannelOutbox +[Back to constructors index](/API_docs/constructors/index.html) + + + +Outgoing messages in a [channel/supergroup](https://core.telegram.org/api/channel) were read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|channel\_id|[long](/API_docs/types/long.html) | Yes|Channel/supergroup ID| +|max\_id|[int](/API_docs/types/int.html) | Yes|Position up to which all outgoing messages are read.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadChannelOutbox = ['_' => 'updateReadChannelOutbox', 'channel_id' => long, 'max_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadFeaturedEmojiStickers.md b/docs/API_docs/constructors/updateReadFeaturedEmojiStickers.md new file mode 100644 index 0000000000..09195be318 --- /dev/null +++ b/docs/API_docs/constructors/updateReadFeaturedEmojiStickers.md @@ -0,0 +1,24 @@ +--- +title: "updateReadFeaturedEmojiStickers" +description: "Some featured custom emoji stickers were marked as read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadFeaturedEmojiStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Some featured [custom emoji stickers](https://core.telegram.org/api/custom-emoji) were marked as read + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadFeaturedEmojiStickers = ['_' => 'updateReadFeaturedEmojiStickers']; +``` diff --git a/docs/API_docs/constructors/updateReadFeaturedStickers.md b/docs/API_docs/constructors/updateReadFeaturedStickers.md new file mode 100644 index 0000000000..488090423a --- /dev/null +++ b/docs/API_docs/constructors/updateReadFeaturedStickers.md @@ -0,0 +1,24 @@ +--- +title: "updateReadFeaturedStickers" +description: "Some featured stickers were marked as read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadFeaturedStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +Some featured stickers were marked as read + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadFeaturedStickers = ['_' => 'updateReadFeaturedStickers']; +``` diff --git a/docs/API_docs/constructors/updateReadHistoryInbox.md b/docs/API_docs/constructors/updateReadHistoryInbox.md new file mode 100644 index 0000000000..3c13cd3f02 --- /dev/null +++ b/docs/API_docs/constructors/updateReadHistoryInbox.md @@ -0,0 +1,34 @@ +--- +title: "updateReadHistoryInbox" +description: "Incoming messages were read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadHistoryInbox +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incoming messages were read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|max\_id|[int](/API_docs/types/int.html) | Yes|Maximum ID of messages read| +|still\_unread\_count|[int](/API_docs/types/int.html) | Yes|Number of messages that are still unread| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadHistoryInbox = ['_' => 'updateReadHistoryInbox', 'folder_id' => int, 'peer' => long, 'max_id' => int, 'still_unread_count' => int, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadHistoryOutbox.md b/docs/API_docs/constructors/updateReadHistoryOutbox.md new file mode 100644 index 0000000000..5b25d25292 --- /dev/null +++ b/docs/API_docs/constructors/updateReadHistoryOutbox.md @@ -0,0 +1,32 @@ +--- +title: "updateReadHistoryOutbox" +description: "Outgoing messages were read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadHistoryOutbox +[Back to constructors index](/API_docs/constructors/index.html) + + + +Outgoing messages were read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer| +|max\_id|[int](/API_docs/types/int.html) | Yes|Maximum ID of read outgoing messages| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadHistoryOutbox = ['_' => 'updateReadHistoryOutbox', 'peer' => long, 'max_id' => int, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadMessagesContents.md b/docs/API_docs/constructors/updateReadMessagesContents.md new file mode 100644 index 0000000000..c7a43d91e3 --- /dev/null +++ b/docs/API_docs/constructors/updateReadMessagesContents.md @@ -0,0 +1,32 @@ +--- +title: "updateReadMessagesContents" +description: "Contents of messages in the common message box were read" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadMessagesContents +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contents of messages in the common [message box](https://core.telegram.org/api/updates) were read + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|messages|Array of [int](/API_docs/types/int.html) | Yes|IDs of read messages| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| +|date|[int](/API_docs/types/int.html) | Optional|When was the last message in `messages` marked as read.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadMessagesContents = ['_' => 'updateReadMessagesContents', 'messages' => [int, int], 'pts' => int, 'pts_count' => int, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/updateReadStories.md b/docs/API_docs/constructors/updateReadStories.md new file mode 100644 index 0000000000..f1d1f1fbbd --- /dev/null +++ b/docs/API_docs/constructors/updateReadStories.md @@ -0,0 +1,30 @@ +--- +title: "updateReadStories" +description: "Stories of a specific peer were marked as read." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateReadStories +[Back to constructors index](/API_docs/constructors/index.html) + + + +Stories of a specific peer were marked as read. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer| +|max\_id|[int](/API_docs/types/int.html) | Yes|ID of the last story that was marked as read| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateReadStories = ['_' => 'updateReadStories', 'peer' => long, 'max_id' => int]; +``` diff --git a/docs/API_docs/constructors/updateRecentEmojiStatuses.md b/docs/API_docs/constructors/updateRecentEmojiStatuses.md new file mode 100644 index 0000000000..68e0cbf797 --- /dev/null +++ b/docs/API_docs/constructors/updateRecentEmojiStatuses.md @@ -0,0 +1,24 @@ +--- +title: "updateRecentEmojiStatuses" +description: "The list of recent emoji statuses has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateRecentEmojiStatuses +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of recent [emoji statuses](https://core.telegram.org/api/emoji-status) has changed + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateRecentEmojiStatuses = ['_' => 'updateRecentEmojiStatuses']; +``` diff --git a/docs/API_docs/constructors/updateRecentReactions.md b/docs/API_docs/constructors/updateRecentReactions.md new file mode 100644 index 0000000000..7d4f374b76 --- /dev/null +++ b/docs/API_docs/constructors/updateRecentReactions.md @@ -0,0 +1,24 @@ +--- +title: "updateRecentReactions" +description: "The list of recent message reactions has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateRecentReactions +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of recent [message reactions](https://core.telegram.org/api/reactions) has changed + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateRecentReactions = ['_' => 'updateRecentReactions']; +``` diff --git a/docs/API_docs/constructors/updateRecentStickers.md b/docs/API_docs/constructors/updateRecentStickers.md new file mode 100644 index 0000000000..4f46c91e42 --- /dev/null +++ b/docs/API_docs/constructors/updateRecentStickers.md @@ -0,0 +1,24 @@ +--- +title: "updateRecentStickers" +description: "The recent sticker list was updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateRecentStickers +[Back to constructors index](/API_docs/constructors/index.html) + + + +The recent sticker list was updated + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateRecentStickers = ['_' => 'updateRecentStickers']; +``` diff --git a/docs/API_docs/constructors/updateSavedDialogPinned.md b/docs/API_docs/constructors/updateSavedDialogPinned.md new file mode 100644 index 0000000000..f47cf99ff3 --- /dev/null +++ b/docs/API_docs/constructors/updateSavedDialogPinned.md @@ -0,0 +1,30 @@ +--- +title: "updateSavedDialogPinned" +description: "A saved message dialog was pinned/unpinned" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateSavedDialogPinned +[Back to constructors index](/API_docs/constructors/index.html) + + + +A [saved message dialog](https://core.telegram.org/api/saved-messages) was pinned/unpinned + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pinned|[Bool](/API_docs/types/Bool.html) | Optional|Whether the dialog was pinned| +|peer|[DialogPeer](/API_docs/types/DialogPeer.html) | Yes|The dialog| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateSavedDialogPinned = ['_' => 'updateSavedDialogPinned', 'pinned' => Bool, 'peer' => DialogPeer]; +``` diff --git a/docs/API_docs/constructors/updateSavedGifs.md b/docs/API_docs/constructors/updateSavedGifs.md new file mode 100644 index 0000000000..67901c59be --- /dev/null +++ b/docs/API_docs/constructors/updateSavedGifs.md @@ -0,0 +1,24 @@ +--- +title: "updateSavedGifs" +description: "The saved gif list has changed, the client should refetch it using messages.getSavedGifs" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateSavedGifs +[Back to constructors index](/API_docs/constructors/index.html) + + + +The saved gif list has changed, the client should refetch it using [messages.getSavedGifs](https://core.telegram.org/method/messages.getSavedGifs) + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateSavedGifs = ['_' => 'updateSavedGifs']; +``` diff --git a/docs/API_docs/constructors/updateSavedReactionTags.md b/docs/API_docs/constructors/updateSavedReactionTags.md new file mode 100644 index 0000000000..b6d54b0a40 --- /dev/null +++ b/docs/API_docs/constructors/updateSavedReactionTags.md @@ -0,0 +1,22 @@ +--- +title: "updateSavedReactionTags" +description: "updateSavedReactionTags attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateSavedReactionTags +[Back to constructors index](/API_docs/constructors/index.html) + + + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateSavedReactionTags = ['_' => 'updateSavedReactionTags']; +``` diff --git a/docs/API_docs/constructors/updateSavedRingtones.md b/docs/API_docs/constructors/updateSavedRingtones.md new file mode 100644 index 0000000000..300dc88605 --- /dev/null +++ b/docs/API_docs/constructors/updateSavedRingtones.md @@ -0,0 +1,24 @@ +--- +title: "updateSavedRingtones" +description: "The list of saved notification sounds has changed, use account.getSavedRingtones to fetch the new list." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateSavedRingtones +[Back to constructors index](/API_docs/constructors/index.html) + + + +The list of saved notification sounds has changed, use [account.getSavedRingtones](../methods/account.getSavedRingtones.html) to fetch the new list. + + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateSavedRingtones = ['_' => 'updateSavedRingtones']; +``` diff --git a/docs/API_docs/constructors/updateSentStoryReaction.md b/docs/API_docs/constructors/updateSentStoryReaction.md new file mode 100644 index 0000000000..cd761e6fe8 --- /dev/null +++ b/docs/API_docs/constructors/updateSentStoryReaction.md @@ -0,0 +1,31 @@ +--- +title: "updateSentStoryReaction" +description: "Indicates we reacted to a story »." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateSentStoryReaction +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates we [reacted to a story »](https://core.telegram.org/api/stories#reactions). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|The peer that sent the story| +|story\_id|[int](/API_docs/types/int.html) | Yes|ID of the story we reacted to| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional|The reaction that was sent| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateSentStoryReaction = ['_' => 'updateSentStoryReaction', 'peer' => long, 'story_id' => int, 'reaction' => Reaction]; +``` diff --git a/docs/API_docs/constructors/updateServiceNotification.md b/docs/API_docs/constructors/updateServiceNotification.md new file mode 100644 index 0000000000..9a9b8b1b5a --- /dev/null +++ b/docs/API_docs/constructors/updateServiceNotification.md @@ -0,0 +1,98 @@ +--- +title: "updateServiceNotification" +description: "A service message for the user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateServiceNotification +[Back to constructors index](/API_docs/constructors/index.html) + + + +A service message for the user. + +The app must show the message to the user upon receiving this update. In case the **popup** parameter was passed, the text message must be displayed in a popup alert immediately upon receipt. It is recommended to handle the text as you would an ordinary message in terms of highlighting links, etc. The message must also be stored locally as part of the message history with the user id `777000` (Telegram Notifications). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|popup|[Bool](/API_docs/types/Bool.html) | Optional|If set, the message must be displayed in a popup.| +|invert\_media|[Bool](/API_docs/types/Bool.html) | Optional|If set, any eventual webpage preview will be shown on top of the message instead of at the bottom.| +|inbox\_date|[int](/API_docs/types/int.html) | Optional|When was the notification received
The message must also be stored locally as part of the message history with the user id `777000` (Telegram Notifications).| +|type|[string](/API_docs/types/string.html) | Yes|String, identical in format and contents to the [**type**](https://core.telegram.org/api/errors#error-type) field in API errors. Describes type of service message. It is acceptable to ignore repeated messages of the same **type** within a short period of time (15 minutes).| +|message|[string](/API_docs/types/string.html) | Yes|Message text| +|media|[MessageMedia](/API_docs/types/MessageMedia.html) | Optional|Media content (optional)| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Yes|[Message entities for styled text](https://core.telegram.org/api/entities)| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + + +### Type: [Update](/API_docs/types/Update.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$updateServiceNotification = ['_' => 'updateServiceNotification', 'popup' => Bool, 'invert_media' => Bool, 'inbox_date' => int, 'type' => 'string', 'message' => 'string', 'media' => MessageMedia, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', ]; +``` diff --git a/docs/API_docs/constructors/updateShort.md b/docs/API_docs/constructors/updateShort.md new file mode 100644 index 0000000000..a8efd70f97 --- /dev/null +++ b/docs/API_docs/constructors/updateShort.md @@ -0,0 +1,30 @@ +--- +title: "updateShort" +description: "Shortened constructor containing info on one update not requiring auxiliary data" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateShort +[Back to constructors index](/API_docs/constructors/index.html) + + + +Shortened constructor containing info on one update not requiring auxiliary data + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|update|[Update](/API_docs/types/Update.html) | Yes|Update| +|date|[int](/API_docs/types/int.html) | Yes|Date of event| + + + +### Type: [Updates](/API_docs/types/Updates.html) + + +### Example: + +``` +$updateShort = ['_' => 'updateShort', 'update' => Update, 'date' => int]; +``` diff --git a/docs/API_docs/constructors/updateShortChatMessage.md b/docs/API_docs/constructors/updateShortChatMessage.md new file mode 100644 index 0000000000..3bcd157303 --- /dev/null +++ b/docs/API_docs/constructors/updateShortChatMessage.md @@ -0,0 +1,105 @@ +--- +title: "updateShortChatMessage" +description: "Shortened constructor containing info on one new incoming text message from a chat" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateShortChatMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Shortened constructor containing info on one new incoming text message from a chat + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|out|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message is outgoing| +|mentioned|[Bool](/API_docs/types/Bool.html) | Optional|Whether we were mentioned in this message| +|media\_unread|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message contains some **unread** mentions| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|If true, the message is a silent message, no notifications should be triggered| +|id|[int](/API_docs/types/int.html) | Yes|ID of the message| +|from\_id|[long](/API_docs/types/long.html) | Yes|ID of the sender of the message| +|chat\_id|[long](/API_docs/types/long.html) | Yes|ID of the chat where the message was sent| +|message|[string](/API_docs/types/string.html) | Yes|Message| +|pts|[int](/API_docs/types/int.html) | Yes|[PTS](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[PTS count](https://core.telegram.org/api/updates)| +|date|[int](/API_docs/types/int.html) | Yes|[date](https://core.telegram.org/api/updates)| +|fwd\_from|[MessageFwdHeader](/API_docs/types/MessageFwdHeader.html) | Optional|Info about a forwarded message| +|via\_bot\_id|[long](/API_docs/types/long.html) | Optional|Info about the inline bot used to generate this message| +|reply\_to|[MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) | Optional|Reply (thread) information| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Entities](https://core.telegram.org/api/entities) for styled text| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time To Live of the message, once updateShortChatMessage.date+updateShortChatMessage.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well.| + + + +### Type: [Updates](/API_docs/types/Updates.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$updateShortChatMessage = ['_' => 'updateShortChatMessage', 'out' => Bool, 'mentioned' => Bool, 'media_unread' => Bool, 'silent' => Bool, 'id' => int, 'from_id' => long, 'chat_id' => long, 'message' => 'string', 'pts' => int, 'pts_count' => int, 'date' => int, 'fwd_from' => MessageFwdHeader, 'via_bot_id' => long, 'reply_to' => MessageReplyHeader, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'ttl_period' => int]; +``` diff --git a/docs/API_docs/constructors/updateShortMessage.md b/docs/API_docs/constructors/updateShortMessage.md new file mode 100644 index 0000000000..4883f26903 --- /dev/null +++ b/docs/API_docs/constructors/updateShortMessage.md @@ -0,0 +1,104 @@ +--- +title: "updateShortMessage" +description: "Info about a message sent to (received from) another user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateShortMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a message sent to (received from) another user + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|out|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message is outgoing| +|mentioned|[Bool](/API_docs/types/Bool.html) | Optional|Whether we were mentioned in the message| +|media\_unread|[Bool](/API_docs/types/Bool.html) | Optional|Whether there are some **unread** mentions in this message| +|silent|[Bool](/API_docs/types/Bool.html) | Optional|If true, the message is a silent message, no notifications should be triggered| +|id|[int](/API_docs/types/int.html) | Yes|The message ID| +|user\_id|[long](/API_docs/types/long.html) | Yes|The ID of the sender (if `outgoing` will be the ID of the destination) of the message| +|message|[string](/API_docs/types/string.html) | Yes|The message| +|pts|[int](/API_docs/types/int.html) | Yes|[PTS](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[PTS count](https://core.telegram.org/api/updates)| +|date|[int](/API_docs/types/int.html) | Yes|[date](https://core.telegram.org/api/updates)| +|fwd\_from|[MessageFwdHeader](/API_docs/types/MessageFwdHeader.html) | Optional|Info about a forwarded message| +|via\_bot\_id|[long](/API_docs/types/long.html) | Optional|Info about the inline bot used to generate this message| +|reply\_to|[MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) | Optional|Reply and [thread](https://core.telegram.org/api/threads) information| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Entities](https://core.telegram.org/api/entities) for styled text| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time To Live of the message, once message.date+message.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well.| + + + +### Type: [Updates](/API_docs/types/Updates.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$updateShortMessage = ['_' => 'updateShortMessage', 'out' => Bool, 'mentioned' => Bool, 'media_unread' => Bool, 'silent' => Bool, 'id' => int, 'user_id' => long, 'message' => 'string', 'pts' => int, 'pts_count' => int, 'date' => int, 'fwd_from' => MessageFwdHeader, 'via_bot_id' => long, 'reply_to' => MessageReplyHeader, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'ttl_period' => int]; +``` diff --git a/docs/API_docs/constructors/updateShortSentMessage.md b/docs/API_docs/constructors/updateShortSentMessage.md new file mode 100644 index 0000000000..ba61a35995 --- /dev/null +++ b/docs/API_docs/constructors/updateShortSentMessage.md @@ -0,0 +1,97 @@ +--- +title: "updateShortSentMessage" +description: "Shortened constructor containing info on one outgoing message to a contact (the destination chat has to be extracted from the method call that returned this object)." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateShortSentMessage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Shortened constructor containing info on one outgoing message to a contact (the destination chat has to be extracted from the method call that returned this object). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|out|[Bool](/API_docs/types/Bool.html) | Optional|Whether the message is outgoing| +|id|[int](/API_docs/types/int.html) | Yes|ID of the sent message| +|pts|[int](/API_docs/types/int.html) | Yes|[PTS](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[PTS count](https://core.telegram.org/api/updates)| +|date|[int](/API_docs/types/int.html) | Yes|[date](https://core.telegram.org/api/updates)| +|media|[MessageMedia](/API_docs/types/MessageMedia.html) | Optional|Attached media| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Optional|[Entities](https://core.telegram.org/api/entities) for styled text| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time To Live of the message, once message.date+message.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well.| + + + +### Type: [Updates](/API_docs/types/Updates.html) + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + +### Example: + +``` +$updateShortSentMessage = ['_' => 'updateShortSentMessage', 'out' => Bool, 'id' => int, 'pts' => int, 'pts_count' => int, 'date' => int, 'media' => MessageMedia, 'entities' => [MessageEntity, MessageEntity]parse_mode: 'string', , 'ttl_period' => int]; +``` diff --git a/docs/API_docs/constructors/updateSmsJob.md b/docs/API_docs/constructors/updateSmsJob.md new file mode 100644 index 0000000000..381bd6dbde --- /dev/null +++ b/docs/API_docs/constructors/updateSmsJob.md @@ -0,0 +1,27 @@ +--- +title: "updateSmsJob" +description: "updateSmsJob attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateSmsJob +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|job\_id|[string](/API_docs/types/string.html) | Yes| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateSmsJob = ['_' => 'updateSmsJob', 'job_id' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateStickerSets.md b/docs/API_docs/constructors/updateStickerSets.md new file mode 100644 index 0000000000..290af8486e --- /dev/null +++ b/docs/API_docs/constructors/updateStickerSets.md @@ -0,0 +1,30 @@ +--- +title: "updateStickerSets" +description: "Installed stickersets have changed, the client should refetch them as described in the docs." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateStickerSets +[Back to constructors index](/API_docs/constructors/index.html) + + + +Installed stickersets have changed, the client should refetch them as [described in the docs](https://core.telegram.org/api/stickers#installing-stickersets). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|masks|[Bool](/API_docs/types/Bool.html) | Optional|Whether mask stickersets have changed| +|emojis|[Bool](/API_docs/types/Bool.html) | Optional|Whether the list of installed [custom emoji stickersets](https://core.telegram.org/api/custom-emoji) has changed| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateStickerSets = ['_' => 'updateStickerSets', 'masks' => Bool, 'emojis' => Bool]; +``` diff --git a/docs/API_docs/constructors/updateStickerSetsOrder.md b/docs/API_docs/constructors/updateStickerSetsOrder.md new file mode 100644 index 0000000000..dfed1f5b64 --- /dev/null +++ b/docs/API_docs/constructors/updateStickerSetsOrder.md @@ -0,0 +1,31 @@ +--- +title: "updateStickerSetsOrder" +description: "The order of stickersets was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateStickerSetsOrder +[Back to constructors index](/API_docs/constructors/index.html) + + + +The order of stickersets was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|masks|[Bool](/API_docs/types/Bool.html) | Optional|Whether the updated stickers are mask stickers| +|emojis|[Bool](/API_docs/types/Bool.html) | Optional|Whether the updated stickers are custom emoji stickers| +|order|Array of [long](/API_docs/types/long.html) | Yes|New sticker order by sticker ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateStickerSetsOrder = ['_' => 'updateStickerSetsOrder', 'masks' => Bool, 'emojis' => Bool, 'order' => [long, long]]; +``` diff --git a/docs/API_docs/constructors/updateStoriesStealthMode.md b/docs/API_docs/constructors/updateStoriesStealthMode.md new file mode 100644 index 0000000000..55de54e6ef --- /dev/null +++ b/docs/API_docs/constructors/updateStoriesStealthMode.md @@ -0,0 +1,29 @@ +--- +title: "updateStoriesStealthMode" +description: "Indicates that stories stealth mode was activated." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateStoriesStealthMode +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates that [stories stealth mode](https://core.telegram.org/api/stories#stealth-mode) was activated. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|stealth\_mode|[StoriesStealthMode](/API_docs/types/StoriesStealthMode.html) | Yes|Information about the current [stealth mode](https://core.telegram.org/api/stories#stealth-mode) session.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateStoriesStealthMode = ['_' => 'updateStoriesStealthMode', 'stealth_mode' => StoriesStealthMode]; +``` diff --git a/docs/API_docs/constructors/updateStory.md b/docs/API_docs/constructors/updateStory.md new file mode 100644 index 0000000000..fda66a4e46 --- /dev/null +++ b/docs/API_docs/constructors/updateStory.md @@ -0,0 +1,30 @@ +--- +title: "updateStory" +description: "A new story was posted." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +A new story was posted. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|ID of the poster.| +|story|[StoryItem](/API_docs/types/StoryItem.html) | Yes|The story that was posted.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateStory = ['_' => 'updateStory', 'peer' => long, 'story' => StoryItem]; +``` diff --git a/docs/API_docs/constructors/updateStoryID.md b/docs/API_docs/constructors/updateStoryID.md new file mode 100644 index 0000000000..c66d88c7bc --- /dev/null +++ b/docs/API_docs/constructors/updateStoryID.md @@ -0,0 +1,31 @@ +--- +title: "updateStoryID" +description: "A story was successfully uploaded." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateStoryID +[Back to constructors index](/API_docs/constructors/index.html) + + + +A story was successfully uploaded. + +Once a story is successfully uploaded, an [updateStoryID](../constructors/updateStoryID.html) will be returned, indicating the story ID (`id`) that was attributed to the story (like for messages, `random_id` indicates the `random_id` that was passed to [stories.sendStory](../methods/stories.sendStory.html): this way, you can tell which story was assigned a specific `id` by checking which [stories.sendStory](../methods/stories.sendStory.html) call has the returned `random_id`). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[int](/API_docs/types/int.html) | Yes|The `id` that was attributed to the story.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateStoryID = ['_' => 'updateStoryID', 'id' => int]; +``` diff --git a/docs/API_docs/constructors/updateTheme.md b/docs/API_docs/constructors/updateTheme.md new file mode 100644 index 0000000000..c5b0bda51a --- /dev/null +++ b/docs/API_docs/constructors/updateTheme.md @@ -0,0 +1,29 @@ +--- +title: "updateTheme" +description: "A cloud theme was updated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateTheme +[Back to constructors index](/API_docs/constructors/index.html) + + + +A cloud theme was updated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|theme|[Theme](/API_docs/types/Theme.html) | Yes|Theme| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateTheme = ['_' => 'updateTheme', 'theme' => Theme]; +``` diff --git a/docs/API_docs/constructors/updateTranscribedAudio.md b/docs/API_docs/constructors/updateTranscribedAudio.md new file mode 100644 index 0000000000..420df5c503 --- /dev/null +++ b/docs/API_docs/constructors/updateTranscribedAudio.md @@ -0,0 +1,33 @@ +--- +title: "updateTranscribedAudio" +description: "A pending voice message transcription » initiated with messages.transcribeAudio was updated." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateTranscribedAudio +[Back to constructors index](/API_docs/constructors/index.html) + + + +A pending [voice message transcription »](https://core.telegram.org/api/transcribe) initiated with [messages.transcribeAudio](../methods/messages.transcribeAudio.html) was updated. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pending|[Bool](/API_docs/types/Bool.html) | Optional|Whether this transcription is still pending and further [updateTranscribedAudio](../constructors/updateTranscribedAudio.html) about it will be sent in the future.| +|peer|[long](/API_docs/types/long.html) | Yes|Peer of the transcribed message| +|msg\_id|[int](/API_docs/types/int.html) | Yes|Transcribed message ID| +|transcription\_id|[long](/API_docs/types/long.html) | Yes|Transcription ID| +|text|[string](/API_docs/types/string.html) | Yes|Transcribed text| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateTranscribedAudio = ['_' => 'updateTranscribedAudio', 'pending' => Bool, 'peer' => long, 'msg_id' => int, 'transcription_id' => long, 'text' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateUser.md b/docs/API_docs/constructors/updateUser.md new file mode 100644 index 0000000000..687f3d834e --- /dev/null +++ b/docs/API_docs/constructors/updateUser.md @@ -0,0 +1,29 @@ +--- +title: "updateUser" +description: "User information was updated, it must be refetched using users.getFullUser." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateUser +[Back to constructors index](/API_docs/constructors/index.html) + + + +User information was updated, it must be refetched using [users.getFullUser](../methods/users.getFullUser.html). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateUser = ['_' => 'updateUser', 'user_id' => long]; +``` diff --git a/docs/API_docs/constructors/updateUserEmojiStatus.md b/docs/API_docs/constructors/updateUserEmojiStatus.md new file mode 100644 index 0000000000..8dc22243e5 --- /dev/null +++ b/docs/API_docs/constructors/updateUserEmojiStatus.md @@ -0,0 +1,30 @@ +--- +title: "updateUserEmojiStatus" +description: "The emoji status of a certain user has changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateUserEmojiStatus +[Back to constructors index](/API_docs/constructors/index.html) + + + +The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|emoji\_status|[EmojiStatus](/API_docs/types/EmojiStatus.html) | Optional|New [emoji status](https://core.telegram.org/api/emoji-status)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateUserEmojiStatus = ['_' => 'updateUserEmojiStatus', 'user_id' => long, 'emoji_status' => EmojiStatus]; +``` diff --git a/docs/API_docs/constructors/updateUserName.md b/docs/API_docs/constructors/updateUserName.md new file mode 100644 index 0000000000..bed45abac6 --- /dev/null +++ b/docs/API_docs/constructors/updateUserName.md @@ -0,0 +1,32 @@ +--- +title: "updateUserName" +description: "Changes the user's first name, last name and username." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateUserName +[Back to constructors index](/API_docs/constructors/index.html) + + + +Changes the user's first name, last name and username. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|first\_name|[string](/API_docs/types/string.html) | Yes|New first name. Corresponds to the new value of **real\_first\_name** field of the [userFull](../constructors/userFull.html) constructor.| +|last\_name|[string](/API_docs/types/string.html) | Yes|New last name. Corresponds to the new value of **real\_last\_name** field of the [userFull](../constructors/userFull.html) constructor.| +|usernames|Array of [Username](/API_docs/types/Username.html) | Yes|Usernames.| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateUserName = ['_' => 'updateUserName', 'user_id' => long, 'first_name' => 'string', 'last_name' => 'string', 'usernames' => [Username, Username]]; +``` diff --git a/docs/API_docs/constructors/updateUserPhone.md b/docs/API_docs/constructors/updateUserPhone.md new file mode 100644 index 0000000000..6beaa3019d --- /dev/null +++ b/docs/API_docs/constructors/updateUserPhone.md @@ -0,0 +1,30 @@ +--- +title: "updateUserPhone" +description: "A user's phone number was changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateUserPhone +[Back to constructors index](/API_docs/constructors/index.html) + + + +A user's phone number was changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User ID| +|phone|[string](/API_docs/types/string.html) | Yes|New phone number| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateUserPhone = ['_' => 'updateUserPhone', 'user_id' => long, 'phone' => 'string']; +``` diff --git a/docs/API_docs/constructors/updateUserStatus.md b/docs/API_docs/constructors/updateUserStatus.md new file mode 100644 index 0000000000..e8020b51c4 --- /dev/null +++ b/docs/API_docs/constructors/updateUserStatus.md @@ -0,0 +1,30 @@ +--- +title: "updateUserStatus" +description: "Contact status update." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateUserStatus +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contact status update. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User identifier| +|status|[UserStatus](/API_docs/types/UserStatus.html) | Optional|New status| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateUserStatus = ['_' => 'updateUserStatus', 'user_id' => long, 'status' => UserStatus]; +``` diff --git a/docs/API_docs/constructors/updateUserTyping.md b/docs/API_docs/constructors/updateUserTyping.md new file mode 100644 index 0000000000..002a22a709 --- /dev/null +++ b/docs/API_docs/constructors/updateUserTyping.md @@ -0,0 +1,30 @@ +--- +title: "updateUserTyping" +description: "The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateUserTyping +[Back to constructors index](/API_docs/constructors/index.html) + + + +The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|user\_id|[long](/API_docs/types/long.html) | Yes|User id| +|action|[SendMessageAction](/API_docs/types/SendMessageAction.html) | Yes|Action type| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateUserTyping = ['_' => 'updateUserTyping', 'user_id' => long, 'action' => SendMessageAction]; +``` diff --git a/docs/API_docs/constructors/updateWebPage.md b/docs/API_docs/constructors/updateWebPage.md new file mode 100644 index 0000000000..6435882982 --- /dev/null +++ b/docs/API_docs/constructors/updateWebPage.md @@ -0,0 +1,31 @@ +--- +title: "updateWebPage" +description: "An instant view webpage preview was generated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateWebPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +An [instant view](https://instantview.telegram.org) webpage preview was generated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|webpage|[WebPage](/API_docs/types/WebPage.html) | Optional|Webpage preview| +|pts|[int](/API_docs/types/int.html) | Yes|[Event count after generation](https://core.telegram.org/api/updates)| +|pts\_count|[int](/API_docs/types/int.html) | Yes|[Number of events that were generated](https://core.telegram.org/api/updates)| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateWebPage = ['_' => 'updateWebPage', 'webpage' => WebPage, 'pts' => int, 'pts_count' => int]; +``` diff --git a/docs/API_docs/constructors/updateWebViewResultSent.md b/docs/API_docs/constructors/updateWebViewResultSent.md new file mode 100644 index 0000000000..81b8cf668e --- /dev/null +++ b/docs/API_docs/constructors/updateWebViewResultSent.md @@ -0,0 +1,29 @@ +--- +title: "updateWebViewResultSent" +description: "Indicates to a bot that a webview was closed and an inline message was sent on behalf of the user using messages.sendWebViewResultMessage" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updateWebViewResultSent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates to a bot that a webview was closed and an inline message was sent on behalf of the user using [messages.sendWebViewResultMessage](../methods/messages.sendWebViewResultMessage.html) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Web app interaction ID| + + + +### Type: [Update](/API_docs/types/Update.html) + + +### Example: + +``` +$updateWebViewResultSent = ['_' => 'updateWebViewResultSent', 'query_id' => long]; +``` diff --git a/docs/API_docs/constructors/updates.channelDifference.md b/docs/API_docs/constructors/updates.channelDifference.md new file mode 100644 index 0000000000..0f4296968a --- /dev/null +++ b/docs/API_docs/constructors/updates.channelDifference.md @@ -0,0 +1,36 @@ +--- +title: "updates.channelDifference" +description: "The new updates" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_channelDifference.html +--- +# Constructor: updates.channelDifference +[Back to constructors index](/API_docs/constructors/index.html) + + + +The new updates + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|final|[Bool](/API_docs/types/Bool.html) | Optional|Whether there are more updates to be fetched using getDifference, starting from the provided `pts`| +|pts|[int](/API_docs/types/int.html) | Yes|The [PTS](https://core.telegram.org/api/updates) from which to start getting updates the next time| +|timeout|[int](/API_docs/types/int.html) | Optional|Clients are supposed to refetch the channel difference after timeout seconds have elapsed| +|new\_messages|Array of [Message](/API_docs/types/Message.html) | Yes|New messages| +|other\_updates|Array of [Update](/API_docs/types/Update.html) | Yes|Other updates| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users| + + + +### Type: [updates.ChannelDifference](/API_docs/types/updates.ChannelDifference.html) + + +### Example: + +``` +$updates_channelDifference = ['_' => 'updates.channelDifference', 'final' => Bool, 'pts' => int, 'timeout' => int, 'new_messages' => [Message, Message], 'other_updates' => [Update, Update], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/updates.channelDifferenceEmpty.md b/docs/API_docs/constructors/updates.channelDifferenceEmpty.md new file mode 100644 index 0000000000..ca499226fb --- /dev/null +++ b/docs/API_docs/constructors/updates.channelDifferenceEmpty.md @@ -0,0 +1,32 @@ +--- +title: "updates.channelDifferenceEmpty" +description: "There are no new updates" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_channelDifferenceEmpty.html +--- +# Constructor: updates.channelDifferenceEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +There are no new updates + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|final|[Bool](/API_docs/types/Bool.html) | Optional|Whether there are more updates that must be fetched (always false)| +|pts|[int](/API_docs/types/int.html) | Yes|The latest [PTS](https://core.telegram.org/api/updates)| +|timeout|[int](/API_docs/types/int.html) | Optional|Clients are supposed to refetch the channel difference after timeout seconds have elapsed| + + + +### Type: [updates.ChannelDifference](/API_docs/types/updates.ChannelDifference.html) + + +### Example: + +``` +$updates_channelDifferenceEmpty = ['_' => 'updates.channelDifferenceEmpty', 'final' => Bool, 'pts' => int, 'timeout' => int]; +``` diff --git a/docs/API_docs/constructors/updates.channelDifferenceTooLong.md b/docs/API_docs/constructors/updates.channelDifferenceTooLong.md new file mode 100644 index 0000000000..8c0f997de1 --- /dev/null +++ b/docs/API_docs/constructors/updates.channelDifferenceTooLong.md @@ -0,0 +1,50 @@ +--- +title: "updates.channelDifferenceTooLong" +description: "The provided pts + limit < remote pts. Simply, there are too many updates to be fetched (more than limit), the client has to resolve the update gap in one of the following ways (assuming the existence of a persistent database to locally store messages)" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_channelDifferenceTooLong.html +--- +# Constructor: updates.channelDifferenceTooLong +[Back to constructors index](/API_docs/constructors/index.html) + + + +The provided `pts + limit < remote pts`. Simply, there are too many updates to be fetched (more than `limit`), the client has to resolve the update gap in one of the following ways (assuming the existence of a persistent database to locally store messages): + +1. Delete all known messages in the chat, begin from scratch by refetching all messages manually with [messages.getHistory](../methods/messages.getHistory.html). It is easy to implement, but suddenly disappearing messages look awful to the user. +2. Save all messages loaded in the memory until application restart, but delete all messages from the database. Messages left in the memory must be lazily updated using calls to [messages.getHistory](../methods/messages.getHistory.html). + It will look much smoother to the user, they will need to redownload messages only after client restart. + Unsynchronized messages left in memory shouldn't be saved to the database, results of [messages.getHistory](../methods/messages.getHistory.html) and [messages.getMessages](../methods/messages.getMessages.html) must be used to update the state of deleted and edited messages left in the memory. +3. Save all messages loaded in the memory and stored in the database without saving that some messages form continuous ranges. + Messages in the database will be excluded when paginating through or searching the local message history after application restart and will be available only through individual message queries. + Every message should still be checked using [messages.getHistory](../methods/messages.getHistory.html). + It has more disadvantages over 2) than advantages. +4. Save all messages with saving all data about continuous message ranges. + Messages from the database may be used when paginating through or searching the local message history. + The messages should still be lazily checked using [messages.getHistory](../methods/messages.getHistory.html), but they are still available offline. + It is the best way for gaps support, but it is pretty hard to implement correctly. + +It should be also noted that some messages like live location messages shouldn't be deleted. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|final|[Bool](/API_docs/types/Bool.html) | Optional|Whether there are more updates that must be fetched (always false)| +|timeout|[int](/API_docs/types/int.html) | Optional|Clients are supposed to refetch the channel difference after timeout seconds have elapsed| +|dialog|[Dialog](/API_docs/types/Dialog.html) | Yes|Dialog containing the latest [PTS](https://core.telegram.org/api/updates) that can be used to reset the channel state| +|messages|Array of [Message](/API_docs/types/Message.html) | Yes|The latest messages| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Chats from messages| +|users|Array of [User](/API_docs/types/User.html) | Yes|Users from messages| + + + +### Type: [updates.ChannelDifference](/API_docs/types/updates.ChannelDifference.html) + + +### Example: + +``` +$updates_channelDifferenceTooLong = ['_' => 'updates.channelDifferenceTooLong', 'final' => Bool, 'timeout' => int, 'dialog' => Dialog, 'messages' => [Message, Message], 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/updates.difference.md b/docs/API_docs/constructors/updates.difference.md new file mode 100644 index 0000000000..68f83ff511 --- /dev/null +++ b/docs/API_docs/constructors/updates.difference.md @@ -0,0 +1,35 @@ +--- +title: "updates.difference" +description: "Full list of occurred events." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_difference.html +--- +# Constructor: updates.difference +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full list of occurred events. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of new messages| +|new\_encrypted\_messages|Array of [EncryptedMessage](/API_docs/types/EncryptedMessage.html) | Yes|List of new encrypted secret chat messages| +|other\_updates|Array of [Update](/API_docs/types/Update.html) | Yes|List of updates| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in events| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in events| +|state|[updates.State](/API_docs/constructors/updates.State.html) | Yes|Current state| + + + +### Type: [updates.Difference](/API_docs/types/updates.Difference.html) + + +### Example: + +``` +$updates_difference = ['_' => 'updates.difference', 'new_messages' => [Message, Message], 'new_encrypted_messages' => [EncryptedMessage, EncryptedMessage], 'other_updates' => [Update, Update], 'chats' => [Chat, Chat], 'users' => [User, User], 'state' => updates.State]; +``` diff --git a/docs/API_docs/constructors/updates.differenceEmpty.md b/docs/API_docs/constructors/updates.differenceEmpty.md new file mode 100644 index 0000000000..d934883965 --- /dev/null +++ b/docs/API_docs/constructors/updates.differenceEmpty.md @@ -0,0 +1,31 @@ +--- +title: "updates.differenceEmpty" +description: "No events." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_differenceEmpty.html +--- +# Constructor: updates.differenceEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No events. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|date|[int](/API_docs/types/int.html) | Yes|Current date| +|seq|[int](/API_docs/types/int.html) | Yes|Number of sent updates| + + + +### Type: [updates.Difference](/API_docs/types/updates.Difference.html) + + +### Example: + +``` +$updates_differenceEmpty = ['_' => 'updates.differenceEmpty', 'date' => int, 'seq' => int]; +``` diff --git a/docs/API_docs/constructors/updates.differenceSlice.md b/docs/API_docs/constructors/updates.differenceSlice.md new file mode 100644 index 0000000000..b381db482a --- /dev/null +++ b/docs/API_docs/constructors/updates.differenceSlice.md @@ -0,0 +1,35 @@ +--- +title: "updates.differenceSlice" +description: "Incomplete list of occurred events." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_differenceSlice.html +--- +# Constructor: updates.differenceSlice +[Back to constructors index](/API_docs/constructors/index.html) + + + +Incomplete list of occurred events. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|new\_messages|Array of [Message](/API_docs/types/Message.html) | Yes|List of new messages| +|new\_encrypted\_messages|Array of [EncryptedMessage](/API_docs/types/EncryptedMessage.html) | Yes|New messages from the [encrypted event sequence](https://core.telegram.org/api/updates)| +|other\_updates|Array of [Update](/API_docs/types/Update.html) | Yes|List of updates| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in events| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in events| +|intermediate\_state|[updates.State](/API_docs/constructors/updates.State.html) | Yes|Intermediary state| + + + +### Type: [updates.Difference](/API_docs/types/updates.Difference.html) + + +### Example: + +``` +$updates_differenceSlice = ['_' => 'updates.differenceSlice', 'new_messages' => [Message, Message], 'new_encrypted_messages' => [EncryptedMessage, EncryptedMessage], 'other_updates' => [Update, Update], 'chats' => [Chat, Chat], 'users' => [User, User], 'intermediate_state' => updates.State]; +``` diff --git a/docs/API_docs/constructors/updates.differenceTooLong.md b/docs/API_docs/constructors/updates.differenceTooLong.md new file mode 100644 index 0000000000..ef7445040a --- /dev/null +++ b/docs/API_docs/constructors/updates.differenceTooLong.md @@ -0,0 +1,30 @@ +--- +title: "updates.differenceTooLong" +description: "The difference is too long, and the specified state must be used to refetch updates." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_differenceTooLong.html +--- +# Constructor: updates.differenceTooLong +[Back to constructors index](/API_docs/constructors/index.html) + + + +The difference is [too long](https://core.telegram.org/api/updates#recovering-gaps), and the specified state must be used to refetch updates. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pts|[int](/API_docs/types/int.html) | Yes|The new state to use.| + + + +### Type: [updates.Difference](/API_docs/types/updates.Difference.html) + + +### Example: + +``` +$updates_differenceTooLong = ['_' => 'updates.differenceTooLong', 'pts' => int]; +``` diff --git a/docs/API_docs/constructors/updates.md b/docs/API_docs/constructors/updates.md new file mode 100644 index 0000000000..de48a4a249 --- /dev/null +++ b/docs/API_docs/constructors/updates.md @@ -0,0 +1,33 @@ +--- +title: "updates" +description: "Full constructor of updates" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updates +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full constructor of updates + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|updates|Array of [Update](/API_docs/types/Update.html) | Yes|List of updates| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in updates| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in updates| +|date|[int](/API_docs/types/int.html) | Yes|Current date| +|seq|[int](/API_docs/types/int.html) | Yes|Total number of sent updates| + + + +### Type: [Updates](/API_docs/types/Updates.html) + + +### Example: + +``` +$updates = ['_' => 'updates', 'updates' => [Update, Update], 'users' => [User, User], 'chats' => [Chat, Chat], 'date' => int, 'seq' => int]; +``` diff --git a/docs/API_docs/constructors/updates.state.md b/docs/API_docs/constructors/updates.state.md new file mode 100644 index 0000000000..2290f3c476 --- /dev/null +++ b/docs/API_docs/constructors/updates.state.md @@ -0,0 +1,34 @@ +--- +title: "updates.state" +description: "Updates state." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/updates_state.html +--- +# Constructor: updates.state +[Back to constructors index](/API_docs/constructors/index.html) + + + +Updates state. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|pts|[int](/API_docs/types/int.html) | Yes|Number of events occurred in a text box| +|qts|[int](/API_docs/types/int.html) | Yes|Position in a sequence of updates in secret chats. For further details refer to article [secret chats](https://core.telegram.org/api/end-to-end)| +|date|[int](/API_docs/types/int.html) | Yes|Date of condition| +|seq|[int](/API_docs/types/int.html) | Yes|Number of sent updates| +|unread\_count|[int](/API_docs/types/int.html) | Yes|Number of unread messages| + + + +### Type: [updates.State](/API_docs/types/updates.State.html) + + +### Example: + +``` +$updates_state = ['_' => 'updates.state', 'pts' => int, 'qts' => int, 'date' => int, 'seq' => int, 'unread_count' => int]; +``` diff --git a/docs/API_docs/constructors/updatesCombined.md b/docs/API_docs/constructors/updatesCombined.md new file mode 100644 index 0000000000..661614d9ec --- /dev/null +++ b/docs/API_docs/constructors/updatesCombined.md @@ -0,0 +1,34 @@ +--- +title: "updatesCombined" +description: "Constructor for a group of updates." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatesCombined +[Back to constructors index](/API_docs/constructors/index.html) + + + +Constructor for a group of updates. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|updates|Array of [Update](/API_docs/types/Update.html) | Yes|List of updates| +|users|Array of [User](/API_docs/types/User.html) | Yes|List of users mentioned in updates| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|List of chats mentioned in updates| +|date|[int](/API_docs/types/int.html) | Yes|Current date| +|seq\_start|[int](/API_docs/types/int.html) | Yes|Value **seq** for the earliest update in a group| +|seq|[int](/API_docs/types/int.html) | Yes|Value **seq** for the latest update in a group| + + + +### Type: [Updates](/API_docs/types/Updates.html) + + +### Example: + +``` +$updatesCombined = ['_' => 'updatesCombined', 'updates' => [Update, Update], 'users' => [User, User], 'chats' => [Chat, Chat], 'date' => int, 'seq_start' => int, 'seq' => int]; +``` diff --git a/docs/API_docs/constructors/updatesTooLong.md b/docs/API_docs/constructors/updatesTooLong.md new file mode 100644 index 0000000000..064cdc72f1 --- /dev/null +++ b/docs/API_docs/constructors/updatesTooLong.md @@ -0,0 +1,24 @@ +--- +title: "updatesTooLong" +description: "Too many updates, it is necessary to execute updates.getDifference." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: updatesTooLong +[Back to constructors index](/API_docs/constructors/index.html) + + + +Too many updates, it is necessary to execute [updates.getDifference](../methods/updates.getDifference.html). + + + + +### Type: [Updates](/API_docs/types/Updates.html) + + +### Example: + +``` +$updatesTooLong = ['_' => 'updatesTooLong']; +``` diff --git a/docs/API_docs/constructors/upload.cdnFile.md b/docs/API_docs/constructors/upload.cdnFile.md new file mode 100644 index 0000000000..f3a0b246e9 --- /dev/null +++ b/docs/API_docs/constructors/upload.cdnFile.md @@ -0,0 +1,30 @@ +--- +title: "upload.cdnFile" +description: "Represent a chunk of a CDN file." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/upload_cdnFile.html +--- +# Constructor: upload.cdnFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represent a chunk of a [CDN](https://core.telegram.org/cdn) file. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|The data| + + + +### Type: [upload.CdnFile](/API_docs/types/upload.CdnFile.html) + + +### Example: + +``` +$upload_cdnFile = ['_' => 'upload.cdnFile', 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/upload.cdnFileReuploadNeeded.md b/docs/API_docs/constructors/upload.cdnFileReuploadNeeded.md new file mode 100644 index 0000000000..afff9a780e --- /dev/null +++ b/docs/API_docs/constructors/upload.cdnFileReuploadNeeded.md @@ -0,0 +1,30 @@ +--- +title: "upload.cdnFileReuploadNeeded" +description: "The file was cleared from the temporary RAM cache of the CDN and has to be re-uploaded." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/upload_cdnFileReuploadNeeded.html +--- +# Constructor: upload.cdnFileReuploadNeeded +[Back to constructors index](/API_docs/constructors/index.html) + + + +The file was cleared from the temporary RAM cache of the [CDN](https://core.telegram.org/cdn) and has to be re-uploaded. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|request\_token|[bytes](/API_docs/types/bytes.html) | Yes|Request token (see [CDN](https://core.telegram.org/cdn))| + + + +### Type: [upload.CdnFile](/API_docs/types/upload.CdnFile.html) + + +### Example: + +``` +$upload_cdnFileReuploadNeeded = ['_' => 'upload.cdnFileReuploadNeeded', 'request_token' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/upload.file.md b/docs/API_docs/constructors/upload.file.md new file mode 100644 index 0000000000..15e21d988a --- /dev/null +++ b/docs/API_docs/constructors/upload.file.md @@ -0,0 +1,32 @@ +--- +title: "upload.file" +description: "File content." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/upload_file.html +--- +# Constructor: upload.file +[Back to constructors index](/API_docs/constructors/index.html) + + + +File content. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[storage.FileType](/API_docs/constructors/storage.FileType.html) | Yes|File type| +|mtime|[int](/API_docs/types/int.html) | Yes|Modification time| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|Binary data, file content| + + + +### Type: [upload.File](/API_docs/types/upload.File.html) + + +### Example: + +``` +$upload_file = ['_' => 'upload.file', 'type' => storage.FileType, 'mtime' => int, 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/upload.fileCdnRedirect.md b/docs/API_docs/constructors/upload.fileCdnRedirect.md new file mode 100644 index 0000000000..789939684e --- /dev/null +++ b/docs/API_docs/constructors/upload.fileCdnRedirect.md @@ -0,0 +1,34 @@ +--- +title: "upload.fileCdnRedirect" +description: "The file must be downloaded from a CDN DC." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/upload_fileCdnRedirect.html +--- +# Constructor: upload.fileCdnRedirect +[Back to constructors index](/API_docs/constructors/index.html) + + + +The file must be downloaded from a [CDN DC](https://core.telegram.org/cdn). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|dc\_id|[int](/API_docs/types/int.html) | Yes|[CDN DC](https://core.telegram.org/cdn) ID| +|file\_token|[string](/API_docs/types/string.html) | Yes| +|encryption\_key|[string](/API_docs/types/string.html) | Yes| +|encryption\_iv|[string](/API_docs/types/string.html) | Yes| +|file\_hashes|Array of [FileHash](/API_docs/types/FileHash.html) | Yes|File hashes (see [CDN files](https://core.telegram.org/cdn))| + + + +### Type: [upload.File](/API_docs/types/upload.File.html) + + +### Example: + +``` +$upload_fileCdnRedirect = ['_' => 'upload.fileCdnRedirect', 'dc_id' => int, 'file_token' => 'string', 'encryption_key' => 'string', 'encryption_iv' => 'string', 'file_hashes' => [FileHash, FileHash]]; +``` diff --git a/docs/API_docs/constructors/upload.webFile.md b/docs/API_docs/constructors/upload.webFile.md new file mode 100644 index 0000000000..46ed1724ef --- /dev/null +++ b/docs/API_docs/constructors/upload.webFile.md @@ -0,0 +1,34 @@ +--- +title: "upload.webFile" +description: "Represents a chunk of an HTTP webfile downloaded through telegram's secure MTProto servers" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/upload_webFile.html +--- +# Constructor: upload.webFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a chunk of an [HTTP webfile](https://core.telegram.org/api/files) downloaded through telegram's secure MTProto servers + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|size|[int](/API_docs/types/int.html) | Yes|File size| +|mime\_type|[string](/API_docs/types/string.html) | Yes|Mime type| +|file\_type|[storage.FileType](/API_docs/constructors/storage.FileType.html) | Yes|File type| +|mtime|[int](/API_docs/types/int.html) | Yes|Modified time| +|bytes|[bytes](/API_docs/types/bytes.html) | Yes|Data| + + + +### Type: [upload.WebFile](/API_docs/types/upload.WebFile.html) + + +### Example: + +``` +$upload_webFile = ['_' => 'upload.webFile', 'size' => int, 'mime_type' => 'string', 'file_type' => storage.FileType, 'mtime' => int, 'bytes' => 'bytes']; +``` diff --git a/docs/API_docs/constructors/urlAuthResultAccepted.md b/docs/API_docs/constructors/urlAuthResultAccepted.md new file mode 100644 index 0000000000..49d92b83eb --- /dev/null +++ b/docs/API_docs/constructors/urlAuthResultAccepted.md @@ -0,0 +1,29 @@ +--- +title: "urlAuthResultAccepted" +description: "Details about an accepted authorization request, for more info click here »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: urlAuthResultAccepted +[Back to constructors index](/API_docs/constructors/index.html) + + + +Details about an accepted authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|The URL name of the website on which the user has logged in.| + + + +### Type: [UrlAuthResult](/API_docs/types/UrlAuthResult.html) + + +### Example: + +``` +$urlAuthResultAccepted = ['_' => 'urlAuthResultAccepted', 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/urlAuthResultDefault.md b/docs/API_docs/constructors/urlAuthResultDefault.md new file mode 100644 index 0000000000..7637a8c98a --- /dev/null +++ b/docs/API_docs/constructors/urlAuthResultDefault.md @@ -0,0 +1,24 @@ +--- +title: "urlAuthResultDefault" +description: "Details about an accepted authorization request, for more info click here »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: urlAuthResultDefault +[Back to constructors index](/API_docs/constructors/index.html) + + + +Details about an accepted authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization) + + + + +### Type: [UrlAuthResult](/API_docs/types/UrlAuthResult.html) + + +### Example: + +``` +$urlAuthResultDefault = ['_' => 'urlAuthResultDefault']; +``` diff --git a/docs/API_docs/constructors/urlAuthResultRequest.md b/docs/API_docs/constructors/urlAuthResultRequest.md new file mode 100644 index 0000000000..09ce94bcb6 --- /dev/null +++ b/docs/API_docs/constructors/urlAuthResultRequest.md @@ -0,0 +1,31 @@ +--- +title: "urlAuthResultRequest" +description: "Details about the authorization request, for more info click here »" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: urlAuthResultRequest +[Back to constructors index](/API_docs/constructors/index.html) + + + +Details about the authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|request\_write\_access|[Bool](/API_docs/types/Bool.html) | Optional|Whether the bot would like to send messages to the user| +|bot|[User](/API_docs/types/User.html) | Optional|Username of a bot, which will be used for user authorization. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See [Linking your domain to the bot](https://core.telegram.org/widgets/login#linking-your-domain-to-the-bot) for more details.| +|domain|[string](/API_docs/types/string.html) | Yes|The domain name of the website on which the user will log in.| + + + +### Type: [UrlAuthResult](/API_docs/types/UrlAuthResult.html) + + +### Example: + +``` +$urlAuthResultRequest = ['_' => 'urlAuthResultRequest', 'request_write_access' => Bool, 'bot' => User, 'domain' => 'string']; +``` diff --git a/docs/API_docs/constructors/user.md b/docs/API_docs/constructors/user.md new file mode 100644 index 0000000000..029fdc4ac6 --- /dev/null +++ b/docs/API_docs/constructors/user.md @@ -0,0 +1,69 @@ +--- +title: "user" +description: "Indicates info about a certain user" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: user +[Back to constructors index](/API_docs/constructors/index.html) + + + +Indicates info about a certain user + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|self|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user indicates the currently logged in user| +|contact|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user is a contact| +|mutual\_contact|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user is a mutual contact| +|deleted|[Bool](/API_docs/types/Bool.html) | Optional|Whether the account of this user was deleted| +|bot|[Bool](/API_docs/types/Bool.html) | Optional|Is this user a bot?| +|bot\_chat\_history|[Bool](/API_docs/types/Bool.html) | Optional|Can the bot see all messages in groups?| +|bot\_nochats|[Bool](/API_docs/types/Bool.html) | Optional|Can the bot be added to groups?| +|verified|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user is verified| +|restricted|[Bool](/API_docs/types/Bool.html) | Optional|Access to this user must be restricted for the reason specified in `restriction_reason`| +|min|[Bool](/API_docs/types/Bool.html) | Optional|See [min](https://core.telegram.org/api/min)| +|bot\_inline\_geo|[Bool](/API_docs/types/Bool.html) | Optional|Whether the bot can request our geolocation in inline mode| +|support|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is an official support user| +|scam|[Bool](/API_docs/types/Bool.html) | Optional|This may be a scam user| +|apply\_min\_photo|[Bool](/API_docs/types/Bool.html) | Optional|If set, the profile picture for this user should be refetched| +|fake|[Bool](/API_docs/types/Bool.html) | Optional|If set, this user was reported by many users as a fake or scam user: be careful when interacting with them.| +|bot\_attach\_menu|[Bool](/API_docs/types/Bool.html) | Optional|Whether this bot offers an [attachment menu web app](https://core.telegram.org/api/bots/attach)| +|premium|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user is a Telegram Premium user| +|attach\_menu\_enabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether we installed the [attachment menu web app](https://core.telegram.org/api/bots/attach) offered by this bot| +|bot\_can\_edit|[Bool](/API_docs/types/Bool.html) | Optional| +|close\_friend|[Bool](/API_docs/types/Bool.html) | Optional| +|stories\_hidden|[Bool](/API_docs/types/Bool.html) | Optional| +|stories\_unavailable|[Bool](/API_docs/types/Bool.html) | Optional| +|contact\_require\_premium|[Bool](/API_docs/types/Bool.html) | Optional| +|bot\_business|[Bool](/API_docs/types/Bool.html) | Optional| +|id|[long](/API_docs/types/long.html) | Yes|ID of the user| +|access\_hash|[long](/API_docs/types/long.html) | Optional|Access hash of the user| +|first\_name|[string](/API_docs/types/string.html) | Optional|First name| +|last\_name|[string](/API_docs/types/string.html) | Optional|Last name| +|username|[string](/API_docs/types/string.html) | Optional|Username| +|phone|[string](/API_docs/types/string.html) | Optional|Phone number| +|photo|[UserProfilePhoto](/API_docs/types/UserProfilePhoto.html) | Optional|Profile picture of user| +|status|[UserStatus](/API_docs/types/UserStatus.html) | Optional|Online status of user| +|bot\_info\_version|[int](/API_docs/types/int.html) | Optional|Version of the [bot\_info field in userFull](../constructors/userFull.html), incremented every time it changes| +|restriction\_reason|Array of [RestrictionReason](/API_docs/types/RestrictionReason.html) | Optional|Contains the reason why access to this user must be restricted.| +|bot\_inline\_placeholder|[string](/API_docs/types/string.html) | Optional|Inline placeholder for this inline bot| +|lang\_code|[string](/API_docs/types/string.html) | Optional|Language code of the user| +|emoji\_status|[EmojiStatus](/API_docs/types/EmojiStatus.html) | Optional|[Emoji status](https://core.telegram.org/api/emoji-status)| +|usernames|Array of [Username](/API_docs/types/Username.html) | Optional| +|stories\_max\_id|[int](/API_docs/types/int.html) | Optional| +|color|[PeerColor](/API_docs/types/PeerColor.html) | Optional| +|profile\_color|[PeerColor](/API_docs/types/PeerColor.html) | Optional| + + + +### Type: [User](/API_docs/types/User.html) + + +### Example: + +``` +$user = ['_' => 'user', 'self' => Bool, 'contact' => Bool, 'mutual_contact' => Bool, 'deleted' => Bool, 'bot' => Bool, 'bot_chat_history' => Bool, 'bot_nochats' => Bool, 'verified' => Bool, 'restricted' => Bool, 'min' => Bool, 'bot_inline_geo' => Bool, 'support' => Bool, 'scam' => Bool, 'apply_min_photo' => Bool, 'fake' => Bool, 'bot_attach_menu' => Bool, 'premium' => Bool, 'attach_menu_enabled' => Bool, 'bot_can_edit' => Bool, 'close_friend' => Bool, 'stories_hidden' => Bool, 'stories_unavailable' => Bool, 'contact_require_premium' => Bool, 'bot_business' => Bool, 'id' => long, 'access_hash' => long, 'first_name' => 'string', 'last_name' => 'string', 'username' => 'string', 'phone' => 'string', 'photo' => UserProfilePhoto, 'status' => UserStatus, 'bot_info_version' => int, 'restriction_reason' => [RestrictionReason, RestrictionReason], 'bot_inline_placeholder' => 'string', 'lang_code' => 'string', 'emoji_status' => EmojiStatus, 'usernames' => [Username, Username], 'stories_max_id' => int, 'color' => PeerColor, 'profile_color' => PeerColor]; +``` diff --git a/docs/API_docs/constructors/userEmpty.md b/docs/API_docs/constructors/userEmpty.md new file mode 100644 index 0000000000..5d343246ef --- /dev/null +++ b/docs/API_docs/constructors/userEmpty.md @@ -0,0 +1,29 @@ +--- +title: "userEmpty" +description: "Empty constructor, non-existent user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Empty constructor, non-existent user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|User identifier or `0`| + + + +### Type: [User](/API_docs/types/User.html) + + +### Example: + +``` +$userEmpty = ['_' => 'userEmpty', 'id' => long]; +``` diff --git a/docs/API_docs/constructors/userFull.md b/docs/API_docs/constructors/userFull.md new file mode 100644 index 0000000000..1fa07d227a --- /dev/null +++ b/docs/API_docs/constructors/userFull.md @@ -0,0 +1,69 @@ +--- +title: "userFull" +description: "Extended user info" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userFull +[Back to constructors index](/API_docs/constructors/index.html) + + + +Extended user info + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blocked|[Bool](/API_docs/types/Bool.html) | Optional|Whether you have blocked this user| +|phone\_calls\_available|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user can make VoIP calls| +|phone\_calls\_private|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user's privacy settings allow you to call them| +|can\_pin\_message|[Bool](/API_docs/types/Bool.html) | Optional|Whether you can pin messages in the chat with this user, you can do this only for a chat with yourself| +|has\_scheduled|[Bool](/API_docs/types/Bool.html) | Optional|Whether [scheduled messages](https://core.telegram.org/api/scheduled-messages) are available| +|video\_calls\_available|[Bool](/API_docs/types/Bool.html) | Optional|Whether the user can receive video calls| +|voice\_messages\_forbidden|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user doesn't allow sending voice messages in a private chat with them| +|translations\_disabled|[Bool](/API_docs/types/Bool.html) | Optional|Whether the [real-time chat translation popup](https://core.telegram.org/api/translation) should be hidden.| +|stories\_pinned\_available|[Bool](/API_docs/types/Bool.html) | Optional|Whether this user has some [pinned stories](https://core.telegram.org/api/stories#pinned-or-archived-stories).| +|blocked\_my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Optional|Whether we've [blocked this user, preventing them from seeing our stories »](https://core.telegram.org/api/block).| +|wallpaper\_overridden|[Bool](/API_docs/types/Bool.html) | Optional|Whether the other user has chosen a custom wallpaper for us using [messages.setChatWallPaper](../methods/messages.setChatWallPaper.html) and the `for_both` flag, see [here »](https://core.telegram.org/api/wallpapers#installing-wallpapers-in-a-specific-chat-or-channel) for more info.| +|contact\_require\_premium|[Bool](/API_docs/types/Bool.html) | Optional| +|read\_dates\_private|[Bool](/API_docs/types/Bool.html) | Optional| +|sponsored\_enabled|[Bool](/API_docs/types/Bool.html) | Optional| +|id|[long](/API_docs/types/long.html) | Yes|User ID| +|about|[string](/API_docs/types/string.html) | Optional|Bio of the user| +|settings|[PeerSettings](/API_docs/types/PeerSettings.html) | Yes|Peer settings| +|personal\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Personal profile photo, to be shown instead of `profile_photo`.| +|profile\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Profile photo| +|fallback\_photo|[Photo](/API_docs/types/Photo.html) | Optional|Fallback profile photo, displayed if no photo is present in `profile_photo` or `personal_photo`, due to privacy settings.| +|notify\_settings|[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) | Yes|Notification settings| +|bot\_info|[BotInfo](/API_docs/types/BotInfo.html) | Optional|For bots, info about the bot (bot commands, etc)| +|pinned\_msg\_id|[int](/API_docs/types/int.html) | Optional|Message ID of the last [pinned message](https://core.telegram.org/api/pin)| +|common\_chats\_count|[int](/API_docs/types/int.html) | Yes|Chats in common with this user| +|folder\_id|[int](/API_docs/types/int.html) | Optional|[Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders)| +|ttl\_period|[int](/API_docs/types/int.html) | Optional|Time To Live of all messages in this chat; once a message is this many seconds old, it must be deleted.| +|theme\_emoticon|[string](/API_docs/types/string.html) | Optional|Emoji associated with chat theme| +|private\_forward\_name|[string](/API_docs/types/string.html) | Optional|Anonymized text to be shown instead of the user's name on forwarded messages| +|bot\_group\_admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|A [suggested set of administrator rights](https://core.telegram.org/api/rights#suggested-bot-rights) for the bot, to be shown when adding the bot as admin to a group, see [here for more info on how to handle them »](https://core.telegram.org/api/rights#suggested-bot-rights).| +|bot\_broadcast\_admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Optional|A [suggested set of administrator rights](https://core.telegram.org/api/rights#suggested-bot-rights) for the bot, to be shown when adding the bot as admin to a channel, see [here for more info on how to handle them »](https://core.telegram.org/api/rights#suggested-bot-rights).| +|premium\_gifts|Array of [PremiumGiftOption](/API_docs/types/PremiumGiftOption.html) | Optional|Telegram Premium subscriptions gift options| +|wallpaper|[WallPaper](/API_docs/types/WallPaper.html) | Optional|[Wallpaper](https://core.telegram.org/api/wallpapers) to use in the private chat with the user.| +|stories|[PeerStories](/API_docs/types/PeerStories.html) | Optional|Active [stories »](https://core.telegram.org/api/stories)| +|business\_work\_hours|[BusinessWorkHours](/API_docs/types/BusinessWorkHours.html) | Optional| +|business\_location|[BusinessLocation](/API_docs/types/BusinessLocation.html) | Optional| +|business\_greeting\_message|[BusinessGreetingMessage](/API_docs/types/BusinessGreetingMessage.html) | Optional| +|business\_away\_message|[BusinessAwayMessage](/API_docs/types/BusinessAwayMessage.html) | Optional| +|business\_intro|[BusinessIntro](/API_docs/types/BusinessIntro.html) | Optional| +|birthday|[Birthday](/API_docs/types/Birthday.html) | Optional| +|personal\_channel\_id|[long](/API_docs/types/long.html) | Optional| +|personal\_channel\_message|[int](/API_docs/types/int.html) | Optional| + + + +### Type: [UserFull](/API_docs/types/UserFull.html) + + +### Example: + +``` +$userFull = ['_' => 'userFull', 'blocked' => Bool, 'phone_calls_available' => Bool, 'phone_calls_private' => Bool, 'can_pin_message' => Bool, 'has_scheduled' => Bool, 'video_calls_available' => Bool, 'voice_messages_forbidden' => Bool, 'translations_disabled' => Bool, 'stories_pinned_available' => Bool, 'blocked_my_stories_from' => Bool, 'wallpaper_overridden' => Bool, 'contact_require_premium' => Bool, 'read_dates_private' => Bool, 'sponsored_enabled' => Bool, 'id' => long, 'about' => 'string', 'settings' => PeerSettings, 'personal_photo' => Photo, 'profile_photo' => Photo, 'fallback_photo' => Photo, 'notify_settings' => PeerNotifySettings, 'bot_info' => BotInfo, 'pinned_msg_id' => int, 'common_chats_count' => int, 'folder_id' => int, 'ttl_period' => int, 'theme_emoticon' => 'string', 'private_forward_name' => 'string', 'bot_group_admin_rights' => ChatAdminRights, 'bot_broadcast_admin_rights' => ChatAdminRights, 'premium_gifts' => [PremiumGiftOption, PremiumGiftOption], 'wallpaper' => WallPaper, 'stories' => PeerStories, 'business_work_hours' => BusinessWorkHours, 'business_location' => BusinessLocation, 'business_greeting_message' => BusinessGreetingMessage, 'business_away_message' => BusinessAwayMessage, 'business_intro' => BusinessIntro, 'birthday' => Birthday, 'personal_channel_id' => long, 'personal_channel_message' => int]; +``` diff --git a/docs/API_docs/constructors/userProfilePhoto.md b/docs/API_docs/constructors/userProfilePhoto.md new file mode 100644 index 0000000000..9e623bf54b --- /dev/null +++ b/docs/API_docs/constructors/userProfilePhoto.md @@ -0,0 +1,33 @@ +--- +title: "userProfilePhoto" +description: "User profile photo." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userProfilePhoto +[Back to constructors index](/API_docs/constructors/index.html) + + + +User profile photo. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_video|[Bool](/API_docs/types/Bool.html) | Optional|Whether an [animated profile picture](https://core.telegram.org/api/files#animated-profile-pictures) is available for this user| +|personal|[Bool](/API_docs/types/Bool.html) | Optional|Whether this profile photo is only visible to us (i.e. it was set using [photos.uploadContactProfilePhoto](../methods/photos.uploadContactProfilePhoto.html)).| +|photo\_id|[long](/API_docs/types/long.html) | Yes|Identifier of the respective photo| +|stripped\_thumb|[bytes](/API_docs/types/bytes.html) | Optional|[Stripped thumbnail](https://core.telegram.org/api/files#stripped-thumbnails)| +|dc\_id|[int](/API_docs/types/int.html) | Yes|DC ID where the photo is stored| + + + +### Type: [UserProfilePhoto](/API_docs/types/UserProfilePhoto.html) + + +### Example: + +``` +$userProfilePhoto = ['_' => 'userProfilePhoto', 'has_video' => Bool, 'personal' => Bool, 'photo_id' => long, 'stripped_thumb' => 'bytes', 'dc_id' => int]; +``` diff --git a/docs/API_docs/constructors/userProfilePhotoEmpty.md b/docs/API_docs/constructors/userProfilePhotoEmpty.md new file mode 100644 index 0000000000..56aaf628a3 --- /dev/null +++ b/docs/API_docs/constructors/userProfilePhotoEmpty.md @@ -0,0 +1,24 @@ +--- +title: "userProfilePhotoEmpty" +description: "Profile photo has not been set, or was hidden." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userProfilePhotoEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +Profile photo has not been set, or was hidden. + + + + +### Type: [UserProfilePhoto](/API_docs/types/UserProfilePhoto.html) + + +### Example: + +``` +$userProfilePhotoEmpty = ['_' => 'userProfilePhotoEmpty']; +``` diff --git a/docs/API_docs/constructors/userStatusEmpty.md b/docs/API_docs/constructors/userStatusEmpty.md new file mode 100644 index 0000000000..2f5be5df28 --- /dev/null +++ b/docs/API_docs/constructors/userStatusEmpty.md @@ -0,0 +1,24 @@ +--- +title: "userStatusEmpty" +description: "User status has not been set yet." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userStatusEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +User status has not been set yet. + + + + +### Type: [UserStatus](/API_docs/types/UserStatus.html) + + +### Example: + +``` +$userStatusEmpty = ['_' => 'userStatusEmpty']; +``` diff --git a/docs/API_docs/constructors/userStatusLastMonth.md b/docs/API_docs/constructors/userStatusLastMonth.md new file mode 100644 index 0000000000..fdef7279bd --- /dev/null +++ b/docs/API_docs/constructors/userStatusLastMonth.md @@ -0,0 +1,29 @@ +--- +title: "userStatusLastMonth" +description: "Online status: last seen last month" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userStatusLastMonth +[Back to constructors index](/API_docs/constructors/index.html) + + + +Online status: last seen last month + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|by\_me|[Bool](/API_docs/types/Bool.html) | Optional| + + + +### Type: [UserStatus](/API_docs/types/UserStatus.html) + + +### Example: + +``` +$userStatusLastMonth = ['_' => 'userStatusLastMonth', 'by_me' => Bool]; +``` diff --git a/docs/API_docs/constructors/userStatusLastWeek.md b/docs/API_docs/constructors/userStatusLastWeek.md new file mode 100644 index 0000000000..30e950c156 --- /dev/null +++ b/docs/API_docs/constructors/userStatusLastWeek.md @@ -0,0 +1,29 @@ +--- +title: "userStatusLastWeek" +description: "Online status: last seen last week" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userStatusLastWeek +[Back to constructors index](/API_docs/constructors/index.html) + + + +Online status: last seen last week + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|by\_me|[Bool](/API_docs/types/Bool.html) | Optional| + + + +### Type: [UserStatus](/API_docs/types/UserStatus.html) + + +### Example: + +``` +$userStatusLastWeek = ['_' => 'userStatusLastWeek', 'by_me' => Bool]; +``` diff --git a/docs/API_docs/constructors/userStatusOffline.md b/docs/API_docs/constructors/userStatusOffline.md new file mode 100644 index 0000000000..af6597bf51 --- /dev/null +++ b/docs/API_docs/constructors/userStatusOffline.md @@ -0,0 +1,29 @@ +--- +title: "userStatusOffline" +description: "The user's offline status." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userStatusOffline +[Back to constructors index](/API_docs/constructors/index.html) + + + +The user's offline status. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|was\_online|[int](/API_docs/types/int.html) | Yes|Time the user was last seen online| + + + +### Type: [UserStatus](/API_docs/types/UserStatus.html) + + +### Example: + +``` +$userStatusOffline = ['_' => 'userStatusOffline', 'was_online' => int]; +``` diff --git a/docs/API_docs/constructors/userStatusOnline.md b/docs/API_docs/constructors/userStatusOnline.md new file mode 100644 index 0000000000..cfd01b6cda --- /dev/null +++ b/docs/API_docs/constructors/userStatusOnline.md @@ -0,0 +1,29 @@ +--- +title: "userStatusOnline" +description: "Online status of the user." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userStatusOnline +[Back to constructors index](/API_docs/constructors/index.html) + + + +Online status of the user. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|expires|[int](/API_docs/types/int.html) | Yes|Time to expiration of the current online status| + + + +### Type: [UserStatus](/API_docs/types/UserStatus.html) + + +### Example: + +``` +$userStatusOnline = ['_' => 'userStatusOnline', 'expires' => int]; +``` diff --git a/docs/API_docs/constructors/userStatusRecently.md b/docs/API_docs/constructors/userStatusRecently.md new file mode 100644 index 0000000000..2993de8cd9 --- /dev/null +++ b/docs/API_docs/constructors/userStatusRecently.md @@ -0,0 +1,29 @@ +--- +title: "userStatusRecently" +description: "Online status: last seen recently" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: userStatusRecently +[Back to constructors index](/API_docs/constructors/index.html) + + + +Online status: last seen recently + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|by\_me|[Bool](/API_docs/types/Bool.html) | Optional| + + + +### Type: [UserStatus](/API_docs/types/UserStatus.html) + + +### Example: + +``` +$userStatusRecently = ['_' => 'userStatusRecently', 'by_me' => Bool]; +``` diff --git a/docs/API_docs/constructors/username.md b/docs/API_docs/constructors/username.md new file mode 100644 index 0000000000..50d91a61e6 --- /dev/null +++ b/docs/API_docs/constructors/username.md @@ -0,0 +1,31 @@ +--- +title: "username" +description: "Contains information about a username." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: username +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains information about a username. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|editable|[Bool](/API_docs/types/Bool.html) | Optional|Whether the username is editable, meaning it wasn't bought on [fragment](https://fragment.com).| +|active|[Bool](/API_docs/types/Bool.html) | Optional|Whether the username is active.| +|username|[string](/API_docs/types/string.html) | Yes|The username.| + + + +### Type: [Username](/API_docs/types/Username.html) + + +### Example: + +``` +$username = ['_' => 'username', 'editable' => Bool, 'active' => Bool, 'username' => 'string']; +``` diff --git a/docs/API_docs/constructors/users.userFull.md b/docs/API_docs/constructors/users.userFull.md new file mode 100644 index 0000000000..5b07a59601 --- /dev/null +++ b/docs/API_docs/constructors/users.userFull.md @@ -0,0 +1,32 @@ +--- +title: "users.userFull" +description: "Full user information" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/constructors/users_userFull.html +--- +# Constructor: users.userFull +[Back to constructors index](/API_docs/constructors/index.html) + + + +Full user information + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|full\_user|[UserFull](/API_docs/types/UserFull.html) | Yes|Full user information| +|chats|Array of [Chat](/API_docs/types/Chat.html) | Yes|Mentioned chats| +|users|Array of [User](/API_docs/types/User.html) | Yes|Mentioned users| + + + +### Type: [users.UserFull](/API_docs/types/users.UserFull.html) + + +### Example: + +``` +$users_userFull = ['_' => 'users.userFull', 'full_user' => UserFull, 'chats' => [Chat, Chat], 'users' => [User, User]]; +``` diff --git a/docs/API_docs/constructors/videoSize.md b/docs/API_docs/constructors/videoSize.md new file mode 100644 index 0000000000..f7a97e0c8d --- /dev/null +++ b/docs/API_docs/constructors/videoSize.md @@ -0,0 +1,33 @@ +--- +title: "videoSize" +description: "An animated profile picture in MPEG4 format" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: videoSize +[Back to constructors index](/API_docs/constructors/index.html) + + + +An [animated profile picture](https://core.telegram.org/api/files#animated-profile-pictures) in MPEG4 format + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](/API_docs/types/string.html) | Yes|`u` for animated profile pictures, and `v` for trimmed and downscaled video previews| +|w|[int](/API_docs/types/int.html) | Yes|Video width| +|h|[int](/API_docs/types/int.html) | Yes|Video height| +|size|[int](/API_docs/types/int.html) | Yes|File size| +|video\_start\_ts|[double](/API_docs/types/double.html) | Optional|Timestamp that should be shown as static preview to the user (seconds)| + + + +### Type: [VideoSize](/API_docs/types/VideoSize.html) + + +### Example: + +``` +$videoSize = ['_' => 'videoSize', 'type' => 'string', 'w' => int, 'h' => int, 'size' => int, 'video_start_ts' => double]; +``` diff --git a/docs/API_docs/constructors/videoSizeEmojiMarkup.md b/docs/API_docs/constructors/videoSizeEmojiMarkup.md new file mode 100644 index 0000000000..b736d5944a --- /dev/null +++ b/docs/API_docs/constructors/videoSizeEmojiMarkup.md @@ -0,0 +1,30 @@ +--- +title: "videoSizeEmojiMarkup" +description: "An animated profile picture based on a custom emoji sticker." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: videoSizeEmojiMarkup +[Back to constructors index](/API_docs/constructors/index.html) + + + +An [animated profile picture](https://core.telegram.org/api/files#animated-profile-pictures) based on a [custom emoji sticker](https://core.telegram.org/api/custom-emoji). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|emoji\_id|[long](/API_docs/types/long.html) | Yes|[Custom emoji ID](https://core.telegram.org/api/custom-emoji): the custom emoji sticker is shown at the center of the profile picture and occupies at most 67% of it.| +|background\_colors|Array of [int](/API_docs/types/int.html) | Yes|1, 2, 3 or 4 RBG-24 colors used to generate a solid (1), gradient (2) or freeform gradient (3, 4) background, similar to how [fill wallpapers](https://core.telegram.org/api/wallpapers#fill-types) are generated. The rotation angle for gradient backgrounds is 0.| + + + +### Type: [VideoSize](/API_docs/types/VideoSize.html) + + +### Example: + +``` +$videoSizeEmojiMarkup = ['_' => 'videoSizeEmojiMarkup', 'emoji_id' => long, 'background_colors' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/videoSizeStickerMarkup.md b/docs/API_docs/constructors/videoSizeStickerMarkup.md new file mode 100644 index 0000000000..e3c0958c1b --- /dev/null +++ b/docs/API_docs/constructors/videoSizeStickerMarkup.md @@ -0,0 +1,31 @@ +--- +title: "videoSizeStickerMarkup" +description: "An animated profile picture based on a sticker." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: videoSizeStickerMarkup +[Back to constructors index](/API_docs/constructors/index.html) + + + +An [animated profile picture](https://core.telegram.org/api/files#animated-profile-pictures) based on a [sticker](https://core.telegram.org/api/stickers). + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional|Stickerset| +|sticker\_id|[long](/API_docs/types/long.html) | Yes|Sticker ID| +|background\_colors|Array of [int](/API_docs/types/int.html) | Yes|1, 2, 3 or 4 RBG-24 colors used to generate a solid (1), gradient (2) or freeform gradient (3, 4) background, similar to how [fill wallpapers](https://core.telegram.org/api/wallpapers#fill-types) are generated. The rotation angle for gradient backgrounds is 0.| + + + +### Type: [VideoSize](/API_docs/types/VideoSize.html) + + +### Example: + +``` +$videoSizeStickerMarkup = ['_' => 'videoSizeStickerMarkup', 'stickerset' => InputStickerSet, 'sticker_id' => long, 'background_colors' => [int, int]]; +``` diff --git a/docs/API_docs/constructors/wallPaper.md b/docs/API_docs/constructors/wallPaper.md new file mode 100644 index 0000000000..570e59a17a --- /dev/null +++ b/docs/API_docs/constructors/wallPaper.md @@ -0,0 +1,37 @@ +--- +title: "wallPaper" +description: "Represents a wallpaper based on an image." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: wallPaper +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [wallpaper](https://core.telegram.org/api/wallpapers) based on an image. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Identifier| +|creator|[Bool](/API_docs/types/Bool.html) | Optional|Whether we created this wallpaper| +|default|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is the default wallpaper| +|pattern|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is a [pattern wallpaper »](https://core.telegram.org/api/wallpapers#pattern-wallpapers)| +|dark|[Bool](/API_docs/types/Bool.html) | Optional|Whether this wallpaper should be used in dark mode.| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|slug|[string](/API_docs/types/string.html) | Yes|Unique wallpaper ID, used when generating [wallpaper links](https://core.telegram.org/api/links#wallpaper-links) or [importing wallpaper links](https://core.telegram.org/api/wallpapers).| +|document|[Document](/API_docs/types/Document.html) | Optional|The actual wallpaper| +|settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | Optional|Info on how to generate the wallpaper, according to [these instructions »](https://core.telegram.org/api/wallpapers).| + + + +### Type: [WallPaper](/API_docs/types/WallPaper.html) + + +### Example: + +``` +$wallPaper = ['_' => 'wallPaper', 'id' => long, 'creator' => Bool, 'default' => Bool, 'pattern' => Bool, 'dark' => Bool, 'access_hash' => long, 'slug' => 'string', 'document' => Document, 'settings' => WallPaperSettings]; +``` diff --git a/docs/API_docs/constructors/wallPaperNoFile.md b/docs/API_docs/constructors/wallPaperNoFile.md new file mode 100644 index 0000000000..bcb5c06661 --- /dev/null +++ b/docs/API_docs/constructors/wallPaperNoFile.md @@ -0,0 +1,32 @@ +--- +title: "wallPaperNoFile" +description: "Represents a wallpaper only based on colors/gradients." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: wallPaperNoFile +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a [wallpaper](https://core.telegram.org/api/wallpapers) only based on colors/gradients. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Wallpaper ID| +|default|[Bool](/API_docs/types/Bool.html) | Optional|Whether this is the default wallpaper| +|dark|[Bool](/API_docs/types/Bool.html) | Optional|Whether this wallpaper should be used in dark mode.| +|settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | Optional|Info on how to generate the wallpaper.| + + + +### Type: [WallPaper](/API_docs/types/WallPaper.html) + + +### Example: + +``` +$wallPaperNoFile = ['_' => 'wallPaperNoFile', 'id' => long, 'default' => Bool, 'dark' => Bool, 'settings' => WallPaperSettings]; +``` diff --git a/docs/API_docs/constructors/wallPaperSettings.md b/docs/API_docs/constructors/wallPaperSettings.md new file mode 100644 index 0000000000..cab98abb27 --- /dev/null +++ b/docs/API_docs/constructors/wallPaperSettings.md @@ -0,0 +1,37 @@ +--- +title: "wallPaperSettings" +description: "Wallpaper rendering information." +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: wallPaperSettings +[Back to constructors index](/API_docs/constructors/index.html) + + + +[Wallpaper](https://core.telegram.org/api/wallpapers) rendering information. + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|blur|[Bool](/API_docs/types/Bool.html) | Optional|For [image wallpapers »](https://core.telegram.org/api/wallpapers#image-wallpapers): if set, the JPEG must be downscaled to fit in 450x450 square and then box-blurred with radius 12.| +|motion|[Bool](/API_docs/types/Bool.html) | Optional|If set, the background needs to be slightly moved when the device is rotated.| +|background\_color|[int](/API_docs/types/int.html) | Optional|Used for [solid »](https://core.telegram.org/api/wallpapers#solid-fill), [gradient »](https://core.telegram.org/api/wallpapers#gradient-fill) and [freeform gradient »](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills.| +|second\_background\_color|[int](/API_docs/types/int.html) | Optional|Used for [gradient »](https://core.telegram.org/api/wallpapers#gradient-fill) and [freeform gradient »](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills.| +|third\_background\_color|[int](/API_docs/types/int.html) | Optional|Used for [freeform gradient »](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills.| +|fourth\_background\_color|[int](/API_docs/types/int.html) | Optional|Used for [freeform gradient »](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills.| +|intensity|[int](/API_docs/types/int.html) | Optional|Used for [pattern wallpapers »](https://core.telegram.org/api/wallpapers#pattern-wallpapers).| +|rotation|[int](/API_docs/types/int.html) | Optional|Clockwise rotation angle of the gradient, in degrees; 0-359. Should be always divisible by 45.| +|emoticon|[string](/API_docs/types/string.html) | Optional|If set, this wallpaper can be used as a channel wallpaper and is represented by the specified UTF-8 emoji.| + + + +### Type: [WallPaperSettings](/API_docs/types/WallPaperSettings.html) + + +### Example: + +``` +$wallPaperSettings = ['_' => 'wallPaperSettings', 'blur' => Bool, 'motion' => Bool, 'background_color' => int, 'second_background_color' => int, 'third_background_color' => int, 'fourth_background_color' => int, 'intensity' => int, 'rotation' => int, 'emoticon' => 'string']; +``` diff --git a/docs/API_docs/constructors/webAuthorization.md b/docs/API_docs/constructors/webAuthorization.md new file mode 100644 index 0000000000..a03e948171 --- /dev/null +++ b/docs/API_docs/constructors/webAuthorization.md @@ -0,0 +1,37 @@ +--- +title: "webAuthorization" +description: "Represents a bot logged in using the Telegram login widget" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webAuthorization +[Back to constructors index](/API_docs/constructors/index.html) + + + +Represents a bot logged in using the [Telegram login widget](https://core.telegram.org/widgets/login) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|hash|[long](/API_docs/types/long.html) | Yes|Authorization hash| +|bot\_id|[long](/API_docs/types/long.html) | Yes|Bot ID| +|domain|[string](/API_docs/types/string.html) | Yes|The domain name of the website on which the user has logged in.| +|browser|[string](/API_docs/types/string.html) | Yes|Browser user-agent| +|platform|[string](/API_docs/types/string.html) | Yes|Platform| +|date\_created|[int](/API_docs/types/int.html) | Yes|When was the web session created| +|date\_active|[int](/API_docs/types/int.html) | Yes|When was the web session last active| +|ip|[string](/API_docs/types/string.html) | Yes|IP address| +|region|[string](/API_docs/types/string.html) | Yes|Region, determined from IP address| + + + +### Type: [WebAuthorization](/API_docs/types/WebAuthorization.html) + + +### Example: + +``` +$webAuthorization = ['_' => 'webAuthorization', 'hash' => long, 'bot_id' => long, 'domain' => 'string', 'browser' => 'string', 'platform' => 'string', 'date_created' => int, 'date_active' => int, 'ip' => 'string', 'region' => 'string']; +``` diff --git a/docs/API_docs/constructors/webDocument.md b/docs/API_docs/constructors/webDocument.md new file mode 100644 index 0000000000..af460a978a --- /dev/null +++ b/docs/API_docs/constructors/webDocument.md @@ -0,0 +1,33 @@ +--- +title: "webDocument" +description: "Remote document" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webDocument +[Back to constructors index](/API_docs/constructors/index.html) + + + +Remote document + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Document URL| +|access\_hash|[long](/API_docs/types/long.html) | Yes|Access hash| +|size|[int](/API_docs/types/int.html) | Yes|File size| +|mime\_type|[string](/API_docs/types/string.html) | Yes|MIME type| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Attributes for media types| + + + +### Type: [WebDocument](/API_docs/types/WebDocument.html) + + +### Example: + +``` +$webDocument = ['_' => 'webDocument', 'url' => 'string', 'access_hash' => long, 'size' => int, 'mime_type' => 'string', 'attributes' => [DocumentAttribute, DocumentAttribute]]; +``` diff --git a/docs/API_docs/constructors/webDocumentNoProxy.md b/docs/API_docs/constructors/webDocumentNoProxy.md new file mode 100644 index 0000000000..0e261ab62c --- /dev/null +++ b/docs/API_docs/constructors/webDocumentNoProxy.md @@ -0,0 +1,32 @@ +--- +title: "webDocumentNoProxy" +description: "Remote document that can be downloaded without proxying through telegram" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webDocumentNoProxy +[Back to constructors index](/API_docs/constructors/index.html) + + + +Remote document that can be downloaded without [proxying through telegram](https://core.telegram.org/api/files) + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|url|[string](/API_docs/types/string.html) | Yes|Document URL| +|size|[int](/API_docs/types/int.html) | Yes|File size| +|mime\_type|[string](/API_docs/types/string.html) | Yes|MIME type| +|attributes|Array of [DocumentAttribute](/API_docs/types/DocumentAttribute.html) | Yes|Attributes for media types| + + + +### Type: [WebDocument](/API_docs/types/WebDocument.html) + + +### Example: + +``` +$webDocumentNoProxy = ['_' => 'webDocumentNoProxy', 'url' => 'string', 'size' => int, 'mime_type' => 'string', 'attributes' => [DocumentAttribute, DocumentAttribute]]; +``` diff --git a/docs/API_docs/constructors/webPage.md b/docs/API_docs/constructors/webPage.md new file mode 100644 index 0000000000..b3639261aa --- /dev/null +++ b/docs/API_docs/constructors/webPage.md @@ -0,0 +1,47 @@ +--- +title: "webPage" +description: "Webpage preview" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPage +[Back to constructors index](/API_docs/constructors/index.html) + + + +Webpage preview + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|has\_large\_media|[Bool](/API_docs/types/Bool.html) | Optional|Whether the size of the media in the preview can be changed.| +|id|[long](/API_docs/types/long.html) | Yes|Preview ID| +|url|[string](/API_docs/types/string.html) | Yes|URL of previewed webpage| +|display\_url|[string](/API_docs/types/string.html) | Yes|Webpage URL to be displayed to the user| +|hash|[int](/API_docs/types/int.html) | Yes| +|type|[string](/API_docs/types/string.html) | Optional|Type of the web page. Can be: article, photo, audio, video, document, profile, app, or something else| +|site\_name|[string](/API_docs/types/string.html) | Optional|Short name of the site (e.g., Google Docs, App Store)| +|title|[string](/API_docs/types/string.html) | Optional|Title of the content| +|description|[string](/API_docs/types/string.html) | Optional|Content description| +|photo|[Photo](/API_docs/types/Photo.html) | Optional|Image representing the content| +|embed\_url|[string](/API_docs/types/string.html) | Optional|URL to show in the embedded preview| +|embed\_type|[string](/API_docs/types/string.html) | Optional|MIME type of the embedded preview, (e.g., text/html or video/mp4)| +|embed\_width|[int](/API_docs/types/int.html) | Optional|Width of the embedded preview| +|embed\_height|[int](/API_docs/types/int.html) | Optional|Height of the embedded preview| +|duration|[int](/API_docs/types/int.html) | Optional|Duration of the content, in seconds| +|author|[string](/API_docs/types/string.html) | Optional|Author of the content| +|document|[Document](/API_docs/types/Document.html) | Optional|Preview of the content as a media file| +|cached\_page|[Page](/API_docs/types/Page.html) | Optional|Page contents in [instant view](https://instantview.telegram.org) format| +|attributes|Array of [WebPageAttribute](/API_docs/types/WebPageAttribute.html) | Optional|Webpage attributes| + + + +### Type: [WebPage](/API_docs/types/WebPage.html) + + +### Example: + +``` +$webPage = ['_' => 'webPage', 'has_large_media' => Bool, 'id' => long, 'url' => 'string', 'display_url' => 'string', 'hash' => int, 'type' => 'string', 'site_name' => 'string', 'title' => 'string', 'description' => 'string', 'photo' => Photo, 'embed_url' => 'string', 'embed_type' => 'string', 'embed_width' => int, 'embed_height' => int, 'duration' => int, 'author' => 'string', 'document' => Document, 'cached_page' => Page, 'attributes' => [WebPageAttribute, WebPageAttribute]]; +``` diff --git a/docs/API_docs/constructors/webPageAttributeStickerSet.md b/docs/API_docs/constructors/webPageAttributeStickerSet.md new file mode 100644 index 0000000000..7b29edc6d1 --- /dev/null +++ b/docs/API_docs/constructors/webPageAttributeStickerSet.md @@ -0,0 +1,29 @@ +--- +title: "webPageAttributeStickerSet" +description: "webPageAttributeStickerSet attributes, type and example" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPageAttributeStickerSet +[Back to constructors index](/API_docs/constructors/index.html) + + + +### Attributes: + +| Name | Type | Required | +|----------|---------------|----------| +|emojis|[Bool](/API_docs/types/Bool.html) | Optional| +|text\_color|[Bool](/API_docs/types/Bool.html) | Optional| +|stickers|Array of [Document](/API_docs/types/Document.html) | Yes| + + + +### Type: [WebPageAttribute](/API_docs/types/WebPageAttribute.html) + + +### Example: + +``` +$webPageAttributeStickerSet = ['_' => 'webPageAttributeStickerSet', 'emojis' => Bool, 'text_color' => Bool, 'stickers' => [Document, Document]]; +``` diff --git a/docs/API_docs/constructors/webPageAttributeStory.md b/docs/API_docs/constructors/webPageAttributeStory.md new file mode 100644 index 0000000000..5a461824ce --- /dev/null +++ b/docs/API_docs/constructors/webPageAttributeStory.md @@ -0,0 +1,31 @@ +--- +title: "webPageAttributeStory" +description: "Webpage preview of a Telegram story" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPageAttributeStory +[Back to constructors index](/API_docs/constructors/index.html) + + + +Webpage preview of a Telegram story + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|peer|[long](/API_docs/types/long.html) | Yes|Peer that posted the story| +|id|[int](/API_docs/types/int.html) | Yes|[Story ID](https://core.telegram.org/api/stories#watching-stories)| +|story|[StoryItem](/API_docs/types/StoryItem.html) | Optional|May contain the story, if not the story should be fetched when and if needed using [stories.getStoriesByID](../methods/stories.getStoriesByID.html) with the above `id` and `peer`.| + + + +### Type: [WebPageAttribute](/API_docs/types/WebPageAttribute.html) + + +### Example: + +``` +$webPageAttributeStory = ['_' => 'webPageAttributeStory', 'peer' => long, 'id' => int, 'story' => StoryItem]; +``` diff --git a/docs/API_docs/constructors/webPageAttributeTheme.md b/docs/API_docs/constructors/webPageAttributeTheme.md new file mode 100644 index 0000000000..657bffb64b --- /dev/null +++ b/docs/API_docs/constructors/webPageAttributeTheme.md @@ -0,0 +1,30 @@ +--- +title: "webPageAttributeTheme" +description: "Page theme" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPageAttributeTheme +[Back to constructors index](/API_docs/constructors/index.html) + + + +Page theme + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|documents|Array of [Document](/API_docs/types/Document.html) | Optional|Theme files| +|settings|[ThemeSettings](/API_docs/types/ThemeSettings.html) | Optional|Theme settings| + + + +### Type: [WebPageAttribute](/API_docs/types/WebPageAttribute.html) + + +### Example: + +``` +$webPageAttributeTheme = ['_' => 'webPageAttributeTheme', 'documents' => [Document, Document], 'settings' => ThemeSettings]; +``` diff --git a/docs/API_docs/constructors/webPageEmpty.md b/docs/API_docs/constructors/webPageEmpty.md new file mode 100644 index 0000000000..d909e2b0cf --- /dev/null +++ b/docs/API_docs/constructors/webPageEmpty.md @@ -0,0 +1,30 @@ +--- +title: "webPageEmpty" +description: "No preview is available for the webpage" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPageEmpty +[Back to constructors index](/API_docs/constructors/index.html) + + + +No preview is available for the webpage + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|Preview ID| +|url|[string](/API_docs/types/string.html) | Optional|URL of the webpage.| + + + +### Type: [WebPage](/API_docs/types/WebPage.html) + + +### Example: + +``` +$webPageEmpty = ['_' => 'webPageEmpty', 'id' => long, 'url' => 'string']; +``` diff --git a/docs/API_docs/constructors/webPageNotModified.md b/docs/API_docs/constructors/webPageNotModified.md new file mode 100644 index 0000000000..e520e5d510 --- /dev/null +++ b/docs/API_docs/constructors/webPageNotModified.md @@ -0,0 +1,29 @@ +--- +title: "webPageNotModified" +description: "The preview of the webpage hasn't changed" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPageNotModified +[Back to constructors index](/API_docs/constructors/index.html) + + + +The preview of the webpage hasn't changed + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|cached\_page\_views|[int](/API_docs/types/int.html) | Optional|Page view count| + + + +### Type: [WebPage](/API_docs/types/WebPage.html) + + +### Example: + +``` +$webPageNotModified = ['_' => 'webPageNotModified', 'cached_page_views' => int]; +``` diff --git a/docs/API_docs/constructors/webPagePending.md b/docs/API_docs/constructors/webPagePending.md new file mode 100644 index 0000000000..e4d5003bf3 --- /dev/null +++ b/docs/API_docs/constructors/webPagePending.md @@ -0,0 +1,31 @@ +--- +title: "webPagePending" +description: "A preview of the webpage is currently being generated" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webPagePending +[Back to constructors index](/API_docs/constructors/index.html) + + + +A preview of the webpage is currently being generated + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|id|[long](/API_docs/types/long.html) | Yes|ID of preview| +|url|[string](/API_docs/types/string.html) | Optional|URL of the webpage| +|date|[int](/API_docs/types/int.html) | Yes|When was the processing started| + + + +### Type: [WebPage](/API_docs/types/WebPage.html) + + +### Example: + +``` +$webPagePending = ['_' => 'webPagePending', 'id' => long, 'url' => 'string', 'date' => int]; +``` diff --git a/docs/API_docs/constructors/webViewMessageSent.md b/docs/API_docs/constructors/webViewMessageSent.md new file mode 100644 index 0000000000..a44b288eb0 --- /dev/null +++ b/docs/API_docs/constructors/webViewMessageSent.md @@ -0,0 +1,29 @@ +--- +title: "webViewMessageSent" +description: "Info about a sent inline webview message" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webViewMessageSent +[Back to constructors index](/API_docs/constructors/index.html) + + + +Info about a sent inline webview message + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|msg\_id|[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) | Optional|Message ID| + + + +### Type: [WebViewMessageSent](/API_docs/types/WebViewMessageSent.html) + + +### Example: + +``` +$webViewMessageSent = ['_' => 'webViewMessageSent', 'msg_id' => InputBotInlineMessageID]; +``` diff --git a/docs/API_docs/constructors/webViewResultUrl.md b/docs/API_docs/constructors/webViewResultUrl.md new file mode 100644 index 0000000000..61ee544c18 --- /dev/null +++ b/docs/API_docs/constructors/webViewResultUrl.md @@ -0,0 +1,30 @@ +--- +title: "webViewResultUrl" +description: "Contains the webview URL with appropriate theme and user info parameters added" +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: webViewResultUrl +[Back to constructors index](/API_docs/constructors/index.html) + + + +Contains the webview URL with appropriate theme and user info parameters added + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|query\_id|[long](/API_docs/types/long.html) | Yes|Webview session ID| +|url|[string](/API_docs/types/string.html) | Yes|Webview URL to open| + + + +### Type: [WebViewResult](/API_docs/types/WebViewResult.html) + + +### Example: + +``` +$webViewResultUrl = ['_' => 'webViewResultUrl', 'query_id' => long, 'url' => 'string']; +``` diff --git a/docs/API_docs/index.md b/docs/API_docs/index.md new file mode 100644 index 0000000000..5b2d01d4ec --- /dev/null +++ b/docs/API_docs/index.md @@ -0,0 +1,17 @@ +--- +title: "Telegram RPC API" +description: "MadelineProto API documentation (layer 179)" +has_children: true +has_toc: false +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Telegram RPC API + +[Back to main documentation](..) + + +[Methods](methods/) + +[Constructors](constructors/) + +[Types](types/) diff --git a/docs/API_docs/methods/account.acceptAuthorization.md b/docs/API_docs/methods/account.acceptAuthorization.md new file mode 100644 index 0000000000..28651edbc4 --- /dev/null +++ b/docs/API_docs/methods/account.acceptAuthorization.md @@ -0,0 +1,46 @@ +--- +title: "account.acceptAuthorization" +description: "Sends a Telegram Passport authorization form, effectively sharing data with the service" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_acceptAuthorization.html +--- +# Method: account.acceptAuthorization +[Back to methods index](index.html) + + + +Sends a Telegram Passport authorization form, effectively sharing data with the service + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot\_id|[long](/API_docs/types/long.html) | Bot ID | Yes| +|scope|[string](/API_docs/types/string.html) | Telegram Passport element types requested by the service | Optional| +|public\_key|[string](/API_docs/types/string.html) | Service's public key | Optional| +|value\_hashes|Array of [SecureValueHash](/API_docs/types/SecureValueHash.html) | Types of values sent and their hashes | Yes| +|credentials|[SecureCredentialsEncrypted](/API_docs/types/SecureCredentialsEncrypted.html) | Encrypted values | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->acceptAuthorization(bot_id: $long, scope: 'string', public_key: 'string', value_hashes: [$SecureValueHash, $SecureValueHash], credentials: $SecureCredentialsEncrypted, ); +``` + diff --git a/docs/API_docs/methods/account.cancelPasswordEmail.md b/docs/API_docs/methods/account.cancelPasswordEmail.md new file mode 100644 index 0000000000..6aa0af0cf6 --- /dev/null +++ b/docs/API_docs/methods/account.cancelPasswordEmail.md @@ -0,0 +1,37 @@ +--- +title: "account.cancelPasswordEmail" +description: "Cancel the code that was sent to verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_cancelPasswordEmail.html +--- +# Method: account.cancelPasswordEmail +[Back to methods index](index.html) + + + +Cancel the code that was sent to verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp). + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->cancelPasswordEmail(); +``` + diff --git a/docs/API_docs/methods/account.changeAuthorizationSettings.md b/docs/API_docs/methods/account.changeAuthorizationSettings.md new file mode 100644 index 0000000000..9ca5bf1d41 --- /dev/null +++ b/docs/API_docs/methods/account.changeAuthorizationSettings.md @@ -0,0 +1,45 @@ +--- +title: "account.changeAuthorizationSettings" +description: "Change settings related to a session." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_changeAuthorizationSettings.html +--- +# Method: account.changeAuthorizationSettings +[Back to methods index](index.html) + + + +Change settings related to a session. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|confirmed|[Bool](/API_docs/types/Bool.html) | If set, [confirms a newly logged in session »](https://core.telegram.org/api/auth#confirming-login). | Optional| +|hash|Array of [long](/API_docs/types/long.html) | Session ID from the [authorization](../constructors/authorization.html) constructor, fetchable using [account.getAuthorizations](../methods/account.getAuthorizations.html) | Optional| +|encrypted\_requests\_disabled|[Bool](/API_docs/types/Bool.html) | Whether to enable or disable receiving encrypted chats: if the flag is not set, the previous setting is not changed | Optional| +|call\_requests\_disabled|[Bool](/API_docs/types/Bool.html) | Whether to enable or disable receiving calls: if the flag is not set, the previous setting is not changed | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->changeAuthorizationSettings(confirmed: $Bool, hash: [$long, $long], encrypted_requests_disabled: $Bool, call_requests_disabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.changePhone.md b/docs/API_docs/methods/account.changePhone.md new file mode 100644 index 0000000000..26e0863bb5 --- /dev/null +++ b/docs/API_docs/methods/account.changePhone.md @@ -0,0 +1,44 @@ +--- +title: "account.changePhone" +description: "Change the phone number of the current account" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_changePhone.html +--- +# Method: account.changePhone +[Back to methods index](index.html) + + + +Change the phone number of the current account + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | New phone number | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Phone code hash received when calling [account.sendChangePhoneCode](../methods/account.sendChangePhoneCode.html) | Optional| +|phone\_code|[string](/API_docs/types/string.html) | Phone code received when calling [account.sendChangePhoneCode](../methods/account.sendChangePhoneCode.html) | Optional| + + +### Return type: [User](/API_docs/types/User.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$User = $MadelineProto->account->changePhone(phone_number: 'string', phone_code_hash: 'string', phone_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.checkUsername.md b/docs/API_docs/methods/account.checkUsername.md new file mode 100644 index 0000000000..6a5b5e8906 --- /dev/null +++ b/docs/API_docs/methods/account.checkUsername.md @@ -0,0 +1,42 @@ +--- +title: "account.checkUsername" +description: "Validates a username and checks availability." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_checkUsername.html +--- +# Method: account.checkUsername +[Back to methods index](index.html) + + + +Validates a username and checks availability. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|username|[string](/API_docs/types/string.html) | username
Accepted characters: A-z (case-insensitive), 0-9 and underscores.
Length: 5-32 characters. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->checkUsername(username: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.clearRecentEmojiStatuses.md b/docs/API_docs/methods/account.clearRecentEmojiStatuses.md new file mode 100644 index 0000000000..4d7834b6e7 --- /dev/null +++ b/docs/API_docs/methods/account.clearRecentEmojiStatuses.md @@ -0,0 +1,37 @@ +--- +title: "account.clearRecentEmojiStatuses" +description: "Clears list of recently used [emoji statuses](https://core.telegram.org/api/emoji-status)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_clearRecentEmojiStatuses.html +--- +# Method: account.clearRecentEmojiStatuses +[Back to methods index](index.html) + + + +Clears list of recently used [emoji statuses](https://core.telegram.org/api/emoji-status) + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->clearRecentEmojiStatuses(); +``` + diff --git a/docs/API_docs/methods/account.confirmPasswordEmail.md b/docs/API_docs/methods/account.confirmPasswordEmail.md new file mode 100644 index 0000000000..67e693a4ff --- /dev/null +++ b/docs/API_docs/methods/account.confirmPasswordEmail.md @@ -0,0 +1,42 @@ +--- +title: "account.confirmPasswordEmail" +description: "Verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_confirmPasswordEmail.html +--- +# Method: account.confirmPasswordEmail +[Back to methods index](index.html) + + + +Verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|code|[string](/API_docs/types/string.html) | The phone code that was received after [setting a recovery email](https://core.telegram.org/api/srp#email-verification) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->confirmPasswordEmail(code: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.confirmPhone.md b/docs/API_docs/methods/account.confirmPhone.md new file mode 100644 index 0000000000..8b31086630 --- /dev/null +++ b/docs/API_docs/methods/account.confirmPhone.md @@ -0,0 +1,43 @@ +--- +title: "account.confirmPhone" +description: "Confirm a phone number to cancel account deletion, for more info [click here »](https://core.telegram.org/api/account-deletion)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_confirmPhone.html +--- +# Method: account.confirmPhone +[Back to methods index](index.html) + + + +Confirm a phone number to cancel account deletion, for more info [click here »](https://core.telegram.org/api/account-deletion) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Phone code hash, for more info [click here »](https://core.telegram.org/api/account-deletion) | Optional| +|phone\_code|[string](/API_docs/types/string.html) | SMS code, for more info [click here »](https://core.telegram.org/api/account-deletion) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->confirmPhone(phone_code_hash: 'string', phone_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.createBusinessChatLink.md b/docs/API_docs/methods/account.createBusinessChatLink.md new file mode 100644 index 0000000000..0fabff1743 --- /dev/null +++ b/docs/API_docs/methods/account.createBusinessChatLink.md @@ -0,0 +1,40 @@ +--- +title: "account.createBusinessChatLink" +description: "account.createBusinessChatLink parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_createBusinessChatLink.html +--- +# Method: account.createBusinessChatLink +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|link|[InputBusinessChatLink](/API_docs/types/InputBusinessChatLink.html) | Yes| + + +### Return type: [BusinessChatLink](/API_docs/types/BusinessChatLink.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$BusinessChatLink = $MadelineProto->account->createBusinessChatLink(link: $InputBusinessChatLink, ); +``` + diff --git a/docs/API_docs/methods/account.createTheme.md b/docs/API_docs/methods/account.createTheme.md new file mode 100644 index 0000000000..1474aac876 --- /dev/null +++ b/docs/API_docs/methods/account.createTheme.md @@ -0,0 +1,45 @@ +--- +title: "account.createTheme" +description: "Create a theme" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_createTheme.html +--- +# Method: account.createTheme +[Back to methods index](index.html) + + + +Create a theme + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|slug|[string](/API_docs/types/string.html) | Unique theme ID used to generate [theme deep links](https://core.telegram.org/api/links#theme-links), can be empty to autogenerate a random ID. | Optional| +|title|[string](/API_docs/types/string.html) | Theme name | Optional| +|document|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Theme file | Optional| +|settings|Array of [InputThemeSettings](/API_docs/types/InputThemeSettings.html) | Theme settings, multiple values can be provided for the different base themes (day/night mode, etc). | Optional| + + +### Return type: [Theme](/API_docs/types/Theme.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Theme = $MadelineProto->account->createTheme(slug: 'string', title: 'string', document: $InputDocument, settings: [$InputThemeSettings, $InputThemeSettings], ); +``` + diff --git a/docs/API_docs/methods/account.declinePasswordReset.md b/docs/API_docs/methods/account.declinePasswordReset.md new file mode 100644 index 0000000000..014a692ece --- /dev/null +++ b/docs/API_docs/methods/account.declinePasswordReset.md @@ -0,0 +1,37 @@ +--- +title: "account.declinePasswordReset" +description: "Abort a pending 2FA password reset, [see here for more info »](https://core.telegram.org/api/srp#password-reset)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_declinePasswordReset.html +--- +# Method: account.declinePasswordReset +[Back to methods index](index.html) + + + +Abort a pending 2FA password reset, [see here for more info »](https://core.telegram.org/api/srp#password-reset) + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->declinePasswordReset(); +``` + diff --git a/docs/API_docs/methods/account.deleteAccount.md b/docs/API_docs/methods/account.deleteAccount.md new file mode 100644 index 0000000000..74eb6b4007 --- /dev/null +++ b/docs/API_docs/methods/account.deleteAccount.md @@ -0,0 +1,45 @@ +--- +title: "account.deleteAccount" +description: "Delete the user's account from the telegram servers." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_deleteAccount.html +--- +# Method: account.deleteAccount +[Back to methods index](index.html) + + + +Delete the user's account from the telegram servers. + +Can also be used to delete the account of a user that provided the login code, but forgot the 2FA password and no recovery method is configured, see [here »](https://core.telegram.org/api/srp#password-recovery) for more info on password recovery, and [here »](https://core.telegram.org/api/account-deletion) for more info on account deletion. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|reason|[string](/API_docs/types/string.html) | Why is the account being deleted, can be empty | Optional| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | [2FA password](https://core.telegram.org/api/srp): this field can be omitted even for accounts with 2FA enabled: in this case account account deletion will be delayed by 7 days [as specified in the docs »](https://core.telegram.org/api/account-deletion) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->deleteAccount(reason: 'string', password: $InputCheckPasswordSRP, ); +``` + diff --git a/docs/API_docs/methods/account.deleteAutoSaveExceptions.md b/docs/API_docs/methods/account.deleteAutoSaveExceptions.md new file mode 100644 index 0000000000..920e25552d --- /dev/null +++ b/docs/API_docs/methods/account.deleteAutoSaveExceptions.md @@ -0,0 +1,37 @@ +--- +title: "account.deleteAutoSaveExceptions" +description: "Clear all peer-specific autosave settings." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_deleteAutoSaveExceptions.html +--- +# Method: account.deleteAutoSaveExceptions +[Back to methods index](index.html) + + + +Clear all peer-specific autosave settings. + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->deleteAutoSaveExceptions(); +``` + diff --git a/docs/API_docs/methods/account.deleteBusinessChatLink.md b/docs/API_docs/methods/account.deleteBusinessChatLink.md new file mode 100644 index 0000000000..5600e6af98 --- /dev/null +++ b/docs/API_docs/methods/account.deleteBusinessChatLink.md @@ -0,0 +1,40 @@ +--- +title: "account.deleteBusinessChatLink" +description: "account.deleteBusinessChatLink parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_deleteBusinessChatLink.html +--- +# Method: account.deleteBusinessChatLink +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|slug|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->deleteBusinessChatLink(slug: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.deleteSecureValue.md b/docs/API_docs/methods/account.deleteSecureValue.md new file mode 100644 index 0000000000..023892a478 --- /dev/null +++ b/docs/API_docs/methods/account.deleteSecureValue.md @@ -0,0 +1,42 @@ +--- +title: "account.deleteSecureValue" +description: "Delete stored [Telegram Passport](https://core.telegram.org/passport) documents, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_deleteSecureValue.html +--- +# Method: account.deleteSecureValue +[Back to methods index](index.html) + + + +Delete stored [Telegram Passport](https://core.telegram.org/passport) documents, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|types|Array of [SecureValueType](/API_docs/types/SecureValueType.html) | Document types to delete | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->deleteSecureValue(types: [$SecureValueType, $SecureValueType], ); +``` + diff --git a/docs/API_docs/methods/account.disablePeerConnectedBot.md b/docs/API_docs/methods/account.disablePeerConnectedBot.md new file mode 100644 index 0000000000..5d24b2168d --- /dev/null +++ b/docs/API_docs/methods/account.disablePeerConnectedBot.md @@ -0,0 +1,40 @@ +--- +title: "account.disablePeerConnectedBot" +description: "account.disablePeerConnectedBot parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_disablePeerConnectedBot.html +--- +# Method: account.disablePeerConnectedBot +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->disablePeerConnectedBot(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/account.editBusinessChatLink.md b/docs/API_docs/methods/account.editBusinessChatLink.md new file mode 100644 index 0000000000..aa8bf66e3f --- /dev/null +++ b/docs/API_docs/methods/account.editBusinessChatLink.md @@ -0,0 +1,41 @@ +--- +title: "account.editBusinessChatLink" +description: "account.editBusinessChatLink parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_editBusinessChatLink.html +--- +# Method: account.editBusinessChatLink +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|slug|[string](/API_docs/types/string.html) | Optional| +|link|[InputBusinessChatLink](/API_docs/types/InputBusinessChatLink.html) | Yes| + + +### Return type: [BusinessChatLink](/API_docs/types/BusinessChatLink.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$BusinessChatLink = $MadelineProto->account->editBusinessChatLink(slug: 'string', link: $InputBusinessChatLink, ); +``` + diff --git a/docs/API_docs/methods/account.finishTakeoutSession.md b/docs/API_docs/methods/account.finishTakeoutSession.md new file mode 100644 index 0000000000..c988cbbcdb --- /dev/null +++ b/docs/API_docs/methods/account.finishTakeoutSession.md @@ -0,0 +1,42 @@ +--- +title: "account.finishTakeoutSession" +description: "Terminate a [takeout session, see here » for more info](https://core.telegram.org/api/takeout)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_finishTakeoutSession.html +--- +# Method: account.finishTakeoutSession +[Back to methods index](index.html) + + + +Terminate a [takeout session, see here » for more info](https://core.telegram.org/api/takeout). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|success|[Bool](/API_docs/types/Bool.html) | Data exported successfully | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->finishTakeoutSession(success: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.getAccountTTL.md b/docs/API_docs/methods/account.getAccountTTL.md new file mode 100644 index 0000000000..3838bfb2d8 --- /dev/null +++ b/docs/API_docs/methods/account.getAccountTTL.md @@ -0,0 +1,37 @@ +--- +title: "account.getAccountTTL" +description: "Get days to live of account" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getAccountTTL.html +--- +# Method: account.getAccountTTL +[Back to methods index](index.html) + + + +Get days to live of account + + + +### Return type: [AccountDaysTTL](/API_docs/types/AccountDaysTTL.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$AccountDaysTTL = $MadelineProto->account->getAccountTTL(); +``` + diff --git a/docs/API_docs/methods/account.getAllSecureValues.md b/docs/API_docs/methods/account.getAllSecureValues.md new file mode 100644 index 0000000000..7f95f649a6 --- /dev/null +++ b/docs/API_docs/methods/account.getAllSecureValues.md @@ -0,0 +1,37 @@ +--- +title: "account.getAllSecureValues" +description: "Get all saved [Telegram Passport](https://core.telegram.org/passport) documents, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getAllSecureValues.html +--- +# Method: account.getAllSecureValues +[Back to methods index](index.html) + + + +Get all saved [Telegram Passport](https://core.telegram.org/passport) documents, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) + + + +### Return type: [Vector\_of\_SecureValue](/API_docs/types/SecureValue.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_SecureValue = $MadelineProto->account->getAllSecureValues(); +``` + diff --git a/docs/API_docs/methods/account.getAuthorizationForm.md b/docs/API_docs/methods/account.getAuthorizationForm.md new file mode 100644 index 0000000000..1393098d4b --- /dev/null +++ b/docs/API_docs/methods/account.getAuthorizationForm.md @@ -0,0 +1,44 @@ +--- +title: "account.getAuthorizationForm" +description: "Returns a Telegram Passport authorization form for sharing data with a service" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getAuthorizationForm.html +--- +# Method: account.getAuthorizationForm +[Back to methods index](index.html) + + + +Returns a Telegram Passport authorization form for sharing data with a service + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot\_id|[long](/API_docs/types/long.html) | User identifier of the service's bot | Yes| +|scope|[string](/API_docs/types/string.html) | Telegram Passport element types requested by the service | Optional| +|public\_key|[string](/API_docs/types/string.html) | Service's public key | Optional| + + +### Return type: [account.AuthorizationForm](/API_docs/types/account.AuthorizationForm.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_AuthorizationForm = $MadelineProto->account->getAuthorizationForm(bot_id: $long, scope: 'string', public_key: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.getAuthorizations.md b/docs/API_docs/methods/account.getAuthorizations.md new file mode 100644 index 0000000000..1ce320dd2c --- /dev/null +++ b/docs/API_docs/methods/account.getAuthorizations.md @@ -0,0 +1,37 @@ +--- +title: "account.getAuthorizations" +description: "Get logged-in sessions" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getAuthorizations.html +--- +# Method: account.getAuthorizations +[Back to methods index](index.html) + + + +Get logged-in sessions + + + +### Return type: [account.Authorizations](/API_docs/types/account.Authorizations.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_Authorizations = $MadelineProto->account->getAuthorizations(); +``` + diff --git a/docs/API_docs/methods/account.getAutoDownloadSettings.md b/docs/API_docs/methods/account.getAutoDownloadSettings.md new file mode 100644 index 0000000000..8a928005dc --- /dev/null +++ b/docs/API_docs/methods/account.getAutoDownloadSettings.md @@ -0,0 +1,37 @@ +--- +title: "account.getAutoDownloadSettings" +description: "Get media autodownload settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getAutoDownloadSettings.html +--- +# Method: account.getAutoDownloadSettings +[Back to methods index](index.html) + + + +Get media autodownload settings + + + +### Return type: [account.AutoDownloadSettings](/API_docs/types/account.AutoDownloadSettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_AutoDownloadSettings = $MadelineProto->account->getAutoDownloadSettings(); +``` + diff --git a/docs/API_docs/methods/account.getAutoSaveSettings.md b/docs/API_docs/methods/account.getAutoSaveSettings.md new file mode 100644 index 0000000000..659b39810c --- /dev/null +++ b/docs/API_docs/methods/account.getAutoSaveSettings.md @@ -0,0 +1,37 @@ +--- +title: "account.getAutoSaveSettings" +description: "Get autosave settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getAutoSaveSettings.html +--- +# Method: account.getAutoSaveSettings +[Back to methods index](index.html) + + + +Get autosave settings + + + +### Return type: [account.AutoSaveSettings](/API_docs/types/account.AutoSaveSettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_AutoSaveSettings = $MadelineProto->account->getAutoSaveSettings(); +``` + diff --git a/docs/API_docs/methods/account.getBotBusinessConnection.md b/docs/API_docs/methods/account.getBotBusinessConnection.md new file mode 100644 index 0000000000..525e416776 --- /dev/null +++ b/docs/API_docs/methods/account.getBotBusinessConnection.md @@ -0,0 +1,40 @@ +--- +title: "account.getBotBusinessConnection" +description: "account.getBotBusinessConnection parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getBotBusinessConnection.html +--- +# Method: account.getBotBusinessConnection +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|connection\_id|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->account->getBotBusinessConnection(connection_id: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.getBusinessChatLinks.md b/docs/API_docs/methods/account.getBusinessChatLinks.md new file mode 100644 index 0000000000..5f195fdae3 --- /dev/null +++ b/docs/API_docs/methods/account.getBusinessChatLinks.md @@ -0,0 +1,35 @@ +--- +title: "account.getBusinessChatLinks" +description: "account.getBusinessChatLinks parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getBusinessChatLinks.html +--- +# Method: account.getBusinessChatLinks +[Back to methods index](index.html) + + + + + +### Return type: [account.BusinessChatLinks](/API_docs/types/account.BusinessChatLinks.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_BusinessChatLinks = $MadelineProto->account->getBusinessChatLinks(); +``` + diff --git a/docs/API_docs/methods/account.getChannelDefaultEmojiStatuses.md b/docs/API_docs/methods/account.getChannelDefaultEmojiStatuses.md new file mode 100644 index 0000000000..054113f043 --- /dev/null +++ b/docs/API_docs/methods/account.getChannelDefaultEmojiStatuses.md @@ -0,0 +1,42 @@ +--- +title: "account.getChannelDefaultEmojiStatuses" +description: "Get a list of default suggested [channel emoji statuses](https://core.telegram.org/api/emoji-status)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getChannelDefaultEmojiStatuses.html +--- +# Method: account.getChannelDefaultEmojiStatuses +[Back to methods index](index.html) + + + +Get a list of default suggested [channel emoji statuses](https://core.telegram.org/api/emoji-status). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_EmojiStatuses = $MadelineProto->account->getChannelDefaultEmojiStatuses(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getChannelRestrictedStatusEmojis.md b/docs/API_docs/methods/account.getChannelRestrictedStatusEmojis.md new file mode 100644 index 0000000000..42fcd6e89d --- /dev/null +++ b/docs/API_docs/methods/account.getChannelRestrictedStatusEmojis.md @@ -0,0 +1,42 @@ +--- +title: "account.getChannelRestrictedStatusEmojis" +description: "Returns fetch the full list of [custom emoji IDs »](https://core.telegram.org/api/custom-emoji) that cannot be used in [channel emoji statuses »](https://core.telegram.org/api/emoji-status)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getChannelRestrictedStatusEmojis.html +--- +# Method: account.getChannelRestrictedStatusEmojis +[Back to methods index](index.html) + + + +Returns fetch the full list of [custom emoji IDs »](https://core.telegram.org/api/custom-emoji) that cannot be used in [channel emoji statuses »](https://core.telegram.org/api/emoji-status). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [EmojiList](/API_docs/types/EmojiList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiList = $MadelineProto->account->getChannelRestrictedStatusEmojis(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getChatThemes.md b/docs/API_docs/methods/account.getChatThemes.md new file mode 100644 index 0000000000..7fd977b357 --- /dev/null +++ b/docs/API_docs/methods/account.getChatThemes.md @@ -0,0 +1,42 @@ +--- +title: "account.getChatThemes" +description: "Get all available chat [themes »](https://core.telegram.org/api/themes)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getChatThemes.html +--- +# Method: account.getChatThemes +[Back to methods index](index.html) + + + +Get all available chat [themes »](https://core.telegram.org/api/themes). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.Themes](/API_docs/types/account.Themes.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_Themes = $MadelineProto->account->getChatThemes(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getConnectedBots.md b/docs/API_docs/methods/account.getConnectedBots.md new file mode 100644 index 0000000000..6aa0cab326 --- /dev/null +++ b/docs/API_docs/methods/account.getConnectedBots.md @@ -0,0 +1,35 @@ +--- +title: "account.getConnectedBots" +description: "account.getConnectedBots parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getConnectedBots.html +--- +# Method: account.getConnectedBots +[Back to methods index](index.html) + + + + + +### Return type: [account.ConnectedBots](/API_docs/types/account.ConnectedBots.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_ConnectedBots = $MadelineProto->account->getConnectedBots(); +``` + diff --git a/docs/API_docs/methods/account.getContactSignUpNotification.md b/docs/API_docs/methods/account.getContactSignUpNotification.md new file mode 100644 index 0000000000..af4e2e363c --- /dev/null +++ b/docs/API_docs/methods/account.getContactSignUpNotification.md @@ -0,0 +1,37 @@ +--- +title: "account.getContactSignUpNotification" +description: "Whether the user will receive notifications when contacts sign up" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getContactSignUpNotification.html +--- +# Method: account.getContactSignUpNotification +[Back to methods index](index.html) + + + +Whether the user will receive notifications when contacts sign up + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->getContactSignUpNotification(); +``` + diff --git a/docs/API_docs/methods/account.getContentSettings.md b/docs/API_docs/methods/account.getContentSettings.md new file mode 100644 index 0000000000..31681d6292 --- /dev/null +++ b/docs/API_docs/methods/account.getContentSettings.md @@ -0,0 +1,37 @@ +--- +title: "account.getContentSettings" +description: "Get sensitive content settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getContentSettings.html +--- +# Method: account.getContentSettings +[Back to methods index](index.html) + + + +Get sensitive content settings + + + +### Return type: [account.ContentSettings](/API_docs/types/account.ContentSettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_ContentSettings = $MadelineProto->account->getContentSettings(); +``` + diff --git a/docs/API_docs/methods/account.getDefaultBackgroundEmojis.md b/docs/API_docs/methods/account.getDefaultBackgroundEmojis.md new file mode 100644 index 0000000000..65edc03fb1 --- /dev/null +++ b/docs/API_docs/methods/account.getDefaultBackgroundEmojis.md @@ -0,0 +1,42 @@ +--- +title: "account.getDefaultBackgroundEmojis" +description: "Get a set of suggested [custom emoji stickers](https://core.telegram.org/api/custom-emoji) that can be used in an [accent color pattern](https://core.telegram.org/api/colors)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getDefaultBackgroundEmojis.html +--- +# Method: account.getDefaultBackgroundEmojis +[Back to methods index](index.html) + + + +Get a set of suggested [custom emoji stickers](https://core.telegram.org/api/custom-emoji) that can be used in an [accent color pattern](https://core.telegram.org/api/colors). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [EmojiList](/API_docs/types/EmojiList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiList = $MadelineProto->account->getDefaultBackgroundEmojis(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getDefaultEmojiStatuses.md b/docs/API_docs/methods/account.getDefaultEmojiStatuses.md new file mode 100644 index 0000000000..cf938407a3 --- /dev/null +++ b/docs/API_docs/methods/account.getDefaultEmojiStatuses.md @@ -0,0 +1,42 @@ +--- +title: "account.getDefaultEmojiStatuses" +description: "Get a list of default suggested [emoji statuses](https://core.telegram.org/api/emoji-status)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getDefaultEmojiStatuses.html +--- +# Method: account.getDefaultEmojiStatuses +[Back to methods index](index.html) + + + +Get a list of default suggested [emoji statuses](https://core.telegram.org/api/emoji-status) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_EmojiStatuses = $MadelineProto->account->getDefaultEmojiStatuses(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getDefaultGroupPhotoEmojis.md b/docs/API_docs/methods/account.getDefaultGroupPhotoEmojis.md new file mode 100644 index 0000000000..dfb57ec3af --- /dev/null +++ b/docs/API_docs/methods/account.getDefaultGroupPhotoEmojis.md @@ -0,0 +1,42 @@ +--- +title: "account.getDefaultGroupPhotoEmojis" +description: "Get a set of suggested [custom emoji stickers](https://core.telegram.org/api/custom-emoji) that can be [used as group picture](https://core.telegram.org/api/files#sticker-profile-pictures)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getDefaultGroupPhotoEmojis.html +--- +# Method: account.getDefaultGroupPhotoEmojis +[Back to methods index](index.html) + + + +Get a set of suggested [custom emoji stickers](https://core.telegram.org/api/custom-emoji) that can be [used as group picture](https://core.telegram.org/api/files#sticker-profile-pictures) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [EmojiList](/API_docs/types/EmojiList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiList = $MadelineProto->account->getDefaultGroupPhotoEmojis(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getDefaultProfilePhotoEmojis.md b/docs/API_docs/methods/account.getDefaultProfilePhotoEmojis.md new file mode 100644 index 0000000000..68a0f3114d --- /dev/null +++ b/docs/API_docs/methods/account.getDefaultProfilePhotoEmojis.md @@ -0,0 +1,42 @@ +--- +title: "account.getDefaultProfilePhotoEmojis" +description: "Get a set of suggested [custom emoji stickers](https://core.telegram.org/api/custom-emoji) that can be [used as profile picture](https://core.telegram.org/api/files#sticker-profile-pictures)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getDefaultProfilePhotoEmojis.html +--- +# Method: account.getDefaultProfilePhotoEmojis +[Back to methods index](index.html) + + + +Get a set of suggested [custom emoji stickers](https://core.telegram.org/api/custom-emoji) that can be [used as profile picture](https://core.telegram.org/api/files#sticker-profile-pictures) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [EmojiList](/API_docs/types/EmojiList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiList = $MadelineProto->account->getDefaultProfilePhotoEmojis(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getGlobalPrivacySettings.md b/docs/API_docs/methods/account.getGlobalPrivacySettings.md new file mode 100644 index 0000000000..680b787b6f --- /dev/null +++ b/docs/API_docs/methods/account.getGlobalPrivacySettings.md @@ -0,0 +1,37 @@ +--- +title: "account.getGlobalPrivacySettings" +description: "Get global privacy settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getGlobalPrivacySettings.html +--- +# Method: account.getGlobalPrivacySettings +[Back to methods index](index.html) + + + +Get global privacy settings + + + +### Return type: [GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$GlobalPrivacySettings = $MadelineProto->account->getGlobalPrivacySettings(); +``` + diff --git a/docs/API_docs/methods/account.getMultiWallPapers.md b/docs/API_docs/methods/account.getMultiWallPapers.md new file mode 100644 index 0000000000..feaed6ae1d --- /dev/null +++ b/docs/API_docs/methods/account.getMultiWallPapers.md @@ -0,0 +1,42 @@ +--- +title: "account.getMultiWallPapers" +description: "Get info about multiple [wallpapers](https://core.telegram.org/api/wallpapers)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getMultiWallPapers.html +--- +# Method: account.getMultiWallPapers +[Back to methods index](index.html) + + + +Get info about multiple [wallpapers](https://core.telegram.org/api/wallpapers) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|wallpapers|Array of [InputWallPaper](/API_docs/types/InputWallPaper.html) | [Wallpapers](https://core.telegram.org/api/wallpapers) to fetch info about | Yes| + + +### Return type: [Vector\_of\_WallPaper](/API_docs/types/WallPaper.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_WallPaper = $MadelineProto->account->getMultiWallPapers(wallpapers: [$InputWallPaper, $InputWallPaper], ); +``` + diff --git a/docs/API_docs/methods/account.getNotifyExceptions.md b/docs/API_docs/methods/account.getNotifyExceptions.md new file mode 100644 index 0000000000..0be1c170e4 --- /dev/null +++ b/docs/API_docs/methods/account.getNotifyExceptions.md @@ -0,0 +1,44 @@ +--- +title: "account.getNotifyExceptions" +description: "Returns list of chats with non-default notification settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getNotifyExceptions.html +--- +# Method: account.getNotifyExceptions +[Back to methods index](index.html) + + + +Returns list of chats with non-default notification settings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|compare\_sound|[Bool](/API_docs/types/Bool.html) | If set, chats with non-default sound will be returned | Optional| +|compare\_stories|[Bool](/API_docs/types/Bool.html) | If set, chats with non-default notification settings for stories will be returned | Optional| +|peer|[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) | If specified, only chats of the specified category will be returned | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->account->getNotifyExceptions(compare_sound: $Bool, compare_stories: $Bool, peer: $InputNotifyPeer, ); +``` + diff --git a/docs/API_docs/methods/account.getNotifySettings.md b/docs/API_docs/methods/account.getNotifySettings.md new file mode 100644 index 0000000000..82e19e469b --- /dev/null +++ b/docs/API_docs/methods/account.getNotifySettings.md @@ -0,0 +1,42 @@ +--- +title: "account.getNotifySettings" +description: "Gets current notification settings for a given user/group, from all users/all groups." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getNotifySettings.html +--- +# Method: account.getNotifySettings +[Back to methods index](index.html) + + + +Gets current notification settings for a given user/group, from all users/all groups. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) | Notification source | Yes| + + +### Return type: [PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$PeerNotifySettings = $MadelineProto->account->getNotifySettings(peer: $InputNotifyPeer, ); +``` + diff --git a/docs/API_docs/methods/account.getPassword.md b/docs/API_docs/methods/account.getPassword.md new file mode 100644 index 0000000000..663448e586 --- /dev/null +++ b/docs/API_docs/methods/account.getPassword.md @@ -0,0 +1,37 @@ +--- +title: "account.getPassword" +description: "Obtain configuration for two-factor authorization with password" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getPassword.html +--- +# Method: account.getPassword +[Back to methods index](index.html) + + + +Obtain configuration for two-factor authorization with password + + + +### Return type: [account.Password](/API_docs/types/account.Password.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_Password = $MadelineProto->account->getPassword(); +``` + diff --git a/docs/API_docs/methods/account.getPasswordSettings.md b/docs/API_docs/methods/account.getPasswordSettings.md new file mode 100644 index 0000000000..742e23a632 --- /dev/null +++ b/docs/API_docs/methods/account.getPasswordSettings.md @@ -0,0 +1,42 @@ +--- +title: "account.getPasswordSettings" +description: "You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getPasswordSettings.html +--- +# Method: account.getPasswordSettings +[Back to methods index](index.html) + + + +You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | The password (see [SRP](https://core.telegram.org/api/srp)) | Yes| + + +### Return type: [account.PasswordSettings](/API_docs/types/account.PasswordSettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_PasswordSettings = $MadelineProto->account->getPasswordSettings(password: $InputCheckPasswordSRP, ); +``` + diff --git a/docs/API_docs/methods/account.getPrivacy.md b/docs/API_docs/methods/account.getPrivacy.md new file mode 100644 index 0000000000..b69f08b0ac --- /dev/null +++ b/docs/API_docs/methods/account.getPrivacy.md @@ -0,0 +1,42 @@ +--- +title: "account.getPrivacy" +description: "Get privacy settings of current account" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getPrivacy.html +--- +# Method: account.getPrivacy +[Back to methods index](index.html) + + + +Get privacy settings of current account + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|key|[InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) | Peer category whose privacy settings should be fetched | Yes| + + +### Return type: [account.PrivacyRules](/API_docs/types/account.PrivacyRules.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_PrivacyRules = $MadelineProto->account->getPrivacy(key: $InputPrivacyKey, ); +``` + diff --git a/docs/API_docs/methods/account.getReactionsNotifySettings.md b/docs/API_docs/methods/account.getReactionsNotifySettings.md new file mode 100644 index 0000000000..c52ce7d87c --- /dev/null +++ b/docs/API_docs/methods/account.getReactionsNotifySettings.md @@ -0,0 +1,35 @@ +--- +title: "account.getReactionsNotifySettings" +description: "account.getReactionsNotifySettings parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getReactionsNotifySettings.html +--- +# Method: account.getReactionsNotifySettings +[Back to methods index](index.html) + + + + + +### Return type: [ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ReactionsNotifySettings = $MadelineProto->account->getReactionsNotifySettings(); +``` + diff --git a/docs/API_docs/methods/account.getRecentEmojiStatuses.md b/docs/API_docs/methods/account.getRecentEmojiStatuses.md new file mode 100644 index 0000000000..7a8012069a --- /dev/null +++ b/docs/API_docs/methods/account.getRecentEmojiStatuses.md @@ -0,0 +1,42 @@ +--- +title: "account.getRecentEmojiStatuses" +description: "Get recently used [emoji statuses](https://core.telegram.org/api/emoji-status)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getRecentEmojiStatuses.html +--- +# Method: account.getRecentEmojiStatuses +[Back to methods index](index.html) + + + +Get recently used [emoji statuses](https://core.telegram.org/api/emoji-status) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_EmojiStatuses = $MadelineProto->account->getRecentEmojiStatuses(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getSavedRingtones.md b/docs/API_docs/methods/account.getSavedRingtones.md new file mode 100644 index 0000000000..b908b331a1 --- /dev/null +++ b/docs/API_docs/methods/account.getSavedRingtones.md @@ -0,0 +1,42 @@ +--- +title: "account.getSavedRingtones" +description: "Fetch saved notification sounds" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getSavedRingtones.html +--- +# Method: account.getSavedRingtones +[Back to methods index](index.html) + + + +Fetch saved notification sounds + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.SavedRingtones](/API_docs/types/account.SavedRingtones.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_SavedRingtones = $MadelineProto->account->getSavedRingtones(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getSecureValue.md b/docs/API_docs/methods/account.getSecureValue.md new file mode 100644 index 0000000000..c9b502b4ea --- /dev/null +++ b/docs/API_docs/methods/account.getSecureValue.md @@ -0,0 +1,42 @@ +--- +title: "account.getSecureValue" +description: "Get saved [Telegram Passport](https://core.telegram.org/passport) document, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getSecureValue.html +--- +# Method: account.getSecureValue +[Back to methods index](index.html) + + + +Get saved [Telegram Passport](https://core.telegram.org/passport) document, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|types|Array of [SecureValueType](/API_docs/types/SecureValueType.html) | Requested value types | Yes| + + +### Return type: [Vector\_of\_SecureValue](/API_docs/types/SecureValue.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_SecureValue = $MadelineProto->account->getSecureValue(types: [$SecureValueType, $SecureValueType], ); +``` + diff --git a/docs/API_docs/methods/account.getTheme.md b/docs/API_docs/methods/account.getTheme.md new file mode 100644 index 0000000000..4e9c8b74f4 --- /dev/null +++ b/docs/API_docs/methods/account.getTheme.md @@ -0,0 +1,43 @@ +--- +title: "account.getTheme" +description: "Get theme information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getTheme.html +--- +# Method: account.getTheme +[Back to methods index](index.html) + + + +Get theme information + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|format|[string](/API_docs/types/string.html) | Theme format, a string that identifies the theming engines supported by the client | Optional| +|theme|[InputTheme](/API_docs/types/InputTheme.html) | Theme | Yes| + + +### Return type: [Theme](/API_docs/types/Theme.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Theme = $MadelineProto->account->getTheme(format: 'string', theme: $InputTheme, ); +``` + diff --git a/docs/API_docs/methods/account.getThemes.md b/docs/API_docs/methods/account.getThemes.md new file mode 100644 index 0000000000..9318a6decf --- /dev/null +++ b/docs/API_docs/methods/account.getThemes.md @@ -0,0 +1,43 @@ +--- +title: "account.getThemes" +description: "Get installed themes" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getThemes.html +--- +# Method: account.getThemes +[Back to methods index](index.html) + + + +Get installed themes + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|format|[string](/API_docs/types/string.html) | Theme format, a string that identifies the theming engines supported by the client | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.Themes](/API_docs/types/account.Themes.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_Themes = $MadelineProto->account->getThemes(format: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getTmpPassword.md b/docs/API_docs/methods/account.getTmpPassword.md new file mode 100644 index 0000000000..0a9a412828 --- /dev/null +++ b/docs/API_docs/methods/account.getTmpPassword.md @@ -0,0 +1,43 @@ +--- +title: "account.getTmpPassword" +description: "Get temporary payment password" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getTmpPassword.html +--- +# Method: account.getTmpPassword +[Back to methods index](index.html) + + + +Get temporary payment password + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | SRP password parameters | Yes| +|period|[int](/API_docs/types/int.html) | Time during which the temporary password will be valid, in seconds; should be between 60 and 86400 | Optional| + + +### Return type: [account.TmpPassword](/API_docs/types/account.TmpPassword.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_TmpPassword = $MadelineProto->account->getTmpPassword(password: $InputCheckPasswordSRP, period: $int, ); +``` + diff --git a/docs/API_docs/methods/account.getWallPaper.md b/docs/API_docs/methods/account.getWallPaper.md new file mode 100644 index 0000000000..39b15bd358 --- /dev/null +++ b/docs/API_docs/methods/account.getWallPaper.md @@ -0,0 +1,42 @@ +--- +title: "account.getWallPaper" +description: "Get info about a certain [wallpaper](https://core.telegram.org/api/wallpapers)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getWallPaper.html +--- +# Method: account.getWallPaper +[Back to methods index](index.html) + + + +Get info about a certain [wallpaper](https://core.telegram.org/api/wallpapers) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|wallpaper|[InputWallPaper](/API_docs/types/InputWallPaper.html) | The [wallpaper](https://core.telegram.org/api/wallpapers) to get info about | Yes| + + +### Return type: [WallPaper](/API_docs/types/WallPaper.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$WallPaper = $MadelineProto->account->getWallPaper(wallpaper: $InputWallPaper, ); +``` + diff --git a/docs/API_docs/methods/account.getWallPapers.md b/docs/API_docs/methods/account.getWallPapers.md new file mode 100644 index 0000000000..9890ece20a --- /dev/null +++ b/docs/API_docs/methods/account.getWallPapers.md @@ -0,0 +1,42 @@ +--- +title: "account.getWallPapers" +description: "Returns a list of available [wallpapers](https://core.telegram.org/api/wallpapers)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getWallPapers.html +--- +# Method: account.getWallPapers +[Back to methods index](index.html) + + + +Returns a list of available [wallpapers](https://core.telegram.org/api/wallpapers). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [account.WallPapers](/API_docs/types/account.WallPapers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_WallPapers = $MadelineProto->account->getWallPapers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.getWebAuthorizations.md b/docs/API_docs/methods/account.getWebAuthorizations.md new file mode 100644 index 0000000000..493c353d8f --- /dev/null +++ b/docs/API_docs/methods/account.getWebAuthorizations.md @@ -0,0 +1,37 @@ +--- +title: "account.getWebAuthorizations" +description: "Get web [login widget](https://core.telegram.org/widgets/login) authorizations" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_getWebAuthorizations.html +--- +# Method: account.getWebAuthorizations +[Back to methods index](index.html) + + + +Get web [login widget](https://core.telegram.org/widgets/login) authorizations + + + +### Return type: [account.WebAuthorizations](/API_docs/types/account.WebAuthorizations.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_WebAuthorizations = $MadelineProto->account->getWebAuthorizations(); +``` + diff --git a/docs/API_docs/methods/account.initTakeoutSession.md b/docs/API_docs/methods/account.initTakeoutSession.md new file mode 100644 index 0000000000..a0e9c29ffd --- /dev/null +++ b/docs/API_docs/methods/account.initTakeoutSession.md @@ -0,0 +1,48 @@ +--- +title: "account.initTakeoutSession" +description: "Initialize a [takeout session, see here » for more info](https://core.telegram.org/api/takeout)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_initTakeoutSession.html +--- +# Method: account.initTakeoutSession +[Back to methods index](index.html) + + + +Initialize a [takeout session, see here » for more info](https://core.telegram.org/api/takeout). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|contacts|[Bool](/API_docs/types/Bool.html) | Whether to export contacts | Optional| +|message\_users|[Bool](/API_docs/types/Bool.html) | Whether to export messages in private chats | Optional| +|message\_chats|[Bool](/API_docs/types/Bool.html) | Whether to export messages in [basic groups](https://core.telegram.org/api/channel#basic-groups) | Optional| +|message\_megagroups|[Bool](/API_docs/types/Bool.html) | Whether to export messages in [supergroups](https://core.telegram.org/api/channel#supergroups) | Optional| +|message\_channels|[Bool](/API_docs/types/Bool.html) | Whether to export messages in [channels](https://core.telegram.org/api/channel#channels) | Optional| +|files|[Bool](/API_docs/types/Bool.html) | Whether to export files | Optional| +|file\_max\_size|[long](/API_docs/types/long.html) | Maximum size of files to export | Optional| + + +### Return type: [account.Takeout](/API_docs/types/account.Takeout.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_Takeout = $MadelineProto->account->initTakeoutSession(contacts: $Bool, message_users: $Bool, message_chats: $Bool, message_megagroups: $Bool, message_channels: $Bool, files: $Bool, file_max_size: $long, ); +``` + diff --git a/docs/API_docs/methods/account.installTheme.md b/docs/API_docs/methods/account.installTheme.md new file mode 100644 index 0000000000..94f5fff970 --- /dev/null +++ b/docs/API_docs/methods/account.installTheme.md @@ -0,0 +1,45 @@ +--- +title: "account.installTheme" +description: "Install a theme" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_installTheme.html +--- +# Method: account.installTheme +[Back to methods index](index.html) + + + +Install a theme + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|dark|[Bool](/API_docs/types/Bool.html) | Whether to install the dark version | Optional| +|theme|[InputTheme](/API_docs/types/InputTheme.html) | Theme to install | Optional| +|format|[string](/API_docs/types/string.html) | Theme format, a string that identifies the theming engines supported by the client | Optional| +|base\_theme|[BaseTheme](/API_docs/types/BaseTheme.html) | Indicates a basic theme provided by all clients | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->installTheme(dark: $Bool, theme: $InputTheme, format: 'string', base_theme: $BaseTheme, ); +``` + diff --git a/docs/API_docs/methods/account.installWallPaper.md b/docs/API_docs/methods/account.installWallPaper.md new file mode 100644 index 0000000000..15548844c3 --- /dev/null +++ b/docs/API_docs/methods/account.installWallPaper.md @@ -0,0 +1,43 @@ +--- +title: "account.installWallPaper" +description: "Install [wallpaper](https://core.telegram.org/api/wallpapers)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_installWallPaper.html +--- +# Method: account.installWallPaper +[Back to methods index](index.html) + + + +Install [wallpaper](https://core.telegram.org/api/wallpapers) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|wallpaper|[InputWallPaper](/API_docs/types/InputWallPaper.html) | [Wallpaper](https://core.telegram.org/api/wallpapers) to install | Yes| +|settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | [Wallpaper](https://core.telegram.org/api/wallpapers) settings | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->installWallPaper(wallpaper: $InputWallPaper, settings: $WallPaperSettings, ); +``` + diff --git a/docs/API_docs/methods/account.invalidateSignInCodes.md b/docs/API_docs/methods/account.invalidateSignInCodes.md new file mode 100644 index 0000000000..909ce93652 --- /dev/null +++ b/docs/API_docs/methods/account.invalidateSignInCodes.md @@ -0,0 +1,42 @@ +--- +title: "account.invalidateSignInCodes" +description: "Invalidate the specified login codes, see [here »](https://core.telegram.org/api/auth#invalidating-login-codes) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_invalidateSignInCodes.html +--- +# Method: account.invalidateSignInCodes +[Back to methods index](index.html) + + + +Invalidate the specified login codes, see [here »](https://core.telegram.org/api/auth#invalidating-login-codes) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|codes|Array of [string](/API_docs/types/string.html) | The login codes to invalidate. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->invalidateSignInCodes(codes: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/account.registerDevice.md b/docs/API_docs/methods/account.registerDevice.md new file mode 100644 index 0000000000..88f3a6a2a5 --- /dev/null +++ b/docs/API_docs/methods/account.registerDevice.md @@ -0,0 +1,47 @@ +--- +title: "account.registerDevice" +description: "Register device to receive [PUSH notifications](https://core.telegram.org/api/push-updates)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_registerDevice.html +--- +# Method: account.registerDevice +[Back to methods index](index.html) + + + +Register device to receive [PUSH notifications](https://core.telegram.org/api/push-updates) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|no\_muted|[Bool](/API_docs/types/Bool.html) | Avoid receiving (silent and invisible background) notifications. Useful to save battery. | Optional| +|token\_type|[int](/API_docs/types/int.html) | Device token type, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values. | Optional| +|token|[string](/API_docs/types/string.html) | Device token, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values. | Optional| +|app\_sandbox|[Bool](/API_docs/types/Bool.html) | If [(boolTrue)](../constructors/boolTrue.html) is transmitted, a sandbox-certificate will be used during transmission. | Yes| +|secret|[bytes](/API_docs/types/bytes.html) | For FCM and APNS VoIP, optional encryption key used to encrypt push notifications | Yes| +|other\_uids|Array of [long](/API_docs/types/long.html) | List of user identifiers of other users currently using the client | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->registerDevice(no_muted: $Bool, token_type: $int, token: 'string', app_sandbox: $Bool, secret: 'bytes', other_uids: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.reorderUsernames.md b/docs/API_docs/methods/account.reorderUsernames.md new file mode 100644 index 0000000000..d43dbf471f --- /dev/null +++ b/docs/API_docs/methods/account.reorderUsernames.md @@ -0,0 +1,42 @@ +--- +title: "account.reorderUsernames" +description: "Reorder usernames associated with the currently logged-in user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_reorderUsernames.html +--- +# Method: account.reorderUsernames +[Back to methods index](index.html) + + + +Reorder usernames associated with the currently logged-in user. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|order|Array of [string](/API_docs/types/string.html) | The new order for active usernames. All active usernames must be specified. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->reorderUsernames(order: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/account.reportPeer.md b/docs/API_docs/methods/account.reportPeer.md new file mode 100644 index 0000000000..1bf6692e0a --- /dev/null +++ b/docs/API_docs/methods/account.reportPeer.md @@ -0,0 +1,50 @@ +--- +title: "account.reportPeer" +description: "Report a peer for violation of telegram's Terms of Service" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_reportPeer.html +--- +# Method: account.reportPeer +[Back to methods index](index.html) + + + +Report a peer for violation of telegram's Terms of Service + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer to report | Optional| +|reason|[ReportReason](/API_docs/types/ReportReason.html) | The reason why this peer is being reported | Yes| +|message|[string](/API_docs/types/string.html) | Comment for report moderation | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->reportPeer(peer: $InputPeer, reason: $ReportReason, message: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/account.reportProfilePhoto.md b/docs/API_docs/methods/account.reportProfilePhoto.md new file mode 100644 index 0000000000..fc3a5b1023 --- /dev/null +++ b/docs/API_docs/methods/account.reportProfilePhoto.md @@ -0,0 +1,51 @@ +--- +title: "account.reportProfilePhoto" +description: "Report a profile photo of a dialog" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_reportProfilePhoto.html +--- +# Method: account.reportProfilePhoto +[Back to methods index](index.html) + + + +Report a profile photo of a dialog + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The dialog | Optional| +|photo\_id|[MessageMedia, Update, Message or InputPhoto](/API_docs/types/InputPhoto.html) | Dialog photo ID | Optional| +|reason|[ReportReason](/API_docs/types/ReportReason.html) | Report reason | Yes| +|message|[string](/API_docs/types/string.html) | Comment for report moderation | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->reportProfilePhoto(peer: $InputPeer, photo_id: $InputPhoto, reason: $ReportReason, message: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/account.resendPasswordEmail.md b/docs/API_docs/methods/account.resendPasswordEmail.md new file mode 100644 index 0000000000..1e4e9edb22 --- /dev/null +++ b/docs/API_docs/methods/account.resendPasswordEmail.md @@ -0,0 +1,37 @@ +--- +title: "account.resendPasswordEmail" +description: "Resend the code to verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resendPasswordEmail.html +--- +# Method: account.resendPasswordEmail +[Back to methods index](index.html) + + + +Resend the code to verify an email to use as [2FA recovery method](https://core.telegram.org/api/srp). + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->resendPasswordEmail(); +``` + diff --git a/docs/API_docs/methods/account.resetAuthorization.md b/docs/API_docs/methods/account.resetAuthorization.md new file mode 100644 index 0000000000..beccaa0fca --- /dev/null +++ b/docs/API_docs/methods/account.resetAuthorization.md @@ -0,0 +1,42 @@ +--- +title: "account.resetAuthorization" +description: "Log out an active [authorized session](https://core.telegram.org/api/auth) by its hash" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resetAuthorization.html +--- +# Method: account.resetAuthorization +[Back to methods index](index.html) + + + +Log out an active [authorized session](https://core.telegram.org/api/auth) by its hash + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | Session hash | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->resetAuthorization(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.resetNotifySettings.md b/docs/API_docs/methods/account.resetNotifySettings.md new file mode 100644 index 0000000000..a746f0b915 --- /dev/null +++ b/docs/API_docs/methods/account.resetNotifySettings.md @@ -0,0 +1,37 @@ +--- +title: "account.resetNotifySettings" +description: "Resets all notification settings from users and groups." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resetNotifySettings.html +--- +# Method: account.resetNotifySettings +[Back to methods index](index.html) + + + +Resets all notification settings from users and groups. + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->resetNotifySettings(); +``` + diff --git a/docs/API_docs/methods/account.resetPassword.md b/docs/API_docs/methods/account.resetPassword.md new file mode 100644 index 0000000000..c5347dcb31 --- /dev/null +++ b/docs/API_docs/methods/account.resetPassword.md @@ -0,0 +1,37 @@ +--- +title: "account.resetPassword" +description: "Initiate a 2FA password reset: can only be used if the user is already logged-in, [see here for more info »](https://core.telegram.org/api/srp#password-reset)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resetPassword.html +--- +# Method: account.resetPassword +[Back to methods index](index.html) + + + +Initiate a 2FA password reset: can only be used if the user is already logged-in, [see here for more info »](https://core.telegram.org/api/srp#password-reset) + + + +### Return type: [account.ResetPasswordResult](/API_docs/types/account.ResetPasswordResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_ResetPasswordResult = $MadelineProto->account->resetPassword(); +``` + diff --git a/docs/API_docs/methods/account.resetWallPapers.md b/docs/API_docs/methods/account.resetWallPapers.md new file mode 100644 index 0000000000..e6c7d21fd5 --- /dev/null +++ b/docs/API_docs/methods/account.resetWallPapers.md @@ -0,0 +1,37 @@ +--- +title: "account.resetWallPapers" +description: "Delete all installed [wallpapers](https://core.telegram.org/api/wallpapers), reverting to the default wallpaper set." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resetWallPapers.html +--- +# Method: account.resetWallPapers +[Back to methods index](index.html) + + + +Delete all installed [wallpapers](https://core.telegram.org/api/wallpapers), reverting to the default wallpaper set. + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->resetWallPapers(); +``` + diff --git a/docs/API_docs/methods/account.resetWebAuthorization.md b/docs/API_docs/methods/account.resetWebAuthorization.md new file mode 100644 index 0000000000..ceb8b046b6 --- /dev/null +++ b/docs/API_docs/methods/account.resetWebAuthorization.md @@ -0,0 +1,42 @@ +--- +title: "account.resetWebAuthorization" +description: "Log out an active web [telegram login](https://core.telegram.org/widgets/login) session" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resetWebAuthorization.html +--- +# Method: account.resetWebAuthorization +[Back to methods index](index.html) + + + +Log out an active web [telegram login](https://core.telegram.org/widgets/login) session + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Session](../constructors/webAuthorization.html) hash | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->resetWebAuthorization(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.resetWebAuthorizations.md b/docs/API_docs/methods/account.resetWebAuthorizations.md new file mode 100644 index 0000000000..bb5c683532 --- /dev/null +++ b/docs/API_docs/methods/account.resetWebAuthorizations.md @@ -0,0 +1,37 @@ +--- +title: "account.resetWebAuthorizations" +description: "Reset all active web [telegram login](https://core.telegram.org/widgets/login) sessions" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resetWebAuthorizations.html +--- +# Method: account.resetWebAuthorizations +[Back to methods index](index.html) + + + +Reset all active web [telegram login](https://core.telegram.org/widgets/login) sessions + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->resetWebAuthorizations(); +``` + diff --git a/docs/API_docs/methods/account.resolveBusinessChatLink.md b/docs/API_docs/methods/account.resolveBusinessChatLink.md new file mode 100644 index 0000000000..839a9280e5 --- /dev/null +++ b/docs/API_docs/methods/account.resolveBusinessChatLink.md @@ -0,0 +1,40 @@ +--- +title: "account.resolveBusinessChatLink" +description: "account.resolveBusinessChatLink parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_resolveBusinessChatLink.html +--- +# Method: account.resolveBusinessChatLink +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|slug|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [account.ResolvedBusinessChatLinks](/API_docs/types/account.ResolvedBusinessChatLinks.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_ResolvedBusinessChatLinks = $MadelineProto->account->resolveBusinessChatLink(slug: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.saveAutoDownloadSettings.md b/docs/API_docs/methods/account.saveAutoDownloadSettings.md new file mode 100644 index 0000000000..0f8eaa388f --- /dev/null +++ b/docs/API_docs/methods/account.saveAutoDownloadSettings.md @@ -0,0 +1,44 @@ +--- +title: "account.saveAutoDownloadSettings" +description: "Change media autodownload settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_saveAutoDownloadSettings.html +--- +# Method: account.saveAutoDownloadSettings +[Back to methods index](index.html) + + + +Change media autodownload settings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|low|[Bool](/API_docs/types/Bool.html) | Whether to save media in the low data usage preset | Optional| +|high|[Bool](/API_docs/types/Bool.html) | Whether to save media in the high data usage preset | Optional| +|settings|[AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html) | Media autodownload settings | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->saveAutoDownloadSettings(low: $Bool, high: $Bool, settings: $AutoDownloadSettings, ); +``` + diff --git a/docs/API_docs/methods/account.saveAutoSaveSettings.md b/docs/API_docs/methods/account.saveAutoSaveSettings.md new file mode 100644 index 0000000000..9bb17e08cd --- /dev/null +++ b/docs/API_docs/methods/account.saveAutoSaveSettings.md @@ -0,0 +1,46 @@ +--- +title: "account.saveAutoSaveSettings" +description: "Modify autosave settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_saveAutoSaveSettings.html +--- +# Method: account.saveAutoSaveSettings +[Back to methods index](index.html) + + + +Modify autosave settings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|users|[Bool](/API_docs/types/Bool.html) | Whether the new settings should affect all private chats | Optional| +|chats|[Bool](/API_docs/types/Bool.html) | Whether the new settings should affect all groups | Optional| +|broadcasts|[Bool](/API_docs/types/Bool.html) | Whether the new settings should affect all [channels](https://core.telegram.org/api/channel) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Whether the new settings should affect a specific peer | Optional| +|settings|[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) | The new autosave settings | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->saveAutoSaveSettings(users: $Bool, chats: $Bool, broadcasts: $Bool, peer: $InputPeer, settings: $AutoSaveSettings, ); +``` + diff --git a/docs/API_docs/methods/account.saveRingtone.md b/docs/API_docs/methods/account.saveRingtone.md new file mode 100644 index 0000000000..5e62fcd12b --- /dev/null +++ b/docs/API_docs/methods/account.saveRingtone.md @@ -0,0 +1,46 @@ +--- +title: "account.saveRingtone" +description: "Save or remove saved notification sound." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_saveRingtone.html +--- +# Method: account.saveRingtone +[Back to methods index](index.html) + + + +Save or remove saved notification sound. + +If the notification sound is already in MP3 format, [account.savedRingtone](../constructors/account.savedRingtone.html) will be returned. +Otherwise, it will be automatically converted and a [account.savedRingtoneConverted](../constructors/account.savedRingtoneConverted.html) will be returned, containing a new [document](../constructors/document.html) object that should be used to refer to the ringtone from now on (ie when deleting it using the `unsave` parameter, or when downloading it). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Notification sound uploaded using [account.uploadRingtone](../methods/account.uploadRingtone.html) | Optional| +|unsave|[Bool](/API_docs/types/Bool.html) | Whether to add or delete the notification sound | Yes| + + +### Return type: [account.SavedRingtone](/API_docs/types/account.SavedRingtone.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_SavedRingtone = $MadelineProto->account->saveRingtone(id: $InputDocument, unsave: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.saveSecureValue.md b/docs/API_docs/methods/account.saveSecureValue.md new file mode 100644 index 0000000000..a57f223952 --- /dev/null +++ b/docs/API_docs/methods/account.saveSecureValue.md @@ -0,0 +1,43 @@ +--- +title: "account.saveSecureValue" +description: "Securely save [Telegram Passport](https://core.telegram.org/passport) document, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_saveSecureValue.html +--- +# Method: account.saveSecureValue +[Back to methods index](index.html) + + + +Securely save [Telegram Passport](https://core.telegram.org/passport) document, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|value|[InputSecureValue](/API_docs/types/InputSecureValue.html) | Secure value, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) | Yes| +|secure\_secret\_id|[long](/API_docs/types/long.html) | Passport secret hash, [for more info see the passport docs »](https://core.telegram.org/passport/encryption#encryption) | Yes| + + +### Return type: [SecureValue](/API_docs/types/SecureValue.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$SecureValue = $MadelineProto->account->saveSecureValue(value: $InputSecureValue, secure_secret_id: $long, ); +``` + diff --git a/docs/API_docs/methods/account.saveTheme.md b/docs/API_docs/methods/account.saveTheme.md new file mode 100644 index 0000000000..d7c6ea5327 --- /dev/null +++ b/docs/API_docs/methods/account.saveTheme.md @@ -0,0 +1,43 @@ +--- +title: "account.saveTheme" +description: "Save a theme" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_saveTheme.html +--- +# Method: account.saveTheme +[Back to methods index](index.html) + + + +Save a theme + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|theme|[InputTheme](/API_docs/types/InputTheme.html) | Theme to save | Yes| +|unsave|[Bool](/API_docs/types/Bool.html) | Unsave | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->saveTheme(theme: $InputTheme, unsave: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.saveWallPaper.md b/docs/API_docs/methods/account.saveWallPaper.md new file mode 100644 index 0000000000..671462db93 --- /dev/null +++ b/docs/API_docs/methods/account.saveWallPaper.md @@ -0,0 +1,44 @@ +--- +title: "account.saveWallPaper" +description: "Install/uninstall [wallpaper](https://core.telegram.org/api/wallpapers)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_saveWallPaper.html +--- +# Method: account.saveWallPaper +[Back to methods index](index.html) + + + +Install/uninstall [wallpaper](https://core.telegram.org/api/wallpapers) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|wallpaper|[InputWallPaper](/API_docs/types/InputWallPaper.html) | [Wallpaper](https://core.telegram.org/api/wallpapers) to install or uninstall | Yes| +|unsave|[Bool](/API_docs/types/Bool.html) | Uninstall wallpaper? | Yes| +|settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | Wallpaper settings | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->saveWallPaper(wallpaper: $InputWallPaper, unsave: $Bool, settings: $WallPaperSettings, ); +``` + diff --git a/docs/API_docs/methods/account.sendChangePhoneCode.md b/docs/API_docs/methods/account.sendChangePhoneCode.md new file mode 100644 index 0000000000..63ac8b3e5d --- /dev/null +++ b/docs/API_docs/methods/account.sendChangePhoneCode.md @@ -0,0 +1,43 @@ +--- +title: "account.sendChangePhoneCode" +description: "Verify a new phone number to associate to the current account" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_sendChangePhoneCode.html +--- +# Method: account.sendChangePhoneCode +[Back to methods index](index.html) + + + +Verify a new phone number to associate to the current account + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | New phone number | Optional| +|settings|[CodeSettings](/API_docs/types/CodeSettings.html) | Phone code settings | Yes| + + +### Return type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_SentCode = $MadelineProto->account->sendChangePhoneCode(phone_number: 'string', settings: $CodeSettings, ); +``` + diff --git a/docs/API_docs/methods/account.sendConfirmPhoneCode.md b/docs/API_docs/methods/account.sendConfirmPhoneCode.md new file mode 100644 index 0000000000..0dc3d41f84 --- /dev/null +++ b/docs/API_docs/methods/account.sendConfirmPhoneCode.md @@ -0,0 +1,43 @@ +--- +title: "account.sendConfirmPhoneCode" +description: "Send confirmation code to cancel account deletion, for more info [click here »](https://core.telegram.org/api/account-deletion)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_sendConfirmPhoneCode.html +--- +# Method: account.sendConfirmPhoneCode +[Back to methods index](index.html) + + + +Send confirmation code to cancel account deletion, for more info [click here »](https://core.telegram.org/api/account-deletion) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|[string](/API_docs/types/string.html) | The hash from the service notification, for more info [click here »](https://core.telegram.org/api/account-deletion) | Optional| +|settings|[CodeSettings](/API_docs/types/CodeSettings.html) | Phone code settings | Yes| + + +### Return type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_SentCode = $MadelineProto->account->sendConfirmPhoneCode(hash: 'string', settings: $CodeSettings, ); +``` + diff --git a/docs/API_docs/methods/account.sendVerifyEmailCode.md b/docs/API_docs/methods/account.sendVerifyEmailCode.md new file mode 100644 index 0000000000..615d842669 --- /dev/null +++ b/docs/API_docs/methods/account.sendVerifyEmailCode.md @@ -0,0 +1,43 @@ +--- +title: "account.sendVerifyEmailCode" +description: "Send an email verification code." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_sendVerifyEmailCode.html +--- +# Method: account.sendVerifyEmailCode +[Back to methods index](index.html) + + + +Send an email verification code. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|purpose|[EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html) | Verification purpose. | Yes| +|email|[string](/API_docs/types/string.html) | The email where to send the code. | Optional| + + +### Return type: [account.SentEmailCode](/API_docs/types/account.SentEmailCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_SentEmailCode = $MadelineProto->account->sendVerifyEmailCode(purpose: $EmailVerifyPurpose, email: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.sendVerifyPhoneCode.md b/docs/API_docs/methods/account.sendVerifyPhoneCode.md new file mode 100644 index 0000000000..ebcf758ca1 --- /dev/null +++ b/docs/API_docs/methods/account.sendVerifyPhoneCode.md @@ -0,0 +1,43 @@ +--- +title: "account.sendVerifyPhoneCode" +description: "Send the verification phone code for telegram [passport](https://core.telegram.org/passport)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_sendVerifyPhoneCode.html +--- +# Method: account.sendVerifyPhoneCode +[Back to methods index](index.html) + + + +Send the verification phone code for telegram [passport](https://core.telegram.org/passport). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | The phone number to verify | Optional| +|settings|[CodeSettings](/API_docs/types/CodeSettings.html) | Phone code settings | Yes| + + +### Return type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_SentCode = $MadelineProto->account->sendVerifyPhoneCode(phone_number: 'string', settings: $CodeSettings, ); +``` + diff --git a/docs/API_docs/methods/account.setAccountTTL.md b/docs/API_docs/methods/account.setAccountTTL.md new file mode 100644 index 0000000000..6813032f48 --- /dev/null +++ b/docs/API_docs/methods/account.setAccountTTL.md @@ -0,0 +1,42 @@ +--- +title: "account.setAccountTTL" +description: "Set account self-destruction period" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setAccountTTL.html +--- +# Method: account.setAccountTTL +[Back to methods index](index.html) + + + +Set account self-destruction period + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|ttl|[AccountDaysTTL](/API_docs/types/AccountDaysTTL.html) | Time to live in days | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->setAccountTTL(ttl: $AccountDaysTTL, ); +``` + diff --git a/docs/API_docs/methods/account.setAuthorizationTTL.md b/docs/API_docs/methods/account.setAuthorizationTTL.md new file mode 100644 index 0000000000..557293bcc6 --- /dev/null +++ b/docs/API_docs/methods/account.setAuthorizationTTL.md @@ -0,0 +1,42 @@ +--- +title: "account.setAuthorizationTTL" +description: "Set time-to-live of current session" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setAuthorizationTTL.html +--- +# Method: account.setAuthorizationTTL +[Back to methods index](index.html) + + + +Set time-to-live of current session + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|authorization\_ttl\_days|[int](/API_docs/types/int.html) | Time-to-live of current session in days | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->setAuthorizationTTL(authorization_ttl_days: $int, ); +``` + diff --git a/docs/API_docs/methods/account.setContactSignUpNotification.md b/docs/API_docs/methods/account.setContactSignUpNotification.md new file mode 100644 index 0000000000..9d4747049d --- /dev/null +++ b/docs/API_docs/methods/account.setContactSignUpNotification.md @@ -0,0 +1,42 @@ +--- +title: "account.setContactSignUpNotification" +description: "Toggle contact sign up notifications" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setContactSignUpNotification.html +--- +# Method: account.setContactSignUpNotification +[Back to methods index](index.html) + + + +Toggle contact sign up notifications + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Whether to disable contact sign up notifications | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->setContactSignUpNotification(silent: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.setContentSettings.md b/docs/API_docs/methods/account.setContentSettings.md new file mode 100644 index 0000000000..cd94d5bc75 --- /dev/null +++ b/docs/API_docs/methods/account.setContentSettings.md @@ -0,0 +1,42 @@ +--- +title: "account.setContentSettings" +description: "Set sensitive content settings (for viewing or hiding NSFW content)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setContentSettings.html +--- +# Method: account.setContentSettings +[Back to methods index](index.html) + + + +Set sensitive content settings (for viewing or hiding NSFW content) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|sensitive\_enabled|[Bool](/API_docs/types/Bool.html) | Enable NSFW content | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->setContentSettings(sensitive_enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.setGlobalPrivacySettings.md b/docs/API_docs/methods/account.setGlobalPrivacySettings.md new file mode 100644 index 0000000000..11c3b91567 --- /dev/null +++ b/docs/API_docs/methods/account.setGlobalPrivacySettings.md @@ -0,0 +1,42 @@ +--- +title: "account.setGlobalPrivacySettings" +description: "Set global privacy settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setGlobalPrivacySettings.html +--- +# Method: account.setGlobalPrivacySettings +[Back to methods index](index.html) + + + +Set global privacy settings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|settings|[GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) | Global privacy settings | Yes| + + +### Return type: [GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$GlobalPrivacySettings = $MadelineProto->account->setGlobalPrivacySettings(settings: $GlobalPrivacySettings, ); +``` + diff --git a/docs/API_docs/methods/account.setPrivacy.md b/docs/API_docs/methods/account.setPrivacy.md new file mode 100644 index 0000000000..0c5b809e06 --- /dev/null +++ b/docs/API_docs/methods/account.setPrivacy.md @@ -0,0 +1,43 @@ +--- +title: "account.setPrivacy" +description: "Change privacy settings of current account" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setPrivacy.html +--- +# Method: account.setPrivacy +[Back to methods index](index.html) + + + +Change privacy settings of current account + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|key|[InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) | New privacy rule | Yes| +|rules|Array of [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) | Peers to which the privacy rule will apply. | Yes| + + +### Return type: [account.PrivacyRules](/API_docs/types/account.PrivacyRules.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_PrivacyRules = $MadelineProto->account->setPrivacy(key: $InputPrivacyKey, rules: [$InputPrivacyRule, $InputPrivacyRule], ); +``` + diff --git a/docs/API_docs/methods/account.setReactionsNotifySettings.md b/docs/API_docs/methods/account.setReactionsNotifySettings.md new file mode 100644 index 0000000000..a7148fab19 --- /dev/null +++ b/docs/API_docs/methods/account.setReactionsNotifySettings.md @@ -0,0 +1,40 @@ +--- +title: "account.setReactionsNotifySettings" +description: "account.setReactionsNotifySettings parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_setReactionsNotifySettings.html +--- +# Method: account.setReactionsNotifySettings +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|settings|[ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) | Yes| + + +### Return type: [ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ReactionsNotifySettings = $MadelineProto->account->setReactionsNotifySettings(settings: $ReactionsNotifySettings, ); +``` + diff --git a/docs/API_docs/methods/account.toggleConnectedBotPaused.md b/docs/API_docs/methods/account.toggleConnectedBotPaused.md new file mode 100644 index 0000000000..d337584c4d --- /dev/null +++ b/docs/API_docs/methods/account.toggleConnectedBotPaused.md @@ -0,0 +1,41 @@ +--- +title: "account.toggleConnectedBotPaused" +description: "account.toggleConnectedBotPaused parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_toggleConnectedBotPaused.html +--- +# Method: account.toggleConnectedBotPaused +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| +|paused|[Bool](/API_docs/types/Bool.html) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->toggleConnectedBotPaused(peer: $InputPeer, paused: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.toggleSponsoredMessages.md b/docs/API_docs/methods/account.toggleSponsoredMessages.md new file mode 100644 index 0000000000..d852a814ed --- /dev/null +++ b/docs/API_docs/methods/account.toggleSponsoredMessages.md @@ -0,0 +1,40 @@ +--- +title: "account.toggleSponsoredMessages" +description: "account.toggleSponsoredMessages parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_toggleSponsoredMessages.html +--- +# Method: account.toggleSponsoredMessages +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|enabled|[Bool](/API_docs/types/Bool.html) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->toggleSponsoredMessages(enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.toggleUsername.md b/docs/API_docs/methods/account.toggleUsername.md new file mode 100644 index 0000000000..05865d7bc8 --- /dev/null +++ b/docs/API_docs/methods/account.toggleUsername.md @@ -0,0 +1,43 @@ +--- +title: "account.toggleUsername" +description: "Activate or deactivate a purchased [fragment.com](https://fragment.com) username associated to the currently logged-in user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_toggleUsername.html +--- +# Method: account.toggleUsername +[Back to methods index](index.html) + + + +Activate or deactivate a purchased [fragment.com](https://fragment.com) username associated to the currently logged-in user. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|username|[string](/API_docs/types/string.html) | Username | Optional| +|active|[Bool](/API_docs/types/Bool.html) | Whether to activate or deactivate it | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->toggleUsername(username: 'string', active: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.unregisterDevice.md b/docs/API_docs/methods/account.unregisterDevice.md new file mode 100644 index 0000000000..03b4241ad0 --- /dev/null +++ b/docs/API_docs/methods/account.unregisterDevice.md @@ -0,0 +1,44 @@ +--- +title: "account.unregisterDevice" +description: "Deletes a device by its token, stops sending PUSH-notifications to it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_unregisterDevice.html +--- +# Method: account.unregisterDevice +[Back to methods index](index.html) + + + +Deletes a device by its token, stops sending PUSH-notifications to it. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|token\_type|[int](/API_docs/types/int.html) | Device token type, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values. | Optional| +|token|[string](/API_docs/types/string.html) | Device token, see [PUSH updates](https://core.telegram.org/api/push-updates#subscribing-to-notifications) for the possible values. | Optional| +|other\_uids|Array of [long](/API_docs/types/long.html) | List of user identifiers of other users currently using the client | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->unregisterDevice(token_type: $int, token: 'string', other_uids: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/account.updateBirthday.md b/docs/API_docs/methods/account.updateBirthday.md new file mode 100644 index 0000000000..683aabad38 --- /dev/null +++ b/docs/API_docs/methods/account.updateBirthday.md @@ -0,0 +1,40 @@ +--- +title: "account.updateBirthday" +description: "account.updateBirthday parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateBirthday.html +--- +# Method: account.updateBirthday +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|birthday|[Birthday](/API_docs/types/Birthday.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateBirthday(birthday: $Birthday, ); +``` + diff --git a/docs/API_docs/methods/account.updateBusinessAwayMessage.md b/docs/API_docs/methods/account.updateBusinessAwayMessage.md new file mode 100644 index 0000000000..0011834952 --- /dev/null +++ b/docs/API_docs/methods/account.updateBusinessAwayMessage.md @@ -0,0 +1,46 @@ +--- +title: "account.updateBusinessAwayMessage" +description: "account.updateBusinessAwayMessage parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateBusinessAwayMessage.html +--- +# Method: account.updateBusinessAwayMessage +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|message|[InputBusinessAwayMessage](/API_docs/types/InputBusinessAwayMessage.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateBusinessAwayMessage(message: $InputBusinessAwayMessage, ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/account.updateBusinessGreetingMessage.md b/docs/API_docs/methods/account.updateBusinessGreetingMessage.md new file mode 100644 index 0000000000..025c376a33 --- /dev/null +++ b/docs/API_docs/methods/account.updateBusinessGreetingMessage.md @@ -0,0 +1,46 @@ +--- +title: "account.updateBusinessGreetingMessage" +description: "account.updateBusinessGreetingMessage parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateBusinessGreetingMessage.html +--- +# Method: account.updateBusinessGreetingMessage +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|message|[InputBusinessGreetingMessage](/API_docs/types/InputBusinessGreetingMessage.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateBusinessGreetingMessage(message: $InputBusinessGreetingMessage, ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/account.updateBusinessIntro.md b/docs/API_docs/methods/account.updateBusinessIntro.md new file mode 100644 index 0000000000..d5cd94926a --- /dev/null +++ b/docs/API_docs/methods/account.updateBusinessIntro.md @@ -0,0 +1,40 @@ +--- +title: "account.updateBusinessIntro" +description: "account.updateBusinessIntro parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateBusinessIntro.html +--- +# Method: account.updateBusinessIntro +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|intro|[InputBusinessIntro](/API_docs/types/InputBusinessIntro.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateBusinessIntro(intro: $InputBusinessIntro, ); +``` + diff --git a/docs/API_docs/methods/account.updateBusinessLocation.md b/docs/API_docs/methods/account.updateBusinessLocation.md new file mode 100644 index 0000000000..1b2d199896 --- /dev/null +++ b/docs/API_docs/methods/account.updateBusinessLocation.md @@ -0,0 +1,41 @@ +--- +title: "account.updateBusinessLocation" +description: "account.updateBusinessLocation parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateBusinessLocation.html +--- +# Method: account.updateBusinessLocation +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Optional| +|address|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateBusinessLocation(geo_point: $InputGeoPoint, address: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.updateBusinessWorkHours.md b/docs/API_docs/methods/account.updateBusinessWorkHours.md new file mode 100644 index 0000000000..cc2f63b0a2 --- /dev/null +++ b/docs/API_docs/methods/account.updateBusinessWorkHours.md @@ -0,0 +1,40 @@ +--- +title: "account.updateBusinessWorkHours" +description: "account.updateBusinessWorkHours parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateBusinessWorkHours.html +--- +# Method: account.updateBusinessWorkHours +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|business\_work\_hours|[BusinessWorkHours](/API_docs/types/BusinessWorkHours.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateBusinessWorkHours(business_work_hours: $BusinessWorkHours, ); +``` + diff --git a/docs/API_docs/methods/account.updateColor.md b/docs/API_docs/methods/account.updateColor.md new file mode 100644 index 0000000000..d2d65ad83f --- /dev/null +++ b/docs/API_docs/methods/account.updateColor.md @@ -0,0 +1,44 @@ +--- +title: "account.updateColor" +description: "Update the [accent color and background custom emoji »](https://core.telegram.org/api/colors) of the current account." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateColor.html +--- +# Method: account.updateColor +[Back to methods index](index.html) + + + +Update the [accent color and background custom emoji »](https://core.telegram.org/api/colors) of the current account. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|for\_profile|[Bool](/API_docs/types/Bool.html) | Whether to change the accent color emoji pattern of the profile page; otherwise, the accent color and emoji pattern of messages will be changed. | Optional| +|color|[int](/API_docs/types/int.html) | [ID of the accent color palette »](https://core.telegram.org/api/colors) to use (not RGB24, see [here »](https://core.telegram.org/api/colors) for more info). | Optional| +|background\_emoji\_id|[long](/API_docs/types/long.html) | Custom emoji ID used in the accent color pattern. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateColor(for_profile: $Bool, color: $int, background_emoji_id: $long, ); +``` + diff --git a/docs/API_docs/methods/account.updateConnectedBot.md b/docs/API_docs/methods/account.updateConnectedBot.md new file mode 100644 index 0000000000..4510b1eabd --- /dev/null +++ b/docs/API_docs/methods/account.updateConnectedBot.md @@ -0,0 +1,43 @@ +--- +title: "account.updateConnectedBot" +description: "account.updateConnectedBot parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateConnectedBot.html +--- +# Method: account.updateConnectedBot +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|can\_reply|[Bool](/API_docs/types/Bool.html) | Optional| +|deleted|[Bool](/API_docs/types/Bool.html) | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Optional| +|recipients|[InputBusinessBotRecipients](/API_docs/types/InputBusinessBotRecipients.html) | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->account->updateConnectedBot(can_reply: $Bool, deleted: $Bool, bot: $InputUser, recipients: $InputBusinessBotRecipients, ); +``` + diff --git a/docs/API_docs/methods/account.updateDeviceLocked.md b/docs/API_docs/methods/account.updateDeviceLocked.md new file mode 100644 index 0000000000..cea8f1416a --- /dev/null +++ b/docs/API_docs/methods/account.updateDeviceLocked.md @@ -0,0 +1,42 @@ +--- +title: "account.updateDeviceLocked" +description: "When client-side passcode lock feature is enabled, will not show message texts in incoming [PUSH notifications](https://core.telegram.org/api/push-updates)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateDeviceLocked.html +--- +# Method: account.updateDeviceLocked +[Back to methods index](index.html) + + + +When client-side passcode lock feature is enabled, will not show message texts in incoming [PUSH notifications](https://core.telegram.org/api/push-updates). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|period|[int](/API_docs/types/int.html) | Inactivity period after which to start hiding message texts in [PUSH notifications](https://core.telegram.org/api/push-updates). | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateDeviceLocked(period: $int, ); +``` + diff --git a/docs/API_docs/methods/account.updateEmojiStatus.md b/docs/API_docs/methods/account.updateEmojiStatus.md new file mode 100644 index 0000000000..56257f44e9 --- /dev/null +++ b/docs/API_docs/methods/account.updateEmojiStatus.md @@ -0,0 +1,42 @@ +--- +title: "account.updateEmojiStatus" +description: "Set an [emoji status](https://core.telegram.org/api/emoji-status)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateEmojiStatus.html +--- +# Method: account.updateEmojiStatus +[Back to methods index](index.html) + + + +Set an [emoji status](https://core.telegram.org/api/emoji-status) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|emoji\_status|[EmojiStatus](/API_docs/types/EmojiStatus.html) | [Emoji status](https://core.telegram.org/api/emoji-status) to set | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateEmojiStatus(emoji_status: $EmojiStatus, ); +``` + diff --git a/docs/API_docs/methods/account.updateNotifySettings.md b/docs/API_docs/methods/account.updateNotifySettings.md new file mode 100644 index 0000000000..ed5c2a4067 --- /dev/null +++ b/docs/API_docs/methods/account.updateNotifySettings.md @@ -0,0 +1,43 @@ +--- +title: "account.updateNotifySettings" +description: "Edits notification settings from a given user/group, from all users/all groups." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateNotifySettings.html +--- +# Method: account.updateNotifySettings +[Back to methods index](index.html) + + + +Edits notification settings from a given user/group, from all users/all groups. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) | Notification source | Yes| +|settings|[InputPeerNotifySettings](/API_docs/types/InputPeerNotifySettings.html) | Notification settings | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateNotifySettings(peer: $InputNotifyPeer, settings: $InputPeerNotifySettings, ); +``` + diff --git a/docs/API_docs/methods/account.updatePasswordSettings.md b/docs/API_docs/methods/account.updatePasswordSettings.md new file mode 100644 index 0000000000..6ad890a2ac --- /dev/null +++ b/docs/API_docs/methods/account.updatePasswordSettings.md @@ -0,0 +1,43 @@ +--- +title: "account.updatePasswordSettings" +description: "You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updatePasswordSettings.html +--- +# Method: account.updatePasswordSettings +[Back to methods index](index.html) + + + +You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | The old password (see [SRP](https://core.telegram.org/api/srp)) | Yes| +|new\_settings|[account.PasswordInputSettings](/API_docs/types/account.PasswordInputSettings.html) | The new password (see [SRP](https://core.telegram.org/api/srp)) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updatePasswordSettings(password: $InputCheckPasswordSRP, new_settings: $account.PasswordInputSettings, ); +``` + diff --git a/docs/API_docs/methods/account.updatePersonalChannel.md b/docs/API_docs/methods/account.updatePersonalChannel.md new file mode 100644 index 0000000000..5763cb21bc --- /dev/null +++ b/docs/API_docs/methods/account.updatePersonalChannel.md @@ -0,0 +1,40 @@ +--- +title: "account.updatePersonalChannel" +description: "account.updatePersonalChannel parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updatePersonalChannel.html +--- +# Method: account.updatePersonalChannel +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updatePersonalChannel(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/account.updateProfile.md b/docs/API_docs/methods/account.updateProfile.md new file mode 100644 index 0000000000..95ac4670aa --- /dev/null +++ b/docs/API_docs/methods/account.updateProfile.md @@ -0,0 +1,44 @@ +--- +title: "account.updateProfile" +description: "Updates user profile." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateProfile.html +--- +# Method: account.updateProfile +[Back to methods index](index.html) + + + +Updates user profile. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|first\_name|[string](/API_docs/types/string.html) | New user first name | Optional| +|last\_name|[string](/API_docs/types/string.html) | New user last name | Optional| +|about|[string](/API_docs/types/string.html) | New bio | Optional| + + +### Return type: [User](/API_docs/types/User.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$User = $MadelineProto->account->updateProfile(first_name: 'string', last_name: 'string', about: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.updateStatus.md b/docs/API_docs/methods/account.updateStatus.md new file mode 100644 index 0000000000..04a79946f0 --- /dev/null +++ b/docs/API_docs/methods/account.updateStatus.md @@ -0,0 +1,42 @@ +--- +title: "account.updateStatus" +description: "Updates online user status." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateStatus.html +--- +# Method: account.updateStatus +[Back to methods index](index.html) + + + +Updates online user status. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|offline|[Bool](/API_docs/types/Bool.html) | If [(boolTrue)](../constructors/boolTrue.html) is transmitted, user status will change to [(userStatusOffline)](../constructors/userStatusOffline.html). | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->updateStatus(offline: $Bool, ); +``` + diff --git a/docs/API_docs/methods/account.updateTheme.md b/docs/API_docs/methods/account.updateTheme.md new file mode 100644 index 0000000000..83709aca60 --- /dev/null +++ b/docs/API_docs/methods/account.updateTheme.md @@ -0,0 +1,47 @@ +--- +title: "account.updateTheme" +description: "Update theme" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateTheme.html +--- +# Method: account.updateTheme +[Back to methods index](index.html) + + + +Update theme + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|format|[string](/API_docs/types/string.html) | Theme format, a string that identifies the theming engines supported by the client | Optional| +|theme|[InputTheme](/API_docs/types/InputTheme.html) | Theme to update | Yes| +|slug|[string](/API_docs/types/string.html) | Unique theme ID | Optional| +|title|[string](/API_docs/types/string.html) | Theme name | Optional| +|document|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Theme file | Optional| +|settings|Array of [InputThemeSettings](/API_docs/types/InputThemeSettings.html) | Theme settings | Optional| + + +### Return type: [Theme](/API_docs/types/Theme.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Theme = $MadelineProto->account->updateTheme(format: 'string', theme: $InputTheme, slug: 'string', title: 'string', document: $InputDocument, settings: [$InputThemeSettings, $InputThemeSettings], ); +``` + diff --git a/docs/API_docs/methods/account.updateUsername.md b/docs/API_docs/methods/account.updateUsername.md new file mode 100644 index 0000000000..8d6943a138 --- /dev/null +++ b/docs/API_docs/methods/account.updateUsername.md @@ -0,0 +1,42 @@ +--- +title: "account.updateUsername" +description: "Changes username for the current user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_updateUsername.html +--- +# Method: account.updateUsername +[Back to methods index](index.html) + + + +Changes username for the current user. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|username|[string](/API_docs/types/string.html) | username or empty string if username is to be removed
Accepted characters: a-z (case-insensitive), 0-9 and underscores.
Length: 5-32 characters. | Optional| + + +### Return type: [User](/API_docs/types/User.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$User = $MadelineProto->account->updateUsername(username: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.uploadRingtone.md b/docs/API_docs/methods/account.uploadRingtone.md new file mode 100644 index 0000000000..1d96979372 --- /dev/null +++ b/docs/API_docs/methods/account.uploadRingtone.md @@ -0,0 +1,44 @@ +--- +title: "account.uploadRingtone" +description: "Upload notification sound, use [account.saveRingtone](../methods/account.saveRingtone.html) to convert it and add it to the list of saved notification sounds." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_uploadRingtone.html +--- +# Method: account.uploadRingtone +[Back to methods index](index.html) + + + +Upload notification sound, use [account.saveRingtone](../methods/account.saveRingtone.html) to convert it and add it to the list of saved notification sounds. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Notification sound | Yes| +|file\_name|[string](/API_docs/types/string.html) | File name | Optional| +|mime\_type|[string](/API_docs/types/string.html) | MIME type of file | Optional| + + +### Return type: [Document](/API_docs/types/Document.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Document = $MadelineProto->account->uploadRingtone(file: $InputFile, file_name: 'string', mime_type: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.uploadTheme.md b/docs/API_docs/methods/account.uploadTheme.md new file mode 100644 index 0000000000..b97ea77b79 --- /dev/null +++ b/docs/API_docs/methods/account.uploadTheme.md @@ -0,0 +1,45 @@ +--- +title: "account.uploadTheme" +description: "Upload theme" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_uploadTheme.html +--- +# Method: account.uploadTheme +[Back to methods index](index.html) + + + +Upload theme + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | [Previously uploaded](https://core.telegram.org/api/themes#uploading-theme-files) theme file with platform-specific colors for UI components, can be left unset when creating themes that only modify the wallpaper or accent colors. | Yes| +|thumb|[File path or InputFile](/API_docs/types/InputFile.html) | Thumbnail | Optional| +|file\_name|[string](/API_docs/types/string.html) | File name | Optional| +|mime\_type|[string](/API_docs/types/string.html) | MIME type, must be `application/x-tgtheme-{format}`, where `format` depends on the client | Optional| + + +### Return type: [Document](/API_docs/types/Document.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Document = $MadelineProto->account->uploadTheme(file: $InputFile, thumb: $InputFile, file_name: 'string', mime_type: 'string', ); +``` + diff --git a/docs/API_docs/methods/account.uploadWallPaper.md b/docs/API_docs/methods/account.uploadWallPaper.md new file mode 100644 index 0000000000..0b6990e662 --- /dev/null +++ b/docs/API_docs/methods/account.uploadWallPaper.md @@ -0,0 +1,45 @@ +--- +title: "account.uploadWallPaper" +description: "Create and upload a new [wallpaper](https://core.telegram.org/api/wallpapers)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_uploadWallPaper.html +--- +# Method: account.uploadWallPaper +[Back to methods index](index.html) + + + +Create and upload a new [wallpaper](https://core.telegram.org/api/wallpapers) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|for\_chat|[Bool](/API_docs/types/Bool.html) | Set this flag when uploading wallpapers to be passed to [messages.setChatWallPaper](../methods/messages.setChatWallPaper.html). | Optional| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | The JPG/PNG wallpaper | Yes| +|mime\_type|[string](/API_docs/types/string.html) | MIME type of uploaded wallpaper | Optional| +|settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | Wallpaper settings | Yes| + + +### Return type: [WallPaper](/API_docs/types/WallPaper.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$WallPaper = $MadelineProto->account->uploadWallPaper(for_chat: $Bool, file: $InputFile, mime_type: 'string', settings: $WallPaperSettings, ); +``` + diff --git a/docs/API_docs/methods/account.verifyEmail.md b/docs/API_docs/methods/account.verifyEmail.md new file mode 100644 index 0000000000..862d7fce08 --- /dev/null +++ b/docs/API_docs/methods/account.verifyEmail.md @@ -0,0 +1,43 @@ +--- +title: "account.verifyEmail" +description: "Verify an email address." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_verifyEmail.html +--- +# Method: account.verifyEmail +[Back to methods index](index.html) + + + +Verify an email address. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|purpose|[EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html) | Verification purpose | Yes| +|verification|[EmailVerification](/API_docs/types/EmailVerification.html) | Email verification code or token | Yes| + + +### Return type: [account.EmailVerified](/API_docs/types/account.EmailVerified.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$account_EmailVerified = $MadelineProto->account->verifyEmail(purpose: $EmailVerifyPurpose, verification: $EmailVerification, ); +``` + diff --git a/docs/API_docs/methods/account.verifyPhone.md b/docs/API_docs/methods/account.verifyPhone.md new file mode 100644 index 0000000000..0d82b88beb --- /dev/null +++ b/docs/API_docs/methods/account.verifyPhone.md @@ -0,0 +1,44 @@ +--- +title: "account.verifyPhone" +description: "Verify a phone number for telegram [passport](https://core.telegram.org/passport)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/account_verifyPhone.html +--- +# Method: account.verifyPhone +[Back to methods index](index.html) + + + +Verify a phone number for telegram [passport](https://core.telegram.org/passport). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Phone number | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Phone code hash received from the call to [account.sendVerifyPhoneCode](../methods/account.sendVerifyPhoneCode.html) | Optional| +|phone\_code|[string](/API_docs/types/string.html) | Code received after the call to [account.sendVerifyPhoneCode](../methods/account.sendVerifyPhoneCode.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->account->verifyPhone(phone_number: 'string', phone_code_hash: 'string', phone_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/api_index.md b/docs/API_docs/methods/api_index.md new file mode 100644 index 0000000000..e0c9ab077f --- /dev/null +++ b/docs/API_docs/methods/api_index.md @@ -0,0 +1,2542 @@ +--- +title: Methods (API) +description: List of methods +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Methods +[Back to API documentation index](..) + +[Go to the new description-version method index](index.html) + +$MadelineProto->[logout](https://docs.madelineproto.xyz/logout.html)(); + +$MadelineProto->[phoneLogin](https://docs.madelineproto.xyz/phoneLogin.html)($number); + +$MadelineProto->[completePhoneLogin](https://docs.madelineproto.xyz/completePhoneLogin.html)($code); + +$MadelineProto->[complete2FALogin](https://docs.madelineproto.xyz/complete2FAlogin.html)($password); + +$MadelineProto->[botLogin](https://docs.madelineproto.xyz/botLogin.html)($token); + + +$MadelineProto->[getDialogs](https://docs.madelineproto.xyz/getDialogs.html)(); + +$MadelineProto->[getPwrChat](https://docs.madelineproto.xyz/getPwrChat.html)($id); + +$MadelineProto->[getInfo](https://docs.madelineproto.xyz/getInfo.html)($id); + +$MadelineProto->[getFullInfo](https://docs.madelineproto.xyz/getFullInfo.html)($id); + +$MadelineProto->[getSelf](https://docs.madelineproto.xyz/getSelf.html)(); + + +$MadelineProto->[requestCall](https://docs.madelineproto.xyz/requestCall.html)($id); + +$MadelineProto->[requestSecretChat](https://docs.madelineproto.xyz/requestSecretChat.html)($id); + +*** +

+$MadelineProto->[account->acceptAuthorization](/API_docs/methods/account.acceptAuthorization.html)(\[bot_id: $[long](/API_docs/types/long.html), scope: $[string](/API_docs/types/string.html), public_key: $[string](/API_docs/types/string.html), value_hashes: \[$[SecureValueHash](/API_docs/types/SecureValueHash.html)\], credentials: $[SecureCredentialsEncrypted](/API_docs/types/SecureCredentialsEncrypted.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->cancelPasswordEmail](/API_docs/methods/account.cancelPasswordEmail.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->changeAuthorizationSettings](/API_docs/methods/account.changeAuthorizationSettings.html)(\[confirmed: $[Bool](/API_docs/types/Bool.html), hash: $[long](/API_docs/types/long.html), encrypted_requests_disabled: $[Bool](/API_docs/types/Bool.html), call_requests_disabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->changePhone](/API_docs/methods/account.changePhone.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), phone_code: $[string](/API_docs/types/string.html), \]) === [$User](/API_docs/types/User.html) + +*** +

+$MadelineProto->[account->checkUsername](/API_docs/methods/account.checkUsername.html)(\[username: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->clearRecentEmojiStatuses](/API_docs/methods/account.clearRecentEmojiStatuses.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->confirmPasswordEmail](/API_docs/methods/account.confirmPasswordEmail.html)(\[code: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->confirmPhone](/API_docs/methods/account.confirmPhone.html)(\[phone_code_hash: $[string](/API_docs/types/string.html), phone_code: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->createBusinessChatLink](/API_docs/methods/account.createBusinessChatLink.html)(\[link: $[InputBusinessChatLink](/API_docs/types/InputBusinessChatLink.html), \]) === [$BusinessChatLink](/API_docs/types/BusinessChatLink.html) + +*** +

+$MadelineProto->[account->createTheme](/API_docs/methods/account.createTheme.html)(\[slug: $[string](/API_docs/types/string.html), title: $[string](/API_docs/types/string.html), document: $[InputDocument](/API_docs/types/InputDocument.html), settings: \[$[InputThemeSettings](/API_docs/types/InputThemeSettings.html)\], \]) === [$Theme](/API_docs/types/Theme.html) + +*** +

+$MadelineProto->[account->declinePasswordReset](/API_docs/methods/account.declinePasswordReset.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->deleteAccount](/API_docs/methods/account.deleteAccount.html)(\[reason: $[string](/API_docs/types/string.html), password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->deleteAutoSaveExceptions](/API_docs/methods/account.deleteAutoSaveExceptions.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->deleteBusinessChatLink](/API_docs/methods/account.deleteBusinessChatLink.html)(\[slug: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->deleteSecureValue](/API_docs/methods/account.deleteSecureValue.html)(\[types: \[$[SecureValueType](/API_docs/types/SecureValueType.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->disablePeerConnectedBot](/API_docs/methods/account.disablePeerConnectedBot.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->editBusinessChatLink](/API_docs/methods/account.editBusinessChatLink.html)(\[slug: $[string](/API_docs/types/string.html), link: $[InputBusinessChatLink](/API_docs/types/InputBusinessChatLink.html), \]) === [$BusinessChatLink](/API_docs/types/BusinessChatLink.html) + +*** +

+$MadelineProto->[account->finishTakeoutSession](/API_docs/methods/account.finishTakeoutSession.html)(\[success: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->getAccountTTL](/API_docs/methods/account.getAccountTTL.html)(\[\]) === [$AccountDaysTTL](/API_docs/types/AccountDaysTTL.html) + +*** +

+$MadelineProto->[account->getAllSecureValues](/API_docs/methods/account.getAllSecureValues.html)(\[\]) === [$Vector\_of\_SecureValue](/API_docs/types/SecureValue.html) + +*** +

+$MadelineProto->[account->getAuthorizationForm](/API_docs/methods/account.getAuthorizationForm.html)(\[bot_id: $[long](/API_docs/types/long.html), scope: $[string](/API_docs/types/string.html), public_key: $[string](/API_docs/types/string.html), \]) === [$account.AuthorizationForm](/API_docs/types/account.AuthorizationForm.html) + +*** +

+$MadelineProto->[account->getAuthorizations](/API_docs/methods/account.getAuthorizations.html)(\[\]) === [$account.Authorizations](/API_docs/types/account.Authorizations.html) + +*** +

+$MadelineProto->[account->getAutoDownloadSettings](/API_docs/methods/account.getAutoDownloadSettings.html)(\[\]) === [$account.AutoDownloadSettings](/API_docs/types/account.AutoDownloadSettings.html) + +*** +

+$MadelineProto->[account->getAutoSaveSettings](/API_docs/methods/account.getAutoSaveSettings.html)(\[\]) === [$account.AutoSaveSettings](/API_docs/types/account.AutoSaveSettings.html) + +*** +

+$MadelineProto->[account->getBotBusinessConnection](/API_docs/methods/account.getBotBusinessConnection.html)(\[connection_id: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[account->getBusinessChatLinks](/API_docs/methods/account.getBusinessChatLinks.html)(\[\]) === [$account.BusinessChatLinks](/API_docs/types/account.BusinessChatLinks.html) + +*** +

+$MadelineProto->[account->getChannelDefaultEmojiStatuses](/API_docs/methods/account.getChannelDefaultEmojiStatuses.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +*** +

+$MadelineProto->[account->getChannelRestrictedStatusEmojis](/API_docs/methods/account.getChannelRestrictedStatusEmojis.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$EmojiList](/API_docs/types/EmojiList.html) + +*** +

+$MadelineProto->[account->getChatThemes](/API_docs/methods/account.getChatThemes.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$account.Themes](/API_docs/types/account.Themes.html) + +*** +

+$MadelineProto->[account->getConnectedBots](/API_docs/methods/account.getConnectedBots.html)(\[\]) === [$account.ConnectedBots](/API_docs/types/account.ConnectedBots.html) + +*** +

+$MadelineProto->[account->getContactSignUpNotification](/API_docs/methods/account.getContactSignUpNotification.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->getContentSettings](/API_docs/methods/account.getContentSettings.html)(\[\]) === [$account.ContentSettings](/API_docs/types/account.ContentSettings.html) + +*** +

+$MadelineProto->[account->getDefaultBackgroundEmojis](/API_docs/methods/account.getDefaultBackgroundEmojis.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$EmojiList](/API_docs/types/EmojiList.html) + +*** +

+$MadelineProto->[account->getDefaultEmojiStatuses](/API_docs/methods/account.getDefaultEmojiStatuses.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +*** +

+$MadelineProto->[account->getDefaultGroupPhotoEmojis](/API_docs/methods/account.getDefaultGroupPhotoEmojis.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$EmojiList](/API_docs/types/EmojiList.html) + +*** +

+$MadelineProto->[account->getDefaultProfilePhotoEmojis](/API_docs/methods/account.getDefaultProfilePhotoEmojis.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$EmojiList](/API_docs/types/EmojiList.html) + +*** +

+$MadelineProto->[account->getGlobalPrivacySettings](/API_docs/methods/account.getGlobalPrivacySettings.html)(\[\]) === [$GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) + +*** +

+$MadelineProto->[account->getMultiWallPapers](/API_docs/methods/account.getMultiWallPapers.html)(\[wallpapers: \[$[InputWallPaper](/API_docs/types/InputWallPaper.html)\], \]) === [$Vector\_of\_WallPaper](/API_docs/types/WallPaper.html) + +*** +

+$MadelineProto->[account->getNotifyExceptions](/API_docs/methods/account.getNotifyExceptions.html)(\[compare_sound: $[Bool](/API_docs/types/Bool.html), compare_stories: $[Bool](/API_docs/types/Bool.html), peer: $[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[account->getNotifySettings](/API_docs/methods/account.getNotifySettings.html)(\[peer: $[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html), \]) === [$PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) + +*** +

+$MadelineProto->[account->getPassword](/API_docs/methods/account.getPassword.html)(\[\]) === [$account.Password](/API_docs/types/account.Password.html) + +*** +

+$MadelineProto->[account->getPasswordSettings](/API_docs/methods/account.getPasswordSettings.html)(\[password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), \]) === [$account.PasswordSettings](/API_docs/types/account.PasswordSettings.html) + +*** +

+$MadelineProto->[account->getPrivacy](/API_docs/methods/account.getPrivacy.html)(\[key: $[InputPrivacyKey](/API_docs/types/InputPrivacyKey.html), \]) === [$account.PrivacyRules](/API_docs/types/account.PrivacyRules.html) + +*** +

+$MadelineProto->[account->getReactionsNotifySettings](/API_docs/methods/account.getReactionsNotifySettings.html)(\[\]) === [$ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) + +*** +

+$MadelineProto->[account->getRecentEmojiStatuses](/API_docs/methods/account.getRecentEmojiStatuses.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +*** +

+$MadelineProto->[account->getSavedRingtones](/API_docs/methods/account.getSavedRingtones.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$account.SavedRingtones](/API_docs/types/account.SavedRingtones.html) + +*** +

+$MadelineProto->[account->getSecureValue](/API_docs/methods/account.getSecureValue.html)(\[types: \[$[SecureValueType](/API_docs/types/SecureValueType.html)\], \]) === [$Vector\_of\_SecureValue](/API_docs/types/SecureValue.html) + +*** +

+$MadelineProto->[account->getTheme](/API_docs/methods/account.getTheme.html)(\[format: $[string](/API_docs/types/string.html), theme: $[InputTheme](/API_docs/types/InputTheme.html), \]) === [$Theme](/API_docs/types/Theme.html) + +*** +

+$MadelineProto->[account->getThemes](/API_docs/methods/account.getThemes.html)(\[format: $[string](/API_docs/types/string.html), hash: $[long](/API_docs/types/long.html), \]) === [$account.Themes](/API_docs/types/account.Themes.html) + +*** +

+$MadelineProto->[account->getTmpPassword](/API_docs/methods/account.getTmpPassword.html)(\[password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), period: $[int](/API_docs/types/int.html), \]) === [$account.TmpPassword](/API_docs/types/account.TmpPassword.html) + +*** +

+$MadelineProto->[account->getWallPaper](/API_docs/methods/account.getWallPaper.html)(\[wallpaper: $[InputWallPaper](/API_docs/types/InputWallPaper.html), \]) === [$WallPaper](/API_docs/types/WallPaper.html) + +*** +

+$MadelineProto->[account->getWallPapers](/API_docs/methods/account.getWallPapers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$account.WallPapers](/API_docs/types/account.WallPapers.html) + +*** +

+$MadelineProto->[account->getWebAuthorizations](/API_docs/methods/account.getWebAuthorizations.html)(\[\]) === [$account.WebAuthorizations](/API_docs/types/account.WebAuthorizations.html) + +*** +

+$MadelineProto->[account->initTakeoutSession](/API_docs/methods/account.initTakeoutSession.html)(\[contacts: $[Bool](/API_docs/types/Bool.html), message_users: $[Bool](/API_docs/types/Bool.html), message_chats: $[Bool](/API_docs/types/Bool.html), message_megagroups: $[Bool](/API_docs/types/Bool.html), message_channels: $[Bool](/API_docs/types/Bool.html), files: $[Bool](/API_docs/types/Bool.html), file_max_size: $[long](/API_docs/types/long.html), \]) === [$account.Takeout](/API_docs/types/account.Takeout.html) + +*** +

+$MadelineProto->[account->installTheme](/API_docs/methods/account.installTheme.html)(\[dark: $[Bool](/API_docs/types/Bool.html), theme: $[InputTheme](/API_docs/types/InputTheme.html), format: $[string](/API_docs/types/string.html), base_theme: $[BaseTheme](/API_docs/types/BaseTheme.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->installWallPaper](/API_docs/methods/account.installWallPaper.html)(\[wallpaper: $[InputWallPaper](/API_docs/types/InputWallPaper.html), settings: $[WallPaperSettings](/API_docs/types/WallPaperSettings.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->invalidateSignInCodes](/API_docs/methods/account.invalidateSignInCodes.html)(\[codes: \[$[string](/API_docs/types/string.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->registerDevice](/API_docs/methods/account.registerDevice.html)(\[no_muted: $[Bool](/API_docs/types/Bool.html), token_type: $[int](/API_docs/types/int.html), token: $[string](/API_docs/types/string.html), app_sandbox: $[Bool](/API_docs/types/Bool.html), secret: $[bytes](/API_docs/types/bytes.html), other_uids: \[$[long](/API_docs/types/long.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->reorderUsernames](/API_docs/methods/account.reorderUsernames.html)(\[order: \[$[string](/API_docs/types/string.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->reportPeer](/API_docs/methods/account.reportPeer.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), reason: $[ReportReason](/API_docs/types/ReportReason.html), message: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->reportProfilePhoto](/API_docs/methods/account.reportProfilePhoto.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), photo_id: $[InputPhoto](/API_docs/types/InputPhoto.html), reason: $[ReportReason](/API_docs/types/ReportReason.html), message: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resendPasswordEmail](/API_docs/methods/account.resendPasswordEmail.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resetAuthorization](/API_docs/methods/account.resetAuthorization.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resetNotifySettings](/API_docs/methods/account.resetNotifySettings.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resetPassword](/API_docs/methods/account.resetPassword.html)(\[\]) === [$account.ResetPasswordResult](/API_docs/types/account.ResetPasswordResult.html) + +*** +

+$MadelineProto->[account->resetWallPapers](/API_docs/methods/account.resetWallPapers.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resetWebAuthorization](/API_docs/methods/account.resetWebAuthorization.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resetWebAuthorizations](/API_docs/methods/account.resetWebAuthorizations.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->resolveBusinessChatLink](/API_docs/methods/account.resolveBusinessChatLink.html)(\[slug: $[string](/API_docs/types/string.html), \]) === [$account.ResolvedBusinessChatLinks](/API_docs/types/account.ResolvedBusinessChatLinks.html) + +*** +

+$MadelineProto->[account->saveAutoDownloadSettings](/API_docs/methods/account.saveAutoDownloadSettings.html)(\[low: $[Bool](/API_docs/types/Bool.html), high: $[Bool](/API_docs/types/Bool.html), settings: $[AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->saveAutoSaveSettings](/API_docs/methods/account.saveAutoSaveSettings.html)(\[users: $[Bool](/API_docs/types/Bool.html), chats: $[Bool](/API_docs/types/Bool.html), broadcasts: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), settings: $[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->saveRingtone](/API_docs/methods/account.saveRingtone.html)(\[id: $[InputDocument](/API_docs/types/InputDocument.html), unsave: $[Bool](/API_docs/types/Bool.html), \]) === [$account.SavedRingtone](/API_docs/types/account.SavedRingtone.html) + +*** +

+$MadelineProto->[account->saveSecureValue](/API_docs/methods/account.saveSecureValue.html)(\[value: $[InputSecureValue](/API_docs/types/InputSecureValue.html), secure_secret_id: $[long](/API_docs/types/long.html), \]) === [$SecureValue](/API_docs/types/SecureValue.html) + +*** +

+$MadelineProto->[account->saveTheme](/API_docs/methods/account.saveTheme.html)(\[theme: $[InputTheme](/API_docs/types/InputTheme.html), unsave: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->saveWallPaper](/API_docs/methods/account.saveWallPaper.html)(\[wallpaper: $[InputWallPaper](/API_docs/types/InputWallPaper.html), unsave: $[Bool](/API_docs/types/Bool.html), settings: $[WallPaperSettings](/API_docs/types/WallPaperSettings.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->sendChangePhoneCode](/API_docs/methods/account.sendChangePhoneCode.html)(\[phone_number: $[string](/API_docs/types/string.html), settings: $[CodeSettings](/API_docs/types/CodeSettings.html), \]) === [$auth.SentCode](/API_docs/types/auth.SentCode.html) + +*** +

+$MadelineProto->[account->sendConfirmPhoneCode](/API_docs/methods/account.sendConfirmPhoneCode.html)(\[hash: $[string](/API_docs/types/string.html), settings: $[CodeSettings](/API_docs/types/CodeSettings.html), \]) === [$auth.SentCode](/API_docs/types/auth.SentCode.html) + +*** +

+$MadelineProto->[account->sendVerifyEmailCode](/API_docs/methods/account.sendVerifyEmailCode.html)(\[purpose: $[EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html), email: $[string](/API_docs/types/string.html), \]) === [$account.SentEmailCode](/API_docs/types/account.SentEmailCode.html) + +*** +

+$MadelineProto->[account->sendVerifyPhoneCode](/API_docs/methods/account.sendVerifyPhoneCode.html)(\[phone_number: $[string](/API_docs/types/string.html), settings: $[CodeSettings](/API_docs/types/CodeSettings.html), \]) === [$auth.SentCode](/API_docs/types/auth.SentCode.html) + +*** +

+$MadelineProto->[account->setAccountTTL](/API_docs/methods/account.setAccountTTL.html)(\[ttl: $[AccountDaysTTL](/API_docs/types/AccountDaysTTL.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->setAuthorizationTTL](/API_docs/methods/account.setAuthorizationTTL.html)(\[authorization_ttl_days: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->setContactSignUpNotification](/API_docs/methods/account.setContactSignUpNotification.html)(\[silent: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->setContentSettings](/API_docs/methods/account.setContentSettings.html)(\[sensitive_enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->setGlobalPrivacySettings](/API_docs/methods/account.setGlobalPrivacySettings.html)(\[settings: $[GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html), \]) === [$GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) + +*** +

+$MadelineProto->[account->setPrivacy](/API_docs/methods/account.setPrivacy.html)(\[key: $[InputPrivacyKey](/API_docs/types/InputPrivacyKey.html), rules: \[$[InputPrivacyRule](/API_docs/types/InputPrivacyRule.html)\], \]) === [$account.PrivacyRules](/API_docs/types/account.PrivacyRules.html) + +*** +

+$MadelineProto->[account->setReactionsNotifySettings](/API_docs/methods/account.setReactionsNotifySettings.html)(\[settings: $[ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html), \]) === [$ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) + +*** +

+$MadelineProto->[account->toggleConnectedBotPaused](/API_docs/methods/account.toggleConnectedBotPaused.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), paused: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->toggleSponsoredMessages](/API_docs/methods/account.toggleSponsoredMessages.html)(\[enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->toggleUsername](/API_docs/methods/account.toggleUsername.html)(\[username: $[string](/API_docs/types/string.html), active: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->unregisterDevice](/API_docs/methods/account.unregisterDevice.html)(\[token_type: $[int](/API_docs/types/int.html), token: $[string](/API_docs/types/string.html), other_uids: \[$[long](/API_docs/types/long.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateBirthday](/API_docs/methods/account.updateBirthday.html)(\[birthday: $[Birthday](/API_docs/types/Birthday.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateBusinessAwayMessage](/API_docs/methods/account.updateBusinessAwayMessage.html)(\[message: $[InputBusinessAwayMessage](/API_docs/types/InputBusinessAwayMessage.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateBusinessGreetingMessage](/API_docs/methods/account.updateBusinessGreetingMessage.html)(\[message: $[InputBusinessGreetingMessage](/API_docs/types/InputBusinessGreetingMessage.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateBusinessIntro](/API_docs/methods/account.updateBusinessIntro.html)(\[intro: $[InputBusinessIntro](/API_docs/types/InputBusinessIntro.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateBusinessLocation](/API_docs/methods/account.updateBusinessLocation.html)(\[geo_point: $[InputGeoPoint](/API_docs/types/InputGeoPoint.html), address: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateBusinessWorkHours](/API_docs/methods/account.updateBusinessWorkHours.html)(\[business_work_hours: $[BusinessWorkHours](/API_docs/types/BusinessWorkHours.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateColor](/API_docs/methods/account.updateColor.html)(\[for_profile: $[Bool](/API_docs/types/Bool.html), color: $[int](/API_docs/types/int.html), background_emoji_id: $[long](/API_docs/types/long.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateConnectedBot](/API_docs/methods/account.updateConnectedBot.html)(\[can_reply: $[Bool](/API_docs/types/Bool.html), deleted: $[Bool](/API_docs/types/Bool.html), bot: $[InputUser](/API_docs/types/InputUser.html), recipients: $[InputBusinessBotRecipients](/API_docs/types/InputBusinessBotRecipients.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[account->updateDeviceLocked](/API_docs/methods/account.updateDeviceLocked.html)(\[period: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateEmojiStatus](/API_docs/methods/account.updateEmojiStatus.html)(\[emoji_status: $[EmojiStatus](/API_docs/types/EmojiStatus.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateNotifySettings](/API_docs/methods/account.updateNotifySettings.html)(\[peer: $[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html), settings: $[InputPeerNotifySettings](/API_docs/types/InputPeerNotifySettings.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updatePasswordSettings](/API_docs/methods/account.updatePasswordSettings.html)(\[password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), new_settings: $[account.PasswordInputSettings](/API_docs/types/account.PasswordInputSettings.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updatePersonalChannel](/API_docs/methods/account.updatePersonalChannel.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateProfile](/API_docs/methods/account.updateProfile.html)(\[first_name: $[string](/API_docs/types/string.html), last_name: $[string](/API_docs/types/string.html), about: $[string](/API_docs/types/string.html), \]) === [$User](/API_docs/types/User.html) + +*** +

+$MadelineProto->[account->updateStatus](/API_docs/methods/account.updateStatus.html)(\[offline: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[account->updateTheme](/API_docs/methods/account.updateTheme.html)(\[format: $[string](/API_docs/types/string.html), theme: $[InputTheme](/API_docs/types/InputTheme.html), slug: $[string](/API_docs/types/string.html), title: $[string](/API_docs/types/string.html), document: $[InputDocument](/API_docs/types/InputDocument.html), settings: \[$[InputThemeSettings](/API_docs/types/InputThemeSettings.html)\], \]) === [$Theme](/API_docs/types/Theme.html) + +*** +

+$MadelineProto->[account->updateUsername](/API_docs/methods/account.updateUsername.html)(\[username: $[string](/API_docs/types/string.html), \]) === [$User](/API_docs/types/User.html) + +*** +

+$MadelineProto->[account->uploadRingtone](/API_docs/methods/account.uploadRingtone.html)(\[file: $[InputFile](/API_docs/types/InputFile.html), file_name: $[string](/API_docs/types/string.html), mime_type: $[string](/API_docs/types/string.html), \]) === [$Document](/API_docs/types/Document.html) + +*** +

+$MadelineProto->[account->uploadTheme](/API_docs/methods/account.uploadTheme.html)(\[file: $[InputFile](/API_docs/types/InputFile.html), thumb: $[InputFile](/API_docs/types/InputFile.html), file_name: $[string](/API_docs/types/string.html), mime_type: $[string](/API_docs/types/string.html), \]) === [$Document](/API_docs/types/Document.html) + +*** +

+$MadelineProto->[account->uploadWallPaper](/API_docs/methods/account.uploadWallPaper.html)(\[for_chat: $[Bool](/API_docs/types/Bool.html), file: $[InputFile](/API_docs/types/InputFile.html), mime_type: $[string](/API_docs/types/string.html), settings: $[WallPaperSettings](/API_docs/types/WallPaperSettings.html), \]) === [$WallPaper](/API_docs/types/WallPaper.html) + +*** +

+$MadelineProto->[account->verifyEmail](/API_docs/methods/account.verifyEmail.html)(\[purpose: $[EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html), verification: $[EmailVerification](/API_docs/types/EmailVerification.html), \]) === [$account.EmailVerified](/API_docs/types/account.EmailVerified.html) + +*** +

+$MadelineProto->[account->verifyPhone](/API_docs/methods/account.verifyPhone.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), phone_code: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->acceptLoginToken](/API_docs/methods/auth.acceptLoginToken.html)(\[token: $[bytes](/API_docs/types/bytes.html), \]) === [$Authorization](/API_docs/types/Authorization.html) + +*** +

+$MadelineProto->[auth->bindTempAuthKey](/API_docs/methods/auth.bindTempAuthKey.html)(\[perm_auth_key_id: $[long](/API_docs/types/long.html), nonce: $[long](/API_docs/types/long.html), expires_at: $[int](/API_docs/types/int.html), encrypted_message: $[bytes](/API_docs/types/bytes.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->cancelCode](/API_docs/methods/auth.cancelCode.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->checkPassword](/API_docs/methods/auth.checkPassword.html)(\[password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[auth->checkRecoveryPassword](/API_docs/methods/auth.checkRecoveryPassword.html)(\[code: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->dropTempAuthKeys](/API_docs/methods/auth.dropTempAuthKeys.html)(\[except_auth_keys: \[$[long](/API_docs/types/long.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->exportAuthorization](/API_docs/methods/auth.exportAuthorization.html)(\[dc_id: $[int](/API_docs/types/int.html), \]) === [$auth.ExportedAuthorization](/API_docs/types/auth.ExportedAuthorization.html) + +*** +

+$MadelineProto->[auth->exportLoginToken](/API_docs/methods/auth.exportLoginToken.html)(\[api_id: $[int](/API_docs/types/int.html), api_hash: $[string](/API_docs/types/string.html), except_ids: \[$[long](/API_docs/types/long.html)\], \]) === [$auth.LoginToken](/API_docs/types/auth.LoginToken.html) + +*** +

+$MadelineProto->[auth->importAuthorization](/API_docs/methods/auth.importAuthorization.html)(\[id: $[long](/API_docs/types/long.html), bytes: $[bytes](/API_docs/types/bytes.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[auth->importBotAuthorization](/API_docs/methods/auth.importBotAuthorization.html)(\[api_id: $[int](/API_docs/types/int.html), api_hash: $[string](/API_docs/types/string.html), bot_auth_token: $[string](/API_docs/types/string.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[auth->importLoginToken](/API_docs/methods/auth.importLoginToken.html)(\[token: $[bytes](/API_docs/types/bytes.html), \]) === [$auth.LoginToken](/API_docs/types/auth.LoginToken.html) + +*** +

+$MadelineProto->[auth->importWebTokenAuthorization](/API_docs/methods/auth.importWebTokenAuthorization.html)(\[api_id: $[int](/API_docs/types/int.html), api_hash: $[string](/API_docs/types/string.html), web_auth_token: $[string](/API_docs/types/string.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[auth->logOut](/API_docs/methods/auth.logOut.html)(\[\]) === [$auth.LoggedOut](/API_docs/types/auth.LoggedOut.html) + +*** +

+$MadelineProto->[auth->recoverPassword](/API_docs/methods/auth.recoverPassword.html)(\[code: $[string](/API_docs/types/string.html), new_settings: $[account.PasswordInputSettings](/API_docs/types/account.PasswordInputSettings.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[auth->reportMissingCode](/API_docs/methods/auth.reportMissingCode.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), mnc: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->requestFirebaseSms](/API_docs/methods/auth.requestFirebaseSms.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), safety_net_token: $[string](/API_docs/types/string.html), ios_push_secret: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->requestPasswordRecovery](/API_docs/methods/auth.requestPasswordRecovery.html)(\[\]) === [$auth.PasswordRecovery](/API_docs/types/auth.PasswordRecovery.html) + +*** +

+$MadelineProto->[auth->resendCode](/API_docs/methods/auth.resendCode.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), \]) === [$auth.SentCode](/API_docs/types/auth.SentCode.html) + +*** +

+$MadelineProto->[auth->resetAuthorizations](/API_docs/methods/auth.resetAuthorizations.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[auth->resetLoginEmail](/API_docs/methods/auth.resetLoginEmail.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), \]) === [$auth.SentCode](/API_docs/types/auth.SentCode.html) + +*** +

+$MadelineProto->[auth->sendCode](/API_docs/methods/auth.sendCode.html)(\[phone_number: $[string](/API_docs/types/string.html), api_id: $[int](/API_docs/types/int.html), api_hash: $[string](/API_docs/types/string.html), settings: $[CodeSettings](/API_docs/types/CodeSettings.html), \]) === [$auth.SentCode](/API_docs/types/auth.SentCode.html) + +*** +

+$MadelineProto->[auth->signIn](/API_docs/methods/auth.signIn.html)(\[phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), phone_code: $[string](/API_docs/types/string.html), email_verification: $[EmailVerification](/API_docs/types/EmailVerification.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[auth->signUp](/API_docs/methods/auth.signUp.html)(\[no_joined_notifications: $[Bool](/API_docs/types/Bool.html), phone_number: $[string](/API_docs/types/string.html), phone_code_hash: $[string](/API_docs/types/string.html), first_name: $[string](/API_docs/types/string.html), last_name: $[string](/API_docs/types/string.html), \]) === [$auth.Authorization](/API_docs/types/auth.Authorization.html) + +*** +

+$MadelineProto->[bots->allowSendMessage](/API_docs/methods/bots.allowSendMessage.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[bots->answerWebhookJSONQuery](/API_docs/methods/bots.answerWebhookJSONQuery.html)(\[query_id: $[long](/API_docs/types/long.html), data: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->canSendMessage](/API_docs/methods/bots.canSendMessage.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->getBotCommands](/API_docs/methods/bots.getBotCommands.html)(\[scope: $[BotCommandScope](/API_docs/types/BotCommandScope.html), lang_code: $[string](/API_docs/types/string.html), \]) === [$Vector\_of\_BotCommand](/API_docs/types/BotCommand.html) + +*** +

+$MadelineProto->[bots->getBotInfo](/API_docs/methods/bots.getBotInfo.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), lang_code: $[string](/API_docs/types/string.html), \]) === [$bots.BotInfo](/API_docs/types/bots.BotInfo.html) + +*** +

+$MadelineProto->[bots->getBotMenuButton](/API_docs/methods/bots.getBotMenuButton.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$BotMenuButton](/API_docs/types/BotMenuButton.html) + +*** +

+$MadelineProto->[bots->invokeWebViewCustomMethod](/API_docs/methods/bots.invokeWebViewCustomMethod.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), custom_method: $[string](/API_docs/types/string.html), params: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$DataJSON](/API_docs/types/DataJSON.html) + +*** +

+$MadelineProto->[bots->reorderUsernames](/API_docs/methods/bots.reorderUsernames.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), order: \[$[string](/API_docs/types/string.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->resetBotCommands](/API_docs/methods/bots.resetBotCommands.html)(\[scope: $[BotCommandScope](/API_docs/types/BotCommandScope.html), lang_code: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->sendCustomRequest](/API_docs/methods/bots.sendCustomRequest.html)(\[custom_method: $[string](/API_docs/types/string.html), params: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$DataJSON](/API_docs/types/DataJSON.html) + +*** +

+$MadelineProto->[bots->setBotBroadcastDefaultAdminRights](/API_docs/methods/bots.setBotBroadcastDefaultAdminRights.html)(\[admin_rights: $[ChatAdminRights](/API_docs/types/ChatAdminRights.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->setBotCommands](/API_docs/methods/bots.setBotCommands.html)(\[scope: $[BotCommandScope](/API_docs/types/BotCommandScope.html), lang_code: $[string](/API_docs/types/string.html), commands: \[$[BotCommand](/API_docs/types/BotCommand.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->setBotGroupDefaultAdminRights](/API_docs/methods/bots.setBotGroupDefaultAdminRights.html)(\[admin_rights: $[ChatAdminRights](/API_docs/types/ChatAdminRights.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->setBotInfo](/API_docs/methods/bots.setBotInfo.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), lang_code: $[string](/API_docs/types/string.html), name: $[string](/API_docs/types/string.html), about: $[string](/API_docs/types/string.html), description: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->setBotMenuButton](/API_docs/methods/bots.setBotMenuButton.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), button: $[BotMenuButton](/API_docs/types/BotMenuButton.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[bots->toggleUsername](/API_docs/methods/bots.toggleUsername.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), username: $[string](/API_docs/types/string.html), active: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->checkUsername](/API_docs/methods/channels.checkUsername.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), username: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->clickSponsoredMessage](/API_docs/methods/channels.clickSponsoredMessage.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->convertToGigagroup](/API_docs/methods/channels.convertToGigagroup.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->createChannel](/API_docs/methods/channels.createChannel.html)(\[broadcast: $[Bool](/API_docs/types/Bool.html), megagroup: $[Bool](/API_docs/types/Bool.html), for_import: $[Bool](/API_docs/types/Bool.html), forum: $[Bool](/API_docs/types/Bool.html), title: $[string](/API_docs/types/string.html), about: $[string](/API_docs/types/string.html), geo_point: $[InputGeoPoint](/API_docs/types/InputGeoPoint.html), address: $[string](/API_docs/types/string.html), ttl_period: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->createForumTopic](/API_docs/methods/channels.createForumTopic.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), title: $[string](/API_docs/types/string.html), icon_color: $[int](/API_docs/types/int.html), icon_emoji_id: $[long](/API_docs/types/long.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->deactivateAllUsernames](/API_docs/methods/channels.deactivateAllUsernames.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->deleteChannel](/API_docs/methods/channels.deleteChannel.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->deleteHistory](/API_docs/methods/channels.deleteHistory.html)(\[for_everyone: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), max_id: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->deleteMessages](/API_docs/methods/channels.deleteMessages.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +*** +

+$MadelineProto->[channels->deleteParticipantHistory](/API_docs/methods/channels.deleteParticipantHistory.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), participant: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[channels->deleteTopicHistory](/API_docs/methods/channels.deleteTopicHistory.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), top_msg_id: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[channels->editAdmin](/API_docs/methods/channels.editAdmin.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), user_id: $[InputUser](/API_docs/types/InputUser.html), admin_rights: $[ChatAdminRights](/API_docs/types/ChatAdminRights.html), rank: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->editBanned](/API_docs/methods/channels.editBanned.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), participant: $[InputPeer](/API_docs/types/InputPeer.html), banned_rights: $[ChatBannedRights](/API_docs/types/ChatBannedRights.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->editCreator](/API_docs/methods/channels.editCreator.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), user_id: $[InputUser](/API_docs/types/InputUser.html), password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->editForumTopic](/API_docs/methods/channels.editForumTopic.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), topic_id: $[int](/API_docs/types/int.html), title: $[string](/API_docs/types/string.html), icon_emoji_id: $[long](/API_docs/types/long.html), closed: $[Bool](/API_docs/types/Bool.html), hidden: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->editLocation](/API_docs/methods/channels.editLocation.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), geo_point: $[InputGeoPoint](/API_docs/types/InputGeoPoint.html), address: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->editPhoto](/API_docs/methods/channels.editPhoto.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), photo: $[InputChatPhoto](/API_docs/types/InputChatPhoto.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->editTitle](/API_docs/methods/channels.editTitle.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), title: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->exportMessageLink](/API_docs/methods/channels.exportMessageLink.html)(\[grouped: $[Bool](/API_docs/types/Bool.html), thread: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), id: $[int](/API_docs/types/int.html), \]) === [$ExportedMessageLink](/API_docs/types/ExportedMessageLink.html) + +*** +

+$MadelineProto->[channels->getAdminLog](/API_docs/methods/channels.getAdminLog.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), q: $[string](/API_docs/types/string.html), events_filter: $[ChannelAdminLogEventsFilter](/API_docs/types/ChannelAdminLogEventsFilter.html), admins: \[$[InputUser](/API_docs/types/InputUser.html)\], max_id: $[long](/API_docs/types/long.html), min_id: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$channels.AdminLogResults](/API_docs/types/channels.AdminLogResults.html) + +*** +

+$MadelineProto->[channels->getAdminedPublicChannels](/API_docs/methods/channels.getAdminedPublicChannels.html)(\[by_location: $[Bool](/API_docs/types/Bool.html), check_limit: $[Bool](/API_docs/types/Bool.html), for_personal: $[Bool](/API_docs/types/Bool.html), \]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[channels->getChannelRecommendations](/API_docs/methods/channels.getChannelRecommendations.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[channels->getChannels](/API_docs/methods/channels.getChannels.html)(\[id: \[$[InputChannel](/API_docs/types/InputChannel.html)\], \]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[channels->getForumTopics](/API_docs/methods/channels.getForumTopics.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), q: $[string](/API_docs/types/string.html), offset_date: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), offset_topic: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.ForumTopics](/API_docs/types/messages.ForumTopics.html) + +*** +

+$MadelineProto->[channels->getForumTopicsByID](/API_docs/methods/channels.getForumTopicsByID.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), topics: \[$[int](/API_docs/types/int.html)\], \]) === [$messages.ForumTopics](/API_docs/types/messages.ForumTopics.html) + +*** +

+$MadelineProto->[channels->getFullChannel](/API_docs/methods/channels.getFullChannel.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$messages.ChatFull](/API_docs/types/messages.ChatFull.html) + +*** +

+$MadelineProto->[channels->getGroupsForDiscussion](/API_docs/methods/channels.getGroupsForDiscussion.html)(\[\]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[channels->getInactiveChannels](/API_docs/methods/channels.getInactiveChannels.html)(\[\]) === [$messages.InactiveChats](/API_docs/types/messages.InactiveChats.html) + +*** +

+$MadelineProto->[channels->getLeftChannels](/API_docs/methods/channels.getLeftChannels.html)(\[offset: $[int](/API_docs/types/int.html), \]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[channels->getMessages](/API_docs/methods/channels.getMessages.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), id: \[$[InputMessage](/API_docs/types/InputMessage.html)\], \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[channels->getParticipant](/API_docs/methods/channels.getParticipant.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), participant: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$channels.ChannelParticipant](/API_docs/types/channels.ChannelParticipant.html) + +*** +

+$MadelineProto->[channels->getParticipants](/API_docs/methods/channels.getParticipants.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), filter: $[ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html), offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$channels.ChannelParticipants](/API_docs/types/channels.ChannelParticipants.html) + +*** +

+$MadelineProto->[channels->getSendAs](/API_docs/methods/channels.getSendAs.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$channels.SendAsPeers](/API_docs/types/channels.SendAsPeers.html) + +*** +

+$MadelineProto->[channels->getSponsoredMessages](/API_docs/methods/channels.getSponsoredMessages.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$messages.SponsoredMessages](/API_docs/types/messages.SponsoredMessages.html) + +*** +

+$MadelineProto->[channels->inviteToChannel](/API_docs/methods/channels.inviteToChannel.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), users: \[$[InputUser](/API_docs/types/InputUser.html)\], \]) === [$messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +*** +

+$MadelineProto->[channels->joinChannel](/API_docs/methods/channels.joinChannel.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->leaveChannel](/API_docs/methods/channels.leaveChannel.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->readHistory](/API_docs/methods/channels.readHistory.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), max_id: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->readMessageContents](/API_docs/methods/channels.readMessageContents.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->reorderPinnedForumTopics](/API_docs/methods/channels.reorderPinnedForumTopics.html)(\[force: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), order: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->reorderUsernames](/API_docs/methods/channels.reorderUsernames.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), order: \[$[string](/API_docs/types/string.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->reportAntiSpamFalsePositive](/API_docs/methods/channels.reportAntiSpamFalsePositive.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->reportSpam](/API_docs/methods/channels.reportSpam.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), participant: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->reportSponsoredMessage](/API_docs/methods/channels.reportSponsoredMessage.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), option: $[bytes](/API_docs/types/bytes.html), \]) === [$channels.SponsoredMessageReportResult](/API_docs/types/channels.SponsoredMessageReportResult.html) + +*** +

+$MadelineProto->[channels->restrictSponsoredMessages](/API_docs/methods/channels.restrictSponsoredMessages.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), restricted: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->setBoostsToUnblockRestrictions](/API_docs/methods/channels.setBoostsToUnblockRestrictions.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), boosts: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->setDiscussionGroup](/API_docs/methods/channels.setDiscussionGroup.html)(\[broadcast: $[InputChannel](/API_docs/types/InputChannel.html), group: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->setEmojiStickers](/API_docs/methods/channels.setEmojiStickers.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->setStickers](/API_docs/methods/channels.setStickers.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->toggleAntiSpam](/API_docs/methods/channels.toggleAntiSpam.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleForum](/API_docs/methods/channels.toggleForum.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleJoinRequest](/API_docs/methods/channels.toggleJoinRequest.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleJoinToSend](/API_docs/methods/channels.toggleJoinToSend.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleParticipantsHidden](/API_docs/methods/channels.toggleParticipantsHidden.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->togglePreHistoryHidden](/API_docs/methods/channels.togglePreHistoryHidden.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleSignatures](/API_docs/methods/channels.toggleSignatures.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleSlowMode](/API_docs/methods/channels.toggleSlowMode.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), seconds: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->toggleUsername](/API_docs/methods/channels.toggleUsername.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), username: $[string](/API_docs/types/string.html), active: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->toggleViewForumAsMessages](/API_docs/methods/channels.toggleViewForumAsMessages.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->updateColor](/API_docs/methods/channels.updateColor.html)(\[for_profile: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), color: $[int](/API_docs/types/int.html), background_emoji_id: $[long](/API_docs/types/long.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->updateEmojiStatus](/API_docs/methods/channels.updateEmojiStatus.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), emoji_status: $[EmojiStatus](/API_docs/types/EmojiStatus.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->updatePinnedForumTopic](/API_docs/methods/channels.updatePinnedForumTopic.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), topic_id: $[int](/API_docs/types/int.html), pinned: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[channels->updateUsername](/API_docs/methods/channels.updateUsername.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), username: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[channels->viewSponsoredMessage](/API_docs/methods/channels.viewSponsoredMessage.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[chatlists->checkChatlistInvite](/API_docs/methods/chatlists.checkChatlistInvite.html)(\[slug: $[string](/API_docs/types/string.html), \]) === [$chatlists.ChatlistInvite](/API_docs/types/chatlists.ChatlistInvite.html) + +*** +

+$MadelineProto->[chatlists->deleteExportedInvite](/API_docs/methods/chatlists.deleteExportedInvite.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), slug: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[chatlists->editExportedInvite](/API_docs/methods/chatlists.editExportedInvite.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), slug: $[string](/API_docs/types/string.html), title: $[string](/API_docs/types/string.html), peers: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html) + +*** +

+$MadelineProto->[chatlists->exportChatlistInvite](/API_docs/methods/chatlists.exportChatlistInvite.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), title: $[string](/API_docs/types/string.html), peers: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$chatlists.ExportedChatlistInvite](/API_docs/types/chatlists.ExportedChatlistInvite.html) + +*** +

+$MadelineProto->[chatlists->getChatlistUpdates](/API_docs/methods/chatlists.getChatlistUpdates.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), \]) === [$chatlists.ChatlistUpdates](/API_docs/types/chatlists.ChatlistUpdates.html) + +*** +

+$MadelineProto->[chatlists->getExportedInvites](/API_docs/methods/chatlists.getExportedInvites.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), \]) === [$chatlists.ExportedInvites](/API_docs/types/chatlists.ExportedInvites.html) + +*** +

+$MadelineProto->[chatlists->getLeaveChatlistSuggestions](/API_docs/methods/chatlists.getLeaveChatlistSuggestions.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), \]) === [$Vector\_of\_Peer](/API_docs/types/Peer.html) + +*** +

+$MadelineProto->[chatlists->hideChatlistUpdates](/API_docs/methods/chatlists.hideChatlistUpdates.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[chatlists->joinChatlistInvite](/API_docs/methods/chatlists.joinChatlistInvite.html)(\[slug: $[string](/API_docs/types/string.html), peers: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[chatlists->joinChatlistUpdates](/API_docs/methods/chatlists.joinChatlistUpdates.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), peers: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[chatlists->leaveChatlist](/API_docs/methods/chatlists.leaveChatlist.html)(\[chatlist: $[InputChatlist](/API_docs/types/InputChatlist.html), peers: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[contacts->acceptContact](/API_docs/methods/contacts.acceptContact.html)(\[id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[contacts->addContact](/API_docs/methods/contacts.addContact.html)(\[add_phone_privacy_exception: $[Bool](/API_docs/types/Bool.html), id: $[InputUser](/API_docs/types/InputUser.html), first_name: $[string](/API_docs/types/string.html), last_name: $[string](/API_docs/types/string.html), phone: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[contacts->block](/API_docs/methods/contacts.block.html)(\[my_stories_from: $[Bool](/API_docs/types/Bool.html), id: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->blockFromReplies](/API_docs/methods/contacts.blockFromReplies.html)(\[delete_message: $[Bool](/API_docs/types/Bool.html), delete_history: $[Bool](/API_docs/types/Bool.html), report_spam: $[Bool](/API_docs/types/Bool.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[contacts->deleteByPhones](/API_docs/methods/contacts.deleteByPhones.html)(\[phones: \[$[string](/API_docs/types/string.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->deleteContacts](/API_docs/methods/contacts.deleteContacts.html)(\[id: \[$[InputUser](/API_docs/types/InputUser.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[contacts->editCloseFriends](/API_docs/methods/contacts.editCloseFriends.html)(\[id: \[$[long](/API_docs/types/long.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->exportContactToken](/API_docs/methods/contacts.exportContactToken.html)(\[\]) === [$ExportedContactToken](/API_docs/types/ExportedContactToken.html) + +*** +

+$MadelineProto->[contacts->getBirthdays](/API_docs/methods/contacts.getBirthdays.html)(\[\]) === [$contacts.ContactBirthdays](/API_docs/types/contacts.ContactBirthdays.html) + +*** +

+$MadelineProto->[contacts->getBlocked](/API_docs/methods/contacts.getBlocked.html)(\[my_stories_from: $[Bool](/API_docs/types/Bool.html), offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$contacts.Blocked](/API_docs/types/contacts.Blocked.html) + +*** +

+$MadelineProto->[contacts->getContactIDs](/API_docs/methods/contacts.getContactIDs.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$Vector\_of\_int](/API_docs/types/int.html) + +*** +

+$MadelineProto->[contacts->getContacts](/API_docs/methods/contacts.getContacts.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$contacts.Contacts](/API_docs/types/contacts.Contacts.html) + +*** +

+$MadelineProto->[contacts->getLocated](/API_docs/methods/contacts.getLocated.html)(\[background: $[Bool](/API_docs/types/Bool.html), geo_point: $[InputGeoPoint](/API_docs/types/InputGeoPoint.html), self_expires: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[contacts->getSaved](/API_docs/methods/contacts.getSaved.html)(\[\]) === [$Vector\_of\_SavedContact](/API_docs/types/SavedContact.html) + +*** +

+$MadelineProto->[contacts->getStatuses](/API_docs/methods/contacts.getStatuses.html)(\[\]) === [$Vector\_of\_ContactStatus](/API_docs/types/ContactStatus.html) + +*** +

+$MadelineProto->[contacts->getTopPeers](/API_docs/methods/contacts.getTopPeers.html)(\[correspondents: $[Bool](/API_docs/types/Bool.html), bots_pm: $[Bool](/API_docs/types/Bool.html), bots_inline: $[Bool](/API_docs/types/Bool.html), phone_calls: $[Bool](/API_docs/types/Bool.html), forward_users: $[Bool](/API_docs/types/Bool.html), forward_chats: $[Bool](/API_docs/types/Bool.html), groups: $[Bool](/API_docs/types/Bool.html), channels: $[Bool](/API_docs/types/Bool.html), offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$contacts.TopPeers](/API_docs/types/contacts.TopPeers.html) + +*** +

+$MadelineProto->[contacts->importContactToken](/API_docs/methods/contacts.importContactToken.html)(\[token: $[string](/API_docs/types/string.html), \]) === [$User](/API_docs/types/User.html) + +*** +

+$MadelineProto->[contacts->importContacts](/API_docs/methods/contacts.importContacts.html)(\[contacts: \[$[InputContact](/API_docs/types/InputContact.html)\], \]) === [$contacts.ImportedContacts](/API_docs/types/contacts.ImportedContacts.html) + +*** +

+$MadelineProto->[contacts->resetSaved](/API_docs/methods/contacts.resetSaved.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->resetTopPeerRating](/API_docs/methods/contacts.resetTopPeerRating.html)(\[category: $[TopPeerCategory](/API_docs/types/TopPeerCategory.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->resolvePhone](/API_docs/methods/contacts.resolvePhone.html)(\[phone: $[string](/API_docs/types/string.html), \]) === [$contacts.ResolvedPeer](/API_docs/types/contacts.ResolvedPeer.html) + +*** +

+$MadelineProto->[contacts->resolveUsername](/API_docs/methods/contacts.resolveUsername.html)(\[username: $[string](/API_docs/types/string.html), \]) === [$contacts.ResolvedPeer](/API_docs/types/contacts.ResolvedPeer.html) + +*** +

+$MadelineProto->[contacts->search](/API_docs/methods/contacts.search.html)(\[q: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$contacts.Found](/API_docs/types/contacts.Found.html) + +*** +

+$MadelineProto->[contacts->setBlocked](/API_docs/methods/contacts.setBlocked.html)(\[my_stories_from: $[Bool](/API_docs/types/Bool.html), id: \[$[InputPeer](/API_docs/types/InputPeer.html)\], limit: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->toggleTopPeers](/API_docs/methods/contacts.toggleTopPeers.html)(\[enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[contacts->unblock](/API_docs/methods/contacts.unblock.html)(\[my_stories_from: $[Bool](/API_docs/types/Bool.html), id: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[folders->editPeerFolders](/API_docs/methods/folders.editPeerFolders.html)(\[folder_peers: \[$[InputFolderPeer](/API_docs/types/InputFolderPeer.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[fragment->getCollectibleInfo](/API_docs/methods/fragment.getCollectibleInfo.html)(\[collectible: $[InputCollectible](/API_docs/types/InputCollectible.html), \]) === [$fragment.CollectibleInfo](/API_docs/types/fragment.CollectibleInfo.html) + +*** +

+$MadelineProto->[help->acceptTermsOfService](/API_docs/methods/help.acceptTermsOfService.html)(\[id: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[help->dismissSuggestion](/API_docs/methods/help.dismissSuggestion.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), suggestion: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[help->editUserInfo](/API_docs/methods/help.editUserInfo.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), message: $[string](/API_docs/types/string.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], \]) === [$help.UserInfo](/API_docs/types/help.UserInfo.html) + +*** +

+$MadelineProto->[help->getAppConfig](/API_docs/methods/help.getAppConfig.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$help.AppConfig](/API_docs/types/help.AppConfig.html) + +*** +

+$MadelineProto->[help->getAppUpdate](/API_docs/methods/help.getAppUpdate.html)(\[source: $[string](/API_docs/types/string.html), \]) === [$help.AppUpdate](/API_docs/types/help.AppUpdate.html) + +*** +

+$MadelineProto->[help->getCdnConfig](/API_docs/methods/help.getCdnConfig.html)(\[\]) === [$CdnConfig](/API_docs/types/CdnConfig.html) + +*** +

+$MadelineProto->[help->getConfig](/API_docs/methods/help.getConfig.html)(\[\]) === [$Config](/API_docs/types/Config.html) + +*** +

+$MadelineProto->[help->getCountriesList](/API_docs/methods/help.getCountriesList.html)(\[lang_code: $[string](/API_docs/types/string.html), hash: $[int](/API_docs/types/int.html), \]) === [$help.CountriesList](/API_docs/types/help.CountriesList.html) + +*** +

+$MadelineProto->[help->getDeepLinkInfo](/API_docs/methods/help.getDeepLinkInfo.html)(\[path: $[string](/API_docs/types/string.html), \]) === [$help.DeepLinkInfo](/API_docs/types/help.DeepLinkInfo.html) + +*** +

+$MadelineProto->[help->getInviteText](/API_docs/methods/help.getInviteText.html)(\[\]) === [$help.InviteText](/API_docs/types/help.InviteText.html) + +*** +

+$MadelineProto->[help->getNearestDc](/API_docs/methods/help.getNearestDc.html)(\[\]) === [$NearestDc](/API_docs/types/NearestDc.html) + +*** +

+$MadelineProto->[help->getPassportConfig](/API_docs/methods/help.getPassportConfig.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$help.PassportConfig](/API_docs/types/help.PassportConfig.html) + +*** +

+$MadelineProto->[help->getPeerColors](/API_docs/methods/help.getPeerColors.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$help.PeerColors](/API_docs/types/help.PeerColors.html) + +*** +

+$MadelineProto->[help->getPeerProfileColors](/API_docs/methods/help.getPeerProfileColors.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$help.PeerColors](/API_docs/types/help.PeerColors.html) + +*** +

+$MadelineProto->[help->getPremiumPromo](/API_docs/methods/help.getPremiumPromo.html)(\[\]) === [$help.PremiumPromo](/API_docs/types/help.PremiumPromo.html) + +*** +

+$MadelineProto->[help->getPromoData](/API_docs/methods/help.getPromoData.html)(\[\]) === [$help.PromoData](/API_docs/types/help.PromoData.html) + +*** +

+$MadelineProto->[help->getRecentMeUrls](/API_docs/methods/help.getRecentMeUrls.html)(\[referer: $[string](/API_docs/types/string.html), \]) === [$help.RecentMeUrls](/API_docs/types/help.RecentMeUrls.html) + +*** +

+$MadelineProto->[help->getSupport](/API_docs/methods/help.getSupport.html)(\[\]) === [$help.Support](/API_docs/types/help.Support.html) + +*** +

+$MadelineProto->[help->getSupportName](/API_docs/methods/help.getSupportName.html)(\[\]) === [$help.SupportName](/API_docs/types/help.SupportName.html) + +*** +

+$MadelineProto->[help->getTermsOfServiceUpdate](/API_docs/methods/help.getTermsOfServiceUpdate.html)(\[\]) === [$help.TermsOfServiceUpdate](/API_docs/types/help.TermsOfServiceUpdate.html) + +*** +

+$MadelineProto->[help->getTimezonesList](/API_docs/methods/help.getTimezonesList.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$help.TimezonesList](/API_docs/types/help.TimezonesList.html) + +*** +

+$MadelineProto->[help->getUserInfo](/API_docs/methods/help.getUserInfo.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$help.UserInfo](/API_docs/types/help.UserInfo.html) + +*** +

+$MadelineProto->[help->hidePromoData](/API_docs/methods/help.hidePromoData.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[help->saveAppLog](/API_docs/methods/help.saveAppLog.html)(\[events: \[$[InputAppEvent](/API_docs/types/InputAppEvent.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[help->setBotUpdatesStatus](/API_docs/methods/help.setBotUpdatesStatus.html)(\[pending_updates_count: $[int](/API_docs/types/int.html), message: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[initConnection](/API_docs/methods/initConnection.html)(\[api_id: $[int](/API_docs/types/int.html), device_model: $[string](/API_docs/types/string.html), system_version: $[string](/API_docs/types/string.html), app_version: $[string](/API_docs/types/string.html), system_lang_code: $[string](/API_docs/types/string.html), lang_pack: $[string](/API_docs/types/string.html), lang_code: $[string](/API_docs/types/string.html), proxy: $[InputClientProxy](/API_docs/types/InputClientProxy.html), params: $[JSONValue](/API_docs/types/JSONValue.html), query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeAfterMsg](/API_docs/methods/invokeAfterMsg.html)(\[msg_id: $[long](/API_docs/types/long.html), query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeAfterMsgs](/API_docs/methods/invokeAfterMsgs.html)(\[msg_ids: \[$[long](/API_docs/types/long.html)\], query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeWithBusinessConnection](/API_docs/methods/invokeWithBusinessConnection.html)(\[connection_id: $[string](/API_docs/types/string.html), query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeWithLayer](/API_docs/methods/invokeWithLayer.html)(\[layer: $[int](/API_docs/types/int.html), query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeWithMessagesRange](/API_docs/methods/invokeWithMessagesRange.html)(\[range: $[MessageRange](/API_docs/types/MessageRange.html), query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeWithTakeout](/API_docs/methods/invokeWithTakeout.html)(\[takeout_id: $[long](/API_docs/types/long.html), query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[invokeWithoutUpdates](/API_docs/methods/invokeWithoutUpdates.html)(\[query: $[!X](/API_docs/types/!X.html), \]) === [$X](/API_docs/types/X.html) + +*** +

+$MadelineProto->[langpack->getDifference](/API_docs/methods/langpack.getDifference.html)(\[lang_pack: $[string](/API_docs/types/string.html), lang_code: $[string](/API_docs/types/string.html), from_version: $[int](/API_docs/types/int.html), \]) === [$LangPackDifference](/API_docs/types/LangPackDifference.html) + +*** +

+$MadelineProto->[langpack->getLangPack](/API_docs/methods/langpack.getLangPack.html)(\[lang_pack: $[string](/API_docs/types/string.html), lang_code: $[string](/API_docs/types/string.html), \]) === [$LangPackDifference](/API_docs/types/LangPackDifference.html) + +*** +

+$MadelineProto->[langpack->getLanguage](/API_docs/methods/langpack.getLanguage.html)(\[lang_pack: $[string](/API_docs/types/string.html), lang_code: $[string](/API_docs/types/string.html), \]) === [$LangPackLanguage](/API_docs/types/LangPackLanguage.html) + +*** +

+$MadelineProto->[langpack->getLanguages](/API_docs/methods/langpack.getLanguages.html)(\[lang_pack: $[string](/API_docs/types/string.html), \]) === [$Vector\_of\_LangPackLanguage](/API_docs/types/LangPackLanguage.html) + +*** +

+$MadelineProto->[langpack->getStrings](/API_docs/methods/langpack.getStrings.html)(\[lang_pack: $[string](/API_docs/types/string.html), lang_code: $[string](/API_docs/types/string.html), keys: \[$[string](/API_docs/types/string.html)\], \]) === [$Vector\_of\_LangPackString](/API_docs/types/LangPackString.html) + +*** +

+$MadelineProto->[messages->acceptEncryption](/API_docs/methods/messages.acceptEncryption.html)(\[peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), g_b: $[bytes](/API_docs/types/bytes.html), key_fingerprint: $[strlong](/API_docs/constructors/strlong.html), \]) === [$EncryptedChat](/API_docs/types/EncryptedChat.html) + +*** +

+$MadelineProto->[messages->acceptUrlAuth](/API_docs/methods/messages.acceptUrlAuth.html)(\[write_allowed: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), button_id: $[int](/API_docs/types/int.html), url: $[string](/API_docs/types/string.html), \]) === [$UrlAuthResult](/API_docs/types/UrlAuthResult.html) + +*** +

+$MadelineProto->[messages->addChatUser](/API_docs/methods/messages.addChatUser.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), user_id: $[InputUser](/API_docs/types/InputUser.html), fwd_limit: $[int](/API_docs/types/int.html), \]) === [$messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +*** +

+$MadelineProto->[messages->checkChatInvite](/API_docs/methods/messages.checkChatInvite.html)(\[hash: $[string](/API_docs/types/string.html), \]) === [$ChatInvite](/API_docs/types/ChatInvite.html) + +*** +

+$MadelineProto->[messages->checkHistoryImport](/API_docs/methods/messages.checkHistoryImport.html)(\[import_head: $[string](/API_docs/types/string.html), \]) === [$messages.HistoryImportParsed](/API_docs/types/messages.HistoryImportParsed.html) + +*** +

+$MadelineProto->[messages->checkHistoryImportPeer](/API_docs/methods/messages.checkHistoryImportPeer.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$messages.CheckedHistoryImportPeer](/API_docs/types/messages.CheckedHistoryImportPeer.html) + +*** +

+$MadelineProto->[messages->checkQuickReplyShortcut](/API_docs/methods/messages.checkQuickReplyShortcut.html)(\[shortcut: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->clearAllDrafts](/API_docs/methods/messages.clearAllDrafts.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->clearRecentReactions](/API_docs/methods/messages.clearRecentReactions.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->clearRecentStickers](/API_docs/methods/messages.clearRecentStickers.html)(\[attached: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->createChat](/API_docs/methods/messages.createChat.html)(\[users: \[$[InputUser](/API_docs/types/InputUser.html)\], title: $[string](/API_docs/types/string.html), ttl_period: $[int](/API_docs/types/int.html), \]) === [$messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +*** +

+$MadelineProto->[messages->deleteChat](/API_docs/methods/messages.deleteChat.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->deleteChatUser](/API_docs/methods/messages.deleteChatUser.html)(\[revoke_history: $[Bool](/API_docs/types/Bool.html), chat_id: $[InputPeer](/API_docs/types/InputPeer.html), user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->deleteExportedChatInvite](/API_docs/methods/messages.deleteExportedChatInvite.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), link: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->deleteHistory](/API_docs/methods/messages.deleteHistory.html)(\[just_clear: $[Bool](/API_docs/types/Bool.html), revoke: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), max_id: $[int](/API_docs/types/int.html), min_date: $[int](/API_docs/types/int.html), max_date: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[messages->deleteMessages](/API_docs/methods/messages.deleteMessages.html)(\[revoke: $[Bool](/API_docs/types/Bool.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +*** +

+$MadelineProto->[messages->deletePhoneCallHistory](/API_docs/methods/messages.deletePhoneCallHistory.html)(\[revoke: $[Bool](/API_docs/types/Bool.html), \]) === [$messages.AffectedFoundMessages](/API_docs/types/messages.AffectedFoundMessages.html) + +*** +

+$MadelineProto->[messages->deleteQuickReplyMessages](/API_docs/methods/messages.deleteQuickReplyMessages.html)(\[shortcut_id: $[int](/API_docs/types/int.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->deleteQuickReplyShortcut](/API_docs/methods/messages.deleteQuickReplyShortcut.html)(\[shortcut_id: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->deleteRevokedExportedChatInvites](/API_docs/methods/messages.deleteRevokedExportedChatInvites.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), admin_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->deleteSavedHistory](/API_docs/methods/messages.deleteSavedHistory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), max_id: $[int](/API_docs/types/int.html), min_date: $[int](/API_docs/types/int.html), max_date: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[messages->deleteScheduledMessages](/API_docs/methods/messages.deleteScheduledMessages.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->discardEncryption](/API_docs/methods/messages.discardEncryption.html)(\[delete_history: $[Bool](/API_docs/types/Bool.html), chat_id: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->editChatAbout](/API_docs/methods/messages.editChatAbout.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), about: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->editChatAdmin](/API_docs/methods/messages.editChatAdmin.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), user_id: $[InputUser](/API_docs/types/InputUser.html), is_admin: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->editChatDefaultBannedRights](/API_docs/methods/messages.editChatDefaultBannedRights.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), banned_rights: $[ChatBannedRights](/API_docs/types/ChatBannedRights.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->editChatPhoto](/API_docs/methods/messages.editChatPhoto.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), photo: $[InputChatPhoto](/API_docs/types/InputChatPhoto.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->editChatTitle](/API_docs/methods/messages.editChatTitle.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), title: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->editExportedChatInvite](/API_docs/methods/messages.editExportedChatInvite.html)(\[revoked: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), link: $[string](/API_docs/types/string.html), expire_date: $[int](/API_docs/types/int.html), usage_limit: $[int](/API_docs/types/int.html), request_needed: $[Bool](/API_docs/types/Bool.html), title: $[string](/API_docs/types/string.html), \]) === [$messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + +*** +

+$MadelineProto->[messages->editInlineBotMessage](/API_docs/methods/messages.editInlineBotMessage.html)(\[no_webpage: $[Bool](/API_docs/types/Bool.html), invert_media: $[Bool](/API_docs/types/Bool.html), id: $[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html), message: $[string](/API_docs/types/string.html), media: $[InputMedia](/API_docs/types/InputMedia.html), reply_markup: $[ReplyMarkup](/API_docs/types/ReplyMarkup.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->editMessage](/API_docs/methods/messages.editMessage.html)(\[no_webpage: $[Bool](/API_docs/types/Bool.html), invert_media: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), message: $[string](/API_docs/types/string.html), media: $[InputMedia](/API_docs/types/InputMedia.html), reply_markup: $[ReplyMarkup](/API_docs/types/ReplyMarkup.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], schedule_date: $[int](/API_docs/types/int.html), quick_reply_shortcut_id: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->editQuickReplyShortcut](/API_docs/methods/messages.editQuickReplyShortcut.html)(\[shortcut_id: $[int](/API_docs/types/int.html), shortcut: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->exportChatInvite](/API_docs/methods/messages.exportChatInvite.html)(\[legacy_revoke_permanent: $[Bool](/API_docs/types/Bool.html), request_needed: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), expire_date: $[int](/API_docs/types/int.html), usage_limit: $[int](/API_docs/types/int.html), title: $[string](/API_docs/types/string.html), \]) === [$ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) + +*** +

+$MadelineProto->[messages->faveSticker](/API_docs/methods/messages.faveSticker.html)(\[id: $[InputDocument](/API_docs/types/InputDocument.html), unfave: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->forwardMessages](/API_docs/methods/messages.forwardMessages.html)(\[silent: $[Bool](/API_docs/types/Bool.html), background: $[Bool](/API_docs/types/Bool.html), with_my_score: $[Bool](/API_docs/types/Bool.html), drop_author: $[Bool](/API_docs/types/Bool.html), drop_media_captions: $[Bool](/API_docs/types/Bool.html), noforwards: $[Bool](/API_docs/types/Bool.html), from_peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], to_peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), schedule_date: $[int](/API_docs/types/int.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), quick_reply_shortcut: $[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->getAdminsWithInvites](/API_docs/methods/messages.getAdminsWithInvites.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$messages.ChatAdminsWithInvites](/API_docs/types/messages.ChatAdminsWithInvites.html) + +*** +

+$MadelineProto->[messages->getAllDrafts](/API_docs/methods/messages.getAllDrafts.html)(\[\]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->getAllStickers](/API_docs/methods/messages.getAllStickers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +*** +

+$MadelineProto->[messages->getArchivedStickers](/API_docs/methods/messages.getArchivedStickers.html)(\[masks: $[Bool](/API_docs/types/Bool.html), emojis: $[Bool](/API_docs/types/Bool.html), offset_id: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.ArchivedStickers](/API_docs/types/messages.ArchivedStickers.html) + +*** +

+$MadelineProto->[messages->getAttachMenuBot](/API_docs/methods/messages.getAttachMenuBot.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), \]) === [$AttachMenuBotsBot](/API_docs/types/AttachMenuBotsBot.html) + +*** +

+$MadelineProto->[messages->getAttachMenuBots](/API_docs/methods/messages.getAttachMenuBots.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$AttachMenuBots](/API_docs/types/AttachMenuBots.html) + +*** +

+$MadelineProto->[messages->getAttachedStickers](/API_docs/methods/messages.getAttachedStickers.html)(\[media: $[InputStickeredMedia](/API_docs/types/InputStickeredMedia.html), \]) === [$Vector\_of\_StickerSetCovered](/API_docs/types/StickerSetCovered.html) + +*** +

+$MadelineProto->[messages->getAvailableReactions](/API_docs/methods/messages.getAvailableReactions.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$messages.AvailableReactions](/API_docs/types/messages.AvailableReactions.html) + +*** +

+$MadelineProto->[messages->getBotApp](/API_docs/methods/messages.getBotApp.html)(\[app: $[InputBotApp](/API_docs/types/InputBotApp.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.BotApp](/API_docs/types/messages.BotApp.html) + +*** +

+$MadelineProto->[messages->getBotCallbackAnswer](/API_docs/methods/messages.getBotCallbackAnswer.html)(\[game: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), data: $[bytes](/API_docs/types/bytes.html), password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), \]) === [$messages.BotCallbackAnswer](/API_docs/types/messages.BotCallbackAnswer.html) + +*** +

+$MadelineProto->[messages->getChatInviteImporters](/API_docs/methods/messages.getChatInviteImporters.html)(\[requested: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), link: $[string](/API_docs/types/string.html), q: $[string](/API_docs/types/string.html), offset_date: $[int](/API_docs/types/int.html), offset_user: $[InputUser](/API_docs/types/InputUser.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.ChatInviteImporters](/API_docs/types/messages.ChatInviteImporters.html) + +*** +

+$MadelineProto->[messages->getChats](/API_docs/methods/messages.getChats.html)(\[id: \[$[long](/API_docs/types/long.html)\], \]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[messages->getCommonChats](/API_docs/methods/messages.getCommonChats.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), max_id: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[messages->getCustomEmojiDocuments](/API_docs/methods/messages.getCustomEmojiDocuments.html)(\[document_id: \[$[long](/API_docs/types/long.html)\], \]) === [$Vector\_of\_Document](/API_docs/types/Document.html) + +*** +

+$MadelineProto->[messages->getDefaultHistoryTTL](/API_docs/methods/messages.getDefaultHistoryTTL.html)(\[\]) === [$DefaultHistoryTTL](/API_docs/types/DefaultHistoryTTL.html) + +*** +

+$MadelineProto->[messages->getDefaultTagReactions](/API_docs/methods/messages.getDefaultTagReactions.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.Reactions](/API_docs/types/messages.Reactions.html) + +*** +

+$MadelineProto->[messages->getDhConfig](/API_docs/methods/messages.getDhConfig.html)(\[version: $[int](/API_docs/types/int.html), random_length: $[int](/API_docs/types/int.html), \]) === [$messages.DhConfig](/API_docs/types/messages.DhConfig.html) + +*** +

+$MadelineProto->[messages->getDialogFilters](/API_docs/methods/messages.getDialogFilters.html)(\[\]) === [$messages.DialogFilters](/API_docs/types/messages.DialogFilters.html) + +*** +

+$MadelineProto->[messages->getDialogUnreadMarks](/API_docs/methods/messages.getDialogUnreadMarks.html)(\[\]) === [$Vector\_of\_DialogPeer](/API_docs/types/DialogPeer.html) + +*** +

+$MadelineProto->[messages->getDialogs](/API_docs/methods/messages.getDialogs.html)(\[exclude_pinned: $[Bool](/API_docs/types/Bool.html), folder_id: $[int](/API_docs/types/int.html), offset_date: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), offset_peer: $[InputPeer](/API_docs/types/InputPeer.html), limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Dialogs](/API_docs/types/messages.Dialogs.html) + +*** +

+$MadelineProto->[messages->getDiscussionMessage](/API_docs/methods/messages.getDiscussionMessage.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$messages.DiscussionMessage](/API_docs/types/messages.DiscussionMessage.html) + +*** +

+$MadelineProto->[messages->getDocumentByHash](/API_docs/methods/messages.getDocumentByHash.html)(\[sha256: $[bytes](/API_docs/types/bytes.html), size: $[long](/API_docs/types/long.html), mime_type: $[string](/API_docs/types/string.html), \]) === [$Document](/API_docs/types/Document.html) + +*** +

+$MadelineProto->[messages->getEmojiGroups](/API_docs/methods/messages.getEmojiGroups.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +*** +

+$MadelineProto->[messages->getEmojiKeywords](/API_docs/methods/messages.getEmojiKeywords.html)(\[lang_code: $[string](/API_docs/types/string.html), \]) === [$EmojiKeywordsDifference](/API_docs/types/EmojiKeywordsDifference.html) + +*** +

+$MadelineProto->[messages->getEmojiKeywordsDifference](/API_docs/methods/messages.getEmojiKeywordsDifference.html)(\[lang_code: $[string](/API_docs/types/string.html), from_version: $[int](/API_docs/types/int.html), \]) === [$EmojiKeywordsDifference](/API_docs/types/EmojiKeywordsDifference.html) + +*** +

+$MadelineProto->[messages->getEmojiKeywordsLanguages](/API_docs/methods/messages.getEmojiKeywordsLanguages.html)(\[lang_codes: \[$[string](/API_docs/types/string.html)\], \]) === [$Vector\_of\_EmojiLanguage](/API_docs/types/EmojiLanguage.html) + +*** +

+$MadelineProto->[messages->getEmojiProfilePhotoGroups](/API_docs/methods/messages.getEmojiProfilePhotoGroups.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +*** +

+$MadelineProto->[messages->getEmojiStatusGroups](/API_docs/methods/messages.getEmojiStatusGroups.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +*** +

+$MadelineProto->[messages->getEmojiStickerGroups](/API_docs/methods/messages.getEmojiStickerGroups.html)(\[hash: $[int](/API_docs/types/int.html), \]) === [$messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +*** +

+$MadelineProto->[messages->getEmojiStickers](/API_docs/methods/messages.getEmojiStickers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +*** +

+$MadelineProto->[messages->getEmojiURL](/API_docs/methods/messages.getEmojiURL.html)(\[lang_code: $[string](/API_docs/types/string.html), \]) === [$EmojiURL](/API_docs/types/EmojiURL.html) + +*** +

+$MadelineProto->[messages->getExportedChatInvite](/API_docs/methods/messages.getExportedChatInvite.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), link: $[string](/API_docs/types/string.html), \]) === [$messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + +*** +

+$MadelineProto->[messages->getExportedChatInvites](/API_docs/methods/messages.getExportedChatInvites.html)(\[revoked: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), admin_id: $[InputUser](/API_docs/types/InputUser.html), offset_date: $[int](/API_docs/types/int.html), offset_link: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.ExportedChatInvites](/API_docs/types/messages.ExportedChatInvites.html) + +*** +

+$MadelineProto->[messages->getExtendedMedia](/API_docs/methods/messages.getExtendedMedia.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->getFavedStickers](/API_docs/methods/messages.getFavedStickers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.FavedStickers](/API_docs/types/messages.FavedStickers.html) + +*** +

+$MadelineProto->[messages->getFeaturedEmojiStickers](/API_docs/methods/messages.getFeaturedEmojiStickers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +*** +

+$MadelineProto->[messages->getFeaturedStickers](/API_docs/methods/messages.getFeaturedStickers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +*** +

+$MadelineProto->[messages->getFullChat](/API_docs/methods/messages.getFullChat.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$messages.ChatFull](/API_docs/types/messages.ChatFull.html) + +*** +

+$MadelineProto->[messages->getGameHighScores](/API_docs/methods/messages.getGameHighScores.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$messages.HighScores](/API_docs/types/messages.HighScores.html) + +*** +

+$MadelineProto->[messages->getHistory](/API_docs/methods/messages.getHistory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), offset_id: $[int](/API_docs/types/int.html), offset_date: $[int](/API_docs/types/int.html), add_offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), max_id: $[int](/API_docs/types/int.html), min_id: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getInlineBotResults](/API_docs/methods/messages.getInlineBotResults.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), geo_point: $[InputGeoPoint](/API_docs/types/InputGeoPoint.html), query: $[string](/API_docs/types/string.html), offset: $[string](/API_docs/types/string.html), \]) === [$messages.BotResults](/API_docs/types/messages.BotResults.html) + +*** +

+$MadelineProto->[messages->getInlineGameHighScores](/API_docs/methods/messages.getInlineGameHighScores.html)(\[id: $[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html), user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$messages.HighScores](/API_docs/types/messages.HighScores.html) + +*** +

+$MadelineProto->[messages->getMaskStickers](/API_docs/methods/messages.getMaskStickers.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +*** +

+$MadelineProto->[messages->getMessageEditData](/API_docs/methods/messages.getMessageEditData.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), \]) === [$messages.MessageEditData](/API_docs/types/messages.MessageEditData.html) + +*** +

+$MadelineProto->[messages->getMessageReactionsList](/API_docs/methods/messages.getMessageReactionsList.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), reaction: $[Reaction](/API_docs/types/Reaction.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.MessageReactionsList](/API_docs/types/messages.MessageReactionsList.html) + +*** +

+$MadelineProto->[messages->getMessageReadParticipants](/API_docs/methods/messages.getMessageReadParticipants.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$Vector\_of\_ReadParticipantDate](/API_docs/types/ReadParticipantDate.html) + +*** +

+$MadelineProto->[messages->getMessages](/API_docs/methods/messages.getMessages.html)(\[id: \[$[InputMessage](/API_docs/types/InputMessage.html)\], \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getMessagesReactions](/API_docs/methods/messages.getMessagesReactions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->getMessagesViews](/API_docs/methods/messages.getMessagesViews.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], increment: $[Bool](/API_docs/types/Bool.html), \]) === [$messages.MessageViews](/API_docs/types/messages.MessageViews.html) + +*** +

+$MadelineProto->[messages->getMyStickers](/API_docs/methods/messages.getMyStickers.html)(\[offset_id: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.MyStickers](/API_docs/types/messages.MyStickers.html) + +*** +

+$MadelineProto->[messages->getOldFeaturedStickers](/API_docs/methods/messages.getOldFeaturedStickers.html)(\[offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +*** +

+$MadelineProto->[messages->getOnlines](/API_docs/methods/messages.getOnlines.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$ChatOnlines](/API_docs/types/ChatOnlines.html) + +*** +

+$MadelineProto->[messages->getOutboxReadDate](/API_docs/methods/messages.getOutboxReadDate.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$OutboxReadDate](/API_docs/types/OutboxReadDate.html) + +*** +

+$MadelineProto->[messages->getPeerDialogs](/API_docs/methods/messages.getPeerDialogs.html)(\[peers: \[$[InputDialogPeer](/API_docs/types/InputDialogPeer.html)\], \]) === [$messages.PeerDialogs](/API_docs/types/messages.PeerDialogs.html) + +*** +

+$MadelineProto->[messages->getPeerSettings](/API_docs/methods/messages.getPeerSettings.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$messages.PeerSettings](/API_docs/types/messages.PeerSettings.html) + +*** +

+$MadelineProto->[messages->getPinnedDialogs](/API_docs/methods/messages.getPinnedDialogs.html)(\[folder_id: $[int](/API_docs/types/int.html), \]) === [$messages.PeerDialogs](/API_docs/types/messages.PeerDialogs.html) + +*** +

+$MadelineProto->[messages->getPinnedSavedDialogs](/API_docs/methods/messages.getPinnedSavedDialogs.html)(\[\]) === [$messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + +*** +

+$MadelineProto->[messages->getPollResults](/API_docs/methods/messages.getPollResults.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->getPollVotes](/API_docs/methods/messages.getPollVotes.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), option: $[bytes](/API_docs/types/bytes.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.VotesList](/API_docs/types/messages.VotesList.html) + +*** +

+$MadelineProto->[messages->getQuickReplies](/API_docs/methods/messages.getQuickReplies.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.QuickReplies](/API_docs/types/messages.QuickReplies.html) + +*** +

+$MadelineProto->[messages->getQuickReplyMessages](/API_docs/methods/messages.getQuickReplyMessages.html)(\[shortcut_id: $[int](/API_docs/types/int.html), id: \[$[int](/API_docs/types/int.html)\], hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getRecentLocations](/API_docs/methods/messages.getRecentLocations.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getRecentReactions](/API_docs/methods/messages.getRecentReactions.html)(\[limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Reactions](/API_docs/types/messages.Reactions.html) + +*** +

+$MadelineProto->[messages->getRecentStickers](/API_docs/methods/messages.getRecentStickers.html)(\[attached: $[Bool](/API_docs/types/Bool.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.RecentStickers](/API_docs/types/messages.RecentStickers.html) + +*** +

+$MadelineProto->[messages->getReplies](/API_docs/methods/messages.getReplies.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), offset_date: $[int](/API_docs/types/int.html), add_offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), max_id: $[int](/API_docs/types/int.html), min_id: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getSavedDialogs](/API_docs/methods/messages.getSavedDialogs.html)(\[exclude_pinned: $[Bool](/API_docs/types/Bool.html), offset_date: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), offset_peer: $[InputPeer](/API_docs/types/InputPeer.html), limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + +*** +

+$MadelineProto->[messages->getSavedGifs](/API_docs/methods/messages.getSavedGifs.html)(\[hash: $[long](/API_docs/types/long.html), \]) === [$messages.SavedGifs](/API_docs/types/messages.SavedGifs.html) + +*** +

+$MadelineProto->[messages->getSavedHistory](/API_docs/methods/messages.getSavedHistory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), offset_id: $[int](/API_docs/types/int.html), offset_date: $[int](/API_docs/types/int.html), add_offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), max_id: $[int](/API_docs/types/int.html), min_id: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getSavedReactionTags](/API_docs/methods/messages.getSavedReactionTags.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.SavedReactionTags](/API_docs/types/messages.SavedReactionTags.html) + +*** +

+$MadelineProto->[messages->getScheduledHistory](/API_docs/methods/messages.getScheduledHistory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getScheduledMessages](/API_docs/methods/messages.getScheduledMessages.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getSearchCounters](/API_docs/methods/messages.getSearchCounters.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), saved_peer_id: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), filters: \[$[MessagesFilter](/API_docs/types/MessagesFilter.html)\], \]) === [$Vector\_of\_messages.SearchCounter](/API_docs/types/messages.SearchCounter.html) + +*** +

+$MadelineProto->[messages->getSearchResultsCalendar](/API_docs/methods/messages.getSearchResultsCalendar.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), saved_peer_id: $[InputPeer](/API_docs/types/InputPeer.html), filter: $[MessagesFilter](/API_docs/types/MessagesFilter.html), offset_id: $[int](/API_docs/types/int.html), offset_date: $[int](/API_docs/types/int.html), \]) === [$messages.SearchResultsCalendar](/API_docs/types/messages.SearchResultsCalendar.html) + +*** +

+$MadelineProto->[messages->getSearchResultsPositions](/API_docs/methods/messages.getSearchResultsPositions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), saved_peer_id: $[InputPeer](/API_docs/types/InputPeer.html), filter: $[MessagesFilter](/API_docs/types/MessagesFilter.html), offset_id: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.SearchResultsPositions](/API_docs/types/messages.SearchResultsPositions.html) + +*** +

+$MadelineProto->[messages->getSplitRanges](/API_docs/methods/messages.getSplitRanges.html)(\[\]) === [$Vector\_of\_MessageRange](/API_docs/types/MessageRange.html) + +*** +

+$MadelineProto->[messages->getStickerSet](/API_docs/methods/messages.getStickerSet.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), hash: $[int](/API_docs/types/int.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[messages->getStickers](/API_docs/methods/messages.getStickers.html)(\[emoticon: $[string](/API_docs/types/string.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Stickers](/API_docs/types/messages.Stickers.html) + +*** +

+$MadelineProto->[messages->getSuggestedDialogFilters](/API_docs/methods/messages.getSuggestedDialogFilters.html)(\[\]) === [$Vector\_of\_DialogFilterSuggested](/API_docs/types/DialogFilterSuggested.html) + +*** +

+$MadelineProto->[messages->getTopReactions](/API_docs/methods/messages.getTopReactions.html)(\[limit: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Reactions](/API_docs/types/messages.Reactions.html) + +*** +

+$MadelineProto->[messages->getUnreadMentions](/API_docs/methods/messages.getUnreadMentions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), add_offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), max_id: $[int](/API_docs/types/int.html), min_id: $[int](/API_docs/types/int.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getUnreadReactions](/API_docs/methods/messages.getUnreadReactions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), add_offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), max_id: $[int](/API_docs/types/int.html), min_id: $[int](/API_docs/types/int.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->getWebPage](/API_docs/methods/messages.getWebPage.html)(\[url: $[string](/API_docs/types/string.html), hash: $[int](/API_docs/types/int.html), \]) === [$messages.WebPage](/API_docs/types/messages.WebPage.html) + +*** +

+$MadelineProto->[messages->getWebPagePreview](/API_docs/methods/messages.getWebPagePreview.html)(\[message: $[string](/API_docs/types/string.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], \]) === [$MessageMedia](/API_docs/types/MessageMedia.html) + +*** +

+$MadelineProto->[messages->hideAllChatJoinRequests](/API_docs/methods/messages.hideAllChatJoinRequests.html)(\[approved: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), link: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->hideChatJoinRequest](/API_docs/methods/messages.hideChatJoinRequest.html)(\[approved: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->hidePeerSettingsBar](/API_docs/methods/messages.hidePeerSettingsBar.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->importChatInvite](/API_docs/methods/messages.importChatInvite.html)(\[hash: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->initHistoryImport](/API_docs/methods/messages.initHistoryImport.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), file: $[InputFile](/API_docs/types/InputFile.html), media_count: $[int](/API_docs/types/int.html), \]) === [$messages.HistoryImport](/API_docs/types/messages.HistoryImport.html) + +*** +

+$MadelineProto->[messages->installStickerSet](/API_docs/methods/messages.installStickerSet.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), archived: $[Bool](/API_docs/types/Bool.html), \]) === [$messages.StickerSetInstallResult](/API_docs/types/messages.StickerSetInstallResult.html) + +*** +

+$MadelineProto->[messages->markDialogUnread](/API_docs/methods/messages.markDialogUnread.html)(\[unread: $[Bool](/API_docs/types/Bool.html), peer: $[InputDialogPeer](/API_docs/types/InputDialogPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->migrateChat](/API_docs/methods/messages.migrateChat.html)(\[chat_id: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->prolongWebView](/API_docs/methods/messages.prolongWebView.html)(\[silent: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), bot: $[InputUser](/API_docs/types/InputUser.html), query_id: $[long](/API_docs/types/long.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->rateTranscribedAudio](/API_docs/methods/messages.rateTranscribedAudio.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), transcription_id: $[long](/API_docs/types/long.html), good: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->readDiscussion](/API_docs/methods/messages.readDiscussion.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), read_max_id: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->readEncryptedHistory](/API_docs/methods/messages.readEncryptedHistory.html)(\[peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), max_date: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->readFeaturedStickers](/API_docs/methods/messages.readFeaturedStickers.html)(\[id: \[$[long](/API_docs/types/long.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->readHistory](/API_docs/methods/messages.readHistory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), max_id: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +*** +

+$MadelineProto->[messages->readMentions](/API_docs/methods/messages.readMentions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[messages->readMessageContents](/API_docs/methods/messages.readMessageContents.html)(\[id: \[$[int](/API_docs/types/int.html)\], \]) === [$messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +*** +

+$MadelineProto->[messages->readReactions](/API_docs/methods/messages.readReactions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[messages->receivedMessages](/API_docs/methods/messages.receivedMessages.html)(\[max_id: $[int](/API_docs/types/int.html), \]) === [$Vector\_of\_ReceivedNotifyMessage](/API_docs/types/ReceivedNotifyMessage.html) + +*** +

+$MadelineProto->[messages->receivedQueue](/API_docs/methods/messages.receivedQueue.html)(\[max_qts: $[int](/API_docs/types/int.html), \]) === [$Vector\_of\_long](/API_docs/types/long.html) + +*** +

+$MadelineProto->[messages->reorderPinnedDialogs](/API_docs/methods/messages.reorderPinnedDialogs.html)(\[force: $[Bool](/API_docs/types/Bool.html), folder_id: $[int](/API_docs/types/int.html), order: \[$[InputDialogPeer](/API_docs/types/InputDialogPeer.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->reorderPinnedSavedDialogs](/API_docs/methods/messages.reorderPinnedSavedDialogs.html)(\[force: $[Bool](/API_docs/types/Bool.html), order: \[$[InputDialogPeer](/API_docs/types/InputDialogPeer.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->reorderQuickReplies](/API_docs/methods/messages.reorderQuickReplies.html)(\[order: \[$[int](/API_docs/types/int.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->reorderStickerSets](/API_docs/methods/messages.reorderStickerSets.html)(\[masks: $[Bool](/API_docs/types/Bool.html), emojis: $[Bool](/API_docs/types/Bool.html), order: \[$[long](/API_docs/types/long.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->report](/API_docs/methods/messages.report.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], reason: $[ReportReason](/API_docs/types/ReportReason.html), message: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->reportEncryptedSpam](/API_docs/methods/messages.reportEncryptedSpam.html)(\[peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->reportReaction](/API_docs/methods/messages.reportReaction.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), reaction_peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->reportSpam](/API_docs/methods/messages.reportSpam.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->requestAppWebView](/API_docs/methods/messages.requestAppWebView.html)(\[write_allowed: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), app: $[InputBotApp](/API_docs/types/InputBotApp.html), start_param: $[string](/API_docs/types/string.html), theme_params: $[DataJSON](/API_docs/types/DataJSON.html), platform: $[string](/API_docs/types/string.html), \]) === [$AppWebViewResult](/API_docs/types/AppWebViewResult.html) + +*** +

+$MadelineProto->[messages->requestEncryption](/API_docs/methods/messages.requestEncryption.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), g_a: $[bytes](/API_docs/types/bytes.html), \]) === [$EncryptedChat](/API_docs/types/EncryptedChat.html) + +*** +

+$MadelineProto->[messages->requestSimpleWebView](/API_docs/methods/messages.requestSimpleWebView.html)(\[from_switch_webview: $[Bool](/API_docs/types/Bool.html), from_side_menu: $[Bool](/API_docs/types/Bool.html), bot: $[InputUser](/API_docs/types/InputUser.html), url: $[string](/API_docs/types/string.html), start_param: $[string](/API_docs/types/string.html), theme_params: $[DataJSON](/API_docs/types/DataJSON.html), platform: $[string](/API_docs/types/string.html), \]) === [$SimpleWebViewResult](/API_docs/types/SimpleWebViewResult.html) + +*** +

+$MadelineProto->[messages->requestUrlAuth](/API_docs/methods/messages.requestUrlAuth.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), button_id: $[int](/API_docs/types/int.html), url: $[string](/API_docs/types/string.html), \]) === [$UrlAuthResult](/API_docs/types/UrlAuthResult.html) + +*** +

+$MadelineProto->[messages->requestWebView](/API_docs/methods/messages.requestWebView.html)(\[from_bot_menu: $[Bool](/API_docs/types/Bool.html), silent: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), bot: $[InputUser](/API_docs/types/InputUser.html), url: $[string](/API_docs/types/string.html), start_param: $[string](/API_docs/types/string.html), theme_params: $[DataJSON](/API_docs/types/DataJSON.html), platform: $[string](/API_docs/types/string.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$WebViewResult](/API_docs/types/WebViewResult.html) + +*** +

+$MadelineProto->[messages->saveDefaultSendAs](/API_docs/methods/messages.saveDefaultSendAs.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->saveDraft](/API_docs/methods/messages.saveDraft.html)(\[no_webpage: $[Bool](/API_docs/types/Bool.html), invert_media: $[Bool](/API_docs/types/Bool.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), message: $[string](/API_docs/types/string.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], media: $[InputMedia](/API_docs/types/InputMedia.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->saveGif](/API_docs/methods/messages.saveGif.html)(\[id: $[InputDocument](/API_docs/types/InputDocument.html), unsave: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->saveRecentSticker](/API_docs/methods/messages.saveRecentSticker.html)(\[attached: $[Bool](/API_docs/types/Bool.html), id: $[InputDocument](/API_docs/types/InputDocument.html), unsave: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->search](/API_docs/methods/messages.search.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), q: $[string](/API_docs/types/string.html), from_id: $[InputPeer](/API_docs/types/InputPeer.html), saved_peer_id: $[InputPeer](/API_docs/types/InputPeer.html), saved_reaction: \[$[Reaction](/API_docs/types/Reaction.html)\], top_msg_id: $[int](/API_docs/types/int.html), filter: $[MessagesFilter](/API_docs/types/MessagesFilter.html), min_date: $[int](/API_docs/types/int.html), max_date: $[int](/API_docs/types/int.html), offset_id: $[int](/API_docs/types/int.html), add_offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), max_id: $[int](/API_docs/types/int.html), min_id: $[int](/API_docs/types/int.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->searchCustomEmoji](/API_docs/methods/messages.searchCustomEmoji.html)(\[emoticon: $[string](/API_docs/types/string.html), hash: $[long](/API_docs/types/long.html), \]) === [$EmojiList](/API_docs/types/EmojiList.html) + +*** +

+$MadelineProto->[messages->searchEmojiStickerSets](/API_docs/methods/messages.searchEmojiStickerSets.html)(\[exclude_featured: $[Bool](/API_docs/types/Bool.html), q: $[string](/API_docs/types/string.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + +*** +

+$MadelineProto->[messages->searchGlobal](/API_docs/methods/messages.searchGlobal.html)(\[broadcasts_only: $[Bool](/API_docs/types/Bool.html), folder_id: $[int](/API_docs/types/int.html), q: $[string](/API_docs/types/string.html), filter: $[MessagesFilter](/API_docs/types/MessagesFilter.html), min_date: $[int](/API_docs/types/int.html), max_date: $[int](/API_docs/types/int.html), offset_rate: $[int](/API_docs/types/int.html), offset_peer: $[InputPeer](/API_docs/types/InputPeer.html), offset_id: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->searchSentMedia](/API_docs/methods/messages.searchSentMedia.html)(\[q: $[string](/API_docs/types/string.html), filter: $[MessagesFilter](/API_docs/types/MessagesFilter.html), limit: $[int](/API_docs/types/int.html), \]) === [$messages.Messages](/API_docs/types/messages.Messages.html) + +*** +

+$MadelineProto->[messages->searchStickerSets](/API_docs/methods/messages.searchStickerSets.html)(\[exclude_featured: $[Bool](/API_docs/types/Bool.html), q: $[string](/API_docs/types/string.html), hash: $[long](/API_docs/types/long.html), \]) === [$messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + +*** +

+$MadelineProto->[messages->sendBotRequestedPeer](/API_docs/methods/messages.sendBotRequestedPeer.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), button_id: $[int](/API_docs/types/int.html), requested_peers: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendEncrypted](/API_docs/methods/messages.sendEncrypted.html)(\[silent: $[Bool](/API_docs/types/Bool.html), peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), data: $[bytes](/API_docs/types/bytes.html), \]) === [$messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +*** +

+$MadelineProto->[messages->sendEncryptedFile](/API_docs/methods/messages.sendEncryptedFile.html)(\[silent: $[Bool](/API_docs/types/Bool.html), peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), data: $[bytes](/API_docs/types/bytes.html), file: $[InputEncryptedFile](/API_docs/types/InputEncryptedFile.html), \]) === [$messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +*** +

+$MadelineProto->[messages->sendEncryptedService](/API_docs/methods/messages.sendEncryptedService.html)(\[peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), data: $[bytes](/API_docs/types/bytes.html), \]) === [$messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +*** +

+$MadelineProto->[messages->sendInlineBotResult](/API_docs/methods/messages.sendInlineBotResult.html)(\[silent: $[Bool](/API_docs/types/Bool.html), background: $[Bool](/API_docs/types/Bool.html), clear_draft: $[Bool](/API_docs/types/Bool.html), hide_via: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), query_id: $[long](/API_docs/types/long.html), id: $[string](/API_docs/types/string.html), schedule_date: $[int](/API_docs/types/int.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), quick_reply_shortcut: $[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendMedia](/API_docs/methods/messages.sendMedia.html)(\[silent: $[Bool](/API_docs/types/Bool.html), background: $[Bool](/API_docs/types/Bool.html), clear_draft: $[Bool](/API_docs/types/Bool.html), noforwards: $[Bool](/API_docs/types/Bool.html), update_stickersets_order: $[Bool](/API_docs/types/Bool.html), invert_media: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), media: $[InputMedia](/API_docs/types/InputMedia.html), message: $[string](/API_docs/types/string.html), reply_markup: $[ReplyMarkup](/API_docs/types/ReplyMarkup.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], schedule_date: $[int](/API_docs/types/int.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), quick_reply_shortcut: $[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendMessage](/API_docs/methods/messages.sendMessage.html)(\[no_webpage: $[Bool](/API_docs/types/Bool.html), silent: $[Bool](/API_docs/types/Bool.html), background: $[Bool](/API_docs/types/Bool.html), clear_draft: $[Bool](/API_docs/types/Bool.html), noforwards: $[Bool](/API_docs/types/Bool.html), update_stickersets_order: $[Bool](/API_docs/types/Bool.html), invert_media: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), message: $[string](/API_docs/types/string.html), reply_markup: $[ReplyMarkup](/API_docs/types/ReplyMarkup.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], schedule_date: $[int](/API_docs/types/int.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), quick_reply_shortcut: $[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendMultiMedia](/API_docs/methods/messages.sendMultiMedia.html)(\[silent: $[Bool](/API_docs/types/Bool.html), background: $[Bool](/API_docs/types/Bool.html), clear_draft: $[Bool](/API_docs/types/Bool.html), noforwards: $[Bool](/API_docs/types/Bool.html), update_stickersets_order: $[Bool](/API_docs/types/Bool.html), invert_media: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), multi_media: \[$[InputSingleMedia](/API_docs/types/InputSingleMedia.html)\], schedule_date: $[int](/API_docs/types/int.html), send_as: $[InputPeer](/API_docs/types/InputPeer.html), quick_reply_shortcut: $[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendQuickReplyMessages](/API_docs/methods/messages.sendQuickReplyMessages.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), shortcut_id: $[int](/API_docs/types/int.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendReaction](/API_docs/methods/messages.sendReaction.html)(\[big: $[Bool](/API_docs/types/Bool.html), add_to_recent: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), reaction: \[$[Reaction](/API_docs/types/Reaction.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendScheduledMessages](/API_docs/methods/messages.sendScheduledMessages.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendScreenshotNotification](/API_docs/methods/messages.sendScreenshotNotification.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), reply_to: $[InputReplyTo](/API_docs/types/InputReplyTo.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendVote](/API_docs/methods/messages.sendVote.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), options: \[$[bytes](/API_docs/types/bytes.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendWebViewData](/API_docs/methods/messages.sendWebViewData.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), button_text: $[string](/API_docs/types/string.html), data: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->sendWebViewResultMessage](/API_docs/methods/messages.sendWebViewResultMessage.html)(\[bot_query_id: $[string](/API_docs/types/string.html), result: $[InputBotInlineResult](/API_docs/types/InputBotInlineResult.html), \]) === [$WebViewMessageSent](/API_docs/types/WebViewMessageSent.html) + +*** +

+$MadelineProto->[messages->setBotCallbackAnswer](/API_docs/methods/messages.setBotCallbackAnswer.html)(\[alert: $[Bool](/API_docs/types/Bool.html), query_id: $[long](/API_docs/types/long.html), message: $[string](/API_docs/types/string.html), url: $[string](/API_docs/types/string.html), cache_time: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setBotPrecheckoutResults](/API_docs/methods/messages.setBotPrecheckoutResults.html)(\[success: $[Bool](/API_docs/types/Bool.html), query_id: $[long](/API_docs/types/long.html), error: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setBotShippingResults](/API_docs/methods/messages.setBotShippingResults.html)(\[query_id: $[long](/API_docs/types/long.html), error: $[string](/API_docs/types/string.html), shipping_options: \[$[ShippingOption](/API_docs/types/ShippingOption.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setChatAvailableReactions](/API_docs/methods/messages.setChatAvailableReactions.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), available_reactions: $[ChatReactions](/API_docs/types/ChatReactions.html), reactions_limit: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->setChatTheme](/API_docs/methods/messages.setChatTheme.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), emoticon: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->setChatWallPaper](/API_docs/methods/messages.setChatWallPaper.html)(\[for_both: $[Bool](/API_docs/types/Bool.html), revert: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), wallpaper: $[InputWallPaper](/API_docs/types/InputWallPaper.html), settings: $[WallPaperSettings](/API_docs/types/WallPaperSettings.html), id: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->setDefaultHistoryTTL](/API_docs/methods/messages.setDefaultHistoryTTL.html)(\[period: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setDefaultReaction](/API_docs/methods/messages.setDefaultReaction.html)(\[reaction: $[Reaction](/API_docs/types/Reaction.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setEncryptedTyping](/API_docs/methods/messages.setEncryptedTyping.html)(\[peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), typing: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setGameScore](/API_docs/methods/messages.setGameScore.html)(\[edit_message: $[Bool](/API_docs/types/Bool.html), force: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), user_id: $[InputUser](/API_docs/types/InputUser.html), score: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->setHistoryTTL](/API_docs/methods/messages.setHistoryTTL.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), period: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->setInlineBotResults](/API_docs/methods/messages.setInlineBotResults.html)(\[gallery: $[Bool](/API_docs/types/Bool.html), private: $[Bool](/API_docs/types/Bool.html), query_id: $[long](/API_docs/types/long.html), results: \[$[InputBotInlineResult](/API_docs/types/InputBotInlineResult.html)\], cache_time: $[int](/API_docs/types/int.html), next_offset: $[string](/API_docs/types/string.html), switch_pm: $[InlineBotSwitchPM](/API_docs/types/InlineBotSwitchPM.html), switch_webview: $[InlineBotWebView](/API_docs/types/InlineBotWebView.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setInlineGameScore](/API_docs/methods/messages.setInlineGameScore.html)(\[edit_message: $[Bool](/API_docs/types/Bool.html), force: $[Bool](/API_docs/types/Bool.html), id: $[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html), user_id: $[InputUser](/API_docs/types/InputUser.html), score: $[int](/API_docs/types/int.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->setTyping](/API_docs/methods/messages.setTyping.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), action: $[SendMessageAction](/API_docs/types/SendMessageAction.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->startBot](/API_docs/methods/messages.startBot.html)(\[bot: $[InputUser](/API_docs/types/InputUser.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), start_param: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->startHistoryImport](/API_docs/methods/messages.startHistoryImport.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), import_id: $[long](/API_docs/types/long.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->toggleBotInAttachMenu](/API_docs/methods/messages.toggleBotInAttachMenu.html)(\[write_allowed: $[Bool](/API_docs/types/Bool.html), bot: $[InputUser](/API_docs/types/InputUser.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->toggleDialogFilterTags](/API_docs/methods/messages.toggleDialogFilterTags.html)(\[enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->toggleDialogPin](/API_docs/methods/messages.toggleDialogPin.html)(\[pinned: $[Bool](/API_docs/types/Bool.html), peer: $[InputDialogPeer](/API_docs/types/InputDialogPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->toggleNoForwards](/API_docs/methods/messages.toggleNoForwards.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), enabled: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->togglePeerTranslations](/API_docs/methods/messages.togglePeerTranslations.html)(\[disabled: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->toggleSavedDialogPin](/API_docs/methods/messages.toggleSavedDialogPin.html)(\[pinned: $[Bool](/API_docs/types/Bool.html), peer: $[InputDialogPeer](/API_docs/types/InputDialogPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->toggleStickerSets](/API_docs/methods/messages.toggleStickerSets.html)(\[uninstall: $[Bool](/API_docs/types/Bool.html), archive: $[Bool](/API_docs/types/Bool.html), unarchive: $[Bool](/API_docs/types/Bool.html), stickersets: \[$[InputStickerSet](/API_docs/types/InputStickerSet.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->transcribeAudio](/API_docs/methods/messages.transcribeAudio.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$messages.TranscribedAudio](/API_docs/types/messages.TranscribedAudio.html) + +*** +

+$MadelineProto->[messages->translateText](/API_docs/methods/messages.translateText.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], text: \[$[TextWithEntities](/API_docs/types/TextWithEntities.html)\], to_lang: $[string](/API_docs/types/string.html), \]) === [$messages.TranslatedText](/API_docs/types/messages.TranslatedText.html) + +*** +

+$MadelineProto->[messages->uninstallStickerSet](/API_docs/methods/messages.uninstallStickerSet.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->unpinAllMessages](/API_docs/methods/messages.unpinAllMessages.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), top_msg_id: $[int](/API_docs/types/int.html), \]) === [$messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +*** +

+$MadelineProto->[messages->updateDialogFilter](/API_docs/methods/messages.updateDialogFilter.html)(\[id: $[int](/API_docs/types/int.html), filter: $[DialogFilter](/API_docs/types/DialogFilter.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->updateDialogFiltersOrder](/API_docs/methods/messages.updateDialogFiltersOrder.html)(\[order: \[$[int](/API_docs/types/int.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->updatePinnedMessage](/API_docs/methods/messages.updatePinnedMessage.html)(\[silent: $[Bool](/API_docs/types/Bool.html), unpin: $[Bool](/API_docs/types/Bool.html), pm_oneside: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[messages->updateSavedReactionTag](/API_docs/methods/messages.updateSavedReactionTag.html)(\[reaction: $[Reaction](/API_docs/types/Reaction.html), title: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[messages->uploadEncryptedFile](/API_docs/methods/messages.uploadEncryptedFile.html)(\[peer: $[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html), file: $[InputEncryptedFile](/API_docs/types/InputEncryptedFile.html), \]) === [$EncryptedFile](/API_docs/types/EncryptedFile.html) + +*** +

+$MadelineProto->[messages->uploadImportedMedia](/API_docs/methods/messages.uploadImportedMedia.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), import_id: $[long](/API_docs/types/long.html), file_name: $[string](/API_docs/types/string.html), media: $[InputMedia](/API_docs/types/InputMedia.html), \]) === [$MessageMedia](/API_docs/types/MessageMedia.html) + +*** +

+$MadelineProto->[messages->uploadMedia](/API_docs/methods/messages.uploadMedia.html)(\[business_connection_id: $[string](/API_docs/types/string.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), media: $[InputMedia](/API_docs/types/InputMedia.html), \]) === [$MessageMedia](/API_docs/types/MessageMedia.html) + +*** +

+$MadelineProto->[payments->applyGiftCode](/API_docs/methods/payments.applyGiftCode.html)(\[slug: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[payments->assignAppStoreTransaction](/API_docs/methods/payments.assignAppStoreTransaction.html)(\[receipt: $[bytes](/API_docs/types/bytes.html), purpose: $[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[payments->assignPlayMarketTransaction](/API_docs/methods/payments.assignPlayMarketTransaction.html)(\[receipt: $[DataJSON](/API_docs/types/DataJSON.html), purpose: $[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[payments->canPurchasePremium](/API_docs/methods/payments.canPurchasePremium.html)(\[purpose: $[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[payments->checkGiftCode](/API_docs/methods/payments.checkGiftCode.html)(\[slug: $[string](/API_docs/types/string.html), \]) === [$payments.CheckedGiftCode](/API_docs/types/payments.CheckedGiftCode.html) + +*** +

+$MadelineProto->[payments->clearSavedInfo](/API_docs/methods/payments.clearSavedInfo.html)(\[credentials: $[Bool](/API_docs/types/Bool.html), info: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[payments->exportInvoice](/API_docs/methods/payments.exportInvoice.html)(\[invoice_media: $[InputMedia](/API_docs/types/InputMedia.html), \]) === [$payments.ExportedInvoice](/API_docs/types/payments.ExportedInvoice.html) + +*** +

+$MadelineProto->[payments->getBankCardData](/API_docs/methods/payments.getBankCardData.html)(\[number: $[string](/API_docs/types/string.html), \]) === [$payments.BankCardData](/API_docs/types/payments.BankCardData.html) + +*** +

+$MadelineProto->[payments->getGiveawayInfo](/API_docs/methods/payments.getGiveawayInfo.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$payments.GiveawayInfo](/API_docs/types/payments.GiveawayInfo.html) + +*** +

+$MadelineProto->[payments->getPaymentForm](/API_docs/methods/payments.getPaymentForm.html)(\[invoice: $[InputInvoice](/API_docs/types/InputInvoice.html), theme_params: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$payments.PaymentForm](/API_docs/types/payments.PaymentForm.html) + +*** +

+$MadelineProto->[payments->getPaymentReceipt](/API_docs/methods/payments.getPaymentReceipt.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$payments.PaymentReceipt](/API_docs/types/payments.PaymentReceipt.html) + +*** +

+$MadelineProto->[payments->getPremiumGiftCodeOptions](/API_docs/methods/payments.getPremiumGiftCodeOptions.html)(\[boost_peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Vector\_of\_PremiumGiftCodeOption](/API_docs/types/PremiumGiftCodeOption.html) + +*** +

+$MadelineProto->[payments->getSavedInfo](/API_docs/methods/payments.getSavedInfo.html)(\[\]) === [$payments.SavedInfo](/API_docs/types/payments.SavedInfo.html) + +*** +

+$MadelineProto->[payments->launchPrepaidGiveaway](/API_docs/methods/payments.launchPrepaidGiveaway.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), giveaway_id: $[long](/API_docs/types/long.html), purpose: $[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[payments->sendPaymentForm](/API_docs/methods/payments.sendPaymentForm.html)(\[form_id: $[long](/API_docs/types/long.html), invoice: $[InputInvoice](/API_docs/types/InputInvoice.html), requested_info_id: $[string](/API_docs/types/string.html), shipping_option_id: $[string](/API_docs/types/string.html), credentials: $[InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html), tip_amount: $[long](/API_docs/types/long.html), \]) === [$payments.PaymentResult](/API_docs/types/payments.PaymentResult.html) + +*** +

+$MadelineProto->[payments->validateRequestedInfo](/API_docs/methods/payments.validateRequestedInfo.html)(\[save: $[Bool](/API_docs/types/Bool.html), invoice: $[InputInvoice](/API_docs/types/InputInvoice.html), info: $[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html), \]) === [$payments.ValidatedRequestedInfo](/API_docs/types/payments.ValidatedRequestedInfo.html) + +*** +

+$MadelineProto->[phone->acceptCall](/API_docs/methods/phone.acceptCall.html)(\[peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), g_b: $[bytes](/API_docs/types/bytes.html), protocol: $[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), \]) === [$phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +*** +

+$MadelineProto->[phone->checkGroupCall](/API_docs/methods/phone.checkGroupCall.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), sources: \[$[int](/API_docs/types/int.html)\], \]) === [$Vector\_of\_int](/API_docs/types/int.html) + +*** +

+$MadelineProto->[phone->confirmCall](/API_docs/methods/phone.confirmCall.html)(\[peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), g_a: $[bytes](/API_docs/types/bytes.html), key_fingerprint: $[strlong](/API_docs/constructors/strlong.html), protocol: $[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), \]) === [$phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +*** +

+$MadelineProto->[phone->createGroupCall](/API_docs/methods/phone.createGroupCall.html)(\[rtmp_stream: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), title: $[string](/API_docs/types/string.html), schedule_date: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->discardCall](/API_docs/methods/phone.discardCall.html)(\[video: $[Bool](/API_docs/types/Bool.html), peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), duration: $[int](/API_docs/types/int.html), reason: $[PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html), connection_id: $[long](/API_docs/types/long.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->discardGroupCall](/API_docs/methods/phone.discardGroupCall.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->editGroupCallParticipant](/API_docs/methods/phone.editGroupCallParticipant.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), participant: $[InputPeer](/API_docs/types/InputPeer.html), muted: $[Bool](/API_docs/types/Bool.html), volume: $[int](/API_docs/types/int.html), raise_hand: $[Bool](/API_docs/types/Bool.html), video_stopped: $[Bool](/API_docs/types/Bool.html), video_paused: $[Bool](/API_docs/types/Bool.html), presentation_paused: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->editGroupCallTitle](/API_docs/methods/phone.editGroupCallTitle.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), title: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->exportGroupCallInvite](/API_docs/methods/phone.exportGroupCallInvite.html)(\[can_self_unmute: $[Bool](/API_docs/types/Bool.html), call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), \]) === [$phone.ExportedGroupCallInvite](/API_docs/types/phone.ExportedGroupCallInvite.html) + +*** +

+$MadelineProto->[phone->getCallConfig](/API_docs/methods/phone.getCallConfig.html)(\[\]) === [$DataJSON](/API_docs/types/DataJSON.html) + +*** +

+$MadelineProto->[phone->getGroupCall](/API_docs/methods/phone.getGroupCall.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), limit: $[int](/API_docs/types/int.html), \]) === [$phone.GroupCall](/API_docs/types/phone.GroupCall.html) + +*** +

+$MadelineProto->[phone->getGroupCallJoinAs](/API_docs/methods/phone.getGroupCallJoinAs.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$phone.JoinAsPeers](/API_docs/types/phone.JoinAsPeers.html) + +*** +

+$MadelineProto->[phone->getGroupCallStreamChannels](/API_docs/methods/phone.getGroupCallStreamChannels.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), \]) === [$phone.GroupCallStreamChannels](/API_docs/types/phone.GroupCallStreamChannels.html) + +*** +

+$MadelineProto->[phone->getGroupCallStreamRtmpUrl](/API_docs/methods/phone.getGroupCallStreamRtmpUrl.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), revoke: $[Bool](/API_docs/types/Bool.html), \]) === [$phone.GroupCallStreamRtmpUrl](/API_docs/types/phone.GroupCallStreamRtmpUrl.html) + +*** +

+$MadelineProto->[phone->getGroupParticipants](/API_docs/methods/phone.getGroupParticipants.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), ids: \[$[InputPeer](/API_docs/types/InputPeer.html)\], sources: \[$[int](/API_docs/types/int.html)\], offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$phone.GroupParticipants](/API_docs/types/phone.GroupParticipants.html) + +*** +

+$MadelineProto->[phone->inviteToGroupCall](/API_docs/methods/phone.inviteToGroupCall.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), users: \[$[InputUser](/API_docs/types/InputUser.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->joinGroupCall](/API_docs/methods/phone.joinGroupCall.html)(\[muted: $[Bool](/API_docs/types/Bool.html), video_stopped: $[Bool](/API_docs/types/Bool.html), call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), join_as: $[InputPeer](/API_docs/types/InputPeer.html), invite_hash: $[string](/API_docs/types/string.html), params: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->joinGroupCallPresentation](/API_docs/methods/phone.joinGroupCallPresentation.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), params: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->leaveGroupCall](/API_docs/methods/phone.leaveGroupCall.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), source: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->leaveGroupCallPresentation](/API_docs/methods/phone.leaveGroupCallPresentation.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->receivedCall](/API_docs/methods/phone.receivedCall.html)(\[peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[phone->requestCall](/API_docs/methods/phone.requestCall.html)(\[video: $[Bool](/API_docs/types/Bool.html), user_id: $[InputUser](/API_docs/types/InputUser.html), g_a_hash: $[bytes](/API_docs/types/bytes.html), protocol: $[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html), \]) === [$phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +*** +

+$MadelineProto->[phone->saveCallDebug](/API_docs/methods/phone.saveCallDebug.html)(\[peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), debug: $[DataJSON](/API_docs/types/DataJSON.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[phone->saveCallLog](/API_docs/methods/phone.saveCallLog.html)(\[peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), file: $[InputFile](/API_docs/types/InputFile.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[phone->saveDefaultGroupCallJoinAs](/API_docs/methods/phone.saveDefaultGroupCallJoinAs.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), join_as: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[phone->sendSignalingData](/API_docs/methods/phone.sendSignalingData.html)(\[peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), data: $[bytes](/API_docs/types/bytes.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[phone->setCallRating](/API_docs/methods/phone.setCallRating.html)(\[user_initiative: $[Bool](/API_docs/types/Bool.html), peer: $[InputPhoneCall](/API_docs/types/InputPhoneCall.html), rating: $[int](/API_docs/types/int.html), comment: $[string](/API_docs/types/string.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->startScheduledGroupCall](/API_docs/methods/phone.startScheduledGroupCall.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->toggleGroupCallRecord](/API_docs/methods/phone.toggleGroupCallRecord.html)(\[start: $[Bool](/API_docs/types/Bool.html), video: $[Bool](/API_docs/types/Bool.html), call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), title: $[string](/API_docs/types/string.html), video_portrait: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->toggleGroupCallSettings](/API_docs/methods/phone.toggleGroupCallSettings.html)(\[reset_invite_hash: $[Bool](/API_docs/types/Bool.html), call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), join_muted: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[phone->toggleGroupCallStartSubscription](/API_docs/methods/phone.toggleGroupCallStartSubscription.html)(\[call: $[InputGroupCall](/API_docs/types/InputGroupCall.html), subscribed: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[photos->deletePhotos](/API_docs/methods/photos.deletePhotos.html)(\[id: \[$[InputPhoto](/API_docs/types/InputPhoto.html)\], \]) === [$Vector\_of\_long](/API_docs/types/long.html) + +*** +

+$MadelineProto->[photos->getUserPhotos](/API_docs/methods/photos.getUserPhotos.html)(\[user_id: $[InputUser](/API_docs/types/InputUser.html), offset: $[int](/API_docs/types/int.html), max_id: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$photos.Photos](/API_docs/types/photos.Photos.html) + +*** +

+$MadelineProto->[photos->updateProfilePhoto](/API_docs/methods/photos.updateProfilePhoto.html)(\[fallback: $[Bool](/API_docs/types/Bool.html), bot: $[InputUser](/API_docs/types/InputUser.html), id: $[InputPhoto](/API_docs/types/InputPhoto.html), \]) === [$photos.Photo](/API_docs/types/photos.Photo.html) + +*** +

+$MadelineProto->[photos->uploadContactProfilePhoto](/API_docs/methods/photos.uploadContactProfilePhoto.html)(\[suggest: $[Bool](/API_docs/types/Bool.html), save: $[Bool](/API_docs/types/Bool.html), user_id: $[InputUser](/API_docs/types/InputUser.html), file: $[InputFile](/API_docs/types/InputFile.html), video: $[InputFile](/API_docs/types/InputFile.html), video_start_ts: $[double](/API_docs/types/double.html), video_emoji_markup: $[VideoSize](/API_docs/types/VideoSize.html), \]) === [$photos.Photo](/API_docs/types/photos.Photo.html) + +*** +

+$MadelineProto->[photos->uploadProfilePhoto](/API_docs/methods/photos.uploadProfilePhoto.html)(\[fallback: $[Bool](/API_docs/types/Bool.html), bot: $[InputUser](/API_docs/types/InputUser.html), file: $[InputFile](/API_docs/types/InputFile.html), video: $[InputFile](/API_docs/types/InputFile.html), video_start_ts: $[double](/API_docs/types/double.html), video_emoji_markup: $[VideoSize](/API_docs/types/VideoSize.html), \]) === [$photos.Photo](/API_docs/types/photos.Photo.html) + +*** +

+$MadelineProto->[premium->applyBoost](/API_docs/methods/premium.applyBoost.html)(\[slots: \[$[int](/API_docs/types/int.html)\], peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$premium.MyBoosts](/API_docs/types/premium.MyBoosts.html) + +*** +

+$MadelineProto->[premium->getBoostsList](/API_docs/methods/premium.getBoostsList.html)(\[gifts: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$premium.BoostsList](/API_docs/types/premium.BoostsList.html) + +*** +

+$MadelineProto->[premium->getBoostsStatus](/API_docs/methods/premium.getBoostsStatus.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$premium.BoostsStatus](/API_docs/types/premium.BoostsStatus.html) + +*** +

+$MadelineProto->[premium->getMyBoosts](/API_docs/methods/premium.getMyBoosts.html)(\[\]) === [$premium.MyBoosts](/API_docs/types/premium.MyBoosts.html) + +*** +

+$MadelineProto->[premium->getUserBoosts](/API_docs/methods/premium.getUserBoosts.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), user_id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$premium.BoostsList](/API_docs/types/premium.BoostsList.html) + +*** +

+$MadelineProto->[smsjobs->finishJob](/API_docs/methods/smsjobs.finishJob.html)(\[job_id: $[string](/API_docs/types/string.html), error: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[smsjobs->getSmsJob](/API_docs/methods/smsjobs.getSmsJob.html)(\[job_id: $[string](/API_docs/types/string.html), \]) === [$SmsJob](/API_docs/types/SmsJob.html) + +*** +

+$MadelineProto->[smsjobs->getStatus](/API_docs/methods/smsjobs.getStatus.html)(\[\]) === [$smsjobs.Status](/API_docs/types/smsjobs.Status.html) + +*** +

+$MadelineProto->[smsjobs->isEligibleToJoin](/API_docs/methods/smsjobs.isEligibleToJoin.html)(\[\]) === [$smsjobs.EligibilityToJoin](/API_docs/types/smsjobs.EligibilityToJoin.html) + +*** +

+$MadelineProto->[smsjobs->join](/API_docs/methods/smsjobs.join.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[smsjobs->leave](/API_docs/methods/smsjobs.leave.html)(\[\]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[smsjobs->updateSettings](/API_docs/methods/smsjobs.updateSettings.html)(\[allow_international: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stats->getBroadcastRevenueStats](/API_docs/methods/stats.getBroadcastRevenueStats.html)(\[dark: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$stats.BroadcastRevenueStats](/API_docs/types/stats.BroadcastRevenueStats.html) + +*** +

+$MadelineProto->[stats->getBroadcastRevenueTransactions](/API_docs/methods/stats.getBroadcastRevenueTransactions.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$stats.BroadcastRevenueTransactions](/API_docs/types/stats.BroadcastRevenueTransactions.html) + +*** +

+$MadelineProto->[stats->getBroadcastRevenueWithdrawalUrl](/API_docs/methods/stats.getBroadcastRevenueWithdrawalUrl.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), password: $[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html), \]) === [$stats.BroadcastRevenueWithdrawalUrl](/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.html) + +*** +

+$MadelineProto->[stats->getBroadcastStats](/API_docs/methods/stats.getBroadcastStats.html)(\[dark: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$stats.BroadcastStats](/API_docs/types/stats.BroadcastStats.html) + +*** +

+$MadelineProto->[stats->getMegagroupStats](/API_docs/methods/stats.getMegagroupStats.html)(\[dark: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), \]) === [$stats.MegagroupStats](/API_docs/types/stats.MegagroupStats.html) + +*** +

+$MadelineProto->[stats->getMessagePublicForwards](/API_docs/methods/stats.getMessagePublicForwards.html)(\[channel: $[InputChannel](/API_docs/types/InputChannel.html), msg_id: $[int](/API_docs/types/int.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$stats.PublicForwards](/API_docs/types/stats.PublicForwards.html) + +*** +

+$MadelineProto->[stats->getMessageStats](/API_docs/methods/stats.getMessageStats.html)(\[dark: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), msg_id: $[int](/API_docs/types/int.html), \]) === [$stats.MessageStats](/API_docs/types/stats.MessageStats.html) + +*** +

+$MadelineProto->[stats->getStoryPublicForwards](/API_docs/methods/stats.getStoryPublicForwards.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$stats.PublicForwards](/API_docs/types/stats.PublicForwards.html) + +*** +

+$MadelineProto->[stats->getStoryStats](/API_docs/methods/stats.getStoryStats.html)(\[dark: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), \]) === [$stats.StoryStats](/API_docs/types/stats.StoryStats.html) + +*** +

+$MadelineProto->[stats->loadAsyncGraph](/API_docs/methods/stats.loadAsyncGraph.html)(\[token: $[string](/API_docs/types/string.html), x: $[long](/API_docs/types/long.html), \]) === [$StatsGraph](/API_docs/types/StatsGraph.html) + +*** +

+$MadelineProto->[stickers->addStickerToSet](/API_docs/methods/stickers.addStickerToSet.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), sticker: $[InputStickerSetItem](/API_docs/types/InputStickerSetItem.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->changeSticker](/API_docs/methods/stickers.changeSticker.html)(\[sticker: $[InputDocument](/API_docs/types/InputDocument.html), emoji: $[string](/API_docs/types/string.html), mask_coords: $[MaskCoords](/API_docs/types/MaskCoords.html), keywords: $[string](/API_docs/types/string.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->changeStickerPosition](/API_docs/methods/stickers.changeStickerPosition.html)(\[sticker: $[InputDocument](/API_docs/types/InputDocument.html), position: $[int](/API_docs/types/int.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->checkShortName](/API_docs/methods/stickers.checkShortName.html)(\[short_name: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stickers->createStickerSet](/API_docs/methods/stickers.createStickerSet.html)(\[masks: $[Bool](/API_docs/types/Bool.html), emojis: $[Bool](/API_docs/types/Bool.html), text_color: $[Bool](/API_docs/types/Bool.html), user_id: $[InputUser](/API_docs/types/InputUser.html), title: $[string](/API_docs/types/string.html), short_name: $[string](/API_docs/types/string.html), thumb: $[InputDocument](/API_docs/types/InputDocument.html), stickers: \[$[InputStickerSetItem](/API_docs/types/InputStickerSetItem.html)\], software: $[string](/API_docs/types/string.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->deleteStickerSet](/API_docs/methods/stickers.deleteStickerSet.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stickers->removeStickerFromSet](/API_docs/methods/stickers.removeStickerFromSet.html)(\[sticker: $[InputDocument](/API_docs/types/InputDocument.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->renameStickerSet](/API_docs/methods/stickers.renameStickerSet.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), title: $[string](/API_docs/types/string.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->replaceSticker](/API_docs/methods/stickers.replaceSticker.html)(\[sticker: $[InputDocument](/API_docs/types/InputDocument.html), new_sticker: $[InputStickerSetItem](/API_docs/types/InputStickerSetItem.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->setStickerSetThumb](/API_docs/methods/stickers.setStickerSetThumb.html)(\[stickerset: $[InputStickerSet](/API_docs/types/InputStickerSet.html), thumb: $[InputDocument](/API_docs/types/InputDocument.html), thumb_document_id: $[long](/API_docs/types/long.html), \]) === [$messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +*** +

+$MadelineProto->[stickers->suggestShortName](/API_docs/methods/stickers.suggestShortName.html)(\[title: $[string](/API_docs/types/string.html), \]) === [$stickers.SuggestedShortName](/API_docs/types/stickers.SuggestedShortName.html) + +*** +

+$MadelineProto->[stories->activateStealthMode](/API_docs/methods/stories.activateStealthMode.html)(\[past: $[Bool](/API_docs/types/Bool.html), future: $[Bool](/API_docs/types/Bool.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[stories->canSendStory](/API_docs/methods/stories.canSendStory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stories->deleteStories](/API_docs/methods/stories.deleteStories.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Vector\_of\_int](/API_docs/types/int.html) + +*** +

+$MadelineProto->[stories->editStory](/API_docs/methods/stories.editStory.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), media: $[InputMedia](/API_docs/types/InputMedia.html), media_areas: \[$[MediaArea](/API_docs/types/MediaArea.html)\], caption: $[string](/API_docs/types/string.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], privacy_rules: \[$[InputPrivacyRule](/API_docs/types/InputPrivacyRule.html)\], \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[stories->exportStoryLink](/API_docs/methods/stories.exportStoryLink.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), \]) === [$ExportedStoryLink](/API_docs/types/ExportedStoryLink.html) + +*** +

+$MadelineProto->[stories->getAllReadPeerStories](/API_docs/methods/stories.getAllReadPeerStories.html)(\[\]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[stories->getAllStories](/API_docs/methods/stories.getAllStories.html)(\[next: $[Bool](/API_docs/types/Bool.html), hidden: $[Bool](/API_docs/types/Bool.html), state: $[string](/API_docs/types/string.html), \]) === [$stories.AllStories](/API_docs/types/stories.AllStories.html) + +*** +

+$MadelineProto->[stories->getChatsToSend](/API_docs/methods/stories.getChatsToSend.html)(\[\]) === [$messages.Chats](/API_docs/types/messages.Chats.html) + +*** +

+$MadelineProto->[stories->getPeerMaxIDs](/API_docs/methods/stories.getPeerMaxIDs.html)(\[id: \[$[InputPeer](/API_docs/types/InputPeer.html)\], \]) === [$Vector\_of\_int](/API_docs/types/int.html) + +*** +

+$MadelineProto->[stories->getPeerStories](/API_docs/methods/stories.getPeerStories.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), \]) === [$stories.PeerStories](/API_docs/types/stories.PeerStories.html) + +*** +

+$MadelineProto->[stories->getPinnedStories](/API_docs/methods/stories.getPinnedStories.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), offset_id: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$stories.Stories](/API_docs/types/stories.Stories.html) + +*** +

+$MadelineProto->[stories->getStoriesArchive](/API_docs/methods/stories.getStoriesArchive.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), offset_id: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$stories.Stories](/API_docs/types/stories.Stories.html) + +*** +

+$MadelineProto->[stories->getStoriesByID](/API_docs/methods/stories.getStoriesByID.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$stories.Stories](/API_docs/types/stories.Stories.html) + +*** +

+$MadelineProto->[stories->getStoriesViews](/API_docs/methods/stories.getStoriesViews.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$stories.StoryViews](/API_docs/types/stories.StoryViews.html) + +*** +

+$MadelineProto->[stories->getStoryReactionsList](/API_docs/methods/stories.getStoryReactionsList.html)(\[forwards_first: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), id: $[int](/API_docs/types/int.html), reaction: $[Reaction](/API_docs/types/Reaction.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$stories.StoryReactionsList](/API_docs/types/stories.StoryReactionsList.html) + +*** +

+$MadelineProto->[stories->getStoryViewsList](/API_docs/methods/stories.getStoryViewsList.html)(\[just_contacts: $[Bool](/API_docs/types/Bool.html), reactions_first: $[Bool](/API_docs/types/Bool.html), forwards_first: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), q: $[string](/API_docs/types/string.html), id: $[int](/API_docs/types/int.html), offset: $[string](/API_docs/types/string.html), limit: $[int](/API_docs/types/int.html), \]) === [$stories.StoryViewsList](/API_docs/types/stories.StoryViewsList.html) + +*** +

+$MadelineProto->[stories->incrementStoryViews](/API_docs/methods/stories.incrementStoryViews.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stories->readStories](/API_docs/methods/stories.readStories.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), max_id: $[int](/API_docs/types/int.html), \]) === [$Vector\_of\_int](/API_docs/types/int.html) + +*** +

+$MadelineProto->[stories->report](/API_docs/methods/stories.report.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], reason: $[ReportReason](/API_docs/types/ReportReason.html), message: $[string](/API_docs/types/string.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stories->sendReaction](/API_docs/methods/stories.sendReaction.html)(\[add_to_recent: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), story_id: $[int](/API_docs/types/int.html), reaction: $[Reaction](/API_docs/types/Reaction.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[stories->sendStory](/API_docs/methods/stories.sendStory.html)(\[pinned: $[Bool](/API_docs/types/Bool.html), noforwards: $[Bool](/API_docs/types/Bool.html), fwd_modified: $[Bool](/API_docs/types/Bool.html), peer: $[InputPeer](/API_docs/types/InputPeer.html), media: $[InputMedia](/API_docs/types/InputMedia.html), media_areas: \[$[MediaArea](/API_docs/types/MediaArea.html)\], caption: $[string](/API_docs/types/string.html), entities: \[$[MessageEntity](/API_docs/types/MessageEntity.html)\], privacy_rules: \[$[InputPrivacyRule](/API_docs/types/InputPrivacyRule.html)\], period: $[int](/API_docs/types/int.html), fwd_from_id: $[InputPeer](/API_docs/types/InputPeer.html), fwd_from_story: $[int](/API_docs/types/int.html), \]) === [$Updates](/API_docs/types/Updates.html) + +*** +

+$MadelineProto->[stories->toggleAllStoriesHidden](/API_docs/methods/stories.toggleAllStoriesHidden.html)(\[hidden: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stories->togglePeerStoriesHidden](/API_docs/methods/stories.togglePeerStoriesHidden.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), hidden: $[Bool](/API_docs/types/Bool.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[stories->togglePinned](/API_docs/methods/stories.togglePinned.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], pinned: $[Bool](/API_docs/types/Bool.html), \]) === [$Vector\_of\_int](/API_docs/types/int.html) + +*** +

+$MadelineProto->[stories->togglePinnedToTop](/API_docs/methods/stories.togglePinnedToTop.html)(\[peer: $[InputPeer](/API_docs/types/InputPeer.html), id: \[$[int](/API_docs/types/int.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[updates->getChannelDifference](/API_docs/methods/updates.getChannelDifference.html)(\[force: $[Bool](/API_docs/types/Bool.html), channel: $[InputChannel](/API_docs/types/InputChannel.html), filter: $[ChannelMessagesFilter](/API_docs/types/ChannelMessagesFilter.html), pts: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$updates.ChannelDifference](/API_docs/types/updates.ChannelDifference.html) + +*** +

+$MadelineProto->[updates->getDifference](/API_docs/methods/updates.getDifference.html)(\[pts: $[int](/API_docs/types/int.html), pts_limit: $[int](/API_docs/types/int.html), pts_total_limit: $[int](/API_docs/types/int.html), date: $[int](/API_docs/types/int.html), qts: $[int](/API_docs/types/int.html), qts_limit: $[int](/API_docs/types/int.html), \]) === [$updates.Difference](/API_docs/types/updates.Difference.html) + +*** +

+$MadelineProto->[updates->getState](/API_docs/methods/updates.getState.html)(\[\]) === [$updates.State](/API_docs/types/updates.State.html) + +*** +

+$MadelineProto->[upload->getCdnFile](/API_docs/methods/upload.getCdnFile.html)(\[file_token: $[string](/API_docs/types/string.html), offset: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$upload.CdnFile](/API_docs/types/upload.CdnFile.html) + +*** +

+$MadelineProto->[upload->getCdnFileHashes](/API_docs/methods/upload.getCdnFileHashes.html)(\[file_token: $[string](/API_docs/types/string.html), offset: $[long](/API_docs/types/long.html), \]) === [$Vector\_of\_FileHash](/API_docs/types/FileHash.html) + +*** +

+$MadelineProto->[upload->getFile](/API_docs/methods/upload.getFile.html)(\[precise: $[Bool](/API_docs/types/Bool.html), cdn_supported: $[Bool](/API_docs/types/Bool.html), location: $[InputFileLocation](/API_docs/types/InputFileLocation.html), offset: $[long](/API_docs/types/long.html), limit: $[int](/API_docs/types/int.html), \]) === [$upload.File](/API_docs/types/upload.File.html) + +*** +

+$MadelineProto->[upload->getFileHashes](/API_docs/methods/upload.getFileHashes.html)(\[location: $[InputFileLocation](/API_docs/types/InputFileLocation.html), offset: $[long](/API_docs/types/long.html), \]) === [$Vector\_of\_FileHash](/API_docs/types/FileHash.html) + +*** +

+$MadelineProto->[upload->getWebFile](/API_docs/methods/upload.getWebFile.html)(\[location: $[InputWebFileLocation](/API_docs/types/InputWebFileLocation.html), offset: $[int](/API_docs/types/int.html), limit: $[int](/API_docs/types/int.html), \]) === [$upload.WebFile](/API_docs/types/upload.WebFile.html) + +*** +

+$MadelineProto->[upload->reuploadCdnFile](/API_docs/methods/upload.reuploadCdnFile.html)(\[file_token: $[string](/API_docs/types/string.html), request_token: $[bytes](/API_docs/types/bytes.html), \]) === [$Vector\_of\_FileHash](/API_docs/types/FileHash.html) + +*** +

+$MadelineProto->[upload->saveBigFilePart](/API_docs/methods/upload.saveBigFilePart.html)(\[file_id: $[long](/API_docs/types/long.html), file_part: $[int](/API_docs/types/int.html), file_total_parts: $[int](/API_docs/types/int.html), bytes: $[bytes](/API_docs/types/bytes.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[upload->saveFilePart](/API_docs/methods/upload.saveFilePart.html)(\[file_id: $[long](/API_docs/types/long.html), file_part: $[int](/API_docs/types/int.html), bytes: $[bytes](/API_docs/types/bytes.html), \]) === [$Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[users->getFullUser](/API_docs/methods/users.getFullUser.html)(\[id: $[InputUser](/API_docs/types/InputUser.html), \]) === [$users.UserFull](/API_docs/types/users.UserFull.html) + +*** +

+$MadelineProto->[users->getIsPremiumRequiredToContact](/API_docs/methods/users.getIsPremiumRequiredToContact.html)(\[id: \[$[InputUser](/API_docs/types/InputUser.html)\], \]) === [$Vector\_of\_Bool](/API_docs/types/Bool.html) + +*** +

+$MadelineProto->[users->getUsers](/API_docs/methods/users.getUsers.html)(\[id: \[$[InputUser](/API_docs/types/InputUser.html)\], \]) === [$Vector\_of\_User](/API_docs/types/User.html) + +*** +

+$MadelineProto->[users->setSecureValueErrors](/API_docs/methods/users.setSecureValueErrors.html)(\[id: $[InputUser](/API_docs/types/InputUser.html), errors: \[$[SecureValueError](/API_docs/types/SecureValueError.html)\], \]) === [$Bool](/API_docs/types/Bool.html) + + diff --git a/docs/API_docs/methods/auth.acceptLoginToken.md b/docs/API_docs/methods/auth.acceptLoginToken.md new file mode 100644 index 0000000000..4796be73b7 --- /dev/null +++ b/docs/API_docs/methods/auth.acceptLoginToken.md @@ -0,0 +1,46 @@ +--- +title: "auth.acceptLoginToken" +description: "Accept QR code login token, logging in the app that generated it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_acceptLoginToken.html +--- +# Method: auth.acceptLoginToken +[Back to methods index](index.html) + + + +Accept QR code login token, logging in the app that generated it. + +Returns info about the new session. + +For more info, see [login via QR code](https://core.telegram.org/api/qr-login). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|token|[bytes](/API_docs/types/bytes.html) | Login token embedded in QR code, for more info, see [login via QR code](https://core.telegram.org/api/qr-login). | Yes| + + +### Return type: [Authorization](/API_docs/types/Authorization.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Authorization = $MadelineProto->auth->acceptLoginToken(token: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/auth.bindTempAuthKey.md b/docs/API_docs/methods/auth.bindTempAuthKey.md new file mode 100644 index 0000000000..c4bdf942e1 --- /dev/null +++ b/docs/API_docs/methods/auth.bindTempAuthKey.md @@ -0,0 +1,45 @@ +--- +title: "auth.bindTempAuthKey" +description: "You cannot use this method directly, instead modify the PFS and default_temp_auth_key_expires_in settings, see https://docs.madelineproto.xyz/docs/SETTINGS.html for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_bindTempAuthKey.html +--- +# Method: auth.bindTempAuthKey +[Back to methods index](index.html) + + + +You cannot use this method directly, instead modify the PFS and default_temp_auth_key_expires_in settings, see https://docs.madelineproto.xyz/docs/SETTINGS.html for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|perm\_auth\_key\_id|[long](/API_docs/types/long.html) | Permanent auth\_key\_id to bind to | Yes| +|nonce|[long](/API_docs/types/long.html) | Random long from [Binding message contents](#binding-message-contents) | Yes| +|expires\_at|[int](/API_docs/types/int.html) | Unix timestamp to invalidate temporary key, see [Binding message contents](#binding-message-contents) | Optional| +|encrypted\_message|[bytes](/API_docs/types/bytes.html) | See [Generating encrypted\_message](#generating-encrypted-message) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->bindTempAuthKey(perm_auth_key_id: $long, nonce: $long, expires_at: $int, encrypted_message: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/auth.cancelCode.md b/docs/API_docs/methods/auth.cancelCode.md new file mode 100644 index 0000000000..b7b95daaba --- /dev/null +++ b/docs/API_docs/methods/auth.cancelCode.md @@ -0,0 +1,43 @@ +--- +title: "auth.cancelCode" +description: "Cancel the login verification code" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_cancelCode.html +--- +# Method: auth.cancelCode +[Back to methods index](index.html) + + + +Cancel the login verification code + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Phone number | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Phone code hash from [auth.sendCode](../methods/auth.sendCode.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->cancelCode(phone_number: 'string', phone_code_hash: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.checkPassword.md b/docs/API_docs/methods/auth.checkPassword.md new file mode 100644 index 0000000000..c056e2ebba --- /dev/null +++ b/docs/API_docs/methods/auth.checkPassword.md @@ -0,0 +1,42 @@ +--- +title: "auth.checkPassword" +description: "You cannot use this method directly, use the complete2falogin method instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_checkPassword.html +--- +# Method: auth.checkPassword +[Back to methods index](index.html) + + + +You cannot use this method directly, use the complete2falogin method instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | The account's password (see [SRP](https://core.telegram.org/api/srp)) | Yes| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->checkPassword(password: $InputCheckPasswordSRP, ); +``` + diff --git a/docs/API_docs/methods/auth.checkRecoveryPassword.md b/docs/API_docs/methods/auth.checkRecoveryPassword.md new file mode 100644 index 0000000000..d21a5b2466 --- /dev/null +++ b/docs/API_docs/methods/auth.checkRecoveryPassword.md @@ -0,0 +1,42 @@ +--- +title: "auth.checkRecoveryPassword" +description: "Check if the [2FA recovery code](https://core.telegram.org/api/srp) sent using [auth.requestPasswordRecovery](../methods/auth.requestPasswordRecovery.html) is valid, before passing it to [auth.recoverPassword](../methods/auth.recoverPassword.html)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_checkRecoveryPassword.html +--- +# Method: auth.checkRecoveryPassword +[Back to methods index](index.html) + + + +Check if the [2FA recovery code](https://core.telegram.org/api/srp) sent using [auth.requestPasswordRecovery](../methods/auth.requestPasswordRecovery.html) is valid, before passing it to [auth.recoverPassword](../methods/auth.recoverPassword.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|code|[string](/API_docs/types/string.html) | Code received via email | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->checkRecoveryPassword(code: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.dropTempAuthKeys.md b/docs/API_docs/methods/auth.dropTempAuthKeys.md new file mode 100644 index 0000000000..db7a5883de --- /dev/null +++ b/docs/API_docs/methods/auth.dropTempAuthKeys.md @@ -0,0 +1,42 @@ +--- +title: "auth.dropTempAuthKeys" +description: "Delete all temporary authorization keys **except for** the ones specified" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_dropTempAuthKeys.html +--- +# Method: auth.dropTempAuthKeys +[Back to methods index](index.html) + + + +Delete all temporary authorization keys **except for** the ones specified + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|except\_auth\_keys|Array of [long](/API_docs/types/long.html) | The auth keys that **shouldn't** be dropped. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->dropTempAuthKeys(except_auth_keys: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/auth.exportAuthorization.md b/docs/API_docs/methods/auth.exportAuthorization.md new file mode 100644 index 0000000000..f232b243dc --- /dev/null +++ b/docs/API_docs/methods/auth.exportAuthorization.md @@ -0,0 +1,42 @@ +--- +title: "auth.exportAuthorization" +description: "You cannot use this method directly, use $MadelineProto->exportAuthorization() instead, see https://docs.madelineproto.xyz/docs/LOGIN.html" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_exportAuthorization.html +--- +# Method: auth.exportAuthorization +[Back to methods index](index.html) + + + +You cannot use this method directly, use $MadelineProto->exportAuthorization() instead, see https://docs.madelineproto.xyz/docs/LOGIN.html + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|dc\_id|[int](/API_docs/types/int.html) | Number of a target data-center | Optional| + + +### Return type: [auth.ExportedAuthorization](/API_docs/types/auth.ExportedAuthorization.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_ExportedAuthorization = $MadelineProto->auth->exportAuthorization(dc_id: $int, ); +``` + diff --git a/docs/API_docs/methods/auth.exportLoginToken.md b/docs/API_docs/methods/auth.exportLoginToken.md new file mode 100644 index 0000000000..f2975d7517 --- /dev/null +++ b/docs/API_docs/methods/auth.exportLoginToken.md @@ -0,0 +1,47 @@ +--- +title: "auth.exportLoginToken" +description: "Generate a login token, for [login via QR code](https://core.telegram.org/api/qr-login). " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_exportLoginToken.html +--- +# Method: auth.exportLoginToken +[Back to methods index](index.html) + + + +Generate a login token, for [login via QR code](https://core.telegram.org/api/qr-login). +The generated login token should be encoded using base64url, then shown as a `tg://login?token=base64encodedtoken` [deep link »](https://core.telegram.org/api/links#qr-code-login-links) in the QR code. + +For more info, see [login via QR code](https://core.telegram.org/api/qr-login). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|api\_id|[int](/API_docs/types/int.html) | Application identifier (see. [App configuration](https://core.telegram.org/myapp)) | Optional| +|api\_hash|[string](/API_docs/types/string.html) | Application identifier hash (see. [App configuration](https://core.telegram.org/myapp)) | Optional| +|except\_ids|Array of [long](/API_docs/types/long.html) | List of already logged-in user IDs, to prevent logging in twice with the same user | Yes| + + +### Return type: [auth.LoginToken](/API_docs/types/auth.LoginToken.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_LoginToken = $MadelineProto->auth->exportLoginToken(api_id: $int, api_hash: 'string', except_ids: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/auth.importAuthorization.md b/docs/API_docs/methods/auth.importAuthorization.md new file mode 100644 index 0000000000..2a2697524a --- /dev/null +++ b/docs/API_docs/methods/auth.importAuthorization.md @@ -0,0 +1,43 @@ +--- +title: "auth.importAuthorization" +description: "You cannot use this method directly, use $MadelineProto->importAuthorization($authorization) instead, see https://docs.madelineproto.xyz/docs/LOGIN.html" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_importAuthorization.html +--- +# Method: auth.importAuthorization +[Back to methods index](index.html) + + + +You cannot use this method directly, use $MadelineProto->importAuthorization($authorization) instead, see https://docs.madelineproto.xyz/docs/LOGIN.html + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[long](/API_docs/types/long.html) | User ID | Yes| +|bytes|[bytes](/API_docs/types/bytes.html) | Authorization key | Yes| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->importAuthorization(id: $long, bytes: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/auth.importBotAuthorization.md b/docs/API_docs/methods/auth.importBotAuthorization.md new file mode 100644 index 0000000000..a57e7382f8 --- /dev/null +++ b/docs/API_docs/methods/auth.importBotAuthorization.md @@ -0,0 +1,44 @@ +--- +title: "auth.importBotAuthorization" +description: "You cannot use this method directly, use the botLogin method instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_importBotAuthorization.html +--- +# Method: auth.importBotAuthorization +[Back to methods index](index.html) + + + +You cannot use this method directly, use the botLogin method instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|api\_id|[int](/API_docs/types/int.html) | Application identifier (see. [App configuration](https://core.telegram.org/myapp)) | Optional| +|api\_hash|[string](/API_docs/types/string.html) | Application identifier hash (see. [App configuration](https://core.telegram.org/myapp)) | Optional| +|bot\_auth\_token|[string](/API_docs/types/string.html) | Bot token (see [bots](https://core.telegram.org/bots)) | Optional| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->importBotAuthorization(api_id: $int, api_hash: 'string', bot_auth_token: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.importLoginToken.md b/docs/API_docs/methods/auth.importLoginToken.md new file mode 100644 index 0000000000..90974d87bb --- /dev/null +++ b/docs/API_docs/methods/auth.importLoginToken.md @@ -0,0 +1,44 @@ +--- +title: "auth.importLoginToken" +description: "Login using a redirected login token, generated in case of DC mismatch during [QR code login](https://core.telegram.org/api/qr-login)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_importLoginToken.html +--- +# Method: auth.importLoginToken +[Back to methods index](index.html) + + + +Login using a redirected login token, generated in case of DC mismatch during [QR code login](https://core.telegram.org/api/qr-login). + +For more info, see [login via QR code](https://core.telegram.org/api/qr-login). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|token|[bytes](/API_docs/types/bytes.html) | Login token | Yes| + + +### Return type: [auth.LoginToken](/API_docs/types/auth.LoginToken.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_LoginToken = $MadelineProto->auth->importLoginToken(token: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/auth.importWebTokenAuthorization.md b/docs/API_docs/methods/auth.importWebTokenAuthorization.md new file mode 100644 index 0000000000..83035d1a25 --- /dev/null +++ b/docs/API_docs/methods/auth.importWebTokenAuthorization.md @@ -0,0 +1,44 @@ +--- +title: "auth.importWebTokenAuthorization" +description: "Login by importing an authorization token" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_importWebTokenAuthorization.html +--- +# Method: auth.importWebTokenAuthorization +[Back to methods index](index.html) + + + +Login by importing an authorization token + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|api\_id|[int](/API_docs/types/int.html) | [API ID](https://core.telegram.org/api/obtaining_api_id) | Optional| +|api\_hash|[string](/API_docs/types/string.html) | [API hash](https://core.telegram.org/api/obtaining_api_id) | Optional| +|web\_auth\_token|[string](/API_docs/types/string.html) | The authorization token | Optional| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->importWebTokenAuthorization(api_id: $int, api_hash: 'string', web_auth_token: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.logOut.md b/docs/API_docs/methods/auth.logOut.md new file mode 100644 index 0000000000..58c11101ef --- /dev/null +++ b/docs/API_docs/methods/auth.logOut.md @@ -0,0 +1,37 @@ +--- +title: "auth.logOut" +description: "You cannot use this method directly, use the logout method instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_logOut.html +--- +# Method: auth.logOut +[Back to methods index](index.html) + + + +You cannot use this method directly, use the logout method instead (see https://docs.madelineproto.xyz for more info) + + + +### Return type: [auth.LoggedOut](/API_docs/types/auth.LoggedOut.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_LoggedOut = $MadelineProto->auth->logOut(); +``` + diff --git a/docs/API_docs/methods/auth.recoverPassword.md b/docs/API_docs/methods/auth.recoverPassword.md new file mode 100644 index 0000000000..9c23746366 --- /dev/null +++ b/docs/API_docs/methods/auth.recoverPassword.md @@ -0,0 +1,43 @@ +--- +title: "auth.recoverPassword" +description: "Reset the [2FA password](https://core.telegram.org/api/srp) using the recovery code sent using [auth.requestPasswordRecovery](../methods/auth.requestPasswordRecovery.html)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_recoverPassword.html +--- +# Method: auth.recoverPassword +[Back to methods index](index.html) + + + +Reset the [2FA password](https://core.telegram.org/api/srp) using the recovery code sent using [auth.requestPasswordRecovery](../methods/auth.requestPasswordRecovery.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|code|[string](/API_docs/types/string.html) | Code received via email | Optional| +|new\_settings|[account.PasswordInputSettings](/API_docs/types/account.PasswordInputSettings.html) | New password | Optional| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->recoverPassword(code: 'string', new_settings: $account.PasswordInputSettings, ); +``` + diff --git a/docs/API_docs/methods/auth.reportMissingCode.md b/docs/API_docs/methods/auth.reportMissingCode.md new file mode 100644 index 0000000000..a55ac6301f --- /dev/null +++ b/docs/API_docs/methods/auth.reportMissingCode.md @@ -0,0 +1,42 @@ +--- +title: "auth.reportMissingCode" +description: "auth.reportMissingCode parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_reportMissingCode.html +--- +# Method: auth.reportMissingCode +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Optional| +|mnc|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->reportMissingCode(phone_number: 'string', phone_code_hash: 'string', mnc: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.requestFirebaseSms.md b/docs/API_docs/methods/auth.requestFirebaseSms.md new file mode 100644 index 0000000000..b2ca56e21d --- /dev/null +++ b/docs/API_docs/methods/auth.requestFirebaseSms.md @@ -0,0 +1,45 @@ +--- +title: "auth.requestFirebaseSms" +description: "Request an SMS code via Firebase." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_requestFirebaseSms.html +--- +# Method: auth.requestFirebaseSms +[Back to methods index](index.html) + + + +Request an SMS code via Firebase. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Phone number | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Phone code hash returned by [auth.sendCode](../methods/auth.sendCode.html) | Optional| +|safety\_net\_token|[string](/API_docs/types/string.html) | On Android, a JWS object obtained as described in the [auth documentation »](https://core.telegram.org/api/auth) | Optional| +|ios\_push\_secret|[string](/API_docs/types/string.html) | Secret token received via an apple push notification | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->requestFirebaseSms(phone_number: 'string', phone_code_hash: 'string', safety_net_token: 'string', ios_push_secret: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.requestPasswordRecovery.md b/docs/API_docs/methods/auth.requestPasswordRecovery.md new file mode 100644 index 0000000000..654293e34b --- /dev/null +++ b/docs/API_docs/methods/auth.requestPasswordRecovery.md @@ -0,0 +1,37 @@ +--- +title: "auth.requestPasswordRecovery" +description: "Request recovery code of a [2FA password](https://core.telegram.org/api/srp), only for accounts with a [recovery email configured](https://core.telegram.org/api/srp#email-verification)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_requestPasswordRecovery.html +--- +# Method: auth.requestPasswordRecovery +[Back to methods index](index.html) + + + +Request recovery code of a [2FA password](https://core.telegram.org/api/srp), only for accounts with a [recovery email configured](https://core.telegram.org/api/srp#email-verification). + + + +### Return type: [auth.PasswordRecovery](/API_docs/types/auth.PasswordRecovery.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_PasswordRecovery = $MadelineProto->auth->requestPasswordRecovery(); +``` + diff --git a/docs/API_docs/methods/auth.resendCode.md b/docs/API_docs/methods/auth.resendCode.md new file mode 100644 index 0000000000..e6fe5f11fa --- /dev/null +++ b/docs/API_docs/methods/auth.resendCode.md @@ -0,0 +1,43 @@ +--- +title: "auth.resendCode" +description: "Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see [login](https://core.telegram.org/api/auth) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_resendCode.html +--- +# Method: auth.resendCode +[Back to methods index](index.html) + + + +Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see [login](https://core.telegram.org/api/auth) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | The phone number | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | The phone code hash obtained from [auth.sendCode](../methods/auth.sendCode.html) | Optional| + + +### Return type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_SentCode = $MadelineProto->auth->resendCode(phone_number: 'string', phone_code_hash: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.resetAuthorizations.md b/docs/API_docs/methods/auth.resetAuthorizations.md new file mode 100644 index 0000000000..579b39e275 --- /dev/null +++ b/docs/API_docs/methods/auth.resetAuthorizations.md @@ -0,0 +1,39 @@ +--- +title: "auth.resetAuthorizations" +description: "Terminates all user's authorized sessions except for the current one." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_resetAuthorizations.html +--- +# Method: auth.resetAuthorizations +[Back to methods index](index.html) + + + +Terminates all user's authorized sessions except for the current one. + +After calling this method it is necessary to reregister the current device using the method [account.registerDevice](../methods/account.registerDevice.html) + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->auth->resetAuthorizations(); +``` + diff --git a/docs/API_docs/methods/auth.resetLoginEmail.md b/docs/API_docs/methods/auth.resetLoginEmail.md new file mode 100644 index 0000000000..380c656590 --- /dev/null +++ b/docs/API_docs/methods/auth.resetLoginEmail.md @@ -0,0 +1,43 @@ +--- +title: "auth.resetLoginEmail" +description: "Reset the [login email »](https://core.telegram.org/api/auth#email-verification)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_resetLoginEmail.html +--- +# Method: auth.resetLoginEmail +[Back to methods index](index.html) + + + +Reset the [login email »](https://core.telegram.org/api/auth#email-verification). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Phone number of the account | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | Phone code hash, obtained as described in the [documentation »](https://core.telegram.org/api/auth) | Optional| + + +### Return type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_SentCode = $MadelineProto->auth->resetLoginEmail(phone_number: 'string', phone_code_hash: 'string', ); +``` + diff --git a/docs/API_docs/methods/auth.sendCode.md b/docs/API_docs/methods/auth.sendCode.md new file mode 100644 index 0000000000..c3d31dd4b5 --- /dev/null +++ b/docs/API_docs/methods/auth.sendCode.md @@ -0,0 +1,45 @@ +--- +title: "auth.sendCode" +description: "You cannot use this method directly, use the phoneLogin method instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_sendCode.html +--- +# Method: auth.sendCode +[Back to methods index](index.html) + + + +You cannot use this method directly, use the phoneLogin method instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Phone number in international format | Optional| +|api\_id|[int](/API_docs/types/int.html) | Application identifier (see [App configuration](https://core.telegram.org/myapp)) | Optional| +|api\_hash|[string](/API_docs/types/string.html) | Application secret hash (see [App configuration](https://core.telegram.org/myapp)) | Optional| +|settings|[CodeSettings](/API_docs/types/CodeSettings.html) | Settings for the code type to send | Yes| + + +### Return type: [auth.SentCode](/API_docs/types/auth.SentCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_SentCode = $MadelineProto->auth->sendCode(phone_number: 'string', api_id: $int, api_hash: 'string', settings: $CodeSettings, ); +``` + diff --git a/docs/API_docs/methods/auth.signIn.md b/docs/API_docs/methods/auth.signIn.md new file mode 100644 index 0000000000..7200736e77 --- /dev/null +++ b/docs/API_docs/methods/auth.signIn.md @@ -0,0 +1,45 @@ +--- +title: "auth.signIn" +description: "You cannot use this method directly, use the completePhoneLogin method instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_signIn.html +--- +# Method: auth.signIn +[Back to methods index](index.html) + + + +You cannot use this method directly, use the completePhoneLogin method instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone\_number|[string](/API_docs/types/string.html) | Phone number in the international format | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | SMS-message ID, obtained from [auth.sendCode](../methods/auth.sendCode.html) | Optional| +|phone\_code|[string](/API_docs/types/string.html) | Valid numerical code from the SMS-message | Optional| +|email\_verification|[EmailVerification](/API_docs/types/EmailVerification.html) | Email verification code or token | Optional| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->signIn(phone_number: 'string', phone_code_hash: 'string', phone_code: 'string', email_verification: $EmailVerification, ); +``` + diff --git a/docs/API_docs/methods/auth.signUp.md b/docs/API_docs/methods/auth.signUp.md new file mode 100644 index 0000000000..1f4236a660 --- /dev/null +++ b/docs/API_docs/methods/auth.signUp.md @@ -0,0 +1,46 @@ +--- +title: "auth.signUp" +description: "You cannot use this method directly, use the completeSignup method instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/auth_signUp.html +--- +# Method: auth.signUp +[Back to methods index](index.html) + + + +You cannot use this method directly, use the completeSignup method instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|no\_joined\_notifications|[Bool](/API_docs/types/Bool.html) | | Optional| +|phone\_number|[string](/API_docs/types/string.html) | Phone number in the international format | Optional| +|phone\_code\_hash|[string](/API_docs/types/string.html) | SMS-message ID | Optional| +|first\_name|[string](/API_docs/types/string.html) | New user first name | Optional| +|last\_name|[string](/API_docs/types/string.html) | New user last name | Optional| + + +### Return type: [auth.Authorization](/API_docs/types/auth.Authorization.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$auth_Authorization = $MadelineProto->auth->signUp(no_joined_notifications: $Bool, phone_number: 'string', phone_code_hash: 'string', first_name: 'string', last_name: 'string', ); +``` + diff --git a/docs/API_docs/methods/bots.allowSendMessage.md b/docs/API_docs/methods/bots.allowSendMessage.md new file mode 100644 index 0000000000..0ba59a00dc --- /dev/null +++ b/docs/API_docs/methods/bots.allowSendMessage.md @@ -0,0 +1,42 @@ +--- +title: "bots.allowSendMessage" +description: "Allow the specified bot to send us messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_allowSendMessage.html +--- +# Method: bots.allowSendMessage +[Back to methods index](index.html) + + + +Allow the specified bot to send us messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The bot | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->bots->allowSendMessage(bot: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/bots.answerWebhookJSONQuery.md b/docs/API_docs/methods/bots.answerWebhookJSONQuery.md new file mode 100644 index 0000000000..961d4c50e9 --- /dev/null +++ b/docs/API_docs/methods/bots.answerWebhookJSONQuery.md @@ -0,0 +1,43 @@ +--- +title: "bots.answerWebhookJSONQuery" +description: "Answers a custom query; for bots only" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_answerWebhookJSONQuery.html +--- +# Method: bots.answerWebhookJSONQuery +[Back to methods index](index.html) + + + +Answers a custom query; for bots only + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|query\_id|[long](/API_docs/types/long.html) | Identifier of a custom query | Yes| +|data|[DataJSON](/API_docs/types/DataJSON.html) | JSON-serialized answer to the query | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->answerWebhookJSONQuery(query_id: $long, data: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/bots.canSendMessage.md b/docs/API_docs/methods/bots.canSendMessage.md new file mode 100644 index 0000000000..9e65c1ff77 --- /dev/null +++ b/docs/API_docs/methods/bots.canSendMessage.md @@ -0,0 +1,42 @@ +--- +title: "bots.canSendMessage" +description: "Check whether the specified bot can send us messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_canSendMessage.html +--- +# Method: bots.canSendMessage +[Back to methods index](index.html) + + + +Check whether the specified bot can send us messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The bot | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->canSendMessage(bot: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/bots.getBotCommands.md b/docs/API_docs/methods/bots.getBotCommands.md new file mode 100644 index 0000000000..10115b2b1f --- /dev/null +++ b/docs/API_docs/methods/bots.getBotCommands.md @@ -0,0 +1,43 @@ +--- +title: "bots.getBotCommands" +description: "Obtain a list of bot commands for the specified bot scope and language code" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_getBotCommands.html +--- +# Method: bots.getBotCommands +[Back to methods index](index.html) + + + +Obtain a list of bot commands for the specified bot scope and language code + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|scope|[BotCommandScope](/API_docs/types/BotCommandScope.html) | Command scope | Yes| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| + + +### Return type: [Vector\_of\_BotCommand](/API_docs/types/BotCommand.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_BotCommand = $MadelineProto->bots->getBotCommands(scope: $BotCommandScope, lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/bots.getBotInfo.md b/docs/API_docs/methods/bots.getBotInfo.md new file mode 100644 index 0000000000..1cd305ed26 --- /dev/null +++ b/docs/API_docs/methods/bots.getBotInfo.md @@ -0,0 +1,43 @@ +--- +title: "bots.getBotInfo" +description: "Get localized name, about text and description of a bot (or of the current account, if called by a bot)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_getBotInfo.html +--- +# Method: bots.getBotInfo +[Back to methods index](index.html) + + + +Get localized name, about text and description of a bot (or of the current account, if called by a bot). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | If called by a user, **must** contain the peer of a bot we own. | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Language code, if left empty this method will return the fallback about text and description. | Optional| + + +### Return type: [bots.BotInfo](/API_docs/types/bots.BotInfo.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$bots_BotInfo = $MadelineProto->bots->getBotInfo(bot: $InputUser, lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/bots.getBotMenuButton.md b/docs/API_docs/methods/bots.getBotMenuButton.md new file mode 100644 index 0000000000..47f8c1266c --- /dev/null +++ b/docs/API_docs/methods/bots.getBotMenuButton.md @@ -0,0 +1,42 @@ +--- +title: "bots.getBotMenuButton" +description: "Gets the menu button action for a given user or for all users, previously set using [bots.setBotMenuButton](../methods/bots.setBotMenuButton.html); users can see this information in the [botInfo](../constructors/botInfo.html) constructor." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_getBotMenuButton.html +--- +# Method: bots.getBotMenuButton +[Back to methods index](index.html) + + + +Gets the menu button action for a given user or for all users, previously set using [bots.setBotMenuButton](../methods/bots.setBotMenuButton.html); users can see this information in the [botInfo](../constructors/botInfo.html) constructor. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID or empty for the default menu button. | Optional| + + +### Return type: [BotMenuButton](/API_docs/types/BotMenuButton.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$BotMenuButton = $MadelineProto->bots->getBotMenuButton(user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/bots.invokeWebViewCustomMethod.md b/docs/API_docs/methods/bots.invokeWebViewCustomMethod.md new file mode 100644 index 0000000000..e77be463b3 --- /dev/null +++ b/docs/API_docs/methods/bots.invokeWebViewCustomMethod.md @@ -0,0 +1,46 @@ +--- +title: "bots.invokeWebViewCustomMethod" +description: "Send a custom request from a [mini bot app](https://core.telegram.org/api/bots/webapps), triggered by a [web\_app\_invoke\_custom\_method event »](https://core.telegram.org/api/web-events#web-app-invoke-custom-method)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_invokeWebViewCustomMethod.html +--- +# Method: bots.invokeWebViewCustomMethod +[Back to methods index](index.html) + + + +Send a custom request from a [mini bot app](https://core.telegram.org/api/bots/webapps), triggered by a [web\_app\_invoke\_custom\_method event »](https://core.telegram.org/api/web-events#web-app-invoke-custom-method). + +The response should be sent using a [custom\_method\_invoked](https://core.telegram.org/api/bots/webapps#custom-method-invoked) event, [see here »](https://core.telegram.org/api/web-events#web-app-invoke-custom-method) for more info on the flow. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Identifier of the bot associated to the [mini bot app](https://core.telegram.org/api/bots/webapps) | Optional| +|custom\_method|[string](/API_docs/types/string.html) | Identifier of the custom method to invoke | Optional| +|params|[DataJSON](/API_docs/types/DataJSON.html) | Method parameters | Yes| + + +### Return type: [DataJSON](/API_docs/types/DataJSON.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$DataJSON = $MadelineProto->bots->invokeWebViewCustomMethod(bot: $InputUser, custom_method: 'string', params: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/bots.reorderUsernames.md b/docs/API_docs/methods/bots.reorderUsernames.md new file mode 100644 index 0000000000..d8e65c791e --- /dev/null +++ b/docs/API_docs/methods/bots.reorderUsernames.md @@ -0,0 +1,43 @@ +--- +title: "bots.reorderUsernames" +description: "Reorder usernames associated to a bot we own." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_reorderUsernames.html +--- +# Method: bots.reorderUsernames +[Back to methods index](index.html) + + + +Reorder usernames associated to a bot we own. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The bot | Optional| +|order|Array of [string](/API_docs/types/string.html) | The new order for active usernames. All active usernames must be specified. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->reorderUsernames(bot: $InputUser, order: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/bots.resetBotCommands.md b/docs/API_docs/methods/bots.resetBotCommands.md new file mode 100644 index 0000000000..496c3431a9 --- /dev/null +++ b/docs/API_docs/methods/bots.resetBotCommands.md @@ -0,0 +1,43 @@ +--- +title: "bots.resetBotCommands" +description: "Clear bot commands for the specified bot scope and language code" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_resetBotCommands.html +--- +# Method: bots.resetBotCommands +[Back to methods index](index.html) + + + +Clear bot commands for the specified bot scope and language code + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|scope|[BotCommandScope](/API_docs/types/BotCommandScope.html) | Command scope | Yes| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->resetBotCommands(scope: $BotCommandScope, lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/bots.sendCustomRequest.md b/docs/API_docs/methods/bots.sendCustomRequest.md new file mode 100644 index 0000000000..dcc5c94409 --- /dev/null +++ b/docs/API_docs/methods/bots.sendCustomRequest.md @@ -0,0 +1,43 @@ +--- +title: "bots.sendCustomRequest" +description: "Sends a custom request; for bots only" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_sendCustomRequest.html +--- +# Method: bots.sendCustomRequest +[Back to methods index](index.html) + + + +Sends a custom request; for bots only + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|custom\_method|[string](/API_docs/types/string.html) | The method name | Optional| +|params|[DataJSON](/API_docs/types/DataJSON.html) | JSON-serialized method parameters | Yes| + + +### Return type: [DataJSON](/API_docs/types/DataJSON.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$DataJSON = $MadelineProto->bots->sendCustomRequest(custom_method: 'string', params: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/bots.setBotBroadcastDefaultAdminRights.md b/docs/API_docs/methods/bots.setBotBroadcastDefaultAdminRights.md new file mode 100644 index 0000000000..73f8386587 --- /dev/null +++ b/docs/API_docs/methods/bots.setBotBroadcastDefaultAdminRights.md @@ -0,0 +1,42 @@ +--- +title: "bots.setBotBroadcastDefaultAdminRights" +description: "Set the default [suggested admin rights](https://core.telegram.org/api/rights#suggested-bot-rights) for bots being added as admins to channels, see [here for more info on how to handle them »](https://core.telegram.org/api/rights#suggested-bot-rights)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_setBotBroadcastDefaultAdminRights.html +--- +# Method: bots.setBotBroadcastDefaultAdminRights +[Back to methods index](index.html) + + + +Set the default [suggested admin rights](https://core.telegram.org/api/rights#suggested-bot-rights) for bots being added as admins to channels, see [here for more info on how to handle them »](https://core.telegram.org/api/rights#suggested-bot-rights). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Admin rights | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->setBotBroadcastDefaultAdminRights(admin_rights: $ChatAdminRights, ); +``` + diff --git a/docs/API_docs/methods/bots.setBotCommands.md b/docs/API_docs/methods/bots.setBotCommands.md new file mode 100644 index 0000000000..00b29f39de --- /dev/null +++ b/docs/API_docs/methods/bots.setBotCommands.md @@ -0,0 +1,44 @@ +--- +title: "bots.setBotCommands" +description: "Set bot command list" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_setBotCommands.html +--- +# Method: bots.setBotCommands +[Back to methods index](index.html) + + + +Set bot command list + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|scope|[BotCommandScope](/API_docs/types/BotCommandScope.html) | Command scope | Yes| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| +|commands|Array of [BotCommand](/API_docs/types/BotCommand.html) | Bot commands | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->setBotCommands(scope: $BotCommandScope, lang_code: 'string', commands: [$BotCommand, $BotCommand], ); +``` + diff --git a/docs/API_docs/methods/bots.setBotGroupDefaultAdminRights.md b/docs/API_docs/methods/bots.setBotGroupDefaultAdminRights.md new file mode 100644 index 0000000000..9e2b73ccde --- /dev/null +++ b/docs/API_docs/methods/bots.setBotGroupDefaultAdminRights.md @@ -0,0 +1,42 @@ +--- +title: "bots.setBotGroupDefaultAdminRights" +description: "Set the default [suggested admin rights](https://core.telegram.org/api/rights#suggested-bot-rights) for bots being added as admins to groups, see [here for more info on how to handle them »](https://core.telegram.org/api/rights#suggested-bot-rights)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_setBotGroupDefaultAdminRights.html +--- +# Method: bots.setBotGroupDefaultAdminRights +[Back to methods index](index.html) + + + +Set the default [suggested admin rights](https://core.telegram.org/api/rights#suggested-bot-rights) for bots being added as admins to groups, see [here for more info on how to handle them »](https://core.telegram.org/api/rights#suggested-bot-rights). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | Admin rights | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->setBotGroupDefaultAdminRights(admin_rights: $ChatAdminRights, ); +``` + diff --git a/docs/API_docs/methods/bots.setBotInfo.md b/docs/API_docs/methods/bots.setBotInfo.md new file mode 100644 index 0000000000..74df18977e --- /dev/null +++ b/docs/API_docs/methods/bots.setBotInfo.md @@ -0,0 +1,46 @@ +--- +title: "bots.setBotInfo" +description: "Set localized name, about text and description of a bot (or of the current account, if called by a bot)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_setBotInfo.html +--- +# Method: bots.setBotInfo +[Back to methods index](index.html) + + + +Set localized name, about text and description of a bot (or of the current account, if called by a bot). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | If called by a user, **must** contain the peer of a bot we own. | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Language code, if left empty update the fallback about text and description | Optional| +|name|[string](/API_docs/types/string.html) | New bot name | Optional| +|about|[string](/API_docs/types/string.html) | New about text | Optional| +|description|[string](/API_docs/types/string.html) | New description | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->setBotInfo(bot: $InputUser, lang_code: 'string', name: 'string', about: 'string', description: 'string', ); +``` + diff --git a/docs/API_docs/methods/bots.setBotMenuButton.md b/docs/API_docs/methods/bots.setBotMenuButton.md new file mode 100644 index 0000000000..365c617cf8 --- /dev/null +++ b/docs/API_docs/methods/bots.setBotMenuButton.md @@ -0,0 +1,43 @@ +--- +title: "bots.setBotMenuButton" +description: "Sets the [menu button action »](https://core.telegram.org/api/bots/menu) for a given user or for all users" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_setBotMenuButton.html +--- +# Method: bots.setBotMenuButton +[Back to methods index](index.html) + + + +Sets the [menu button action »](https://core.telegram.org/api/bots/menu) for a given user or for all users + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID | Optional| +|button|[BotMenuButton](/API_docs/types/BotMenuButton.html) | Bot menu button action | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->setBotMenuButton(user_id: $InputUser, button: $BotMenuButton, ); +``` + diff --git a/docs/API_docs/methods/bots.toggleUsername.md b/docs/API_docs/methods/bots.toggleUsername.md new file mode 100644 index 0000000000..a8d841b2d9 --- /dev/null +++ b/docs/API_docs/methods/bots.toggleUsername.md @@ -0,0 +1,44 @@ +--- +title: "bots.toggleUsername" +description: "Activate or deactivate a purchased [fragment.com](https://fragment.com) username associated to a bot we own." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/bots_toggleUsername.html +--- +# Method: bots.toggleUsername +[Back to methods index](index.html) + + + +Activate or deactivate a purchased [fragment.com](https://fragment.com) username associated to a bot we own. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The bot | Optional| +|username|[string](/API_docs/types/string.html) | Username | Optional| +|active|[Bool](/API_docs/types/Bool.html) | Whether to activate or deactivate it | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->bots->toggleUsername(bot: $InputUser, username: 'string', active: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.checkUsername.md b/docs/API_docs/methods/channels.checkUsername.md new file mode 100644 index 0000000000..44f3041ce4 --- /dev/null +++ b/docs/API_docs/methods/channels.checkUsername.md @@ -0,0 +1,43 @@ +--- +title: "channels.checkUsername" +description: "Check if a username is free and can be assigned to a channel/supergroup" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_checkUsername.html +--- +# Method: channels.checkUsername +[Back to methods index](index.html) + + + +Check if a username is free and can be assigned to a channel/supergroup + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The [channel/supergroup](https://core.telegram.org/api/channel) that will assigned the specified username | Optional| +|username|[string](/API_docs/types/string.html) | The username to check | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->checkUsername(channel: $InputChannel, username: 'string', ); +``` + diff --git a/docs/API_docs/methods/channels.clickSponsoredMessage.md b/docs/API_docs/methods/channels.clickSponsoredMessage.md new file mode 100644 index 0000000000..96943491d5 --- /dev/null +++ b/docs/API_docs/methods/channels.clickSponsoredMessage.md @@ -0,0 +1,46 @@ +--- +title: "channels.clickSponsoredMessage" +description: "Informs the server that the user has either" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_clickSponsoredMessage.html +--- +# Method: channels.clickSponsoredMessage +[Back to methods index](index.html) + + + +Informs the server that the user has either: + +- Clicked on a link in the sponsored message +- Has opened a sponsored chat or a sponsored website via the associated button +- Has opened the sponsored chat via the sponsored message name, the sponsored message photo, or a mention in the sponsored message + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel where the sponsored message was posted | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->clickSponsoredMessage(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.convertToGigagroup.md b/docs/API_docs/methods/channels.convertToGigagroup.md new file mode 100644 index 0000000000..a851a2c30e --- /dev/null +++ b/docs/API_docs/methods/channels.convertToGigagroup.md @@ -0,0 +1,42 @@ +--- +title: "channels.convertToGigagroup" +description: "Convert a [supergroup](https://core.telegram.org/api/channel) to a [gigagroup](https://core.telegram.org/api/channel), when requested by [channel suggestions](https://core.telegram.org/api/config#channel-suggestions)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_convertToGigagroup.html +--- +# Method: channels.convertToGigagroup +[Back to methods index](index.html) + + + +Convert a [supergroup](https://core.telegram.org/api/channel) to a [gigagroup](https://core.telegram.org/api/channel), when requested by [channel suggestions](https://core.telegram.org/api/config#channel-suggestions). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The [supergroup](https://core.telegram.org/api/channel) to convert | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->convertToGigagroup(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.createChannel.md b/docs/API_docs/methods/channels.createChannel.md new file mode 100644 index 0000000000..e34b62984a --- /dev/null +++ b/docs/API_docs/methods/channels.createChannel.md @@ -0,0 +1,50 @@ +--- +title: "channels.createChannel" +description: "Create a [supergroup/channel](https://core.telegram.org/api/channel)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_createChannel.html +--- +# Method: channels.createChannel +[Back to methods index](index.html) + + + +Create a [supergroup/channel](https://core.telegram.org/api/channel). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|broadcast|[Bool](/API_docs/types/Bool.html) | Whether to create a [channel](https://core.telegram.org/api/channel) | Optional| +|megagroup|[Bool](/API_docs/types/Bool.html) | Whether to create a [supergroup](https://core.telegram.org/api/channel) | Optional| +|for\_import|[Bool](/API_docs/types/Bool.html) | Whether the supergroup is being created to import messages from a foreign chat service using [messages.initHistoryImport](../methods/messages.initHistoryImport.html) | Optional| +|forum|[Bool](/API_docs/types/Bool.html) | Whether to create a [forum](https://core.telegram.org/api/forum) | Optional| +|title|[string](/API_docs/types/string.html) | Channel title | Optional| +|about|[string](/API_docs/types/string.html) | Channel description | Optional| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Geogroup location, see [here »](https://core.telegram.org/api/nearby) for more info on geogroups. | Optional| +|address|[string](/API_docs/types/string.html) | Geogroup address, see [here »](https://core.telegram.org/api/nearby) for more info on geogroups. | Optional| +|ttl\_period|[int](/API_docs/types/int.html) | Time-to-live of all messages that will be sent in the supergroup: once message.date+message.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well. You can use [messages.setDefaultHistoryTTL](../methods/messages.setDefaultHistoryTTL.html) to edit this value later. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->createChannel(broadcast: $Bool, megagroup: $Bool, for_import: $Bool, forum: $Bool, title: 'string', about: 'string', geo_point: $InputGeoPoint, address: 'string', ttl_period: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.createForumTopic.md b/docs/API_docs/methods/channels.createForumTopic.md new file mode 100644 index 0000000000..e3bce1c936 --- /dev/null +++ b/docs/API_docs/methods/channels.createForumTopic.md @@ -0,0 +1,46 @@ +--- +title: "channels.createForumTopic" +description: "Create a [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_createForumTopic.html +--- +# Method: channels.createForumTopic +[Back to methods index](index.html) + + + +Create a [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [The forum](https://core.telegram.org/api/forum) | Optional| +|title|[string](/API_docs/types/string.html) | Topic title (maximum UTF-8 length: 128) | Optional| +|icon\_color|[int](/API_docs/types/int.html) | If no custom emoji icon is specified, specifies the color of the fallback topic icon (RGB), one of `0x6FB9F0`, `0xFFD67E`, `0xCB86DB`, `0x8EEE98`, `0xFF93B2`, or `0xFB6F5F`. | Optional| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | ID of the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon. [Telegram Premium](https://core.telegram.org/api/premium) users can use any custom emoji, other users can only use the custom emojis contained in the [inputStickerSetEmojiDefaultTopicIcons](../constructors/inputStickerSetEmojiDefaultTopicIcons.html) emoji pack. | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Create the topic as the specified peer | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->createForumTopic(channel: $InputChannel, title: 'string', icon_color: $int, icon_emoji_id: $long, send_as: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/channels.deactivateAllUsernames.md b/docs/API_docs/methods/channels.deactivateAllUsernames.md new file mode 100644 index 0000000000..962e6ad099 --- /dev/null +++ b/docs/API_docs/methods/channels.deactivateAllUsernames.md @@ -0,0 +1,42 @@ +--- +title: "channels.deactivateAllUsernames" +description: "Disable all purchased usernames of a supergroup or channel" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_deactivateAllUsernames.html +--- +# Method: channels.deactivateAllUsernames +[Back to methods index](index.html) + + + +Disable all purchased usernames of a supergroup or channel + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup or channel | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->deactivateAllUsernames(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.deleteChannel.md b/docs/API_docs/methods/channels.deleteChannel.md new file mode 100644 index 0000000000..4e65c29619 --- /dev/null +++ b/docs/API_docs/methods/channels.deleteChannel.md @@ -0,0 +1,42 @@ +--- +title: "channels.deleteChannel" +description: "Delete a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_deleteChannel.html +--- +# Method: channels.deleteChannel +[Back to methods index](index.html) + + + +Delete a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Channel/supergroup](https://core.telegram.org/api/channel) to delete | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->deleteChannel(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.deleteHistory.md b/docs/API_docs/methods/channels.deleteHistory.md new file mode 100644 index 0000000000..c60a389473 --- /dev/null +++ b/docs/API_docs/methods/channels.deleteHistory.md @@ -0,0 +1,44 @@ +--- +title: "channels.deleteHistory" +description: "Delete the history of a [supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_deleteHistory.html +--- +# Method: channels.deleteHistory +[Back to methods index](index.html) + + + +Delete the history of a [supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|for\_everyone|[Bool](/API_docs/types/Bool.html) | Whether the history should be deleted for everyone | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Supergroup](https://core.telegram.org/api/channel) whose history must be deleted | Optional| +|max\_id|[int](/API_docs/types/int.html) | ID of message **up to which** the history must be deleted | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->deleteHistory(for_everyone: $Bool, channel: $InputChannel, max_id: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.deleteMessages.md b/docs/API_docs/methods/channels.deleteMessages.md new file mode 100644 index 0000000000..747a9e19d5 --- /dev/null +++ b/docs/API_docs/methods/channels.deleteMessages.md @@ -0,0 +1,43 @@ +--- +title: "channels.deleteMessages" +description: "Delete messages in a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_deleteMessages.html +--- +# Method: channels.deleteMessages +[Back to methods index](index.html) + + + +Delete messages in a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Channel/supergroup](https://core.telegram.org/api/channel) | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of messages to delete | Yes| + + +### Return type: [messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedMessages = $MadelineProto->channels->deleteMessages(channel: $InputChannel, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/channels.deleteParticipantHistory.md b/docs/API_docs/methods/channels.deleteParticipantHistory.md new file mode 100644 index 0000000000..f9790ffbc8 --- /dev/null +++ b/docs/API_docs/methods/channels.deleteParticipantHistory.md @@ -0,0 +1,43 @@ +--- +title: "channels.deleteParticipantHistory" +description: "Delete all messages sent by a specific participant of a given supergroup" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_deleteParticipantHistory.html +--- +# Method: channels.deleteParticipantHistory +[Back to methods index](index.html) + + + +Delete all messages sent by a specific participant of a given supergroup + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup | Optional| +|participant|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The participant whose messages should be deleted | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->channels->deleteParticipantHistory(channel: $InputChannel, participant: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/channels.deleteTopicHistory.md b/docs/API_docs/methods/channels.deleteTopicHistory.md new file mode 100644 index 0000000000..525af6c037 --- /dev/null +++ b/docs/API_docs/methods/channels.deleteTopicHistory.md @@ -0,0 +1,43 @@ +--- +title: "channels.deleteTopicHistory" +description: "Delete message history of a [forum topic](https://core.telegram.org/api/forum)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_deleteTopicHistory.html +--- +# Method: channels.deleteTopicHistory +[Back to methods index](index.html) + + + +Delete message history of a [forum topic](https://core.telegram.org/api/forum) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Forum | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | Topic ID | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->channels->deleteTopicHistory(channel: $InputChannel, top_msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.editAdmin.md b/docs/API_docs/methods/channels.editAdmin.md new file mode 100644 index 0000000000..faeb421b74 --- /dev/null +++ b/docs/API_docs/methods/channels.editAdmin.md @@ -0,0 +1,45 @@ +--- +title: "channels.editAdmin" +description: "Modify the admin rights of a user in a [supergroup/channel](https://core.telegram.org/api/channel)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editAdmin.html +--- +# Method: channels.editAdmin +[Back to methods index](index.html) + + + +Modify the admin rights of a user in a [supergroup/channel](https://core.telegram.org/api/channel). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The [supergroup/channel](https://core.telegram.org/api/channel). | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The ID of the user whose admin rights should be modified | Optional| +|admin\_rights|[ChatAdminRights](/API_docs/types/ChatAdminRights.html) | The admin rights | Yes| +|rank|[string](/API_docs/types/string.html) | Indicates the role (rank) of the admin in the group: just an arbitrary string | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->editAdmin(channel: $InputChannel, user_id: $InputUser, admin_rights: $ChatAdminRights, rank: 'string', ); +``` + diff --git a/docs/API_docs/methods/channels.editBanned.md b/docs/API_docs/methods/channels.editBanned.md new file mode 100644 index 0000000000..e4d58c9224 --- /dev/null +++ b/docs/API_docs/methods/channels.editBanned.md @@ -0,0 +1,44 @@ +--- +title: "channels.editBanned" +description: "Ban/unban/kick a user in a [supergroup/channel](https://core.telegram.org/api/channel)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editBanned.html +--- +# Method: channels.editBanned +[Back to methods index](index.html) + + + +Ban/unban/kick a user in a [supergroup/channel](https://core.telegram.org/api/channel). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The [supergroup/channel](https://core.telegram.org/api/channel). | Optional| +|participant|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Participant to ban | Optional| +|banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | The banned rights | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->editBanned(channel: $InputChannel, participant: $InputPeer, banned_rights: $ChatBannedRights, ); +``` + diff --git a/docs/API_docs/methods/channels.editCreator.md b/docs/API_docs/methods/channels.editCreator.md new file mode 100644 index 0000000000..faa1c36923 --- /dev/null +++ b/docs/API_docs/methods/channels.editCreator.md @@ -0,0 +1,44 @@ +--- +title: "channels.editCreator" +description: "Transfer channel ownership" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editCreator.html +--- +# Method: channels.editCreator +[Back to methods index](index.html) + + + +Transfer channel ownership + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | New channel owner | Optional| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | [2FA password](https://core.telegram.org/api/srp) of account | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->editCreator(channel: $InputChannel, user_id: $InputUser, password: $InputCheckPasswordSRP, ); +``` + diff --git a/docs/API_docs/methods/channels.editForumTopic.md b/docs/API_docs/methods/channels.editForumTopic.md new file mode 100644 index 0000000000..1e9ea5c4e4 --- /dev/null +++ b/docs/API_docs/methods/channels.editForumTopic.md @@ -0,0 +1,47 @@ +--- +title: "channels.editForumTopic" +description: "Edit [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editForumTopic.html +--- +# Method: channels.editForumTopic +[Back to methods index](index.html) + + + +Edit [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup | Optional| +|topic\_id|[int](/API_docs/types/int.html) | Topic ID | Optional| +|title|[string](/API_docs/types/string.html) | If present, will update the topic title (maximum UTF-8 length: 128). | Optional| +|icon\_emoji\_id|[long](/API_docs/types/long.html) | If present, updates the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon. [Telegram Premium](https://core.telegram.org/api/premium) users can use any custom emoji, other users can only use the custom emojis contained in the [inputStickerSetEmojiDefaultTopicIcons](../constructors/inputStickerSetEmojiDefaultTopicIcons.html) emoji pack. Pass 0 to switch to the fallback topic icon. | Optional| +|closed|[Bool](/API_docs/types/Bool.html) | If present, will update the open/closed status of the topic. | Optional| +|hidden|[Bool](/API_docs/types/Bool.html) | If present, will hide/unhide the topic (only valid for the "General" topic, `id=1`). | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->editForumTopic(channel: $InputChannel, topic_id: $int, title: 'string', icon_emoji_id: $long, closed: $Bool, hidden: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.editLocation.md b/docs/API_docs/methods/channels.editLocation.md new file mode 100644 index 0000000000..c5614b769f --- /dev/null +++ b/docs/API_docs/methods/channels.editLocation.md @@ -0,0 +1,44 @@ +--- +title: "channels.editLocation" +description: "Edit location of geogroup, see [here »](https://core.telegram.org/api/nearby) for more info on geogroups." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editLocation.html +--- +# Method: channels.editLocation +[Back to methods index](index.html) + + + +Edit location of geogroup, see [here »](https://core.telegram.org/api/nearby) for more info on geogroups. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Geogroup](https://core.telegram.org/api/channel) | Optional| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | New geolocation | Optional| +|address|[string](/API_docs/types/string.html) | Address string | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->editLocation(channel: $InputChannel, geo_point: $InputGeoPoint, address: 'string', ); +``` + diff --git a/docs/API_docs/methods/channels.editPhoto.md b/docs/API_docs/methods/channels.editPhoto.md new file mode 100644 index 0000000000..157615f935 --- /dev/null +++ b/docs/API_docs/methods/channels.editPhoto.md @@ -0,0 +1,43 @@ +--- +title: "channels.editPhoto" +description: "Change the photo of a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editPhoto.html +--- +# Method: channels.editPhoto +[Back to methods index](index.html) + + + +Change the photo of a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup whose photo should be edited | Optional| +|photo|[InputChatPhoto](/API_docs/types/InputChatPhoto.html) | New photo | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->editPhoto(channel: $InputChannel, photo: $InputChatPhoto, ); +``` + diff --git a/docs/API_docs/methods/channels.editTitle.md b/docs/API_docs/methods/channels.editTitle.md new file mode 100644 index 0000000000..7f98dace3a --- /dev/null +++ b/docs/API_docs/methods/channels.editTitle.md @@ -0,0 +1,43 @@ +--- +title: "channels.editTitle" +description: "Edit the name of a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_editTitle.html +--- +# Method: channels.editTitle +[Back to methods index](index.html) + + + +Edit the name of a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup | Optional| +|title|[string](/API_docs/types/string.html) | New name | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->editTitle(channel: $InputChannel, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/channels.exportMessageLink.md b/docs/API_docs/methods/channels.exportMessageLink.md new file mode 100644 index 0000000000..fb0a3480a0 --- /dev/null +++ b/docs/API_docs/methods/channels.exportMessageLink.md @@ -0,0 +1,45 @@ +--- +title: "channels.exportMessageLink" +description: "Get link and embed info of a message in a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_exportMessageLink.html +--- +# Method: channels.exportMessageLink +[Back to methods index](index.html) + + + +Get link and embed info of a message in a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|grouped|[Bool](/API_docs/types/Bool.html) | Whether to include other grouped media (for albums) | Optional| +|thread|[Bool](/API_docs/types/Bool.html) | Whether to also include a thread ID, if available, inside of the link | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|id|[int](/API_docs/types/int.html) | Message ID | Optional| + + +### Return type: [ExportedMessageLink](/API_docs/types/ExportedMessageLink.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ExportedMessageLink = $MadelineProto->channels->exportMessageLink(grouped: $Bool, thread: $Bool, channel: $InputChannel, id: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.getAdminLog.md b/docs/API_docs/methods/channels.getAdminLog.md new file mode 100644 index 0000000000..5f99eab35f --- /dev/null +++ b/docs/API_docs/methods/channels.getAdminLog.md @@ -0,0 +1,48 @@ +--- +title: "channels.getAdminLog" +description: "Get the admin log of a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getAdminLog.html +--- +# Method: channels.getAdminLog +[Back to methods index](index.html) + + + +Get the admin log of a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|q|[string](/API_docs/types/string.html) | Search query, can be empty | Optional| +|events\_filter|[ChannelAdminLogEventsFilter](/API_docs/types/ChannelAdminLogEventsFilter.html) | Event filter | Optional| +|admins|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Only show events from these admins | Optional| +|max\_id|[long](/API_docs/types/long.html) | Maximum ID of message to return (see [pagination](https://core.telegram.org/api/offsets)) | Yes| +|min\_id|[long](/API_docs/types/long.html) | Minimum ID of message to return (see [pagination](https://core.telegram.org/api/offsets)) | Yes| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [channels.AdminLogResults](/API_docs/types/channels.AdminLogResults.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$channels_AdminLogResults = $MadelineProto->channels->getAdminLog(channel: $InputChannel, q: 'string', events_filter: $ChannelAdminLogEventsFilter, admins: [$InputUser, $InputUser], max_id: $long, min_id: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.getAdminedPublicChannels.md b/docs/API_docs/methods/channels.getAdminedPublicChannels.md new file mode 100644 index 0000000000..e240a9bd01 --- /dev/null +++ b/docs/API_docs/methods/channels.getAdminedPublicChannels.md @@ -0,0 +1,44 @@ +--- +title: "channels.getAdminedPublicChannels" +description: "Get [channels/supergroups/geogroups](https://core.telegram.org/api/channel) we're admin in. Usually called when the user exceeds the [limit](../constructors/config.html) for owned public [channels/supergroups/geogroups](https://core.telegram.org/api/channel), and the user is given the choice to remove one of his channels/supergroups/geogroups." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getAdminedPublicChannels.html +--- +# Method: channels.getAdminedPublicChannels +[Back to methods index](index.html) + + + +Get [channels/supergroups/geogroups](https://core.telegram.org/api/channel) we're admin in. Usually called when the user exceeds the [limit](../constructors/config.html) for owned public [channels/supergroups/geogroups](https://core.telegram.org/api/channel), and the user is given the choice to remove one of his channels/supergroups/geogroups. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|by\_location|[Bool](/API_docs/types/Bool.html) | Get geogroups | Optional| +|check\_limit|[Bool](/API_docs/types/Bool.html) | If set and the user has reached the limit of owned public [channels/supergroups/geogroups](https://core.telegram.org/api/channel), instead of returning the channel list one of the specified [errors](#possible-errors) will be returned.
Useful to check if a new public channel can indeed be created, even before asking the user to enter a channel username to use in [channels.checkUsername](../methods/channels.checkUsername.html)/[channels.updateUsername](../methods/channels.updateUsername.html). | Optional| +|for\_personal|[Bool](/API_docs/types/Bool.html) | | Optional| + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->channels->getAdminedPublicChannels(by_location: $Bool, check_limit: $Bool, for_personal: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.getChannelRecommendations.md b/docs/API_docs/methods/channels.getChannelRecommendations.md new file mode 100644 index 0000000000..fb2750c0c8 --- /dev/null +++ b/docs/API_docs/methods/channels.getChannelRecommendations.md @@ -0,0 +1,42 @@ +--- +title: "channels.getChannelRecommendations" +description: "Obtain a list of similarly themed public channels, selected based on similarities in their **subscriber bases**." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getChannelRecommendations.html +--- +# Method: channels.getChannelRecommendations +[Back to methods index](index.html) + + + +Obtain a list of similarly themed public channels, selected based on similarities in their **subscriber bases**. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The method will return channels related to the passed `channel`. | Optional| + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->channels->getChannelRecommendations(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.getChannels.md b/docs/API_docs/methods/channels.getChannels.md new file mode 100644 index 0000000000..2853ecd54f --- /dev/null +++ b/docs/API_docs/methods/channels.getChannels.md @@ -0,0 +1,42 @@ +--- +title: "channels.getChannels" +description: "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getChannels.html +--- +# Method: channels.getChannels +[Back to methods index](index.html) + + + +You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | IDs of channels/supergroups to get info about | Yes| + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->channels->getChannels(id: [$InputChannel, $InputChannel], ); +``` + diff --git a/docs/API_docs/methods/channels.getForumTopics.md b/docs/API_docs/methods/channels.getForumTopics.md new file mode 100644 index 0000000000..5b8d03ce9c --- /dev/null +++ b/docs/API_docs/methods/channels.getForumTopics.md @@ -0,0 +1,47 @@ +--- +title: "channels.getForumTopics" +description: "Get [topics of a forum](https://core.telegram.org/api/forum)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getForumTopics.html +--- +# Method: channels.getForumTopics +[Back to methods index](index.html) + + + +Get [topics of a forum](https://core.telegram.org/api/forum) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup | Optional| +|q|[string](/API_docs/types/string.html) | Search query | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets), date of the last message of the last found topic. Use 0 or any date in the future to get results from the last topic. | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets), ID of the last message of the last found topic (or initially `0`). | Optional| +|offset\_topic|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets), ID of the last found topic (or initially `0`). | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets). For optimal performance, the number of returned topics is chosen by the server and can be smaller than the specified limit. | Optional| + + +### Return type: [messages.ForumTopics](/API_docs/types/messages.ForumTopics.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ForumTopics = $MadelineProto->channels->getForumTopics(channel: $InputChannel, q: 'string', offset_date: $int, offset_id: $int, offset_topic: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.getForumTopicsByID.md b/docs/API_docs/methods/channels.getForumTopicsByID.md new file mode 100644 index 0000000000..d64bf11142 --- /dev/null +++ b/docs/API_docs/methods/channels.getForumTopicsByID.md @@ -0,0 +1,43 @@ +--- +title: "channels.getForumTopicsByID" +description: "Get forum topics by their ID" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getForumTopicsByID.html +--- +# Method: channels.getForumTopicsByID +[Back to methods index](index.html) + + + +Get forum topics by their ID + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Forum | Optional| +|topics|Array of [int](/API_docs/types/int.html) | Topic IDs | Yes| + + +### Return type: [messages.ForumTopics](/API_docs/types/messages.ForumTopics.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ForumTopics = $MadelineProto->channels->getForumTopicsByID(channel: $InputChannel, topics: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/channels.getFullChannel.md b/docs/API_docs/methods/channels.getFullChannel.md new file mode 100644 index 0000000000..3188653df8 --- /dev/null +++ b/docs/API_docs/methods/channels.getFullChannel.md @@ -0,0 +1,42 @@ +--- +title: "channels.getFullChannel" +description: "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getFullChannel.html +--- +# Method: channels.getFullChannel +[Back to methods index](index.html) + + + +You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The [channel](https://core.telegram.org/api/channel#channels), [supergroup](https://core.telegram.org/api/channel#supergroups) or [gigagroup](https://core.telegram.org/api/channel#gigagroups) to get info about | Optional| + + +### Return type: [messages.ChatFull](/API_docs/types/messages.ChatFull.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ChatFull = $MadelineProto->channels->getFullChannel(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.getGroupsForDiscussion.md b/docs/API_docs/methods/channels.getGroupsForDiscussion.md new file mode 100644 index 0000000000..d969531535 --- /dev/null +++ b/docs/API_docs/methods/channels.getGroupsForDiscussion.md @@ -0,0 +1,40 @@ +--- +title: "channels.getGroupsForDiscussion" +description: "Get all groups that can be used as [discussion groups](https://core.telegram.org/api/discussion)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getGroupsForDiscussion.html +--- +# Method: channels.getGroupsForDiscussion +[Back to methods index](index.html) + + + +Get all groups that can be used as [discussion groups](https://core.telegram.org/api/discussion). + +Returned [basic group chats](https://core.telegram.org/api/channel#basic-groups) must be first upgraded to [supergroups](https://core.telegram.org/api/channel#supergroups) before they can be set as a discussion group. +To set a returned supergroup as a discussion group, access to its old messages must be enabled using [channels.togglePreHistoryHidden](../methods/channels.togglePreHistoryHidden.html), first. + + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->channels->getGroupsForDiscussion(); +``` + diff --git a/docs/API_docs/methods/channels.getInactiveChannels.md b/docs/API_docs/methods/channels.getInactiveChannels.md new file mode 100644 index 0000000000..299ff3d82e --- /dev/null +++ b/docs/API_docs/methods/channels.getInactiveChannels.md @@ -0,0 +1,37 @@ +--- +title: "channels.getInactiveChannels" +description: "Get inactive channels and supergroups" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getInactiveChannels.html +--- +# Method: channels.getInactiveChannels +[Back to methods index](index.html) + + + +Get inactive channels and supergroups + + + +### Return type: [messages.InactiveChats](/API_docs/types/messages.InactiveChats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_InactiveChats = $MadelineProto->channels->getInactiveChannels(); +``` + diff --git a/docs/API_docs/methods/channels.getLeftChannels.md b/docs/API_docs/methods/channels.getLeftChannels.md new file mode 100644 index 0000000000..6ff5a59878 --- /dev/null +++ b/docs/API_docs/methods/channels.getLeftChannels.md @@ -0,0 +1,42 @@ +--- +title: "channels.getLeftChannels" +description: "Get a list of [channels/supergroups](https://core.telegram.org/api/channel) we left, requires a [takeout session, see here » for more info](https://core.telegram.org/api/takeout)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getLeftChannels.html +--- +# Method: channels.getLeftChannels +[Back to methods index](index.html) + + + +Get a list of [channels/supergroups](https://core.telegram.org/api/channel) we left, requires a [takeout session, see here » for more info](https://core.telegram.org/api/takeout). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|offset|[int](/API_docs/types/int.html) | Offset for [pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->channels->getLeftChannels(offset: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.getMessages.md b/docs/API_docs/methods/channels.getMessages.md new file mode 100644 index 0000000000..83a34fd3d5 --- /dev/null +++ b/docs/API_docs/methods/channels.getMessages.md @@ -0,0 +1,52 @@ +--- +title: "channels.getMessages" +description: "Get [channel/supergroup](https://core.telegram.org/api/channel) messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getMessages.html +--- +# Method: channels.getMessages +[Back to methods index](index.html) + + + +# Warning: flood wait +**Warning: this method is prone to rate limiting with flood waits, **which can lead to !!! ACCOUNT BANS !!!**, please use the [updates event handler, instead (which is 100% safe) »](/docs/UPDATES.html#async-event-driven)** + +# Warning: non-realtime results +**Warning: this method is not suitable for receiving messages in real-time from chats and users, please use the [updates event handler, instead »](/docs/UPDATES.html#async-event-driven)** + +# Warning: this is probably NOT what you need +You probably need to use the [updates event handler, instead »](/docs/UPDATES.html#async-event-driven) :) + +Get [channel/supergroup](https://core.telegram.org/api/channel) messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup | Optional| +|id|Array of [Message ID or InputMessage](/API_docs/types/InputMessage.html) | IDs of messages to get | Yes| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->channels->getMessages(channel: $InputChannel, id: [$InputMessage, $InputMessage], ); +``` + diff --git a/docs/API_docs/methods/channels.getParticipant.md b/docs/API_docs/methods/channels.getParticipant.md new file mode 100644 index 0000000000..ab26ee63fd --- /dev/null +++ b/docs/API_docs/methods/channels.getParticipant.md @@ -0,0 +1,43 @@ +--- +title: "channels.getParticipant" +description: "Get info about a [channel/supergroup](https://core.telegram.org/api/channel) participant" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getParticipant.html +--- +# Method: channels.getParticipant +[Back to methods index](index.html) + + + +Get info about a [channel/supergroup](https://core.telegram.org/api/channel) participant + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup | Optional| +|participant|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Participant to get info about | Optional| + + +### Return type: [channels.ChannelParticipant](/API_docs/types/channels.ChannelParticipant.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$channels_ChannelParticipant = $MadelineProto->channels->getParticipant(channel: $InputChannel, participant: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/channels.getParticipants.md b/docs/API_docs/methods/channels.getParticipants.md new file mode 100644 index 0000000000..10cdf053ed --- /dev/null +++ b/docs/API_docs/methods/channels.getParticipants.md @@ -0,0 +1,46 @@ +--- +title: "channels.getParticipants" +description: "Get the participants of a [supergroup/channel](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getParticipants.html +--- +# Method: channels.getParticipants +[Back to methods index](index.html) + + + +Get the participants of a [supergroup/channel](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|filter|[ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) | Which participant types to fetch | Yes| +|offset|[int](/API_docs/types/int.html) | [Offset](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | [Limit](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [channels.ChannelParticipants](/API_docs/types/channels.ChannelParticipants.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$channels_ChannelParticipants = $MadelineProto->channels->getParticipants(channel: $InputChannel, filter: $ChannelParticipantsFilter, offset: $int, limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/channels.getSendAs.md b/docs/API_docs/methods/channels.getSendAs.md new file mode 100644 index 0000000000..6bd65088b7 --- /dev/null +++ b/docs/API_docs/methods/channels.getSendAs.md @@ -0,0 +1,42 @@ +--- +title: "channels.getSendAs" +description: "Obtains a list of peers that can be used to send messages in a specific group" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getSendAs.html +--- +# Method: channels.getSendAs +[Back to methods index](index.html) + + + +Obtains a list of peers that can be used to send messages in a specific group + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The group where we intend to send messages | Optional| + + +### Return type: [channels.SendAsPeers](/API_docs/types/channels.SendAsPeers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$channels_SendAsPeers = $MadelineProto->channels->getSendAs(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/channels.getSponsoredMessages.md b/docs/API_docs/methods/channels.getSponsoredMessages.md new file mode 100644 index 0000000000..2343039f98 --- /dev/null +++ b/docs/API_docs/methods/channels.getSponsoredMessages.md @@ -0,0 +1,42 @@ +--- +title: "channels.getSponsoredMessages" +description: "Get a list of sponsored messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_getSponsoredMessages.html +--- +# Method: channels.getSponsoredMessages +[Back to methods index](index.html) + + + +Get a list of sponsored messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Peer | Optional| + + +### Return type: [messages.SponsoredMessages](/API_docs/types/messages.SponsoredMessages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SponsoredMessages = $MadelineProto->channels->getSponsoredMessages(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.inviteToChannel.md b/docs/API_docs/methods/channels.inviteToChannel.md new file mode 100644 index 0000000000..59b67d66b8 --- /dev/null +++ b/docs/API_docs/methods/channels.inviteToChannel.md @@ -0,0 +1,45 @@ +--- +title: "channels.inviteToChannel" +description: "Invite users to a channel/supergroup" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_inviteToChannel.html +--- +# Method: channels.inviteToChannel +[Back to methods index](index.html) + + + +Invite users to a channel/supergroup + +May also return 0-N updates of type [updateGroupInvitePrivacyForbidden](../constructors/updateGroupInvitePrivacyForbidden.html): it indicates we couldn't add a user to a chat because of their privacy settings; if required, an [invite link](https://core.telegram.org/api/invites) can be shared with the user, instead. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup | Optional| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Users to invite | Yes| + + +### Return type: [messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_InvitedUsers = $MadelineProto->channels->inviteToChannel(channel: $InputChannel, users: [$InputUser, $InputUser], ); +``` + diff --git a/docs/API_docs/methods/channels.joinChannel.md b/docs/API_docs/methods/channels.joinChannel.md new file mode 100644 index 0000000000..bd7065157f --- /dev/null +++ b/docs/API_docs/methods/channels.joinChannel.md @@ -0,0 +1,42 @@ +--- +title: "channels.joinChannel" +description: "Join a channel/supergroup" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_joinChannel.html +--- +# Method: channels.joinChannel +[Back to methods index](index.html) + + + +Join a channel/supergroup + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup to join | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->joinChannel(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.leaveChannel.md b/docs/API_docs/methods/channels.leaveChannel.md new file mode 100644 index 0000000000..92a1a4f555 --- /dev/null +++ b/docs/API_docs/methods/channels.leaveChannel.md @@ -0,0 +1,42 @@ +--- +title: "channels.leaveChannel" +description: "Leave a [channel/supergroup](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_leaveChannel.html +--- +# Method: channels.leaveChannel +[Back to methods index](index.html) + + + +Leave a [channel/supergroup](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Channel/supergroup](https://core.telegram.org/api/channel) to leave | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->leaveChannel(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.readHistory.md b/docs/API_docs/methods/channels.readHistory.md new file mode 100644 index 0000000000..c09fabca3b --- /dev/null +++ b/docs/API_docs/methods/channels.readHistory.md @@ -0,0 +1,43 @@ +--- +title: "channels.readHistory" +description: "Mark [channel/supergroup](https://core.telegram.org/api/channel) history as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_readHistory.html +--- +# Method: channels.readHistory +[Back to methods index](index.html) + + + +Mark [channel/supergroup](https://core.telegram.org/api/channel) history as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Channel/supergroup](https://core.telegram.org/api/channel) | Optional| +|max\_id|[int](/API_docs/types/int.html) | ID of message up to which messages should be marked as read | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->readHistory(channel: $InputChannel, max_id: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.readMessageContents.md b/docs/API_docs/methods/channels.readMessageContents.md new file mode 100644 index 0000000000..85eb4b308e --- /dev/null +++ b/docs/API_docs/methods/channels.readMessageContents.md @@ -0,0 +1,43 @@ +--- +title: "channels.readMessageContents" +description: "Mark [channel/supergroup](https://core.telegram.org/api/channel) message contents as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_readMessageContents.html +--- +# Method: channels.readMessageContents +[Back to methods index](index.html) + + + +Mark [channel/supergroup](https://core.telegram.org/api/channel) message contents as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Channel/supergroup](https://core.telegram.org/api/channel) | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of messages whose contents should be marked as read | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->readMessageContents(channel: $InputChannel, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/channels.reorderPinnedForumTopics.md b/docs/API_docs/methods/channels.reorderPinnedForumTopics.md new file mode 100644 index 0000000000..89055ce274 --- /dev/null +++ b/docs/API_docs/methods/channels.reorderPinnedForumTopics.md @@ -0,0 +1,44 @@ +--- +title: "channels.reorderPinnedForumTopics" +description: "Reorder pinned forum topics" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_reorderPinnedForumTopics.html +--- +# Method: channels.reorderPinnedForumTopics +[Back to methods index](index.html) + + + +Reorder pinned forum topics + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|force|[Bool](/API_docs/types/Bool.html) | If not set, the order of only the topics present both server-side and in `order` will be changed (i.e. mentioning topics not pinned server-side in `order` will not pin them, and not mentioning topics pinned server-side will not unpin them).
If set, the entire server-side pinned topic list will be replaced with `order` (i.e. mentioning topics not pinned server-side in `order` will pin them, and not mentioning topics pinned server-side will unpin them) | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup ID | Optional| +|order|Array of [int](/API_docs/types/int.html) | [Topic IDs »](https://core.telegram.org/api/forum) | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->reorderPinnedForumTopics(force: $Bool, channel: $InputChannel, order: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/channels.reorderUsernames.md b/docs/API_docs/methods/channels.reorderUsernames.md new file mode 100644 index 0000000000..4b4035c478 --- /dev/null +++ b/docs/API_docs/methods/channels.reorderUsernames.md @@ -0,0 +1,43 @@ +--- +title: "channels.reorderUsernames" +description: "Reorder active usernames" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_reorderUsernames.html +--- +# Method: channels.reorderUsernames +[Back to methods index](index.html) + + + +Reorder active usernames + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The supergroup or channel | Optional| +|order|Array of [string](/API_docs/types/string.html) | The new order for active usernames. All active usernames must be specified. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->reorderUsernames(channel: $InputChannel, order: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/channels.reportAntiSpamFalsePositive.md b/docs/API_docs/methods/channels.reportAntiSpamFalsePositive.md new file mode 100644 index 0000000000..4d93d72493 --- /dev/null +++ b/docs/API_docs/methods/channels.reportAntiSpamFalsePositive.md @@ -0,0 +1,43 @@ +--- +title: "channels.reportAntiSpamFalsePositive" +description: "Report a [native antispam](https://core.telegram.org/api/antispam) false positive" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_reportAntiSpamFalsePositive.html +--- +# Method: channels.reportAntiSpamFalsePositive +[Back to methods index](index.html) + + + +Report a [native antispam](https://core.telegram.org/api/antispam) false positive + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup ID | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID that was mistakenly deleted by the [native antispam](https://core.telegram.org/api/antispam) system, taken from the [admin log](https://core.telegram.org/api/recent-actions) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->reportAntiSpamFalsePositive(channel: $InputChannel, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.reportSpam.md b/docs/API_docs/methods/channels.reportSpam.md new file mode 100644 index 0000000000..71fde67b26 --- /dev/null +++ b/docs/API_docs/methods/channels.reportSpam.md @@ -0,0 +1,44 @@ +--- +title: "channels.reportSpam" +description: "Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_reportSpam.html +--- +# Method: channels.reportSpam +[Back to methods index](index.html) + + + +Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup | Optional| +|participant|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Participant whose messages should be reported | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of spam messages | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->reportSpam(channel: $InputChannel, participant: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/channels.reportSponsoredMessage.md b/docs/API_docs/methods/channels.reportSponsoredMessage.md new file mode 100644 index 0000000000..14fe30f211 --- /dev/null +++ b/docs/API_docs/methods/channels.reportSponsoredMessage.md @@ -0,0 +1,41 @@ +--- +title: "channels.reportSponsoredMessage" +description: "channels.reportSponsoredMessage parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_reportSponsoredMessage.html +--- +# Method: channels.reportSponsoredMessage +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| +|option|[bytes](/API_docs/types/bytes.html) | Yes| + + +### Return type: [channels.SponsoredMessageReportResult](/API_docs/types/channels.SponsoredMessageReportResult.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$channels_SponsoredMessageReportResult = $MadelineProto->channels->reportSponsoredMessage(channel: $InputChannel, option: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/channels.restrictSponsoredMessages.md b/docs/API_docs/methods/channels.restrictSponsoredMessages.md new file mode 100644 index 0000000000..47929b1f63 --- /dev/null +++ b/docs/API_docs/methods/channels.restrictSponsoredMessages.md @@ -0,0 +1,41 @@ +--- +title: "channels.restrictSponsoredMessages" +description: "channels.restrictSponsoredMessages parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_restrictSponsoredMessages.html +--- +# Method: channels.restrictSponsoredMessages +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| +|restricted|[Bool](/API_docs/types/Bool.html) | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->restrictSponsoredMessages(channel: $InputChannel, restricted: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.setBoostsToUnblockRestrictions.md b/docs/API_docs/methods/channels.setBoostsToUnblockRestrictions.md new file mode 100644 index 0000000000..1eaa5c9aed --- /dev/null +++ b/docs/API_docs/methods/channels.setBoostsToUnblockRestrictions.md @@ -0,0 +1,41 @@ +--- +title: "channels.setBoostsToUnblockRestrictions" +description: "channels.setBoostsToUnblockRestrictions parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_setBoostsToUnblockRestrictions.html +--- +# Method: channels.setBoostsToUnblockRestrictions +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| +|boosts|[int](/API_docs/types/int.html) | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->setBoostsToUnblockRestrictions(channel: $InputChannel, boosts: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.setDiscussionGroup.md b/docs/API_docs/methods/channels.setDiscussionGroup.md new file mode 100644 index 0000000000..5ba403d1be --- /dev/null +++ b/docs/API_docs/methods/channels.setDiscussionGroup.md @@ -0,0 +1,43 @@ +--- +title: "channels.setDiscussionGroup" +description: "Associate a group to a channel as [discussion group](https://core.telegram.org/api/discussion) for that channel" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_setDiscussionGroup.html +--- +# Method: channels.setDiscussionGroup +[Back to methods index](index.html) + + + +Associate a group to a channel as [discussion group](https://core.telegram.org/api/discussion) for that channel + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|broadcast|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|group|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Discussion group](https://core.telegram.org/api/discussion) to associate to the channel | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->setDiscussionGroup(broadcast: $InputChannel, group: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/channels.setEmojiStickers.md b/docs/API_docs/methods/channels.setEmojiStickers.md new file mode 100644 index 0000000000..886fd48db1 --- /dev/null +++ b/docs/API_docs/methods/channels.setEmojiStickers.md @@ -0,0 +1,41 @@ +--- +title: "channels.setEmojiStickers" +description: "channels.setEmojiStickers parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_setEmojiStickers.html +--- +# Method: channels.setEmojiStickers +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->setEmojiStickers(channel: $InputChannel, stickerset: $InputStickerSet, ); +``` + diff --git a/docs/API_docs/methods/channels.setStickers.md b/docs/API_docs/methods/channels.setStickers.md new file mode 100644 index 0000000000..7506786090 --- /dev/null +++ b/docs/API_docs/methods/channels.setStickers.md @@ -0,0 +1,43 @@ +--- +title: "channels.setStickers" +description: "Associate a stickerset to the supergroup" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_setStickers.html +--- +# Method: channels.setStickers +[Back to methods index](index.html) + + + +Associate a stickerset to the supergroup + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup | Optional| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | The stickerset to associate | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->setStickers(channel: $InputChannel, stickerset: $InputStickerSet, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleAntiSpam.md b/docs/API_docs/methods/channels.toggleAntiSpam.md new file mode 100644 index 0000000000..da913a0da1 --- /dev/null +++ b/docs/API_docs/methods/channels.toggleAntiSpam.md @@ -0,0 +1,43 @@ +--- +title: "channels.toggleAntiSpam" +description: "Enable or disable the [native antispam system](https://core.telegram.org/api/antispam)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleAntiSpam.html +--- +# Method: channels.toggleAntiSpam +[Back to methods index](index.html) + + + +Enable or disable the [native antispam system](https://core.telegram.org/api/antispam). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup ID. The specified supergroup must have at least `telegram_antispam_group_size_min` members to enable antispam functionality, as specified by the [client configuration parameters](https://core.telegram.org/api/config#client-configuration). | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Enable or disable the native antispam system. | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleAntiSpam(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleForum.md b/docs/API_docs/methods/channels.toggleForum.md new file mode 100644 index 0000000000..7ab423298c --- /dev/null +++ b/docs/API_docs/methods/channels.toggleForum.md @@ -0,0 +1,43 @@ +--- +title: "channels.toggleForum" +description: "Enable or disable [forum functionality](https://core.telegram.org/api/forum) in a supergroup." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleForum.html +--- +# Method: channels.toggleForum +[Back to methods index](index.html) + + + +Enable or disable [forum functionality](https://core.telegram.org/api/forum) in a supergroup. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup ID | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Enable or disable forum functionality | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleForum(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleJoinRequest.md b/docs/API_docs/methods/channels.toggleJoinRequest.md new file mode 100644 index 0000000000..d40bf8104a --- /dev/null +++ b/docs/API_docs/methods/channels.toggleJoinRequest.md @@ -0,0 +1,43 @@ +--- +title: "channels.toggleJoinRequest" +description: "Set whether all users should [request admin approval to join the group »](https://core.telegram.org/api/invites#join-requests)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleJoinRequest.html +--- +# Method: channels.toggleJoinRequest +[Back to methods index](index.html) + + + +Set whether all users should [request admin approval to join the group »](https://core.telegram.org/api/invites#join-requests). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Group | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Toggle | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleJoinRequest(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleJoinToSend.md b/docs/API_docs/methods/channels.toggleJoinToSend.md new file mode 100644 index 0000000000..32f9b02faf --- /dev/null +++ b/docs/API_docs/methods/channels.toggleJoinToSend.md @@ -0,0 +1,43 @@ +--- +title: "channels.toggleJoinToSend" +description: "Set whether all users [should join a discussion group in order to comment on a post »](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleJoinToSend.html +--- +# Method: channels.toggleJoinToSend +[Back to methods index](index.html) + + + +Set whether all users [should join a discussion group in order to comment on a post »](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Discussion group | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Toggle | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleJoinToSend(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleParticipantsHidden.md b/docs/API_docs/methods/channels.toggleParticipantsHidden.md new file mode 100644 index 0000000000..f2792a8764 --- /dev/null +++ b/docs/API_docs/methods/channels.toggleParticipantsHidden.md @@ -0,0 +1,45 @@ +--- +title: "channels.toggleParticipantsHidden" +description: "Hide or display the participants list in a [supergroup](https://core.telegram.org/api/channel)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleParticipantsHidden.html +--- +# Method: channels.toggleParticipantsHidden +[Back to methods index](index.html) + + + +Hide or display the participants list in a [supergroup](https://core.telegram.org/api/channel). + +The supergroup must have at least `hidden_members_group_size_min` participants in order to use this method, as specified by the [client configuration parameters »](https://core.telegram.org/api/config#client-configuration). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup ID | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | If true, will hide the participants list; otherwise will unhide it. | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleParticipantsHidden(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.togglePreHistoryHidden.md b/docs/API_docs/methods/channels.togglePreHistoryHidden.md new file mode 100644 index 0000000000..649b5c1540 --- /dev/null +++ b/docs/API_docs/methods/channels.togglePreHistoryHidden.md @@ -0,0 +1,43 @@ +--- +title: "channels.togglePreHistoryHidden" +description: "Hide/unhide message history for new channel/supergroup users" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_togglePreHistoryHidden.html +--- +# Method: channels.togglePreHistoryHidden +[Back to methods index](index.html) + + + +Hide/unhide message history for new channel/supergroup users + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel/supergroup | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Hide/unhide | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->togglePreHistoryHidden(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleSignatures.md b/docs/API_docs/methods/channels.toggleSignatures.md new file mode 100644 index 0000000000..532e76150a --- /dev/null +++ b/docs/API_docs/methods/channels.toggleSignatures.md @@ -0,0 +1,43 @@ +--- +title: "channels.toggleSignatures" +description: "Enable/disable message signatures in channels" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleSignatures.html +--- +# Method: channels.toggleSignatures +[Back to methods index](index.html) + + + +Enable/disable message signatures in channels + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Value | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleSignatures(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleSlowMode.md b/docs/API_docs/methods/channels.toggleSlowMode.md new file mode 100644 index 0000000000..96908a04f3 --- /dev/null +++ b/docs/API_docs/methods/channels.toggleSlowMode.md @@ -0,0 +1,43 @@ +--- +title: "channels.toggleSlowMode" +description: "Toggle supergroup slow mode: if enabled, users will only be able to send one message every `seconds` seconds" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleSlowMode.html +--- +# Method: channels.toggleSlowMode +[Back to methods index](index.html) + + + +Toggle supergroup slow mode: if enabled, users will only be able to send one message every `seconds` seconds + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The [supergroup](https://core.telegram.org/api/channel) | Optional| +|seconds|[int](/API_docs/types/int.html) | Users will only be able to send one message every `seconds` seconds, `0` to disable the limitation | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleSlowMode(channel: $InputChannel, seconds: $int, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleUsername.md b/docs/API_docs/methods/channels.toggleUsername.md new file mode 100644 index 0000000000..55acebf3b5 --- /dev/null +++ b/docs/API_docs/methods/channels.toggleUsername.md @@ -0,0 +1,44 @@ +--- +title: "channels.toggleUsername" +description: "Activate or deactivate a purchased [fragment.com](https://fragment.com) username associated to a [supergroup or channel](https://core.telegram.org/api/channel) we own." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleUsername.html +--- +# Method: channels.toggleUsername +[Back to methods index](index.html) + + + +Activate or deactivate a purchased [fragment.com](https://fragment.com) username associated to a [supergroup or channel](https://core.telegram.org/api/channel) we own. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Supergroup or channel](https://core.telegram.org/api/channel) | Optional| +|username|[string](/API_docs/types/string.html) | Username | Optional| +|active|[Bool](/API_docs/types/Bool.html) | Whether to activate or deactivate the username | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->toggleUsername(channel: $InputChannel, username: 'string', active: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.toggleViewForumAsMessages.md b/docs/API_docs/methods/channels.toggleViewForumAsMessages.md new file mode 100644 index 0000000000..58caee9eb0 --- /dev/null +++ b/docs/API_docs/methods/channels.toggleViewForumAsMessages.md @@ -0,0 +1,45 @@ +--- +title: "channels.toggleViewForumAsMessages" +description: "Users may also choose to display messages from all topics of a [forum](https://core.telegram.org/api/forum) as if they were sent to a normal group, using a 'View as messages' setting in the local client: this setting only affects the current account, and is synced to other logged in sessions using this method." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_toggleViewForumAsMessages.html +--- +# Method: channels.toggleViewForumAsMessages +[Back to methods index](index.html) + + + +Users may also choose to display messages from all topics of a [forum](https://core.telegram.org/api/forum) as if they were sent to a normal group, using a "View as messages" setting in the local client: this setting only affects the current account, and is synced to other logged in sessions using this method. + +Invoking this method will update the value of the `view_forum_as_messages` flag of [channelFull](../constructors/channelFull.html) or [dialog](../constructors/dialog.html) and emit an [updateChannelViewForumAsMessages](../constructors/updateChannelViewForumAsMessages.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The forum | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | The new value of the `view_forum_as_messages` flag. | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->toggleViewForumAsMessages(channel: $InputChannel, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.updateColor.md b/docs/API_docs/methods/channels.updateColor.md new file mode 100644 index 0000000000..a8746ba71f --- /dev/null +++ b/docs/API_docs/methods/channels.updateColor.md @@ -0,0 +1,45 @@ +--- +title: "channels.updateColor" +description: "Update the [accent color and background custom emoji »](https://core.telegram.org/api/colors) of a channel." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_updateColor.html +--- +# Method: channels.updateColor +[Back to methods index](index.html) + + + +Update the [accent color and background custom emoji »](https://core.telegram.org/api/colors) of a channel. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|for\_profile|[Bool](/API_docs/types/Bool.html) | Whether to change the accent color emoji pattern of the profile page; otherwise, the accent color and emoji pattern of messages will be changed. | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel whose accent color should be changed. | Optional| +|color|[int](/API_docs/types/int.html) | [ID of the accent color palette »](https://core.telegram.org/api/colors) to use (not RGB24, see [here »](https://core.telegram.org/api/colors) for more info); if not set, the default palette is used. | Optional| +|background\_emoji\_id|[long](/API_docs/types/long.html) | Custom emoji ID used in the accent color pattern. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->updateColor(for_profile: $Bool, channel: $InputChannel, color: $int, background_emoji_id: $long, ); +``` + diff --git a/docs/API_docs/methods/channels.updateEmojiStatus.md b/docs/API_docs/methods/channels.updateEmojiStatus.md new file mode 100644 index 0000000000..b3be5ca9e4 --- /dev/null +++ b/docs/API_docs/methods/channels.updateEmojiStatus.md @@ -0,0 +1,43 @@ +--- +title: "channels.updateEmojiStatus" +description: "Set an [emoji status](https://core.telegram.org/api/emoji-status) for a channel." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_updateEmojiStatus.html +--- +# Method: channels.updateEmojiStatus +[Back to methods index](index.html) + + + +Set an [emoji status](https://core.telegram.org/api/emoji-status) for a channel. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The channel, must have at least [`channel_emoji_status_level_min` boosts](https://core.telegram.org/api/config#channel-emoji-status-level-min). | Optional| +|emoji\_status|[EmojiStatus](/API_docs/types/EmojiStatus.html) | [Emoji status](https://core.telegram.org/api/emoji-status) to set | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->updateEmojiStatus(channel: $InputChannel, emoji_status: $EmojiStatus, ); +``` + diff --git a/docs/API_docs/methods/channels.updatePinnedForumTopic.md b/docs/API_docs/methods/channels.updatePinnedForumTopic.md new file mode 100644 index 0000000000..bd3d1c54ec --- /dev/null +++ b/docs/API_docs/methods/channels.updatePinnedForumTopic.md @@ -0,0 +1,44 @@ +--- +title: "channels.updatePinnedForumTopic" +description: "Pin or unpin [forum topics](https://core.telegram.org/api/forum)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_updatePinnedForumTopic.html +--- +# Method: channels.updatePinnedForumTopic +[Back to methods index](index.html) + + + +Pin or unpin [forum topics](https://core.telegram.org/api/forum) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Supergroup ID | Optional| +|topic\_id|[int](/API_docs/types/int.html) | [Forum topic ID](https://core.telegram.org/api/forum) | Optional| +|pinned|[Bool](/API_docs/types/Bool.html) | Whether to pin or unpin the topic | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->channels->updatePinnedForumTopic(channel: $InputChannel, topic_id: $int, pinned: $Bool, ); +``` + diff --git a/docs/API_docs/methods/channels.updateUsername.md b/docs/API_docs/methods/channels.updateUsername.md new file mode 100644 index 0000000000..0b42935d83 --- /dev/null +++ b/docs/API_docs/methods/channels.updateUsername.md @@ -0,0 +1,43 @@ +--- +title: "channels.updateUsername" +description: "Change or remove the username of a supergroup/channel" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_updateUsername.html +--- +# Method: channels.updateUsername +[Back to methods index](index.html) + + + +Change or remove the username of a supergroup/channel + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel | Optional| +|username|[string](/API_docs/types/string.html) | New username, pass an empty string to remove the username | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->updateUsername(channel: $InputChannel, username: 'string', ); +``` + diff --git a/docs/API_docs/methods/channels.viewSponsoredMessage.md b/docs/API_docs/methods/channels.viewSponsoredMessage.md new file mode 100644 index 0000000000..10f8f1b726 --- /dev/null +++ b/docs/API_docs/methods/channels.viewSponsoredMessage.md @@ -0,0 +1,42 @@ +--- +title: "channels.viewSponsoredMessage" +description: "Mark a specific sponsored message as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/channels_viewSponsoredMessage.html +--- +# Method: channels.viewSponsoredMessage +[Back to methods index](index.html) + + + +Mark a specific sponsored message as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Peer | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->channels->viewSponsoredMessage(channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/chatlists.checkChatlistInvite.md b/docs/API_docs/methods/chatlists.checkChatlistInvite.md new file mode 100644 index 0000000000..5aa7aca2a0 --- /dev/null +++ b/docs/API_docs/methods/chatlists.checkChatlistInvite.md @@ -0,0 +1,42 @@ +--- +title: "chatlists.checkChatlistInvite" +description: "Obtain information about a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_checkChatlistInvite.html +--- +# Method: chatlists.checkChatlistInvite +[Back to methods index](index.html) + + + +Obtain information about a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|slug|[string](/API_docs/types/string.html) | `slug` obtained from the [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links) | Optional| + + +### Return type: [chatlists.ChatlistInvite](/API_docs/types/chatlists.ChatlistInvite.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$chatlists_ChatlistInvite = $MadelineProto->chatlists->checkChatlistInvite(slug: 'string', ); +``` + diff --git a/docs/API_docs/methods/chatlists.deleteExportedInvite.md b/docs/API_docs/methods/chatlists.deleteExportedInvite.md new file mode 100644 index 0000000000..4a9a514b4c --- /dev/null +++ b/docs/API_docs/methods/chatlists.deleteExportedInvite.md @@ -0,0 +1,43 @@ +--- +title: "chatlists.deleteExportedInvite" +description: "Delete a previously created [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_deleteExportedInvite.html +--- +# Method: chatlists.deleteExportedInvite +[Back to methods index](index.html) + + + +Delete a previously created [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | The related folder | Yes| +|slug|[string](/API_docs/types/string.html) | `slug` obtained from the [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->chatlists->deleteExportedInvite(chatlist: $InputChatlist, slug: 'string', ); +``` + diff --git a/docs/API_docs/methods/chatlists.editExportedInvite.md b/docs/API_docs/methods/chatlists.editExportedInvite.md new file mode 100644 index 0000000000..a6fab47440 --- /dev/null +++ b/docs/API_docs/methods/chatlists.editExportedInvite.md @@ -0,0 +1,45 @@ +--- +title: "chatlists.editExportedInvite" +description: "Edit a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_editExportedInvite.html +--- +# Method: chatlists.editExportedInvite +[Back to methods index](index.html) + + + +Edit a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | Folder ID | Yes| +|slug|[string](/API_docs/types/string.html) | `slug` obtained from the [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). | Optional| +|title|[string](/API_docs/types/string.html) | If set, sets a new name for the link | Optional| +|peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | If set, changes the list of peers shared with the link | Optional| + + +### Return type: [ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ExportedChatlistInvite = $MadelineProto->chatlists->editExportedInvite(chatlist: $InputChatlist, slug: 'string', title: 'string', peers: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/chatlists.exportChatlistInvite.md b/docs/API_docs/methods/chatlists.exportChatlistInvite.md new file mode 100644 index 0000000000..fccdd012cd --- /dev/null +++ b/docs/API_docs/methods/chatlists.exportChatlistInvite.md @@ -0,0 +1,44 @@ +--- +title: "chatlists.exportChatlistInvite" +description: "Export a [folder »](https://core.telegram.org/api/folders), creating a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_exportChatlistInvite.html +--- +# Method: chatlists.exportChatlistInvite +[Back to methods index](index.html) + + + +Export a [folder »](https://core.telegram.org/api/folders), creating a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | The folder to export | Yes| +|title|[string](/API_docs/types/string.html) | An optional name for the link | Optional| +|peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The list of channels, group and supergroups to share with the link. Basic groups will automatically be [converted to supergroups](https://core.telegram.org/api/channel#migration) when invoking the method. | Yes| + + +### Return type: [chatlists.ExportedChatlistInvite](/API_docs/types/chatlists.ExportedChatlistInvite.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$chatlists_ExportedChatlistInvite = $MadelineProto->chatlists->exportChatlistInvite(chatlist: $InputChatlist, title: 'string', peers: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/chatlists.getChatlistUpdates.md b/docs/API_docs/methods/chatlists.getChatlistUpdates.md new file mode 100644 index 0000000000..8e18c8729f --- /dev/null +++ b/docs/API_docs/methods/chatlists.getChatlistUpdates.md @@ -0,0 +1,42 @@ +--- +title: "chatlists.getChatlistUpdates" +description: "Fetch new chats associated with an imported [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). Must be invoked at most every `chatlist_update_period` seconds (as per the related [client configuration parameter »](https://core.telegram.org/api/config#chatlist-update-period))." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_getChatlistUpdates.html +--- +# Method: chatlists.getChatlistUpdates +[Back to methods index](index.html) + + + +Fetch new chats associated with an imported [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). Must be invoked at most every `chatlist_update_period` seconds (as per the related [client configuration parameter »](https://core.telegram.org/api/config#chatlist-update-period)). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | The folder | Yes| + + +### Return type: [chatlists.ChatlistUpdates](/API_docs/types/chatlists.ChatlistUpdates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$chatlists_ChatlistUpdates = $MadelineProto->chatlists->getChatlistUpdates(chatlist: $InputChatlist, ); +``` + diff --git a/docs/API_docs/methods/chatlists.getExportedInvites.md b/docs/API_docs/methods/chatlists.getExportedInvites.md new file mode 100644 index 0000000000..1f07b4e124 --- /dev/null +++ b/docs/API_docs/methods/chatlists.getExportedInvites.md @@ -0,0 +1,42 @@ +--- +title: "chatlists.getExportedInvites" +description: "List all [chat folder deep links »](https://core.telegram.org/api/links#chat-folder-links) associated to a folder" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_getExportedInvites.html +--- +# Method: chatlists.getExportedInvites +[Back to methods index](index.html) + + + +List all [chat folder deep links »](https://core.telegram.org/api/links#chat-folder-links) associated to a folder + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | The folder | Yes| + + +### Return type: [chatlists.ExportedInvites](/API_docs/types/chatlists.ExportedInvites.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$chatlists_ExportedInvites = $MadelineProto->chatlists->getExportedInvites(chatlist: $InputChatlist, ); +``` + diff --git a/docs/API_docs/methods/chatlists.getLeaveChatlistSuggestions.md b/docs/API_docs/methods/chatlists.getLeaveChatlistSuggestions.md new file mode 100644 index 0000000000..b2c3cb10b1 --- /dev/null +++ b/docs/API_docs/methods/chatlists.getLeaveChatlistSuggestions.md @@ -0,0 +1,42 @@ +--- +title: "chatlists.getLeaveChatlistSuggestions" +description: "Returns identifiers of pinned or always included chats from a chat folder imported using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links), which are suggested to be left when the chat folder is deleted." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_getLeaveChatlistSuggestions.html +--- +# Method: chatlists.getLeaveChatlistSuggestions +[Back to methods index](index.html) + + + +Returns identifiers of pinned or always included chats from a chat folder imported using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links), which are suggested to be left when the chat folder is deleted. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | Folder ID | Yes| + + +### Return type: [Vector\_of\_Peer](/API_docs/types/Peer.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_Peer = $MadelineProto->chatlists->getLeaveChatlistSuggestions(chatlist: $InputChatlist, ); +``` + diff --git a/docs/API_docs/methods/chatlists.hideChatlistUpdates.md b/docs/API_docs/methods/chatlists.hideChatlistUpdates.md new file mode 100644 index 0000000000..09079ea219 --- /dev/null +++ b/docs/API_docs/methods/chatlists.hideChatlistUpdates.md @@ -0,0 +1,42 @@ +--- +title: "chatlists.hideChatlistUpdates" +description: "Dismiss new pending peers recently added to a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_hideChatlistUpdates.html +--- +# Method: chatlists.hideChatlistUpdates +[Back to methods index](index.html) + + + +Dismiss new pending peers recently added to a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | The folder | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->chatlists->hideChatlistUpdates(chatlist: $InputChatlist, ); +``` + diff --git a/docs/API_docs/methods/chatlists.joinChatlistInvite.md b/docs/API_docs/methods/chatlists.joinChatlistInvite.md new file mode 100644 index 0000000000..a9c86e93f8 --- /dev/null +++ b/docs/API_docs/methods/chatlists.joinChatlistInvite.md @@ -0,0 +1,43 @@ +--- +title: "chatlists.joinChatlistInvite" +description: "Import a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links), joining some or all the chats in the folder." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_joinChatlistInvite.html +--- +# Method: chatlists.joinChatlistInvite +[Back to methods index](index.html) + + + +Import a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links), joining some or all the chats in the folder. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|slug|[string](/API_docs/types/string.html) | `slug` obtained from a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). | Optional| +|peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | List of new chats to join, fetched using [chatlists.checkChatlistInvite](../methods/chatlists.checkChatlistInvite.html) and filtered as specified in the [documentation »](https://core.telegram.org/api/folders#shared-folders). | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->chatlists->joinChatlistInvite(slug: 'string', peers: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/chatlists.joinChatlistUpdates.md b/docs/API_docs/methods/chatlists.joinChatlistUpdates.md new file mode 100644 index 0000000000..90d21fdc54 --- /dev/null +++ b/docs/API_docs/methods/chatlists.joinChatlistUpdates.md @@ -0,0 +1,43 @@ +--- +title: "chatlists.joinChatlistUpdates" +description: "Join channels and supergroups recently added to a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_joinChatlistUpdates.html +--- +# Method: chatlists.joinChatlistUpdates +[Back to methods index](index.html) + + + +Join channels and supergroups recently added to a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | The folder | Yes| +|peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | List of new chats to join, fetched using [chatlists.getChatlistUpdates](../methods/chatlists.getChatlistUpdates.html) and filtered as specified in the [documentation »](https://core.telegram.org/api/folders#shared-folders). | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->chatlists->joinChatlistUpdates(chatlist: $InputChatlist, peers: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/chatlists.leaveChatlist.md b/docs/API_docs/methods/chatlists.leaveChatlist.md new file mode 100644 index 0000000000..fe9170e4ce --- /dev/null +++ b/docs/API_docs/methods/chatlists.leaveChatlist.md @@ -0,0 +1,43 @@ +--- +title: "chatlists.leaveChatlist" +description: "Delete a folder imported using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/chatlists_leaveChatlist.html +--- +# Method: chatlists.leaveChatlist +[Back to methods index](index.html) + + + +Delete a folder imported using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chatlist|[InputChatlist](/API_docs/types/InputChatlist.html) | Folder ID | Yes| +|peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Also leave the specified channels and groups | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->chatlists->leaveChatlist(chatlist: $InputChatlist, peers: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/contacts.acceptContact.md b/docs/API_docs/methods/contacts.acceptContact.md new file mode 100644 index 0000000000..8c20fbda62 --- /dev/null +++ b/docs/API_docs/methods/contacts.acceptContact.md @@ -0,0 +1,42 @@ +--- +title: "contacts.acceptContact" +description: "If the [add contact action bar is active](https://core.telegram.org/api/action-bar#add-contact), add that user as contact" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_acceptContact.html +--- +# Method: contacts.acceptContact +[Back to methods index](index.html) + + + +If the [add contact action bar is active](https://core.telegram.org/api/action-bar#add-contact), add that user as contact + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The user to add as contact | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->contacts->acceptContact(id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/contacts.addContact.md b/docs/API_docs/methods/contacts.addContact.md new file mode 100644 index 0000000000..c1820d24da --- /dev/null +++ b/docs/API_docs/methods/contacts.addContact.md @@ -0,0 +1,48 @@ +--- +title: "contacts.addContact" +description: "Add an existing telegram user as contact." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_addContact.html +--- +# Method: contacts.addContact +[Back to methods index](index.html) + + + +Add an existing telegram user as contact. + +Use [contacts.importContacts](../methods/contacts.importContacts.html) to add contacts by phone number, without knowing their Telegram ID. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|add\_phone\_privacy\_exception|[Bool](/API_docs/types/Bool.html) | Allow the other user to see our phone number? | Optional| +|id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Telegram ID of the other user | Optional| +|first\_name|[string](/API_docs/types/string.html) | First name | Optional| +|last\_name|[string](/API_docs/types/string.html) | Last name | Optional| +|phone|[string](/API_docs/types/string.html) | User's phone number, may be omitted to simply add the user to the contact list, without a phone number. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->contacts->addContact(add_phone_privacy_exception: $Bool, id: $InputUser, first_name: 'string', last_name: 'string', phone: 'string', ); +``` + diff --git a/docs/API_docs/methods/contacts.block.md b/docs/API_docs/methods/contacts.block.md new file mode 100644 index 0000000000..6db3629eac --- /dev/null +++ b/docs/API_docs/methods/contacts.block.md @@ -0,0 +1,43 @@ +--- +title: "contacts.block" +description: "Adds a peer to a blocklist, see [here »](https://core.telegram.org/api/block) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_block.html +--- +# Method: contacts.block +[Back to methods index](index.html) + + + +Adds a peer to a blocklist, see [here »](https://core.telegram.org/api/block) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Whether the peer should be added to the story blocklist; if not set, the peer will be added to the main blocklist, see [here »](https://core.telegram.org/api/block) for more info. | Optional| +|id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->block(my_stories_from: $Bool, id: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/contacts.blockFromReplies.md b/docs/API_docs/methods/contacts.blockFromReplies.md new file mode 100644 index 0000000000..4e79e9acf3 --- /dev/null +++ b/docs/API_docs/methods/contacts.blockFromReplies.md @@ -0,0 +1,45 @@ +--- +title: "contacts.blockFromReplies" +description: "Stop getting notifications about [discussion replies](https://core.telegram.org/api/discussion) of a certain user in `@replies`" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_blockFromReplies.html +--- +# Method: contacts.blockFromReplies +[Back to methods index](index.html) + + + +Stop getting notifications about [discussion replies](https://core.telegram.org/api/discussion) of a certain user in `@replies` + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|delete\_message|[Bool](/API_docs/types/Bool.html) | Whether to delete the specified message as well | Optional| +|delete\_history|[Bool](/API_docs/types/Bool.html) | Whether to delete all `@replies` messages from this user as well | Optional| +|report\_spam|[Bool](/API_docs/types/Bool.html) | Whether to also report this user for spam | Optional| +|msg\_id|[int](/API_docs/types/int.html) | ID of the message in the [@replies](https://core.telegram.org/api/discussion#replies) chat | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->contacts->blockFromReplies(delete_message: $Bool, delete_history: $Bool, report_spam: $Bool, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/contacts.deleteByPhones.md b/docs/API_docs/methods/contacts.deleteByPhones.md new file mode 100644 index 0000000000..4dfc330600 --- /dev/null +++ b/docs/API_docs/methods/contacts.deleteByPhones.md @@ -0,0 +1,42 @@ +--- +title: "contacts.deleteByPhones" +description: "Delete contacts by phone number" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_deleteByPhones.html +--- +# Method: contacts.deleteByPhones +[Back to methods index](index.html) + + + +Delete contacts by phone number + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phones|Array of [string](/API_docs/types/string.html) | Phone numbers | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->deleteByPhones(phones: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/contacts.deleteContacts.md b/docs/API_docs/methods/contacts.deleteContacts.md new file mode 100644 index 0000000000..5b58b1c8dc --- /dev/null +++ b/docs/API_docs/methods/contacts.deleteContacts.md @@ -0,0 +1,42 @@ +--- +title: "contacts.deleteContacts" +description: "Deletes several contacts from the list." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_deleteContacts.html +--- +# Method: contacts.deleteContacts +[Back to methods index](index.html) + + + +Deletes several contacts from the list. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID list | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->contacts->deleteContacts(id: [$InputUser, $InputUser], ); +``` + diff --git a/docs/API_docs/methods/contacts.editCloseFriends.md b/docs/API_docs/methods/contacts.editCloseFriends.md new file mode 100644 index 0000000000..dd0a232a5f --- /dev/null +++ b/docs/API_docs/methods/contacts.editCloseFriends.md @@ -0,0 +1,42 @@ +--- +title: "contacts.editCloseFriends" +description: "Edit the [close friends list, see here »](https://core.telegram.org/api/privacy) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_editCloseFriends.html +--- +# Method: contacts.editCloseFriends +[Back to methods index](index.html) + + + +Edit the [close friends list, see here »](https://core.telegram.org/api/privacy) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [long](/API_docs/types/long.html) | Full list of user IDs of close friends, see [here](https://core.telegram.org/api/privacy) for more info. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->editCloseFriends(id: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/contacts.exportContactToken.md b/docs/API_docs/methods/contacts.exportContactToken.md new file mode 100644 index 0000000000..91d0683e70 --- /dev/null +++ b/docs/API_docs/methods/contacts.exportContactToken.md @@ -0,0 +1,37 @@ +--- +title: "contacts.exportContactToken" +description: "Generates a [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links) for the currently logged-in user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_exportContactToken.html +--- +# Method: contacts.exportContactToken +[Back to methods index](index.html) + + + +Generates a [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links) for the currently logged-in user. + + + +### Return type: [ExportedContactToken](/API_docs/types/ExportedContactToken.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ExportedContactToken = $MadelineProto->contacts->exportContactToken(); +``` + diff --git a/docs/API_docs/methods/contacts.getBirthdays.md b/docs/API_docs/methods/contacts.getBirthdays.md new file mode 100644 index 0000000000..7dbbd369bf --- /dev/null +++ b/docs/API_docs/methods/contacts.getBirthdays.md @@ -0,0 +1,35 @@ +--- +title: "contacts.getBirthdays" +description: "contacts.getBirthdays parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getBirthdays.html +--- +# Method: contacts.getBirthdays +[Back to methods index](index.html) + + + + + +### Return type: [contacts.ContactBirthdays](/API_docs/types/contacts.ContactBirthdays.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_ContactBirthdays = $MadelineProto->contacts->getBirthdays(); +``` + diff --git a/docs/API_docs/methods/contacts.getBlocked.md b/docs/API_docs/methods/contacts.getBlocked.md new file mode 100644 index 0000000000..d9fc1f6178 --- /dev/null +++ b/docs/API_docs/methods/contacts.getBlocked.md @@ -0,0 +1,44 @@ +--- +title: "contacts.getBlocked" +description: "Returns the list of blocked users." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getBlocked.html +--- +# Method: contacts.getBlocked +[Back to methods index](index.html) + + + +Returns the list of blocked users. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Whether to fetch the story blocklist; if not set, will fetch the main blocklist. See [here »](https://core.telegram.org/api/block) for differences between the two. | Optional| +|offset|[int](/API_docs/types/int.html) | The number of list elements to be skipped | Optional| +|limit|[int](/API_docs/types/int.html) | The number of list elements to be returned | Optional| + + +### Return type: [contacts.Blocked](/API_docs/types/contacts.Blocked.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_Blocked = $MadelineProto->contacts->getBlocked(my_stories_from: $Bool, offset: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/contacts.getContactIDs.md b/docs/API_docs/methods/contacts.getContactIDs.md new file mode 100644 index 0000000000..62235623b0 --- /dev/null +++ b/docs/API_docs/methods/contacts.getContactIDs.md @@ -0,0 +1,43 @@ +--- +title: "contacts.getContactIDs" +description: "Get the telegram IDs of all contacts. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getContactIDs.html +--- +# Method: contacts.getContactIDs +[Back to methods index](index.html) + + + +Get the telegram IDs of all contacts. +Returns an array of Telegram user IDs for all contacts (0 if a contact does not have an associated Telegram account or have hidden their account using privacy settings). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [Vector\_of\_int](/API_docs/types/int.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_int = $MadelineProto->contacts->getContactIDs(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/contacts.getContacts.md b/docs/API_docs/methods/contacts.getContacts.md new file mode 100644 index 0000000000..336f027a1e --- /dev/null +++ b/docs/API_docs/methods/contacts.getContacts.md @@ -0,0 +1,42 @@ +--- +title: "contacts.getContacts" +description: "Returns the current user's contact list." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getContacts.html +--- +# Method: contacts.getContacts +[Back to methods index](index.html) + + + +Returns the current user's contact list. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | If there already is a full contact list on the client, a [hash](https://core.telegram.org/api/offsets#hash-generation) of a the list of contact IDs in ascending order may be passed in this parameter. If the contact set was not changed, [(contacts.contactsNotModified)](../constructors/contacts.contactsNotModified.html) will be returned. | Optional| + + +### Return type: [contacts.Contacts](/API_docs/types/contacts.Contacts.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_Contacts = $MadelineProto->contacts->getContacts(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/contacts.getLocated.md b/docs/API_docs/methods/contacts.getLocated.md new file mode 100644 index 0000000000..38415c26bd --- /dev/null +++ b/docs/API_docs/methods/contacts.getLocated.md @@ -0,0 +1,44 @@ +--- +title: "contacts.getLocated" +description: "Get users and geochats near you, see [here »](https://core.telegram.org/api/nearby) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getLocated.html +--- +# Method: contacts.getLocated +[Back to methods index](index.html) + + + +Get users and geochats near you, see [here »](https://core.telegram.org/api/nearby) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|background|[Bool](/API_docs/types/Bool.html) | While the geolocation of the current user is public, clients should update it in the background every half-an-hour or so, while setting this flag.
Do this only if the new location is more than 1 KM away from the previous one, or if the previous location is unknown. | Optional| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | Geolocation | Optional| +|self\_expires|[int](/API_docs/types/int.html) | If set, the geolocation of the current user will be public for the specified number of seconds; pass 0x7fffffff to disable expiry, 0 to make the current geolocation private; if the flag isn't set, no changes will be applied. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->contacts->getLocated(background: $Bool, geo_point: $InputGeoPoint, self_expires: $int, ); +``` + diff --git a/docs/API_docs/methods/contacts.getSaved.md b/docs/API_docs/methods/contacts.getSaved.md new file mode 100644 index 0000000000..20cfc03067 --- /dev/null +++ b/docs/API_docs/methods/contacts.getSaved.md @@ -0,0 +1,37 @@ +--- +title: "contacts.getSaved" +description: "Get all contacts, requires a [takeout session, see here » for more info](https://core.telegram.org/api/takeout)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getSaved.html +--- +# Method: contacts.getSaved +[Back to methods index](index.html) + + + +Get all contacts, requires a [takeout session, see here » for more info](https://core.telegram.org/api/takeout). + + + +### Return type: [Vector\_of\_SavedContact](/API_docs/types/SavedContact.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_SavedContact = $MadelineProto->contacts->getSaved(); +``` + diff --git a/docs/API_docs/methods/contacts.getStatuses.md b/docs/API_docs/methods/contacts.getStatuses.md new file mode 100644 index 0000000000..8cab07b65d --- /dev/null +++ b/docs/API_docs/methods/contacts.getStatuses.md @@ -0,0 +1,37 @@ +--- +title: "contacts.getStatuses" +description: "Use this method to obtain the online statuses of all contacts with an accessible Telegram account." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getStatuses.html +--- +# Method: contacts.getStatuses +[Back to methods index](index.html) + + + +Use this method to obtain the online statuses of all contacts with an accessible Telegram account. + + + +### Return type: [Vector\_of\_ContactStatus](/API_docs/types/ContactStatus.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_ContactStatus = $MadelineProto->contacts->getStatuses(); +``` + diff --git a/docs/API_docs/methods/contacts.getTopPeers.md b/docs/API_docs/methods/contacts.getTopPeers.md new file mode 100644 index 0000000000..9ce75a5707 --- /dev/null +++ b/docs/API_docs/methods/contacts.getTopPeers.md @@ -0,0 +1,52 @@ +--- +title: "contacts.getTopPeers" +description: "Get most used peers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_getTopPeers.html +--- +# Method: contacts.getTopPeers +[Back to methods index](index.html) + + + +Get most used peers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|correspondents|[Bool](/API_docs/types/Bool.html) | Users we've chatted most frequently with | Optional| +|bots\_pm|[Bool](/API_docs/types/Bool.html) | Most used bots | Optional| +|bots\_inline|[Bool](/API_docs/types/Bool.html) | Most used inline bots | Optional| +|phone\_calls|[Bool](/API_docs/types/Bool.html) | Most frequently called users | Optional| +|forward\_users|[Bool](/API_docs/types/Bool.html) | Users to which the users often forwards messages to | Optional| +|forward\_chats|[Bool](/API_docs/types/Bool.html) | Chats to which the users often forwards messages to | Optional| +|groups|[Bool](/API_docs/types/Bool.html) | Often-opened groups and supergroups | Optional| +|channels|[Bool](/API_docs/types/Bool.html) | Most frequently visited channels | Optional| +|offset|[int](/API_docs/types/int.html) | Offset for [pagination](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [contacts.TopPeers](/API_docs/types/contacts.TopPeers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_TopPeers = $MadelineProto->contacts->getTopPeers(correspondents: $Bool, bots_pm: $Bool, bots_inline: $Bool, phone_calls: $Bool, forward_users: $Bool, forward_chats: $Bool, groups: $Bool, channels: $Bool, offset: $int, limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/contacts.importContactToken.md b/docs/API_docs/methods/contacts.importContactToken.md new file mode 100644 index 0000000000..eab671e2be --- /dev/null +++ b/docs/API_docs/methods/contacts.importContactToken.md @@ -0,0 +1,42 @@ +--- +title: "contacts.importContactToken" +description: "Obtain user info from a [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_importContactToken.html +--- +# Method: contacts.importContactToken +[Back to methods index](index.html) + + + +Obtain user info from a [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|token|[string](/API_docs/types/string.html) | The token extracted from the [temporary profile link](https://core.telegram.org/api/links#temporary-profile-links). | Optional| + + +### Return type: [User](/API_docs/types/User.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$User = $MadelineProto->contacts->importContactToken(token: 'string', ); +``` + diff --git a/docs/API_docs/methods/contacts.importContacts.md b/docs/API_docs/methods/contacts.importContacts.md new file mode 100644 index 0000000000..44dcdd54e5 --- /dev/null +++ b/docs/API_docs/methods/contacts.importContacts.md @@ -0,0 +1,44 @@ +--- +title: "contacts.importContacts" +description: "Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_importContacts.html +--- +# Method: contacts.importContacts +[Back to methods index](index.html) + + + +Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info. + +Use [contacts.addContact](../methods/contacts.addContact.html) to add Telegram contacts without actually using their phone number. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|contacts|Array of [InputContact](/API_docs/types/InputContact.html) | List of contacts to import | Yes| + + +### Return type: [contacts.ImportedContacts](/API_docs/types/contacts.ImportedContacts.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_ImportedContacts = $MadelineProto->contacts->importContacts(contacts: [$InputContact, $InputContact], ); +``` + diff --git a/docs/API_docs/methods/contacts.resetSaved.md b/docs/API_docs/methods/contacts.resetSaved.md new file mode 100644 index 0000000000..c30d11565d --- /dev/null +++ b/docs/API_docs/methods/contacts.resetSaved.md @@ -0,0 +1,37 @@ +--- +title: "contacts.resetSaved" +description: "Removes all contacts without an associated Telegram account." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_resetSaved.html +--- +# Method: contacts.resetSaved +[Back to methods index](index.html) + + + +Removes all contacts without an associated Telegram account. + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->resetSaved(); +``` + diff --git a/docs/API_docs/methods/contacts.resetTopPeerRating.md b/docs/API_docs/methods/contacts.resetTopPeerRating.md new file mode 100644 index 0000000000..2c21cb6b84 --- /dev/null +++ b/docs/API_docs/methods/contacts.resetTopPeerRating.md @@ -0,0 +1,43 @@ +--- +title: "contacts.resetTopPeerRating" +description: "Reset [rating](https://core.telegram.org/api/top-rating) of top peer" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_resetTopPeerRating.html +--- +# Method: contacts.resetTopPeerRating +[Back to methods index](index.html) + + + +Reset [rating](https://core.telegram.org/api/top-rating) of top peer + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|category|[TopPeerCategory](/API_docs/types/TopPeerCategory.html) | Top peer category | Yes| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer whose rating should be reset | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->resetTopPeerRating(category: $TopPeerCategory, peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/contacts.resolvePhone.md b/docs/API_docs/methods/contacts.resolvePhone.md new file mode 100644 index 0000000000..95409b7fe1 --- /dev/null +++ b/docs/API_docs/methods/contacts.resolvePhone.md @@ -0,0 +1,42 @@ +--- +title: "contacts.resolvePhone" +description: "Resolve a phone number to get user info, if their privacy settings allow it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_resolvePhone.html +--- +# Method: contacts.resolvePhone +[Back to methods index](index.html) + + + +Resolve a phone number to get user info, if their privacy settings allow it. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|phone|[string](/API_docs/types/string.html) | Phone number in international format, possibly obtained from a [phone number deep link](https://core.telegram.org/api/links#phone-number-links). | Optional| + + +### Return type: [contacts.ResolvedPeer](/API_docs/types/contacts.ResolvedPeer.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_ResolvedPeer = $MadelineProto->contacts->resolvePhone(phone: 'string', ); +``` + diff --git a/docs/API_docs/methods/contacts.resolveUsername.md b/docs/API_docs/methods/contacts.resolveUsername.md new file mode 100644 index 0000000000..82ded862c2 --- /dev/null +++ b/docs/API_docs/methods/contacts.resolveUsername.md @@ -0,0 +1,42 @@ +--- +title: "contacts.resolveUsername" +description: "You cannot use this method directly, use the resolveUsername, getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_resolveUsername.html +--- +# Method: contacts.resolveUsername +[Back to methods index](index.html) + + + +You cannot use this method directly, use the resolveUsername, getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|username|[string](/API_docs/types/string.html) | @username to resolve | Optional| + + +### Return type: [contacts.ResolvedPeer](/API_docs/types/contacts.ResolvedPeer.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_ResolvedPeer = $MadelineProto->contacts->resolveUsername(username: 'string', ); +``` + diff --git a/docs/API_docs/methods/contacts.search.md b/docs/API_docs/methods/contacts.search.md new file mode 100644 index 0000000000..8473d74ef1 --- /dev/null +++ b/docs/API_docs/methods/contacts.search.md @@ -0,0 +1,43 @@ +--- +title: "contacts.search" +description: "Returns users found by username substring." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_search.html +--- +# Method: contacts.search +[Back to methods index](index.html) + + + +Returns users found by username substring. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|q|[string](/API_docs/types/string.html) | Target substring | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of users to be returned | Optional| + + +### Return type: [contacts.Found](/API_docs/types/contacts.Found.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$contacts_Found = $MadelineProto->contacts->search(q: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/contacts.setBlocked.md b/docs/API_docs/methods/contacts.setBlocked.md new file mode 100644 index 0000000000..c8bf9594c8 --- /dev/null +++ b/docs/API_docs/methods/contacts.setBlocked.md @@ -0,0 +1,44 @@ +--- +title: "contacts.setBlocked" +description: "Replace the contents of an entire [blocklist, see here for more info »](https://core.telegram.org/api/block)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_setBlocked.html +--- +# Method: contacts.setBlocked +[Back to methods index](index.html) + + + +Replace the contents of an entire [blocklist, see here for more info »](https://core.telegram.org/api/block). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Whether to edit the story blocklist; if not set, will edit the main blocklist. See [here »](https://core.telegram.org/api/block) for differences between the two. | Optional| +|id|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Full content of the blocklist. | Yes| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->setBlocked(my_stories_from: $Bool, id: [$InputPeer, $InputPeer], limit: $int, ); +``` + diff --git a/docs/API_docs/methods/contacts.toggleTopPeers.md b/docs/API_docs/methods/contacts.toggleTopPeers.md new file mode 100644 index 0000000000..bdf7dd5d4f --- /dev/null +++ b/docs/API_docs/methods/contacts.toggleTopPeers.md @@ -0,0 +1,42 @@ +--- +title: "contacts.toggleTopPeers" +description: "Enable/disable [top peers](https://core.telegram.org/api/top-rating)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_toggleTopPeers.html +--- +# Method: contacts.toggleTopPeers +[Back to methods index](index.html) + + + +Enable/disable [top peers](https://core.telegram.org/api/top-rating) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|enabled|[Bool](/API_docs/types/Bool.html) | Enable/disable | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->toggleTopPeers(enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/contacts.unblock.md b/docs/API_docs/methods/contacts.unblock.md new file mode 100644 index 0000000000..4cabf06b0b --- /dev/null +++ b/docs/API_docs/methods/contacts.unblock.md @@ -0,0 +1,43 @@ +--- +title: "contacts.unblock" +description: "Deletes a peer from a blocklist, see [here »](https://core.telegram.org/api/block) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/contacts_unblock.html +--- +# Method: contacts.unblock +[Back to methods index](index.html) + + + +Deletes a peer from a blocklist, see [here »](https://core.telegram.org/api/block) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|my\_stories\_from|[Bool](/API_docs/types/Bool.html) | Whether the peer should be removed from the story blocklist; if not set, the peer will be removed from the main blocklist, see [here »](https://core.telegram.org/api/block) for more info. | Optional| +|id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->contacts->unblock(my_stories_from: $Bool, id: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/folders.editPeerFolders.md b/docs/API_docs/methods/folders.editPeerFolders.md new file mode 100644 index 0000000000..9fea0fd977 --- /dev/null +++ b/docs/API_docs/methods/folders.editPeerFolders.md @@ -0,0 +1,42 @@ +--- +title: "folders.editPeerFolders" +description: "Edit peers in [peer folder](https://core.telegram.org/api/folders#peer-folders)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/folders_editPeerFolders.html +--- +# Method: folders.editPeerFolders +[Back to methods index](index.html) + + + +Edit peers in [peer folder](https://core.telegram.org/api/folders#peer-folders) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|folder\_peers|Array of [InputFolderPeer](/API_docs/types/InputFolderPeer.html) | New peer list | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->folders->editPeerFolders(folder_peers: [$InputFolderPeer, $InputFolderPeer], ); +``` + diff --git a/docs/API_docs/methods/fragment.getCollectibleInfo.md b/docs/API_docs/methods/fragment.getCollectibleInfo.md new file mode 100644 index 0000000000..04e33d0926 --- /dev/null +++ b/docs/API_docs/methods/fragment.getCollectibleInfo.md @@ -0,0 +1,40 @@ +--- +title: "fragment.getCollectibleInfo" +description: "fragment.getCollectibleInfo parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/fragment_getCollectibleInfo.html +--- +# Method: fragment.getCollectibleInfo +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|collectible|[InputCollectible](/API_docs/types/InputCollectible.html) | Yes| + + +### Return type: [fragment.CollectibleInfo](/API_docs/types/fragment.CollectibleInfo.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$fragment_CollectibleInfo = $MadelineProto->fragment->getCollectibleInfo(collectible: $InputCollectible, ); +``` + diff --git a/docs/API_docs/methods/help.acceptTermsOfService.md b/docs/API_docs/methods/help.acceptTermsOfService.md new file mode 100644 index 0000000000..553840505a --- /dev/null +++ b/docs/API_docs/methods/help.acceptTermsOfService.md @@ -0,0 +1,42 @@ +--- +title: "help.acceptTermsOfService" +description: "Accept the new terms of service" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_acceptTermsOfService.html +--- +# Method: help.acceptTermsOfService +[Back to methods index](index.html) + + + +Accept the new terms of service + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[DataJSON](/API_docs/types/DataJSON.html) | ID of terms of service | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->help->acceptTermsOfService(id: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/help.dismissSuggestion.md b/docs/API_docs/methods/help.dismissSuggestion.md new file mode 100644 index 0000000000..256dd72578 --- /dev/null +++ b/docs/API_docs/methods/help.dismissSuggestion.md @@ -0,0 +1,43 @@ +--- +title: "help.dismissSuggestion" +description: "Dismiss a [suggestion, see here for more info »](https://core.telegram.org/api/config#suggestions)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_dismissSuggestion.html +--- +# Method: help.dismissSuggestion +[Back to methods index](index.html) + + + +Dismiss a [suggestion, see here for more info »](https://core.telegram.org/api/config#suggestions). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | In the case of pending suggestions in [channels](../constructors/channelFull.html), the channel ID. | Optional| +|suggestion|[string](/API_docs/types/string.html) | [Suggestion, see here for more info »](https://core.telegram.org/api/config#suggestions). | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->help->dismissSuggestion(peer: $InputPeer, suggestion: 'string', ); +``` + diff --git a/docs/API_docs/methods/help.editUserInfo.md b/docs/API_docs/methods/help.editUserInfo.md new file mode 100644 index 0000000000..891dbcf533 --- /dev/null +++ b/docs/API_docs/methods/help.editUserInfo.md @@ -0,0 +1,111 @@ +--- +title: "help.editUserInfo" +description: "Internal use" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_editUserInfo.html +--- +# Method: help.editUserInfo +[Back to methods index](index.html) + + + +Internal use + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User | Optional| +|message|[string](/API_docs/types/string.html) | Message | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | [Message entities for styled text](https://core.telegram.org/api/entities) | Yes| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + +### Return type: [help.UserInfo](/API_docs/types/help.UserInfo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_UserInfo = $MadelineProto->help->editUserInfo(user_id: $InputUser, message: 'string', entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [help.UserInfo](../types/help.UserInfo.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/help.getAppConfig.md b/docs/API_docs/methods/help.getAppConfig.md new file mode 100644 index 0000000000..7a20b06c6b --- /dev/null +++ b/docs/API_docs/methods/help.getAppConfig.md @@ -0,0 +1,42 @@ +--- +title: "help.getAppConfig" +description: "Get app-specific configuration, see [client configuration](https://core.telegram.org/api/config#client-configuration) for more info on the result." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getAppConfig.html +--- +# Method: help.getAppConfig +[Back to methods index](index.html) + + + +Get app-specific configuration, see [client configuration](https://core.telegram.org/api/config#client-configuration) for more info on the result. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [help.AppConfig](/API_docs/types/help.AppConfig.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_AppConfig = $MadelineProto->help->getAppConfig(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/help.getAppUpdate.md b/docs/API_docs/methods/help.getAppUpdate.md new file mode 100644 index 0000000000..e7554bdccd --- /dev/null +++ b/docs/API_docs/methods/help.getAppUpdate.md @@ -0,0 +1,42 @@ +--- +title: "help.getAppUpdate" +description: "Returns information on update availability for the current application." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getAppUpdate.html +--- +# Method: help.getAppUpdate +[Back to methods index](index.html) + + + +Returns information on update availability for the current application. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|source|[string](/API_docs/types/string.html) | Source | Optional| + + +### Return type: [help.AppUpdate](/API_docs/types/help.AppUpdate.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_AppUpdate = $MadelineProto->help->getAppUpdate(source: 'string', ); +``` + diff --git a/docs/API_docs/methods/help.getCdnConfig.md b/docs/API_docs/methods/help.getCdnConfig.md new file mode 100644 index 0000000000..d112666f29 --- /dev/null +++ b/docs/API_docs/methods/help.getCdnConfig.md @@ -0,0 +1,37 @@ +--- +title: "help.getCdnConfig" +description: "Get configuration for [CDN](https://core.telegram.org/cdn) file downloads." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getCdnConfig.html +--- +# Method: help.getCdnConfig +[Back to methods index](index.html) + + + +Get configuration for [CDN](https://core.telegram.org/cdn) file downloads. + + + +### Return type: [CdnConfig](/API_docs/types/CdnConfig.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$CdnConfig = $MadelineProto->help->getCdnConfig(); +``` + diff --git a/docs/API_docs/methods/help.getConfig.md b/docs/API_docs/methods/help.getConfig.md new file mode 100644 index 0000000000..2eb4e62841 --- /dev/null +++ b/docs/API_docs/methods/help.getConfig.md @@ -0,0 +1,37 @@ +--- +title: "help.getConfig" +description: "Returns current configuration, including data center configuration." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getConfig.html +--- +# Method: help.getConfig +[Back to methods index](index.html) + + + +Returns current configuration, including data center configuration. + + + +### Return type: [Config](/API_docs/types/Config.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Config = $MadelineProto->help->getConfig(); +``` + diff --git a/docs/API_docs/methods/help.getCountriesList.md b/docs/API_docs/methods/help.getCountriesList.md new file mode 100644 index 0000000000..679041c00c --- /dev/null +++ b/docs/API_docs/methods/help.getCountriesList.md @@ -0,0 +1,43 @@ +--- +title: "help.getCountriesList" +description: "Get name, ISO code, localized name and phone codes/patterns of all available countries" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getCountriesList.html +--- +# Method: help.getCountriesList +[Back to methods index](index.html) + + + +Get name, ISO code, localized name and phone codes/patterns of all available countries + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_code|[string](/API_docs/types/string.html) | Language code of the current user | Optional| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [help.CountriesList](/API_docs/types/help.CountriesList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_CountriesList = $MadelineProto->help->getCountriesList(lang_code: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/help.getDeepLinkInfo.md b/docs/API_docs/methods/help.getDeepLinkInfo.md new file mode 100644 index 0000000000..75f4fa58c0 --- /dev/null +++ b/docs/API_docs/methods/help.getDeepLinkInfo.md @@ -0,0 +1,42 @@ +--- +title: "help.getDeepLinkInfo" +description: "Get info about an unsupported deep link, see [here for more info »](https://core.telegram.org/api/links#unsupported-links)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getDeepLinkInfo.html +--- +# Method: help.getDeepLinkInfo +[Back to methods index](index.html) + + + +Get info about an unsupported deep link, see [here for more info »](https://core.telegram.org/api/links#unsupported-links). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|path|[string](/API_docs/types/string.html) | Path component of a `tg:` link | Optional| + + +### Return type: [help.DeepLinkInfo](/API_docs/types/help.DeepLinkInfo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_DeepLinkInfo = $MadelineProto->help->getDeepLinkInfo(path: 'string', ); +``` + diff --git a/docs/API_docs/methods/help.getInviteText.md b/docs/API_docs/methods/help.getInviteText.md new file mode 100644 index 0000000000..8c4a44fee4 --- /dev/null +++ b/docs/API_docs/methods/help.getInviteText.md @@ -0,0 +1,37 @@ +--- +title: "help.getInviteText" +description: "Returns localized text of a text message with an invitation." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getInviteText.html +--- +# Method: help.getInviteText +[Back to methods index](index.html) + + + +Returns localized text of a text message with an invitation. + + + +### Return type: [help.InviteText](/API_docs/types/help.InviteText.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_InviteText = $MadelineProto->help->getInviteText(); +``` + diff --git a/docs/API_docs/methods/help.getNearestDc.md b/docs/API_docs/methods/help.getNearestDc.md new file mode 100644 index 0000000000..d55ddec38b --- /dev/null +++ b/docs/API_docs/methods/help.getNearestDc.md @@ -0,0 +1,37 @@ +--- +title: "help.getNearestDc" +description: "Returns info on data center nearest to the user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getNearestDc.html +--- +# Method: help.getNearestDc +[Back to methods index](index.html) + + + +Returns info on data center nearest to the user. + + + +### Return type: [NearestDc](/API_docs/types/NearestDc.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$NearestDc = $MadelineProto->help->getNearestDc(); +``` + diff --git a/docs/API_docs/methods/help.getPassportConfig.md b/docs/API_docs/methods/help.getPassportConfig.md new file mode 100644 index 0000000000..ae5ce28247 --- /dev/null +++ b/docs/API_docs/methods/help.getPassportConfig.md @@ -0,0 +1,42 @@ +--- +title: "help.getPassportConfig" +description: "Get [passport](https://core.telegram.org/passport) configuration" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getPassportConfig.html +--- +# Method: help.getPassportConfig +[Back to methods index](index.html) + + + +Get [passport](https://core.telegram.org/passport) configuration + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [help.PassportConfig](/API_docs/types/help.PassportConfig.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_PassportConfig = $MadelineProto->help->getPassportConfig(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/help.getPeerColors.md b/docs/API_docs/methods/help.getPeerColors.md new file mode 100644 index 0000000000..1b9df22c0c --- /dev/null +++ b/docs/API_docs/methods/help.getPeerColors.md @@ -0,0 +1,42 @@ +--- +title: "help.getPeerColors" +description: "Get the set of [accent color palettes »](https://core.telegram.org/api/colors) that can be used for message accents." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getPeerColors.html +--- +# Method: help.getPeerColors +[Back to methods index](index.html) + + + +Get the set of [accent color palettes »](https://core.telegram.org/api/colors) that can be used for message accents. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [help.PeerColors](/API_docs/types/help.PeerColors.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_PeerColors = $MadelineProto->help->getPeerColors(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/help.getPeerProfileColors.md b/docs/API_docs/methods/help.getPeerProfileColors.md new file mode 100644 index 0000000000..06fc38b3ac --- /dev/null +++ b/docs/API_docs/methods/help.getPeerProfileColors.md @@ -0,0 +1,42 @@ +--- +title: "help.getPeerProfileColors" +description: "Get the set of [accent color palettes »](https://core.telegram.org/api/colors) that can be used in profile page backgrounds." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getPeerProfileColors.html +--- +# Method: help.getPeerProfileColors +[Back to methods index](index.html) + + + +Get the set of [accent color palettes »](https://core.telegram.org/api/colors) that can be used in profile page backgrounds. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [help.PeerColors](/API_docs/types/help.PeerColors.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_PeerColors = $MadelineProto->help->getPeerProfileColors(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/help.getPremiumPromo.md b/docs/API_docs/methods/help.getPremiumPromo.md new file mode 100644 index 0000000000..49c09aa553 --- /dev/null +++ b/docs/API_docs/methods/help.getPremiumPromo.md @@ -0,0 +1,37 @@ +--- +title: "help.getPremiumPromo" +description: "Get Telegram Premium promotion information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getPremiumPromo.html +--- +# Method: help.getPremiumPromo +[Back to methods index](index.html) + + + +Get Telegram Premium promotion information + + + +### Return type: [help.PremiumPromo](/API_docs/types/help.PremiumPromo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_PremiumPromo = $MadelineProto->help->getPremiumPromo(); +``` + diff --git a/docs/API_docs/methods/help.getPromoData.md b/docs/API_docs/methods/help.getPromoData.md new file mode 100644 index 0000000000..70fb34d74b --- /dev/null +++ b/docs/API_docs/methods/help.getPromoData.md @@ -0,0 +1,37 @@ +--- +title: "help.getPromoData" +description: "Get MTProxy/Public Service Announcement information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getPromoData.html +--- +# Method: help.getPromoData +[Back to methods index](index.html) + + + +Get MTProxy/Public Service Announcement information + + + +### Return type: [help.PromoData](/API_docs/types/help.PromoData.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_PromoData = $MadelineProto->help->getPromoData(); +``` + diff --git a/docs/API_docs/methods/help.getRecentMeUrls.md b/docs/API_docs/methods/help.getRecentMeUrls.md new file mode 100644 index 0000000000..1b0b8db85e --- /dev/null +++ b/docs/API_docs/methods/help.getRecentMeUrls.md @@ -0,0 +1,45 @@ +--- +title: "help.getRecentMeUrls" +description: "Get recently used `t.me` links." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getRecentMeUrls.html +--- +# Method: help.getRecentMeUrls +[Back to methods index](index.html) + + + +Get recently used `t.me` links. + +When installing official applications from "Download Telegram" buttons present in [t.me](https://t.me) pages, a referral parameter is passed to applications after installation. +If, after downloading the application, the user creates a new account (instead of logging into an existing one), the referral parameter should be imported using this method, which returns the [t.me](https://t.me) pages the user recently opened, before installing Telegram. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|referer|[string](/API_docs/types/string.html) | Referrer | Optional| + + +### Return type: [help.RecentMeUrls](/API_docs/types/help.RecentMeUrls.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_RecentMeUrls = $MadelineProto->help->getRecentMeUrls(referer: 'string', ); +``` + diff --git a/docs/API_docs/methods/help.getSupport.md b/docs/API_docs/methods/help.getSupport.md new file mode 100644 index 0000000000..066fdd1c51 --- /dev/null +++ b/docs/API_docs/methods/help.getSupport.md @@ -0,0 +1,37 @@ +--- +title: "help.getSupport" +description: "Returns the support user for the 'ask a question' feature." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getSupport.html +--- +# Method: help.getSupport +[Back to methods index](index.html) + + + +Returns the support user for the "ask a question" feature. + + + +### Return type: [help.Support](/API_docs/types/help.Support.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_Support = $MadelineProto->help->getSupport(); +``` + diff --git a/docs/API_docs/methods/help.getSupportName.md b/docs/API_docs/methods/help.getSupportName.md new file mode 100644 index 0000000000..31bb7f9845 --- /dev/null +++ b/docs/API_docs/methods/help.getSupportName.md @@ -0,0 +1,37 @@ +--- +title: "help.getSupportName" +description: "Get localized name of the telegram support user" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getSupportName.html +--- +# Method: help.getSupportName +[Back to methods index](index.html) + + + +Get localized name of the telegram support user + + + +### Return type: [help.SupportName](/API_docs/types/help.SupportName.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_SupportName = $MadelineProto->help->getSupportName(); +``` + diff --git a/docs/API_docs/methods/help.getTermsOfServiceUpdate.md b/docs/API_docs/methods/help.getTermsOfServiceUpdate.md new file mode 100644 index 0000000000..32ca482db6 --- /dev/null +++ b/docs/API_docs/methods/help.getTermsOfServiceUpdate.md @@ -0,0 +1,37 @@ +--- +title: "help.getTermsOfServiceUpdate" +description: "Look for updates of telegram's terms of service" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getTermsOfServiceUpdate.html +--- +# Method: help.getTermsOfServiceUpdate +[Back to methods index](index.html) + + + +Look for updates of telegram's terms of service + + + +### Return type: [help.TermsOfServiceUpdate](/API_docs/types/help.TermsOfServiceUpdate.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_TermsOfServiceUpdate = $MadelineProto->help->getTermsOfServiceUpdate(); +``` + diff --git a/docs/API_docs/methods/help.getTimezonesList.md b/docs/API_docs/methods/help.getTimezonesList.md new file mode 100644 index 0000000000..cd6e4a5006 --- /dev/null +++ b/docs/API_docs/methods/help.getTimezonesList.md @@ -0,0 +1,40 @@ +--- +title: "help.getTimezonesList" +description: "help.getTimezonesList parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getTimezonesList.html +--- +# Method: help.getTimezonesList +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | Optional| + + +### Return type: [help.TimezonesList](/API_docs/types/help.TimezonesList.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_TimezonesList = $MadelineProto->help->getTimezonesList(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/help.getUserInfo.md b/docs/API_docs/methods/help.getUserInfo.md new file mode 100644 index 0000000000..ce242cb69c --- /dev/null +++ b/docs/API_docs/methods/help.getUserInfo.md @@ -0,0 +1,42 @@ +--- +title: "help.getUserInfo" +description: "Can only be used by TSF members to obtain internal information." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_getUserInfo.html +--- +# Method: help.getUserInfo +[Back to methods index](index.html) + + + +Can only be used by TSF members to obtain internal information. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID | Optional| + + +### Return type: [help.UserInfo](/API_docs/types/help.UserInfo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$help_UserInfo = $MadelineProto->help->getUserInfo(user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/help.hidePromoData.md b/docs/API_docs/methods/help.hidePromoData.md new file mode 100644 index 0000000000..294e98dd3e --- /dev/null +++ b/docs/API_docs/methods/help.hidePromoData.md @@ -0,0 +1,42 @@ +--- +title: "help.hidePromoData" +description: "Hide MTProxy/Public Service Announcement information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_hidePromoData.html +--- +# Method: help.hidePromoData +[Back to methods index](index.html) + + + +Hide MTProxy/Public Service Announcement information + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer to hide | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->help->hidePromoData(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/help.saveAppLog.md b/docs/API_docs/methods/help.saveAppLog.md new file mode 100644 index 0000000000..64dc1dbc9e --- /dev/null +++ b/docs/API_docs/methods/help.saveAppLog.md @@ -0,0 +1,42 @@ +--- +title: "help.saveAppLog" +description: "Saves logs of application on the server." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_saveAppLog.html +--- +# Method: help.saveAppLog +[Back to methods index](index.html) + + + +Saves logs of application on the server. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|events|Array of [InputAppEvent](/API_docs/types/InputAppEvent.html) | List of input events | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->help->saveAppLog(events: [$InputAppEvent, $InputAppEvent], ); +``` + diff --git a/docs/API_docs/methods/help.setBotUpdatesStatus.md b/docs/API_docs/methods/help.setBotUpdatesStatus.md new file mode 100644 index 0000000000..1e4a2f2d88 --- /dev/null +++ b/docs/API_docs/methods/help.setBotUpdatesStatus.md @@ -0,0 +1,49 @@ +--- +title: "help.setBotUpdatesStatus" +description: "Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/help_setBotUpdatesStatus.html +--- +# Method: help.setBotUpdatesStatus +[Back to methods index](index.html) + + + +Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|pending\_updates\_count|[int](/API_docs/types/int.html) | Number of pending updates | Optional| +|message|[string](/API_docs/types/string.html) | Error message, if present | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->help->setBotUpdatesStatus(pending_updates_count: $int, message: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/index.md b/docs/API_docs/methods/index.md new file mode 100644 index 0000000000..7cabb08994 --- /dev/null +++ b/docs/API_docs/methods/index.md @@ -0,0 +1,1689 @@ +--- +title: Methods +description: What do you want to do? +parent: "Telegram RPC API" +has_children: true +nav_order: 3 +has_toc: false +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# What do you want to do? +[Go back to API documentation index](..) + +[Go to the old code-version method index](api_index.html) + +* [Login](https://docs.madelineproto.xyz/docs/LOGIN.html) + +* [Change 2FA password: update2FA](https://docs.madelineproto.xyz/update2fa.html) + +* [Get all chats, broadcast a message to all chats: getDialogIds, getDialogs, getFullDialogs](https://docs.madelineproto.xyz/docs/DIALOGS.html) + +* [Get the full participant list of a channel/group/supergroup: getPwrChat](https://docs.madelineproto.xyz/getPwrChat.html) + +* [Get full info about a user/chat/supergroup/channel: getFullInfo](https://docs.madelineproto.xyz/getFullInfo.html) + +* [Get info about a user/chat/supergroup/channel: getInfo](https://docs.madelineproto.xyz/getInfo.html) + +* [Get the ID of a user/chat/supergroup/channel/update: getID](https://docs.madelineproto.xyz/getId.html) + +* [Get info about the currently logged-in user: getSelf](https://docs.madelineproto.xyz/getSelf.html) + +* [Upload or download files up to 4 GB: uploadFrom*, downloadTo*](https://docs.madelineproto.xyz/docs/FILES.html) + +* [Make a phone call and play a song](https://docs.madelineproto.xyz/docs/CALLS.html) + +* [Create a secret chat bot](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html) + +* Abort a pending 2FA password reset, see here for more info »: account.declinePasswordReset + +* Accept QR code login token, logging in the app that generated it: auth.acceptLoginToken + +* Accept call: acceptCall + +* Accept secret chat: acceptSecretChat + +* Accept the new terms of service: help.acceptTermsOfService + +* Activate or deactivate a purchased fragment.com username associated to a bot we own: bots.toggleUsername + +* Activate or deactivate a purchased fragment.com username associated to a supergroup or channel we own: channels.toggleUsername + +* Activate or deactivate a purchased fragment.com username associated to the currently logged-in user: account.toggleUsername + +* Activates stories stealth mode, see here » for more info: stories.activateStealthMode + +* Add GIF to saved gifs list: messages.saveGif + +* Add a sticker to a stickerset, bots only. The sticker set must have been created by the bot: stickers.addStickerToSet + +* Add an existing telegram user as contact: contacts.addContact + +* Add/remove sticker from recent stickers list: messages.saveRecentSticker + +* Adds a peer to a blocklist, see here » for more info: contacts.block + +* Adds a user to a chat and sends a service message on it: messages.addChatUser + +* Allow the specified bot to send us messages: bots.allowSendMessage + +* Answer an inline query, for bots only: messages.setInlineBotResults + +* Answers a custom query; for bots only: bots.answerWebhookJSONQuery + +* Apply a Telegram Premium giftcode »: payments.applyGiftCode + +* Apply changes to multiple stickersets: messages.toggleStickerSets + +* Apply one or more boosts » to a peer: premium.applyBoost + +* Associate a group to a channel as discussion group for that channel: channels.setDiscussionGroup + +* Associate a stickerset to the supergroup: channels.setStickers + +* Asynchronously lock a file: flock + +* Asynchronously read line: readLine + +* Asynchronously sleep: sleep + +* Asynchronously write to stdout/browser: echo + +* Ban/unban/kick a user in a supergroup/channel: channels.editBanned + +* Base64URL encode: base64urlEncode + +* Can only be used by TSF members to obtain internal information: help.getUserInfo + +* Cancel a running broadcast: cancelBroadcast + +* Cancel the code that was sent to verify an email to use as 2FA recovery method: account.cancelPasswordEmail + +* Cancel the login verification code: auth.cancelCode + +* Change default emoji reaction to use in the quick reaction menu: the value is synced across devices and can be fetched using help.getConfig, reactions_default field: messages.setDefaultReaction + +* Change group call settings: phone.toggleGroupCallSettings + +* Change media autodownload settings: account.saveAutoDownloadSettings + +* Change or remove the username of a supergroup/channel: channels.updateUsername + +* Change privacy settings of current account: account.setPrivacy + +* Change settings related to a session: account.changeAuthorizationSettings + +* Change the chat theme of a certain chat: messages.setChatTheme + +* Change the default peer that should be used when sending messages, reactions, poll votes to a specific group: messages.saveDefaultSendAs + +* Change the phone number of the current account: account.changePhone + +* Change the photo of a channel/supergroup: channels.editPhoto + +* Change the set of message reactions » that can be used in a certain group, supergroup or channel: messages.setChatAvailableReactions + +* Changes chat name and sends a service message on it: messages.editChatTitle + +* Changes chat photo and sends a service message on it: messages.editChatPhoto + +* Changes the absolute position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot: stickers.changeStickerPosition + +* Changes the default value of the Time-To-Live setting, applied to all new chats: messages.setDefaultHistoryTTL + +* Changes username for the current user: account.updateUsername + +* Check if a certain event handler plugin is installed: hasPlugin + +* Check if a username is free and can be assigned to a channel/supergroup: channels.checkUsername + +* Check if an event handler instance is present: hasEventHandler + +* Check if has admins: hasAdmins + +* Check if has report peers: hasReportPeers + +* Check if is array or similar (traversable && countable && arrayAccess): isArrayOrAlike + +* Check if peer is present in internal peer database: peerIsset + +* Check if the 2FA recovery code sent using auth.requestPasswordRecovery is valid, before passing it to auth.recoverPassword: auth.checkRecoveryPassword + +* Check if the specified peer is a bot: isBot + +* Check if the specified peer is a forum: isForum + +* Check the validity of a chat invite link and get basic info about it: messages.checkChatInvite + +* Check whether chat history exported from another chat app can be imported into a specific Telegram chat, click here for more info »: messages.checkHistoryImportPeer + +* Check whether secret chat exists: hasSecretChat + +* Check whether the given short name is available: stickers.checkShortName + +* Check whether the group call Server Forwarding Unit is currently receiving the streams with the specified WebRTC source IDs.: phone.checkGroupCall + +* Check whether the specified bot can send us messages: bots.canSendMessage + +* Check whether we can post stories as the specified peer: stories.canSendStory + +* Checks whether Telegram Premium purchase is possible. Must be called before in-store Premium purchase, official apps only: payments.canPurchasePremium + +* Clear all drafts: messages.clearAllDrafts + +* Clear all peer-specific autosave settings: account.deleteAutoSaveExceptions + +* Clear bot commands for the specified bot scope and language code: bots.resetBotCommands + +* Clear recent stickers: messages.clearRecentStickers + +* Clear recently used message reactions: messages.clearRecentReactions + +* Clear saved payment information: payments.clearSavedInfo + +* Clears list of recently used emoji statuses: account.clearRecentEmojiStatuses + +* Close connection with client, connected via web: closeConnection + +* Complet user login using login code: completePhoneLogin + +* Complete 2FA login: complete2faLogin + +* Complete signup to Telegram: completeSignup + +* Complete the history import process, importing all messages into the chat.: messages.startHistoryImport + +* Confirm a phone number to cancel account deletion, for more info click here »: account.confirmPhone + +* Confirms receipt of messages by a client, cancels PUSH-notification sending: messages.receivedMessages + +* Convert MTProto parameters to bot API parameters: MTProtoToBotAPI + +* Convert TD parameters to tdcli: tdToTdcli + +* Convert TD to MTProto parameters: tdToMTProto + +* Convert a message and a set of entities to HTML: entitiesToHtml + +* Convert a supergroup to a gigagroup, when requested by channel suggestions: channels.convertToGigagroup + +* Convert bot API parameters to MTProto parameters: botAPIToMTProto + +* Convert double to binary version: packDouble + +* Convert integer to base256 long: packSignedLong + +* Convert integer to base256 signed int: packSignedInt + +* Convert tdcli parameters to tdcli: tdcliToTd + +* Convert to camelCase: toCamelCase + +* Convert to snake_case: toSnakeCase + +* Convert value to unsigned base256 int: packUnsignedInt + +* Converts a string into an async amphp stream: stringToStream + +* Create a forum topic; requires manage_topics rights: channels.createForumTopic + +* Create a group call or livestream: phone.createGroupCall + +* Create a stickerset, bots only: stickers.createStickerSet + +* Create a supergroup/channel: channels.createChannel + +* Create a theme: account.createTheme + +* Create and upload a new wallpaper: account.uploadWallPaper + +* Create array: arr + +* Creates a new chat: messages.createChat + +* Delete a channel/supergroup: channels.deleteChannel + +* Delete a chat invite: messages.deleteExportedChatInvite + +* Delete a chat: messages.deleteChat + +* Delete a folder imported using a chat folder deep link »: chatlists.leaveChatlist + +* Delete a previously created chat folder deep link »: chatlists.deleteExportedInvite + +* Delete all installed wallpapers, reverting to the default wallpaper set: account.resetWallPapers + +* Delete all messages sent by a specific participant of a given supergroup: channels.deleteParticipantHistory + +* Delete all revoked chat invites: messages.deleteRevokedExportedChatInvites + +* Delete all temporary authorization keys except for the ones specified: auth.dropTempAuthKeys + +* Delete contacts by phone number: contacts.deleteByPhones + +* Delete message history of a forum topic: channels.deleteTopicHistory + +* Delete messages in a channel/supergroup: channels.deleteMessages + +* Delete scheduled messages: messages.deleteScheduledMessages + +* Delete stored Telegram Passport documents, for more info see the passport docs »: account.deleteSecureValue + +* Delete the entire phone call history: messages.deletePhoneCallHistory + +* Delete the history of a supergroup: channels.deleteHistory + +* Delete the user's account from the telegram servers: account.deleteAccount + +* Deletes a device by its token, stops sending PUSH-notifications to it: account.unregisterDevice + +* Deletes a peer from a blocklist, see here » for more info: contacts.unblock + +* Deletes a stickerset we created, bots only: stickers.deleteStickerSet + +* Deletes a user from a chat and sends a service message on it: messages.deleteChatUser + +* Deletes communication history: messages.deleteHistory + +* Deletes messages by their identifiers: messages.deleteMessages + +* Deletes messages forwarded from a specific peer to saved messages »: messages.deleteSavedHistory + +* Deletes profile photos. The method returns a list of successfully deleted photo IDs: photos.deletePhotos + +* Deletes several contacts from the list: contacts.deleteContacts + +* Deletes some posted stories: stories.deleteStories + +* Disable all purchased usernames of a supergroup or channel: channels.deactivateAllUsernames + +* Discard call: discardCall + +* Discard secret chat: discardSecretChat + +* Dismiss a suggestion, see here for more info »: help.dismissSuggestion + +* Dismiss new pending peers recently added to a chat folder deep link »: chatlists.hideChatlistUpdates + +* Dismiss or approve a chat join request related to a specific chat or channel: messages.hideChatJoinRequest + +* Dismiss or approve all join requests related to a specific chat or channel: messages.hideAllChatJoinRequests + +* Download file to amphp/http-server response: downloadToResponse + +* Download file to an amphp stream, returning it: downloadToReturnedStream + +* Download file to browser: downloadToBrowser + +* Download file to callable: downloadToCallable + +* Download file to directory: downloadToDir + +* Download file to stream: downloadToStream + +* Download file: downloadToFile + +* Downloads a file to the browser using the specified session file: downloadServer + +* Edit a chat folder deep link »: chatlists.editExportedInvite + +* Edit an exported chat invite: messages.editExportedChatInvite + +* Edit an inline bot message: messages.editInlineBotMessage + +* Edit an uploaded story: stories.editStory + +* Edit forum topic; requires manage_topics rights: channels.editForumTopic + +* Edit information about a given group call participant: phone.editGroupCallParticipant + +* Edit location of geogroup, see here » for more info on geogroups: channels.editLocation + +* Edit message: messages.editMessage + +* Edit peers in peer folder: folders.editPeerFolders + +* Edit the close friends list, see here » for more info: contacts.editCloseFriends + +* Edit the default banned rights of a channel/supergroup/group: messages.editChatDefaultBannedRights + +* Edit the description of a group/supergroup/channel: messages.editChatAbout + +* Edit the name of a channel/supergroup: channels.editTitle + +* Edit the title of a group call or livestream: phone.editGroupCallTitle + +* Edits notification settings from a given user/group, from all users/all groups: account.updateNotifySettings + +* Enable or disable content protection on a channel or chat: messages.toggleNoForwards + +* Enable or disable forum functionality in a supergroup: channels.toggleForum + +* Enable or disable the native antispam system: channels.toggleAntiSpam + +* Enable or disable web bot attachment menu »: messages.toggleBotInAttachMenu + +* Enable/disable message signatures in channels: channels.toggleSignatures + +* Enable/disable top peers: contacts.toggleTopPeers + +* Escape string for MadelineProto's HTML entity converter: htmlEscape + +* Escape string for URL: markdownUrlEscape + +* Escape string for markdown code section: markdownCodeEscape + +* Escape string for markdown codeblock: markdownCodeblockEscape + +* Escape string for markdown: markdownEscape + +* Executes a custom broadcast action with all peers (users, chats, channels) of the bot: broadcastCustom + +* Export a folder », creating a chat folder deep link »: chatlists.exportChatlistInvite + +* Export an invite link for a chat: messages.exportChatInvite + +* Export authorization: exportAuthorization + +* Extract Update constructors from an Updates constructor: extractUpdates + +* Extract a message ID from an Updates constructor: extractMessageId + +* Extract a message constructor from an Updates constructor: extractMessage + +* Extract an update message constructor from an Updates constructor: extractMessageUpdate + +* Extract file info from bot API message: extractBotAPIFile + +* Fetch custom emoji stickers »: messages.getCustomEmojiDocuments + +* Fetch new chats associated with an imported chat folder deep link ». Must be invoked at most every chatlist_update_period seconds (as per the related client configuration parameter »): chatlists.getChatlistUpdates + +* Fetch saved notification sounds: account.getSavedRingtones + +* Fetch the List of active (or active and hidden) stories, see here » for more info on watching stories: stories.getAllStories + +* Fetch the full active story list of a specific peer: stories.getPeerStories + +* Fetch the stories pinned on a peer's profile: stories.getPinnedStories + +* Fetch the story archive » of a peer we control: stories.getStoriesArchive + +* Find out if a media message's caption can be edited: messages.getMessageEditData + +* Fork a new green thread and execute the passed function in the background: callFork + +* Forwards a list of messages to all peers (users, chats, channels) of the bot: broadcastForwardMessages + +* Forwards messages by their IDs: messages.forwardMessages + +* Generate MTProto vector hash: genVectorHash + +* Generate a login token, for login via QR code.: auth.exportLoginToken + +* Generate a story deep link for a specific story: stories.exportStoryLink + +* Generate an invoice deep link: payments.exportInvoice + +* Generates a temporary profile link for the currently logged-in user: contacts.exportContactToken + +* Get MTProxy/Public Service Announcement information: help.getPromoData + +* Get PSR logger: getPsrLogger + +* Get RTMP URL and stream key for RTMP livestreams. Can be used even before creating the actual RTMP livestream with phone.createGroupCall (the rtmp_stream flag must be set): phone.getGroupCallStreamRtmpUrl + +* Get TL namespaces: getMethodNamespaces + +* Get TL serializer: getTL + +* Get Telegram Premium promotion information: help.getPremiumPromo + +* Get Telegram UTF-8 length of string: mbStrlen + +* Get a document by its SHA256 hash, mainly used for gifs: messages.getDocumentByHash + +* Get a list of channels/supergroups we left, requires a takeout session, see here » for more info: channels.getLeftChannels + +* Get a list of default suggested channel emoji statuses: account.getChannelDefaultEmojiStatuses + +* Get a list of default suggested emoji statuses: account.getDefaultEmojiStatuses + +* Get a list of peers that can be used to join a group call, presenting yourself as a specific user/channel: phone.getGroupCallJoinAs + +* Get a list of sponsored messages: channels.getSponsoredMessages + +* Get a message to show to the user when starting the bot: getWebMessage + +* Get a payment form: payments.getPaymentForm + +* Get a set of suggested custom emoji stickers that can be used as group picture: account.getDefaultGroupPhotoEmojis + +* Get a set of suggested custom emoji stickers that can be used as profile picture: account.getDefaultProfilePhotoEmojis + +* Get a set of suggested custom emoji stickers that can be used in an accent color pattern: account.getDefaultBackgroundEmojis + +* Get admin IDs (equal to all user report peers): getAdminIds + +* Get all archived stickers: messages.getArchivedStickers + +* Get all available chat themes »: account.getChatThemes + +* Get all contacts, requires a takeout session, see here » for more info: contacts.getSaved + +* Get all groups that can be used as discussion groups: channels.getGroupsForDiscussion + +* Get all installed stickers: messages.getAllStickers + +* Get all pending and running calls, indexed by user ID: getAllCalls + +* Get all saved Telegram Passport documents, for more info see the passport docs »: account.getAllSecureValues + +* Get an invite link for a group call or livestream: phone.exportGroupCallInvite + +* Get and increase the view counter of a message sent or forwarded from a channel: messages.getMessagesViews + +* Get app-specific configuration, see client configuration for more info on the result: help.getAppConfig + +* Get async DNS client: getDNSClient + +* Get async HTTP client: getHTTPClient + +* Get authorization info: getAuthorization + +* Get autosave settings: account.getAutoSaveSettings + +* Get cached (or eventually re-fetch) server-side config: getConfig + +* Get cached server-side config: getCachedConfig + +* Get call state: getCallState + +* Get changed emoji keywords »: messages.getEmojiKeywordsDifference + +* Get channel statistics: stats.getBroadcastStats + +* Get channel/supergroup messages: channels.getMessages + +* Get channels/supergroups/geogroups we're admin in. Usually called when the user exceeds the limit for owned public channels/supergroups/geogroups, and the user is given the choice to remove one of his channels/supergroups/geogroups: channels.getAdminedPublicChannels + +* Get chats in common with a user: messages.getCommonChats + +* Get configuration for CDN file downloads: help.getCdnConfig + +* Get contents of remote file asynchronously: fileGetContents + +* Get count of online users in a chat: messages.getOnlines + +* Get current number of memory-mapped regions, UNIX only: getMaps + +* Get current password hint: getHint + +* Get days to live of account: account.getAccountTTL + +* Get dialog info of specified peers: messages.getPeerDialogs + +* Get dialogs manually marked as unread: messages.getDialogUnreadMarks + +* Get diffie-hellman configuration: getDhConfig + +* Get discussion message from the associated discussion group of a channel to show it on top of the comment section, without actually joining the group: messages.getDiscussionMessage + +* Get download info of file: getDownloadInfo + +* Get download link of media file: getDownloadLink + +* Get event handler (or plugin instance): getEventHandler + +* Get extension from file location: getExtensionFromLocation + +* Get extension from mime type: getExtensionFromMime + +* Get faved stickers: messages.getFavedStickers + +* Get featured stickers: messages.getFeaturedStickers + +* Get final element of array: end + +* Get folders: messages.getDialogFilters + +* Get forum topics by their ID: channels.getForumTopicsByID + +* Get full list of MTProto and API methods: getAllMethods + +* Get global privacy settings: account.getGlobalPrivacySettings + +* Get group call participants: phone.getGroupParticipants + +* Get highscores of a game sent using an inline bot: messages.getInlineGameHighScores + +* Get highscores of a game: messages.getGameHighScores + +* Get inactive channels and supergroups: channels.getInactiveChannels + +* Get info about RTMP streams in a group call or livestream.: phone.getGroupCallStreamChannels + +* Get info about a certain wallpaper: account.getWallPaper + +* Get info about a channel/supergroup participant: channels.getParticipant + +* Get info about a chat invite: messages.getExportedChatInvite + +* Get info about a credit card: payments.getBankCardData + +* Get info about a group call: phone.getGroupCall + +* Get info about a stickerset: messages.getStickerSet + +* Get info about an unsupported deep link, see here for more info »: help.getDeepLinkInfo + +* Get info about chat invites generated by admins: messages.getAdminsWithInvites + +* Get info about file: getFileInfo + +* Get info about multiple wallpapers: account.getMultiWallPapers + +* Get info about the chat invites of a specific chat: messages.getExportedChatInvites + +* Get info about the logged-in user, not cached: fullGetSelf + +* Get info about the users that joined the chat using a specific chat invite: messages.getChatInviteImporters + +* Get information about a language in a localization pack: langpack.getLanguage + +* Get information about all languages in a localization pack: langpack.getLanguages + +* Get information about extended media: messages.getExtendedMedia + +* Get installed mask stickers: messages.getMaskStickers + +* Get installed themes: account.getThemes + +* Get instant view page: messages.getWebPage + +* Get link and embed info of a message in a channel/supergroup: channels.exportMessageLink + +* Get live location history of a certain user: messages.getRecentLocations + +* Get localization pack strings: langpack.getLangPack + +* Get localized emoji keywords »: messages.getEmojiKeywords + +* Get localized name of the telegram support user: help.getSupportName + +* Get localized name, about text and description of a bot (or of the current account, if called by a bot): bots.getBotInfo + +* Get logged-in sessions: account.getAuthorizations + +* Get logger: getLogger + +* Get maximum number of memory-mapped regions, UNIX only: getMaxMaps + +* Get media autodownload settings: account.getAutoDownloadSettings + +* Get message ranges for saving the user's chat history: messages.getSplitRanges + +* Get message reaction list, along with the sender of each reaction: messages.getMessageReactionsList + +* Get message reactions »: messages.getMessagesReactions + +* Get message statistics: stats.getMessageStats + +* Get messages in a reply thread: messages.getReplies + +* Get mime type from buffer: getMimeFromBuffer + +* Get mime type from file extension: getMimeFromExtension + +* Get mime type of file: getMimeFromFile + +* Get more info about a Seamless Telegram Login authorization request, for more info click here »: messages.requestUrlAuth + +* Get most used peers: contacts.getTopPeers + +* Get name, ISO code, localized name and phone codes/patterns of all available countries: help.getCountriesList + +* Get namespaced methods (method => namespace): getMethodsNamespaced + +* Get new strings in language pack: langpack.getDifference + +* Get passport configuration: help.getPassportConfig + +* Get payment receipt: payments.getPaymentReceipt + +* Get peer settings: messages.getPeerSettings + +* Get phone call configuration to be passed to libtgvoip's shared config: phone.getCallConfig + +* Get phone call information: getCall + +* Get pinned dialogs: messages.getPinnedDialogs + +* Get pinned saved dialogs, see here » for more info: messages.getPinnedSavedDialogs + +* Get poll results for non-anonymous polls: messages.getPollVotes + +* Get poll results: messages.getPollResults + +* Get preview of webpage: messages.getWebPagePreview + +* Get privacy settings of current account: account.getPrivacy + +* Get random integer: randomInt + +* Get recent stickers: messages.getRecentStickers + +* Get recently used emoji statuses: account.getRecentEmojiStatuses + +* Get recently used message reactions: messages.getRecentReactions + +* Get recently used t.me links: help.getRecentMeUrls + +* Get saved GIFs: messages.getSavedGifs + +* Get saved Telegram Passport document, for more info see the passport docs »: account.getSecureValue + +* Get saved payment information: payments.getSavedInfo + +* Get scheduled messages: messages.getScheduledHistory + +* Get scheduled messages: messages.getScheduledMessages + +* Get secret chat: getSecretChat + +* Get secure random string of specified length: random + +* Get sensitive content settings: account.getContentSettings + +* Get sponsored messages for channel: getSponsoredMessages + +* Get statistics for a certain story: stats.getStoryStats + +* Get stickers attached to a photo or video: messages.getAttachedStickers + +* Get stickers by emoji: messages.getStickers + +* Get strings from a language pack: langpack.getStrings + +* Get suggested folders: messages.getSuggestedDialogFilters + +* Get supergroup statistics: stats.getMegagroupStats + +* Get temporary payment password: account.getTmpPassword + +* Get the IDs of the maximum read stories for a set of peers: stories.getPeerMaxIDs + +* Get the admin log of a channel/supergroup: channels.getAdminLog + +* Get the file that is currently being played: callGetCurrent + +* Get the number of results that would be found by a messages.search call with the same parameters: messages.getSearchCounters + +* Get the participants of a supergroup/channel: channels.getParticipants + +* Get the phone call with the specified user ID: getCallByPeer + +* Get the progress of a currently running broadcast: getBroadcastProgress + +* Get the reaction and interaction list of a story posted to a channel, along with the sender of each reaction: stories.getStoryReactionsList + +* Get the set of accent color palettes » that can be used for message accents: help.getPeerColors + +* Get the set of accent color palettes » that can be used in profile page backgrounds: help.getPeerProfileColors + +* Get the telegram IDs of all contacts.: contacts.getContactIDs + +* Get theme information: account.getTheme + +* Get topics of a forum: channels.getForumTopics + +* Get type of peer: getType + +* Get unread messages where we were mentioned: messages.getUnreadMentions + +* Get unread reactions to messages you sent: messages.getUnreadReactions + +* Get users and geochats near you, see here » for more info: contacts.getLocated + +* Get various warnings to show to the user in the web UI: getWebWarnings + +* Get web login widget authorizations: account.getWebAuthorizations + +* Get which users read a specific message: only available for groups and supergroups with less than chat_read_mark_size_threshold members, read receipts will be stored for chat_read_mark_expire_period seconds after the message was sent, see client configuration for more info »: messages.getMessageReadParticipants + +* Gets a secret chat message: getSecretMessage + +* Gets current notification settings for a given user/group, from all users/all groups: account.getNotifySettings + +* Gets featured custom emoji stickersets: messages.getFeaturedEmojiStickers + +* Gets info of the propic of a user: getPropicInfo + +* Gets the current number of boosts of a channel: premium.getBoostsStatus + +* Gets the default value of the Time-To-Live setting, applied to all new chats: messages.getDefaultHistoryTTL + +* Gets the list of currently installed custom emoji stickersets: messages.getEmojiStickers + +* Gets the menu button action for a given user or for all users, previously set using bots.setBotMenuButton; users can see this information in the botInfo constructor: bots.getBotMenuButton + +* Got popular message reactions: messages.getTopReactions + +* Hide MTProxy/Public Service Announcement information: help.hidePromoData + +* Hide or display the participants list in a supergroup: channels.toggleParticipantsHidden + +* Hide the active stories of a specific peer, preventing them from being displayed on the action bar on the homescreen: stories.toggleAllStoriesHidden + +* Hide the active stories of a user, preventing them from being displayed on the action bar on the homescreen, see here » for more info: stories.togglePeerStoriesHidden + +* Hide/unhide message history for new channel/supergroup users: channels.togglePreHistoryHidden + +* If the add contact action bar is active, add that user as contact: contacts.acceptContact + +* If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the bot will receive an updateBotShippingQuery update. Use this method to reply to shipping queries: messages.setBotShippingResults + +* Import a chat folder deep link », joining some or all the chats in the folder: chatlists.joinChatlistInvite + +* Import a chat invite and join a private chat/supergroup/channel: messages.importChatInvite + +* Import authorization: importAuthorization + +* Import chat history from a foreign chat app into a specific Telegram chat, click here for more info about imported chats »: messages.initHistoryImport + +* Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info: contacts.importContacts + +* Increment the view counter of one or more stories: stories.incrementStoryViews + +* Indicate to the server (from the user side) that the user is still using a web app: messages.prolongWebView + +* Inflate stripped photosize to full JPG payload: inflateStripped + +* Informs server about a purchase made through the App Store: for official applications only: payments.assignAppStoreTransaction + +* Informs server about a purchase made through the Play Store: for official applications only: payments.assignPlayMarketTransaction + +* Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only: help.setBotUpdatesStatus + +* Informs the server that the user has either:: channels.clickSponsoredMessage + +* Initialize a takeout session, see here » for more info: account.initTakeoutSession + +* Initialize connection: initConnection + +* Initialize self-restart hack: initSelfRestart + +* Initiate a 2FA password reset: can only be used if the user is already logged-in, see here for more info »: account.resetPassword + +* Initiates QR code login: qrLogin + +* Install a stickerset: messages.installStickerSet + +* Install a theme: account.installTheme + +* Install wallpaper: account.installWallPaper + +* Install/uninstall wallpaper: account.saveWallPaper + +* Installs a previously uploaded photo as a profile photo: photos.updateProfilePhoto + +* Internal endpoint used by the download server: processDownloadServerPing + +* Internal use: help.editUserInfo + +* Invalidate the specified login codes, see here » for more info: account.invalidateSignInCodes + +* Invite a set of users to a group call: phone.inviteToGroupCall + +* Invite users to a channel/supergroup: channels.inviteToChannel + +* Invoke a method within a takeout session, see here » for more info: invokeWithTakeout + +* Invoke a request without subscribing the used connection for updates (this is enabled by default for file queries): invokeWithoutUpdates + +* Invoke the specified query using the specified API layer: invokeWithLayer + +* Invoke with the given message range: invokeWithMessagesRange + +* Invokes a query after a successful completion of previous queries: invokeAfterMsgs + +* Invokes a query after successful completion of one of the previous queries: invokeAfterMsg + +* Join a channel/supergroup: channels.joinChannel + +* Join a group call: phone.joinGroupCall + +* Join channels and supergroups recently added to a chat folder deep link »: chatlists.joinChatlistUpdates + +* Launch a prepaid giveaway »: payments.launchPrepaidGiveaway + +* Leave a channel/supergroup: channels.leaveChannel + +* Leave a group call: phone.leaveGroupCall + +* List all chat folder deep links » associated to a folder: chatlists.getExportedInvites + +* Load channel statistics graph asynchronously: stats.loadAsyncGraph + +* Log in to telegram (via CLI or web): start + +* Log out an active authorized session by its hash: account.resetAuthorization + +* Log out an active web telegram login session: account.resetWebAuthorization + +* Logger: logger + +* Login as bot: botLogin + +* Login as user: phoneLogin + +* Login by importing an authorization token: auth.importWebTokenAuthorization + +* Login using a redirected login token, generated in case of DC mismatch during QR code login: auth.importLoginToken + +* Logout the session: logout + +* Look for custom emojis associated to a UTF8 emoji: messages.searchCustomEmoji + +* Look for updates of telegram's terms of service: help.getTermsOfServiceUpdate + +* MTProto to TD params: MTProtoToTd + +* MTProto to TDCLI params: MTProtoToTdcli + +* Make a user admin in a basic group: messages.editChatAdmin + +* Manually convert HTML to a message and a set of entities: htmlToMessageEntities + +* Manually convert markdown to a message and a set of entities: markdownToMessageEntities + +* Manually mark dialog as unread: messages.markDialogUnread + +* Mark a specific sponsored message as read: channels.viewSponsoredMessage + +* Mark a thread as read: messages.readDiscussion + +* Mark all stories up to a certain ID as read, for a given peer; will emit an updateReadStories update to all logged-in sessions: stories.readStories + +* Mark channel/supergroup history as read: channels.readHistory + +* Mark channel/supergroup message contents as read: channels.readMessageContents + +* Mark mentions as read: messages.readMentions + +* Mark message reactions » as read: messages.readReactions + +* Mark new featured stickers as read: messages.readFeaturedStickers + +* Mark or unmark a sticker as favorite: messages.faveSticker + +* Mark sponsored message as read: viewSponsoredMessage + +* Marks message history as read: messages.readHistory + +* Marks message history within a secret chat as read: messages.readEncryptedHistory + +* Method for fetching previously featured stickers: messages.getOldFeaturedStickers + +* Modify autosave settings: account.saveAutoSaveSettings + +* Modify the admin rights of a user in a supergroup/channel: channels.editAdmin + +* Notifies the sender about the recipient having listened a voice message or watched a video: messages.readMessageContents + +* Notify the other user in a private chat that a screenshot of the chat was taken: messages.sendScreenshotNotification + +* Notify the user that the sent passport data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change): users.setSecureValueErrors + +* Obtain a certain event handler plugin instance: getPlugin + +* Obtain a list of Telegram Premium giveaway/gift code » options: payments.getPremiumGiftCodeOptions + +* Obtain a list of bot commands for the specified bot scope and language code: bots.getBotCommands + +* Obtain a list of channels where the user can post stories: stories.getChatsToSend + +* Obtain a list of related languages that must be used when fetching emoji keyword lists »: messages.getEmojiKeywordsLanguages + +* Obtain a list of similarly themed public channels, selected based on similarities in their subscriber bases: channels.getChannelRecommendations + +* Obtain available message reactions »: messages.getAvailableReactions + +* Obtain configuration for two-factor authorization with password: account.getPassword + +* Obtain forwards of a story as a message to public chats and reposts by public channels: stats.getStoryPublicForwards + +* Obtain full info about a set of stories by their IDs: stories.getStoriesByID + +* Obtain info about the view count, forward count, reactions and recent viewers of one or more stories: stories.getStoriesViews + +* Obtain information about a Telegram Premium giftcode »: payments.checkGiftCode + +* Obtain information about a Telegram Premium giveaway »: payments.getGiveawayInfo + +* Obtain information about a chat folder deep link »: chatlists.checkChatlistInvite + +* Obtain information about a direct link Mini App: messages.getBotApp + +* Obtain the API ID UI template: getWebAPITemplate + +* Obtain the latest read story ID for all peers when first logging in, returned as a list of updateReadStories updates, see here » for more info: stories.getAllReadPeerStories + +* Obtain the list of users that have viewed a specific story we posted: stories.getStoryViewsList + +* Obtain user info from a temporary profile link: contacts.importContactToken + +* Obtain which peers are we currently boosting, and how many boost slots we have left: premium.getMyBoosts + +* Obtains a list of messages, indicating to which other public channels was a channel message forwarded.: stats.getMessagePublicForwards + +* Obtains a list of peers that can be used to send messages in a specific group: channels.getSendAs + +* Obtains a pipe that can be used to upload a file from a stream: getStreamPipe + +* Obtains info about the boosts that were applied to a certain channel (admins only): premium.getBoostsList + +* Obtains information about a chat export file, generated by a foreign chat app, click here for more info about imported chats »: messages.checkHistoryImport + +* Once the user has confirmed their payment and shipping details, the bot receives an updateBotPrecheckoutQuery update.: messages.setBotPrecheckoutResults + +* Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**: getUpdates + +* Open a bot mini app from a direct Mini App deep link, sending over user information after user confirmation: messages.requestAppWebView + +* Open a bot mini app, sending over user information after user confirmation: messages.requestWebView + +* Open a bot mini app: messages.requestSimpleWebView + +* Opens a file in append-only mode: openFileAppendOnly + +* Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended: phone.receivedCall + +* Parse, update and store settings: updateSettings + +* Pauses playback of the current audio file in the call: pausePlay + +* Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements: validateEventHandlerClass + +* Pin a message: messages.updatePinnedMessage + +* Pin or unpin a saved message dialog »: messages.toggleSavedDialogPin + +* Pin or unpin forum topics: channels.updatePinnedForumTopic + +* Pin or unpin one or more stories: stories.togglePinned + +* Pin/unpin a dialog: messages.toggleDialogPin + +* Play file in call: callPlay + +* Play files on hold in call: callPlayOnHold + +* Positive modulo: posmod + +* Press an inline callback button and get a callback answer from the bot: messages.getBotCallbackAnswer + +* Provide a buffered reader for a file, URL or amp stream: openBuffered + +* Provide a stream for a file, URL or amp stream: getStream + +* Query an inline bot: messages.getInlineBotResults + +* Rate a call, returns info about the rating message sent to the official VoIP bot: phone.setCallRating + +* Rate transcribed voice message: messages.rateTranscribedAudio + +* React to a story: stories.sendReaction + +* React to message: messages.sendReaction + +* Refresh full peer cache for a certain peer: refreshFullPeerCache + +* Refresh peer cache for a certain peer: refreshPeerCache + +* Register device to receive PUSH notifications: account.registerDevice + +* Remove a sticker from the set where it belongs, bots only. The sticker set must have been created by the bot: stickers.removeStickerFromSet + +* Removes all contacts without an associated Telegram account: contacts.resetSaved + +* Renames a stickerset, bots only: stickers.renameStickerSet + +* Reorder active usernames: channels.reorderUsernames + +* Reorder folders: messages.updateDialogFiltersOrder + +* Reorder installed stickersets: messages.reorderStickerSets + +* Reorder pinned dialogs: messages.reorderPinnedDialogs + +* Reorder pinned forum topics: channels.reorderPinnedForumTopics + +* Reorder pinned saved message dialogs »: messages.reorderPinnedSavedDialogs + +* Reorder usernames associated to a bot we own: bots.reorderUsernames + +* Reorder usernames associated with the currently logged-in user: account.reorderUsernames + +* Replace the contents of an entire blocklist, see here for more info »: contacts.setBlocked + +* Report a message in a chat for violation of telegram's Terms of Service: messages.report + +* Report a message reaction: messages.reportReaction + +* Report a native antispam false positive: channels.reportAntiSpamFalsePositive + +* Report a new incoming chat for spam, if the peer settings of the chat allow us to do that: messages.reportSpam + +* Report a peer for violation of telegram's Terms of Service: account.reportPeer + +* Report a profile photo of a dialog: account.reportProfilePhoto + +* Report a secret chat for spam: messages.reportEncryptedSpam + +* Report a story: stories.report + +* Report an error to the previously set peer: report + +* Report memory profile with memprof: reportMemoryProfile + +* Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup: channels.reportSpam + +* Represents a list of emoji categories, to be used when selecting custom emojis to set as custom emoji status: messages.getEmojiStatusGroups + +* Represents a list of emoji categories, to be used when selecting custom emojis to set as profile picture: messages.getEmojiProfilePhotoGroups + +* Represents a list of emoji categories, to be used when selecting custom emojis: messages.getEmojiGroups + +* Request VoIP call: requestCall + +* Request an SMS code via Firebase: auth.requestFirebaseSms + +* Request recovery code of a 2FA password, only for accounts with a recovery email configured: auth.requestPasswordRecovery + +* Request secret chat: requestSecretChat + +* Resend the code to verify an email to use as 2FA recovery method: account.resendPasswordEmail + +* Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see login for more info: auth.resendCode + +* Reset all active web telegram login sessions: account.resetWebAuthorizations + +* Reset rating of top peer: contacts.resetTopPeerRating + +* Reset the 2FA password using the recovery code sent using auth.requestPasswordRecovery: auth.recoverPassword + +* Reset the login email »: auth.resetLoginEmail + +* Reset the update state and fetch all updates from the beginning: resetUpdateState + +* Resets all notification settings from users and groups: account.resetNotifySettings + +* Resolve a phone number to get user info, if their privacy settings allow it: contacts.resolvePhone + +* Restart update loop: restart + +* Resumes playback of the current audio file in the call: resumePlay + +* Rethrow exception into event loop: rethrow + +* Return all message drafts.: messages.getAllDrafts + +* Return current settings: getSettings + +* Returns a Telegram Passport authorization form for sharing data with a service: account.getAuthorizationForm + +* Returns a list of available wallpapers: account.getWallPapers + +* Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new emoji keywords ». The URL will be valid for 30 seconds after generation: messages.getEmojiURL + +* Returns attachment menu entry for a bot mini app that can be launched from the attachment menu »: messages.getAttachMenuBot + +* Returns chat basic info on their IDs: messages.getChats + +* Returns content of a web file, by proxying the request through telegram, see the webfile docs for more info: upload.getWebFile + +* Returns current configuration, including data center configuration: help.getConfig + +* Returns fetch the full list of custom emoji IDs » that cannot be used in channel emoji statuses »: account.getChannelRestrictedStatusEmojis + +* Returns identifiers of pinned or always included chats from a chat folder imported using a chat folder deep link », which are suggested to be left when the chat folder is deleted: chatlists.getLeaveChatlistSuggestions + +* Returns info on data center nearest to the user: help.getNearestDc + +* Returns information about the next messages of the specified type in the chat split by days: messages.getSearchResultsCalendar + +* Returns information on update availability for the current application: help.getAppUpdate + +* Returns installed attachment menu bot mini apps »: messages.getAttachMenuBots + +* Returns list of chats with non-default notification settings: account.getNotifyExceptions + +* Returns localized text of a text message with an invitation: help.getInviteText + +* Returns saved messages » forwarded from a specific peer: messages.getSavedHistory + +* Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation: messages.getSearchResultsPositions + +* Returns the conversation history with one interlocutor / within a chat: messages.getHistory + +* Returns the current saved dialog list, see here » for more info: messages.getSavedDialogs + +* Returns the current user dialog list: messages.getDialogs + +* Returns the current user's contact list: contacts.getContacts + +* Returns the list of blocked users: contacts.getBlocked + +* Returns the list of messages by their IDs: messages.getMessages + +* Returns the list of user photos: photos.getUserPhotos + +* Returns the lists of boost that were applied to a channel by a specific user (admins only): premium.getUserBoosts + +* Returns the session name: getSessionName + +* Returns the support user for the "ask a question" feature: help.getSupport + +* Returns users found by username substring: contacts.search + +* Returns whether the current user is a bot: isSelfBot + +* Returns whether the current user is a premium user, cached: isPremium + +* Returns whether the current user is a user: isSelfUser + +* Reupload telegram file: uploadFromTgfile + +* Save a message draft associated to a chat: messages.saveDraft + +* Save a theme: account.saveTheme + +* Save or remove saved notification sound: account.saveRingtone + +* Save phone call debug information: phone.saveCallLog + +* Saves logs of application on the server: help.saveAppLog + +* Search for custom emoji stickersets »: messages.searchEmojiStickerSets + +* Search for messages and peers globally: messages.searchGlobal + +* Search for messages: messages.search + +* Search for stickersets: messages.searchStickerSets + +* Securely save Telegram Passport document, for more info see the passport docs »: account.saveSecureValue + +* Send VoIP signaling data: phone.sendSignalingData + +* Send a custom request from a mini bot app, triggered by a web_app_invoke_custom_method event »: bots.invokeWebViewCustomMethod + +* Send a media: messages.sendMedia + +* Send a result obtained using messages.getInlineBotResults: messages.sendInlineBotResult + +* Send an album or grouped media: messages.sendMultiMedia + +* Send an email verification code: account.sendVerifyEmailCode + +* Send compiled payment form: payments.sendPaymentForm + +* Send confirmation code to cancel account deletion, for more info click here »: account.sendConfirmPhoneCode + +* Send one or more chosen peers, as requested by a keyboardButtonRequestPeer button: messages.sendBotRequestedPeer + +* Send phone call debug data to server: phone.saveCallDebug + +* Send scheduled messages right away: messages.sendScheduledMessages + +* Send the verification phone code for telegram passport: account.sendVerifyPhoneCode + +* Send typing event by the current user to a secret chat: messages.setEncryptedTyping + +* Sends a Telegram Passport authorization form, effectively sharing data with the service: account.acceptAuthorization + +* Sends a current user typing event (see SendMessageAction for all event types) to a conversation partner or group: messages.setTyping + +* Sends a custom request; for bots only: bots.sendCustomRequest + +* Sends a document: sendDocument + +* Sends a gif: sendGif + +* Sends a list of messages to all peers (users, chats, channels) of the bot: broadcastMessages + +* Sends a message to a chat: messages.sendMessage + +* Sends a message to all report peers (admins of the bot): sendMessageToAdmins + +* Sends a message with a file attachment to a secret chat: messages.sendEncryptedFile + +* Sends a message: sendMessage + +* Sends a photo: sendDocumentPhoto + +* Sends a photo: sendPhoto + +* Sends a service message to a secret chat: messages.sendEncryptedService + +* Sends a sticker: sendSticker + +* Sends a text message to a secret chat: messages.sendEncrypted + +* Sends a video: sendVideo + +* Sends a voice: sendVoice + +* Sends an audio: sendAudio + +* Sends an updateCustomEvent update to the event handler: sendCustomEvent + +* Set NOOP update handler, ignoring all updates: setNoop + +* Set a custom wallpaper » in a specific private chat with another user: messages.setChatWallPaper + +* Set account self-destruction period: account.setAccountTTL + +* Set an emoji status for a channel: channels.updateEmojiStatus + +* Set an emoji status: account.updateEmojiStatus + +* Set bot command list: bots.setBotCommands + +* Set global privacy settings: account.setGlobalPrivacySettings + +* Set localized name, about text and description of a bot (or of the current account, if called by a bot): bots.setBotInfo + +* Set maximum Time-To-Live of all messages in the specified chat: messages.setHistoryTTL + +* Set output file or stream for incoming OPUS audio packets in a call: callSetOutput + +* Set peer(s) where to send errors occurred in the event loop: setReportPeers + +* Set sensitive content settings (for viewing or hiding NSFW content): account.setContentSettings + +* Set stickerset thumbnail: stickers.setStickerSetThumb + +* Set the API ID UI template: setWebApiTemplate + +* Set the callback answer to a user button press (bots only): messages.setBotCallbackAnswer + +* Set the default peer that will be used to join a group call in a specific dialog: phone.saveDefaultGroupCallJoinAs + +* Set the default suggested admin rights for bots being added as admins to channels, see here for more info on how to handle them »: bots.setBotBroadcastDefaultAdminRights + +* Set the default suggested admin rights for bots being added as admins to groups, see here for more info on how to handle them »: bots.setBotGroupDefaultAdminRights + +* Set time-to-live of current session: account.setAuthorizationTTL + +* Set webhook update handler: setWebhook + +* Set whether all users should join a discussion group in order to comment on a post »: channels.toggleJoinToSend + +* Set whether all users should request admin approval to join the group »: channels.toggleJoinRequest + +* Sets the menu button action » for a given user or for all users: bots.setBotMenuButton + +* Should be called after the user hides the report spam/add as contact bar of a new chat, effectively prevents the user from executing the actions specified in the action bar »: messages.hidePeerSettingsBar + +* Show or hide the real-time chat translation popup for a certain chat: messages.togglePeerTranslations + +* Start a conversation with a bot using a deep linking parameter: messages.startBot + +* Start a scheduled group call: phone.startScheduledGroupCall + +* Start multiple instances of MadelineProto and the event handlers (enables async): startAndLoopMulti + +* Start or stop recording a group call: the recorded audio and video streams will be automatically sent to Saved messages (the chat with ourselves): phone.toggleGroupCallRecord + +* Start screen sharing in a call: phone.joinGroupCallPresentation + +* Stop getting notifications about discussion replies of a certain user in @replies: contacts.blockFromReplies + +* Stop screen sharing in a group call: phone.leaveGroupCallPresentation + +* Stop update loop: stop + +* Stops playing all files in the call, clears the main and the hold playlist: stopPlay + +* Store RSA keys for CDN datacenters: getCdnConfig + +* Submit requested order information for validation: payments.validateRequestedInfo + +* Subscribe or unsubscribe to a scheduled group call: phone.toggleGroupCallStartSubscription + +* Subscribe to event handler updates for a channel/supergroup we're not a member of: subscribeToUpdates + +* Suggests a short name for a given stickerpack name: stickers.suggestShortName + +* Telegram UTF-8 multibyte split: mbStrSplit + +* Telegram UTF-8 multibyte substring: mbSubstr + +* Terminate a group call: phone.discardGroupCall + +* Terminate a takeout session, see here » for more info: account.finishTakeoutSession + +* Terminate webview interaction started with messages.requestWebView, sending the specified message to the chat on behalf of the user: messages.sendWebViewResultMessage + +* Terminates all user's authorized sessions except for the current one: auth.resetAuthorizations + +* Test fibers: testFibers + +* Toggle contact sign up notifications: account.setContactSignUpNotification + +* Toggle supergroup slow mode: if enabled, users will only be able to send one message every seconds seconds: channels.toggleSlowMode + +* Transcribe voice message: messages.transcribeAudio + +* Transfer channel ownership: channels.editCreator + +* Translate a given text: messages.translateText + +* Turn a basic group into a supergroup: messages.migrateChat + +* Uninstall a stickerset: messages.uninstallStickerSet + +* Unpack base256 signed int: unpackSignedInt + +* Unpack base256 signed long to string: unpackSignedLongString + +* Unpack base256 signed long: unpackSignedLong + +* Unpack binary double: unpackDouble + +* Unpack bot API file ID: unpackFileId + +* Unpin all pinned messages: messages.unpinAllMessages + +* Unset event handler: unsetEventHandler + +* Update folder: messages.updateDialogFilter + +* Update the accent color and background custom emoji » of a channel: channels.updateColor + +* Update the accent color and background custom emoji » of the current account: account.updateColor + +* Update the keywords, emojis or mask coordinates of a sticker, bots only: stickers.changeSticker + +* Update theme: account.updateTheme + +* Updates current user profile photo: photos.uploadProfilePhoto + +* Updates online user status: account.updateStatus + +* Updates user profile: account.updateProfile + +* Upload a custom profile picture for a contact, or suggest a new profile picture to a contact: photos.uploadContactProfilePhoto + +* Upload a file and associate it to a chat (without actually sending it to the chat): messages.uploadMedia + +* Upload a media file associated with an imported chat, click here for more info »: messages.uploadImportedMedia + +* Upload encrypted file and associate it to a secret chat: messages.uploadEncryptedFile + +* Upload file from URL: uploadFromUrl + +* Upload file from callable: uploadFromCallable + +* Upload file from stream: uploadFromStream + +* Upload file to secret chat: uploadEncrypted + +* Upload file: upload + +* Upload notification sound, use account.saveRingtone to convert it and add it to the list of saved notification sounds: account.uploadRingtone + +* Upload theme: account.uploadTheme + +* Uploads a Telegram Story: stories.sendStory + +* Use this method to obtain the online statuses of all contacts with an accessible Telegram account: contacts.getStatuses + +* Use this method to set the score of the specified user in a game sent as a normal message (bots only): messages.setGameScore + +* Use this method to set the score of the specified user in a game sent as an inline message (bots only): messages.setInlineGameScore + +* Use this to accept a Seamless Telegram Login authorization request, for more info click here »: messages.acceptUrlAuth + +* Used by the user to relay data from an opened reply keyboard bot mini app to the bot that owns it: messages.sendWebViewData + +* Users may also choose to display messages from all topics of a forum as if they were sent to a normal group, using a "View as messages" setting in the local client: this setting only affects the current account, and is synced to other logged in sessions using this method: channels.toggleViewForumAsMessages + +* Validates a username and checks availability: account.checkUsername + +* Verify a new phone number to associate to the current account: account.sendChangePhoneCode + +* Verify a phone number for telegram passport: account.verifyPhone + +* Verify an email address: account.verifyEmail + +* Verify an email to use as 2FA recovery method: account.confirmPasswordEmail + +* View and search recently sent media.: messages.searchSentMedia + +* Vote in a poll: messages.sendVote + +* When called, skips to the next file in the playlist: skipPlay + +* When client-side passcode lock feature is enabled, will not show message texts in incoming PUSH notifications: account.updateDeviceLocked + +* When was full info for this chat last cached: fullChatLastUpdated + +* Whether the currently playing audio file is paused: isPlayPaused + +* Whether the user will receive notifications when contacts sign up: account.getContactSignUpNotification + +* Whether this is altervista: isAltervista + +* Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot: canConvertOgg + +* Whether we can convert any audio/video file using ffmpeg: canUseFFmpeg + +* Whether we're an IPC client instance: isIpc + +* Whether we're an IPC server process (as opposed to an event handler): isIpcWorker + +* Whether we're currently connected to the test DCs: isTestMode + +* Wrap a Message constructor into an abstract Message object: wrapMessage + +* Wrap a Pin constructor into an abstract Pinned object: wrapPin + +* Wrap a media constructor into an abstract Media object: wrapMedia + +* Wrap an Update constructor into an abstract Update object: wrapUpdate + +* You cannot use this method directly, instead modify the PFS and default_temp_auth_key_expires_in settings, see https://docs.madelineproto.xyz/docs/SETTINGS.html for more info: auth.bindTempAuthKey + +* You cannot use this method directly, instead use $MadelineProto->getDhConfig();: messages.getDhConfig + +* You cannot use this method directly, please use the event handler, instead: updates.getChannelDifference + +* You cannot use this method directly, please use the event handler, instead: updates.getDifference + +* You cannot use this method directly, please use the event handler, instead: updates.getState + +* You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats: messages.acceptEncryption + +* You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats: messages.discardEncryption + +* You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats: messages.requestEncryption + +* You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls: phone.acceptCall + +* You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls: phone.confirmCall + +* You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls: phone.discardCall + +* You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls: phone.requestCall + +* You cannot use this method directly, use $MadelineProto->exportAuthorization() instead, see https://docs.madelineproto.xyz/docs/LOGIN.html: auth.exportAuthorization + +* You cannot use this method directly, use $MadelineProto->importAuthorization($authorization) instead, see https://docs.madelineproto.xyz/docs/LOGIN.html: auth.importAuthorization + +* You cannot use this method directly, use the botLogin method instead (see https://docs.madelineproto.xyz for more info): auth.importBotAuthorization + +* You cannot use this method directly, use the complete2falogin method instead (see https://docs.madelineproto.xyz for more info): auth.checkPassword + +* You cannot use this method directly, use the completePhoneLogin method instead (see https://docs.madelineproto.xyz for more info): auth.signIn + +* You cannot use this method directly, use the completeSignup method instead (see https://docs.madelineproto.xyz for more info): auth.signUp + +* You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info): channels.getChannels + +* You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info): channels.getFullChannel + +* You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info): messages.getFullChat + +* You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info): users.getFullUser + +* You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info): users.getUsers + +* You cannot use this method directly, use the logout method instead (see https://docs.madelineproto.xyz for more info): auth.logOut + +* You cannot use this method directly, use the phoneLogin method instead (see https://docs.madelineproto.xyz for more info): auth.sendCode + +* You cannot use this method directly, use the resolveUsername, getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info): contacts.resolveUsername + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.getCdnFile + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.getCdnFileHashes + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.getFile + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.getFileHashes + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.reuploadCdnFile + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.saveBigFilePart + +* You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info: upload.saveFilePart + +* You cannot use this method directly: messages.receivedQueue + +* You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https://docs.madelineproto.xyz for more info): account.getPasswordSettings + +* You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https://docs.madelineproto.xyz for more info): account.updatePasswordSettings + +* account.createBusinessChatLink + +* account.deleteBusinessChatLink + +* account.disablePeerConnectedBot + +* account.editBusinessChatLink + +* account.getBotBusinessConnection + +* account.getBusinessChatLinks + +* account.getConnectedBots + +* account.getReactionsNotifySettings + +* account.resolveBusinessChatLink + +* account.setReactionsNotifySettings + +* account.toggleConnectedBotPaused + +* account.toggleSponsoredMessages + +* account.updateBirthday + +* account.updateBusinessAwayMessage + +* account.updateBusinessGreetingMessage + +* account.updateBusinessIntro + +* account.updateBusinessLocation + +* account.updateBusinessWorkHours + +* account.updateConnectedBot + +* account.updatePersonalChannel + +* auth.reportMissingCode + +* base64URL decode: base64urlDecode + +* channels.reportSponsoredMessage + +* channels.restrictSponsoredMessages + +* channels.setBoostsToUnblockRestrictions + +* channels.setEmojiStickers + +* contacts.getBirthdays + +* fragment.getCollectibleInfo + +* help.getTimezonesList + +* invokeWithBusinessConnection + +* messages.checkQuickReplyShortcut + +* messages.deleteQuickReplyMessages + +* messages.deleteQuickReplyShortcut + +* messages.editQuickReplyShortcut + +* messages.getDefaultTagReactions + +* messages.getEmojiStickerGroups + +* messages.getMyStickers + +* messages.getOutboxReadDate + +* messages.getQuickReplies + +* messages.getQuickReplyMessages + +* messages.getSavedReactionTags + +* messages.reorderQuickReplies + +* messages.sendQuickReplyMessages + +* messages.toggleDialogFilterTags + +* messages.updateSavedReactionTag + +* null-byte RLE decode: rleDecode + +* null-byte RLE encode: rleEncode + +* smsjobs.finishJob + +* smsjobs.getSmsJob + +* smsjobs.getStatus + +* smsjobs.isEligibleToJoin + +* smsjobs.join + +* smsjobs.leave + +* smsjobs.updateSettings + +* stats.getBroadcastRevenueStats + +* stats.getBroadcastRevenueTransactions + +* stats.getBroadcastRevenueWithdrawalUrl + +* stickers.replaceSticker + +* stories.togglePinnedToTop + +* users.getIsPremiumRequiredToContact + + diff --git a/docs/API_docs/methods/initConnection.md b/docs/API_docs/methods/initConnection.md new file mode 100644 index 0000000000..6992134b15 --- /dev/null +++ b/docs/API_docs/methods/initConnection.md @@ -0,0 +1,50 @@ +--- +title: "initConnection" +description: "Initialize connection" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: initConnection +[Back to methods index](index.html) + + + +Initialize connection + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|api\_id|[int](/API_docs/types/int.html) | Application identifier (see. [App configuration](https://core.telegram.org/myapp)) | Optional| +|device\_model|[string](/API_docs/types/string.html) | Device model | Optional| +|system\_version|[string](/API_docs/types/string.html) | Operation system version | Optional| +|app\_version|[string](/API_docs/types/string.html) | Application version | Optional| +|system\_lang\_code|[string](/API_docs/types/string.html) | Code for the language used on the device's OS, ISO 639-1 standard | Optional| +|lang\_pack|[string](/API_docs/types/string.html) | Language pack to use | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Code for the language used on the client, ISO 639-1 standard | Optional| +|proxy|[InputClientProxy](/API_docs/types/InputClientProxy.html) | Info about an MTProto proxy | Optional| +|params|[JSONValue](/API_docs/types/JSONValue.html) | Additional initConnection parameters.
For now, only the `tz_offset` field is supported, for specifying timezone offset in seconds. | Optional| +|query|[!X](/API_docs/types/!X.html) | The query itself | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->initConnection(api_id: $int, device_model: 'string', system_version: 'string', app_version: 'string', system_lang_code: 'string', lang_pack: 'string', lang_code: 'string', proxy: $InputClientProxy, params: $JSONValue, query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeAfterMsg.md b/docs/API_docs/methods/invokeAfterMsg.md new file mode 100644 index 0000000000..a5e7098b26 --- /dev/null +++ b/docs/API_docs/methods/invokeAfterMsg.md @@ -0,0 +1,42 @@ +--- +title: "invokeAfterMsg" +description: "Invokes a query after successful completion of one of the previous queries." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeAfterMsg +[Back to methods index](index.html) + + + +Invokes a query after successful completion of one of the previous queries. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|msg\_id|[long](/API_docs/types/long.html) | Message identifier on which a current query depends | Yes| +|query|[!X](/API_docs/types/!X.html) | The query itself | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeAfterMsg(msg_id: $long, query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeAfterMsgs.md b/docs/API_docs/methods/invokeAfterMsgs.md new file mode 100644 index 0000000000..8d0de73599 --- /dev/null +++ b/docs/API_docs/methods/invokeAfterMsgs.md @@ -0,0 +1,42 @@ +--- +title: "invokeAfterMsgs" +description: "Invokes a query after a successful completion of previous queries" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeAfterMsgs +[Back to methods index](index.html) + + + +Invokes a query after a successful completion of previous queries + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|msg\_ids|Array of [long](/API_docs/types/long.html) | List of messages on which a current query depends | Yes| +|query|[!X](/API_docs/types/!X.html) | The query itself | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeAfterMsgs(msg_ids: [$long, $long], query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeWithBusinessConnection.md b/docs/API_docs/methods/invokeWithBusinessConnection.md new file mode 100644 index 0000000000..25b2692fc3 --- /dev/null +++ b/docs/API_docs/methods/invokeWithBusinessConnection.md @@ -0,0 +1,40 @@ +--- +title: "invokeWithBusinessConnection" +description: "invokeWithBusinessConnection parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeWithBusinessConnection +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|connection\_id|[string](/API_docs/types/string.html) | Optional| +|query|[!X](/API_docs/types/!X.html) | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeWithBusinessConnection(connection_id: 'string', query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeWithLayer.md b/docs/API_docs/methods/invokeWithLayer.md new file mode 100644 index 0000000000..0ba8a01c75 --- /dev/null +++ b/docs/API_docs/methods/invokeWithLayer.md @@ -0,0 +1,42 @@ +--- +title: "invokeWithLayer" +description: "Invoke the specified query using the specified API [layer](https://core.telegram.org/api/invoking#layers)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeWithLayer +[Back to methods index](index.html) + + + +Invoke the specified query using the specified API [layer](https://core.telegram.org/api/invoking#layers) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|layer|[int](/API_docs/types/int.html) | The layer to use | Optional| +|query|[!X](/API_docs/types/!X.html) | The query | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeWithLayer(layer: $int, query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeWithMessagesRange.md b/docs/API_docs/methods/invokeWithMessagesRange.md new file mode 100644 index 0000000000..eaa6ccba6e --- /dev/null +++ b/docs/API_docs/methods/invokeWithMessagesRange.md @@ -0,0 +1,42 @@ +--- +title: "invokeWithMessagesRange" +description: "Invoke with the given message range" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeWithMessagesRange +[Back to methods index](index.html) + + + +Invoke with the given message range + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|range|[MessageRange](/API_docs/types/MessageRange.html) | Message range | Yes| +|query|[!X](/API_docs/types/!X.html) | Query | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeWithMessagesRange(range: $MessageRange, query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeWithTakeout.md b/docs/API_docs/methods/invokeWithTakeout.md new file mode 100644 index 0000000000..83d81bd627 --- /dev/null +++ b/docs/API_docs/methods/invokeWithTakeout.md @@ -0,0 +1,42 @@ +--- +title: "invokeWithTakeout" +description: "Invoke a method within a [takeout session, see here » for more info](https://core.telegram.org/api/takeout)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeWithTakeout +[Back to methods index](index.html) + + + +Invoke a method within a [takeout session, see here » for more info](https://core.telegram.org/api/takeout). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|takeout\_id|[long](/API_docs/types/long.html) | [Takeout session ID »](https://core.telegram.org/api/takeout) | Yes| +|query|[!X](/API_docs/types/!X.html) | Query | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeWithTakeout(takeout_id: $long, query: $!X, ); +``` + diff --git a/docs/API_docs/methods/invokeWithoutUpdates.md b/docs/API_docs/methods/invokeWithoutUpdates.md new file mode 100644 index 0000000000..6a440bd78e --- /dev/null +++ b/docs/API_docs/methods/invokeWithoutUpdates.md @@ -0,0 +1,41 @@ +--- +title: "invokeWithoutUpdates" +description: "Invoke a request without subscribing the used connection for [updates](https://core.telegram.org/api/updates) (this is enabled by default for [file queries](https://core.telegram.org/api/files))." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Method: invokeWithoutUpdates +[Back to methods index](index.html) + + + +Invoke a request without subscribing the used connection for [updates](https://core.telegram.org/api/updates) (this is enabled by default for [file queries](https://core.telegram.org/api/files)). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|query|[!X](/API_docs/types/!X.html) | The query | Yes| + + +### Return type: [X](/API_docs/types/X.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$X = $MadelineProto->invokeWithoutUpdates(query: $!X, ); +``` + diff --git a/docs/API_docs/methods/langpack.getDifference.md b/docs/API_docs/methods/langpack.getDifference.md new file mode 100644 index 0000000000..36889cf4e9 --- /dev/null +++ b/docs/API_docs/methods/langpack.getDifference.md @@ -0,0 +1,44 @@ +--- +title: "langpack.getDifference" +description: "Get new strings in language pack" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/langpack_getDifference.html +--- +# Method: langpack.getDifference +[Back to methods index](index.html) + + + +Get new strings in language pack + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_pack|[string](/API_docs/types/string.html) | Language pack | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| +|from\_version|[int](/API_docs/types/int.html) | Previous localization pack version | Optional| + + +### Return type: [LangPackDifference](/API_docs/types/LangPackDifference.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$LangPackDifference = $MadelineProto->langpack->getDifference(lang_pack: 'string', lang_code: 'string', from_version: $int, ); +``` + diff --git a/docs/API_docs/methods/langpack.getLangPack.md b/docs/API_docs/methods/langpack.getLangPack.md new file mode 100644 index 0000000000..0d2b3b3a0a --- /dev/null +++ b/docs/API_docs/methods/langpack.getLangPack.md @@ -0,0 +1,43 @@ +--- +title: "langpack.getLangPack" +description: "Get localization pack strings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/langpack_getLangPack.html +--- +# Method: langpack.getLangPack +[Back to methods index](index.html) + + + +Get localization pack strings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_pack|[string](/API_docs/types/string.html) | Language pack name, usually obtained from a [language pack link](https://core.telegram.org/api/links#language-pack-links) | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| + + +### Return type: [LangPackDifference](/API_docs/types/LangPackDifference.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$LangPackDifference = $MadelineProto->langpack->getLangPack(lang_pack: 'string', lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/langpack.getLanguage.md b/docs/API_docs/methods/langpack.getLanguage.md new file mode 100644 index 0000000000..6b6e475c1b --- /dev/null +++ b/docs/API_docs/methods/langpack.getLanguage.md @@ -0,0 +1,43 @@ +--- +title: "langpack.getLanguage" +description: "Get information about a language in a localization pack" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/langpack_getLanguage.html +--- +# Method: langpack.getLanguage +[Back to methods index](index.html) + + + +Get information about a language in a localization pack + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_pack|[string](/API_docs/types/string.html) | Language pack name, usually obtained from a [language pack link](https://core.telegram.org/api/links#language-pack-links) | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| + + +### Return type: [LangPackLanguage](/API_docs/types/LangPackLanguage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$LangPackLanguage = $MadelineProto->langpack->getLanguage(lang_pack: 'string', lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/langpack.getLanguages.md b/docs/API_docs/methods/langpack.getLanguages.md new file mode 100644 index 0000000000..588297f156 --- /dev/null +++ b/docs/API_docs/methods/langpack.getLanguages.md @@ -0,0 +1,42 @@ +--- +title: "langpack.getLanguages" +description: "Get information about all languages in a localization pack" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/langpack_getLanguages.html +--- +# Method: langpack.getLanguages +[Back to methods index](index.html) + + + +Get information about all languages in a localization pack + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_pack|[string](/API_docs/types/string.html) | Language pack | Optional| + + +### Return type: [Vector\_of\_LangPackLanguage](/API_docs/types/LangPackLanguage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_LangPackLanguage = $MadelineProto->langpack->getLanguages(lang_pack: 'string', ); +``` + diff --git a/docs/API_docs/methods/langpack.getStrings.md b/docs/API_docs/methods/langpack.getStrings.md new file mode 100644 index 0000000000..a990ba9a09 --- /dev/null +++ b/docs/API_docs/methods/langpack.getStrings.md @@ -0,0 +1,44 @@ +--- +title: "langpack.getStrings" +description: "Get strings from a language pack" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/langpack_getStrings.html +--- +# Method: langpack.getStrings +[Back to methods index](index.html) + + + +Get strings from a language pack + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_pack|[string](/API_docs/types/string.html) | Language pack name, usually obtained from a [language pack link](https://core.telegram.org/api/links#language-pack-links) | Optional| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| +|keys|Array of [string](/API_docs/types/string.html) | Strings to get | Yes| + + +### Return type: [Vector\_of\_LangPackString](/API_docs/types/LangPackString.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_LangPackString = $MadelineProto->langpack->getStrings(lang_pack: 'string', lang_code: 'string', keys: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/messages.acceptEncryption.md b/docs/API_docs/methods/messages.acceptEncryption.md new file mode 100644 index 0000000000..85da64e3c6 --- /dev/null +++ b/docs/API_docs/methods/messages.acceptEncryption.md @@ -0,0 +1,44 @@ +--- +title: "messages.acceptEncryption" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_acceptEncryption.html +--- +# Method: messages.acceptEncryption +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | Secret chat ID | Yes| +|g\_b|[bytes](/API_docs/types/bytes.html) | `B = g ^ b mod p`, see [Wikipedia](https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange) | Yes| +|key\_fingerprint|[strlong](/API_docs/constructors/strlong.html) | | Yes| + + +### Return type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EncryptedChat = $MadelineProto->messages->acceptEncryption(peer: $InputEncryptedChat, g_b: 'bytes', key_fingerprint: $strlong, ); +``` + diff --git a/docs/API_docs/methods/messages.acceptUrlAuth.md b/docs/API_docs/methods/messages.acceptUrlAuth.md new file mode 100644 index 0000000000..ef36418c5c --- /dev/null +++ b/docs/API_docs/methods/messages.acceptUrlAuth.md @@ -0,0 +1,46 @@ +--- +title: "messages.acceptUrlAuth" +description: "Use this to accept a Seamless Telegram Login authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_acceptUrlAuth.html +--- +# Method: messages.acceptUrlAuth +[Back to methods index](index.html) + + + +Use this to accept a Seamless Telegram Login authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|write\_allowed|[Bool](/API_docs/types/Bool.html) | Set this flag to allow the bot to send messages to you (if requested) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The location of the message | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID of the message with the login button | Optional| +|button\_id|[int](/API_docs/types/int.html) | ID of the login button | Optional| +|url|[string](/API_docs/types/string.html) | URL used for [link URL authorization, click here for more info »](https://core.telegram.org/api/url-authorization#link-url-authorization) | Optional| + + +### Return type: [UrlAuthResult](/API_docs/types/UrlAuthResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$UrlAuthResult = $MadelineProto->messages->acceptUrlAuth(write_allowed: $Bool, peer: $InputPeer, msg_id: $int, button_id: $int, url: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.addChatUser.md b/docs/API_docs/methods/messages.addChatUser.md new file mode 100644 index 0000000000..449d2a5c7a --- /dev/null +++ b/docs/API_docs/methods/messages.addChatUser.md @@ -0,0 +1,46 @@ +--- +title: "messages.addChatUser" +description: "Adds a user to a chat and sends a service message on it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_addChatUser.html +--- +# Method: messages.addChatUser +[Back to methods index](index.html) + + + +Adds a user to a chat and sends a service message on it. + +May also return 0-N updates of type [updateGroupInvitePrivacyForbidden](../constructors/updateGroupInvitePrivacyForbidden.html): it indicates we couldn't add a user to a chat because of their privacy settings; if required, an [invite link](https://core.telegram.org/api/invites) can be shared with the user, instead. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID to be added | Optional| +|fwd\_limit|[int](/API_docs/types/int.html) | Number of last messages to be forwarded | Optional| + + +### Return type: [messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_InvitedUsers = $MadelineProto->messages->addChatUser(chat_id: $InputPeer, user_id: $InputUser, fwd_limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.checkChatInvite.md b/docs/API_docs/methods/messages.checkChatInvite.md new file mode 100644 index 0000000000..d034c8561d --- /dev/null +++ b/docs/API_docs/methods/messages.checkChatInvite.md @@ -0,0 +1,42 @@ +--- +title: "messages.checkChatInvite" +description: "Check the validity of a chat invite link and get basic info about it" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_checkChatInvite.html +--- +# Method: messages.checkChatInvite +[Back to methods index](index.html) + + + +Check the validity of a chat invite link and get basic info about it + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|[string](/API_docs/types/string.html) | Invite hash from [chat invite deep link »](https://core.telegram.org/api/links#chat-invite-links). | Optional| + + +### Return type: [ChatInvite](/API_docs/types/ChatInvite.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ChatInvite = $MadelineProto->messages->checkChatInvite(hash: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.checkHistoryImport.md b/docs/API_docs/methods/messages.checkHistoryImport.md new file mode 100644 index 0000000000..88cebe5271 --- /dev/null +++ b/docs/API_docs/methods/messages.checkHistoryImport.md @@ -0,0 +1,42 @@ +--- +title: "messages.checkHistoryImport" +description: "Obtains information about a chat export file, generated by a foreign chat app, [click here for more info about imported chats »](https://core.telegram.org/api/import)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_checkHistoryImport.html +--- +# Method: messages.checkHistoryImport +[Back to methods index](index.html) + + + +Obtains information about a chat export file, generated by a foreign chat app, [click here for more info about imported chats »](https://core.telegram.org/api/import). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|import\_head|[string](/API_docs/types/string.html) | Beginning of the message file; up to 100 lines. | Optional| + + +### Return type: [messages.HistoryImportParsed](/API_docs/types/messages.HistoryImportParsed.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_HistoryImportParsed = $MadelineProto->messages->checkHistoryImport(import_head: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.checkHistoryImportPeer.md b/docs/API_docs/methods/messages.checkHistoryImportPeer.md new file mode 100644 index 0000000000..005e458c3a --- /dev/null +++ b/docs/API_docs/methods/messages.checkHistoryImportPeer.md @@ -0,0 +1,44 @@ +--- +title: "messages.checkHistoryImportPeer" +description: "Check whether chat history exported from another chat app can be [imported into a specific Telegram chat, click here for more info »](https://core.telegram.org/api/import)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_checkHistoryImportPeer.html +--- +# Method: messages.checkHistoryImportPeer +[Back to methods index](index.html) + + + +Check whether chat history exported from another chat app can be [imported into a specific Telegram chat, click here for more info »](https://core.telegram.org/api/import). + +If the check succeeds, and no RPC errors are returned, a [messages.CheckedHistoryImportPeer](../types/messages.CheckedHistoryImportPeer.html) constructor will be returned, with a confirmation text to be shown to the user, before actually initializing the import. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat where we want to [import history »](https://core.telegram.org/api/import). | Optional| + + +### Return type: [messages.CheckedHistoryImportPeer](/API_docs/types/messages.CheckedHistoryImportPeer.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_CheckedHistoryImportPeer = $MadelineProto->messages->checkHistoryImportPeer(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.checkQuickReplyShortcut.md b/docs/API_docs/methods/messages.checkQuickReplyShortcut.md new file mode 100644 index 0000000000..eaba9fabaa --- /dev/null +++ b/docs/API_docs/methods/messages.checkQuickReplyShortcut.md @@ -0,0 +1,40 @@ +--- +title: "messages.checkQuickReplyShortcut" +description: "messages.checkQuickReplyShortcut parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_checkQuickReplyShortcut.html +--- +# Method: messages.checkQuickReplyShortcut +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->checkQuickReplyShortcut(shortcut: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.clearAllDrafts.md b/docs/API_docs/methods/messages.clearAllDrafts.md new file mode 100644 index 0000000000..c85a412d84 --- /dev/null +++ b/docs/API_docs/methods/messages.clearAllDrafts.md @@ -0,0 +1,37 @@ +--- +title: "messages.clearAllDrafts" +description: "Clear all [drafts](https://core.telegram.org/api/drafts)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_clearAllDrafts.html +--- +# Method: messages.clearAllDrafts +[Back to methods index](index.html) + + + +Clear all [drafts](https://core.telegram.org/api/drafts). + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->clearAllDrafts(); +``` + diff --git a/docs/API_docs/methods/messages.clearRecentReactions.md b/docs/API_docs/methods/messages.clearRecentReactions.md new file mode 100644 index 0000000000..dee7fda215 --- /dev/null +++ b/docs/API_docs/methods/messages.clearRecentReactions.md @@ -0,0 +1,37 @@ +--- +title: "messages.clearRecentReactions" +description: "Clear recently used [message reactions](https://core.telegram.org/api/reactions)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_clearRecentReactions.html +--- +# Method: messages.clearRecentReactions +[Back to methods index](index.html) + + + +Clear recently used [message reactions](https://core.telegram.org/api/reactions) + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->clearRecentReactions(); +``` + diff --git a/docs/API_docs/methods/messages.clearRecentStickers.md b/docs/API_docs/methods/messages.clearRecentStickers.md new file mode 100644 index 0000000000..0a1e300020 --- /dev/null +++ b/docs/API_docs/methods/messages.clearRecentStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.clearRecentStickers" +description: "Clear recent stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_clearRecentStickers.html +--- +# Method: messages.clearRecentStickers +[Back to methods index](index.html) + + + +Clear recent stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|attached|[Bool](/API_docs/types/Bool.html) | Set this flag to clear the list of stickers recently attached to photo or video files | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->clearRecentStickers(attached: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.createChat.md b/docs/API_docs/methods/messages.createChat.md new file mode 100644 index 0000000000..0a376d48ed --- /dev/null +++ b/docs/API_docs/methods/messages.createChat.md @@ -0,0 +1,46 @@ +--- +title: "messages.createChat" +description: "Creates a new chat." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_createChat.html +--- +# Method: messages.createChat +[Back to methods index](index.html) + + + +Creates a new chat. + +May also return 0-N updates of type [updateGroupInvitePrivacyForbidden](../constructors/updateGroupInvitePrivacyForbidden.html): it indicates we couldn't add a user to a chat because of their privacy settings; if required, an [invite link](https://core.telegram.org/api/invites) can be shared with the user, instead. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | List of user IDs to be invited | Yes| +|title|[string](/API_docs/types/string.html) | Chat name | Optional| +|ttl\_period|[int](/API_docs/types/int.html) | Time-to-live of all messages that will be sent in the chat: once message.date+message.ttl\_period === time(), the message will be deleted on the server, and must be deleted locally as well. You can use [messages.setDefaultHistoryTTL](../methods/messages.setDefaultHistoryTTL.html) to edit this value later. | Optional| + + +### Return type: [messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_InvitedUsers = $MadelineProto->messages->createChat(users: [$InputUser, $InputUser], title: 'string', ttl_period: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteChat.md b/docs/API_docs/methods/messages.deleteChat.md new file mode 100644 index 0000000000..b375550f90 --- /dev/null +++ b/docs/API_docs/methods/messages.deleteChat.md @@ -0,0 +1,42 @@ +--- +title: "messages.deleteChat" +description: "Delete a [chat](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteChat.html +--- +# Method: messages.deleteChat +[Back to methods index](index.html) + + + +Delete a [chat](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->deleteChat(chat_id: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteChatUser.md b/docs/API_docs/methods/messages.deleteChatUser.md new file mode 100644 index 0000000000..157cd9a861 --- /dev/null +++ b/docs/API_docs/methods/messages.deleteChatUser.md @@ -0,0 +1,44 @@ +--- +title: "messages.deleteChatUser" +description: "Deletes a user from a chat and sends a service message on it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteChatUser.html +--- +# Method: messages.deleteChatUser +[Back to methods index](index.html) + + + +Deletes a user from a chat and sends a service message on it. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|revoke\_history|[Bool](/API_docs/types/Bool.html) | Remove the entire chat history of the specified user in this chat. | Optional| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID to be deleted | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->deleteChatUser(revoke_history: $Bool, chat_id: $InputPeer, user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteExportedChatInvite.md b/docs/API_docs/methods/messages.deleteExportedChatInvite.md new file mode 100644 index 0000000000..cd080710fa --- /dev/null +++ b/docs/API_docs/methods/messages.deleteExportedChatInvite.md @@ -0,0 +1,43 @@ +--- +title: "messages.deleteExportedChatInvite" +description: "Delete a chat invite" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteExportedChatInvite.html +--- +# Method: messages.deleteExportedChatInvite +[Back to methods index](index.html) + + + +Delete a chat invite + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|link|[string](/API_docs/types/string.html) | Invite link | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->deleteExportedChatInvite(peer: $InputPeer, link: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.deleteHistory.md b/docs/API_docs/methods/messages.deleteHistory.md new file mode 100644 index 0000000000..56930114ff --- /dev/null +++ b/docs/API_docs/methods/messages.deleteHistory.md @@ -0,0 +1,47 @@ +--- +title: "messages.deleteHistory" +description: "Deletes communication history." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteHistory.html +--- +# Method: messages.deleteHistory +[Back to methods index](index.html) + + + +Deletes communication history. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|just\_clear|[Bool](/API_docs/types/Bool.html) | Just clear history for the current user, without actually removing messages for every chat user | Optional| +|revoke|[Bool](/API_docs/types/Bool.html) | Whether to delete the message history for all chat participants | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | User or chat, communication history of which will be deleted | Optional| +|max\_id|[int](/API_docs/types/int.html) | Maximum ID of message to delete | Optional| +|min\_date|[int](/API_docs/types/int.html) | Delete all messages newer than this UNIX timestamp | Optional| +|max\_date|[int](/API_docs/types/int.html) | Delete all messages older than this UNIX timestamp | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->messages->deleteHistory(just_clear: $Bool, revoke: $Bool, peer: $InputPeer, max_id: $int, min_date: $int, max_date: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteMessages.md b/docs/API_docs/methods/messages.deleteMessages.md new file mode 100644 index 0000000000..9113ad179e --- /dev/null +++ b/docs/API_docs/methods/messages.deleteMessages.md @@ -0,0 +1,43 @@ +--- +title: "messages.deleteMessages" +description: "Deletes messages by their identifiers." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteMessages.html +--- +# Method: messages.deleteMessages +[Back to methods index](index.html) + + + +Deletes messages by their identifiers. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|revoke|[Bool](/API_docs/types/Bool.html) | Whether to delete messages for all participants of the chat | Optional| +|id|Array of [int](/API_docs/types/int.html) | Message ID list | Yes| + + +### Return type: [messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedMessages = $MadelineProto->messages->deleteMessages(revoke: $Bool, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.deletePhoneCallHistory.md b/docs/API_docs/methods/messages.deletePhoneCallHistory.md new file mode 100644 index 0000000000..52353a33ab --- /dev/null +++ b/docs/API_docs/methods/messages.deletePhoneCallHistory.md @@ -0,0 +1,42 @@ +--- +title: "messages.deletePhoneCallHistory" +description: "Delete the entire phone call history." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deletePhoneCallHistory.html +--- +# Method: messages.deletePhoneCallHistory +[Back to methods index](index.html) + + + +Delete the entire phone call history. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|revoke|[Bool](/API_docs/types/Bool.html) | Whether to remove phone call history for participants as well | Optional| + + +### Return type: [messages.AffectedFoundMessages](/API_docs/types/messages.AffectedFoundMessages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedFoundMessages = $MadelineProto->messages->deletePhoneCallHistory(revoke: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteQuickReplyMessages.md b/docs/API_docs/methods/messages.deleteQuickReplyMessages.md new file mode 100644 index 0000000000..25e9706534 --- /dev/null +++ b/docs/API_docs/methods/messages.deleteQuickReplyMessages.md @@ -0,0 +1,41 @@ +--- +title: "messages.deleteQuickReplyMessages" +description: "messages.deleteQuickReplyMessages parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteQuickReplyMessages.html +--- +# Method: messages.deleteQuickReplyMessages +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Optional| +|id|Array of [int](/API_docs/types/int.html) | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->deleteQuickReplyMessages(shortcut_id: $int, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.deleteQuickReplyShortcut.md b/docs/API_docs/methods/messages.deleteQuickReplyShortcut.md new file mode 100644 index 0000000000..aa6c529ec4 --- /dev/null +++ b/docs/API_docs/methods/messages.deleteQuickReplyShortcut.md @@ -0,0 +1,40 @@ +--- +title: "messages.deleteQuickReplyShortcut" +description: "messages.deleteQuickReplyShortcut parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteQuickReplyShortcut.html +--- +# Method: messages.deleteQuickReplyShortcut +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->deleteQuickReplyShortcut(shortcut_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteRevokedExportedChatInvites.md b/docs/API_docs/methods/messages.deleteRevokedExportedChatInvites.md new file mode 100644 index 0000000000..e6670912f5 --- /dev/null +++ b/docs/API_docs/methods/messages.deleteRevokedExportedChatInvites.md @@ -0,0 +1,43 @@ +--- +title: "messages.deleteRevokedExportedChatInvites" +description: "Delete all revoked chat invites" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteRevokedExportedChatInvites.html +--- +# Method: messages.deleteRevokedExportedChatInvites +[Back to methods index](index.html) + + + +Delete all revoked chat invites + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| +|admin\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | ID of the admin that originally generated the revoked chat invites | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->deleteRevokedExportedChatInvites(peer: $InputPeer, admin_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteSavedHistory.md b/docs/API_docs/methods/messages.deleteSavedHistory.md new file mode 100644 index 0000000000..4b33fc1c3c --- /dev/null +++ b/docs/API_docs/methods/messages.deleteSavedHistory.md @@ -0,0 +1,45 @@ +--- +title: "messages.deleteSavedHistory" +description: "Deletes messages forwarded from a specific peer to [saved messages »](https://core.telegram.org/api/saved-messages)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteSavedHistory.html +--- +# Method: messages.deleteSavedHistory +[Back to methods index](index.html) + + + +Deletes messages forwarded from a specific peer to [saved messages »](https://core.telegram.org/api/saved-messages). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer, whose messages will be deleted from [saved messages »](https://core.telegram.org/api/saved-messages) | Optional| +|max\_id|[int](/API_docs/types/int.html) | Maximum ID of message to delete | Optional| +|min\_date|[int](/API_docs/types/int.html) | Delete all messages newer than this UNIX timestamp | Optional| +|max\_date|[int](/API_docs/types/int.html) | Delete all messages older than this UNIX timestamp | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->messages->deleteSavedHistory(peer: $InputPeer, max_id: $int, min_date: $int, max_date: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.deleteScheduledMessages.md b/docs/API_docs/methods/messages.deleteScheduledMessages.md new file mode 100644 index 0000000000..a59309e131 --- /dev/null +++ b/docs/API_docs/methods/messages.deleteScheduledMessages.md @@ -0,0 +1,43 @@ +--- +title: "messages.deleteScheduledMessages" +description: "Delete scheduled messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_deleteScheduledMessages.html +--- +# Method: messages.deleteScheduledMessages +[Back to methods index](index.html) + + + +Delete scheduled messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|Array of [int](/API_docs/types/int.html) | Scheduled message IDs | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->deleteScheduledMessages(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.discardEncryption.md b/docs/API_docs/methods/messages.discardEncryption.md new file mode 100644 index 0000000000..c6d544da1b --- /dev/null +++ b/docs/API_docs/methods/messages.discardEncryption.md @@ -0,0 +1,43 @@ +--- +title: "messages.discardEncryption" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_discardEncryption.html +--- +# Method: messages.discardEncryption +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|delete\_history|[Bool](/API_docs/types/Bool.html) | Whether to delete the entire chat history for the other user as well | Optional| +|chat\_id|[int](/API_docs/types/int.html) | Secret chat ID | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->discardEncryption(delete_history: $Bool, chat_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.editChatAbout.md b/docs/API_docs/methods/messages.editChatAbout.md new file mode 100644 index 0000000000..5859f49257 --- /dev/null +++ b/docs/API_docs/methods/messages.editChatAbout.md @@ -0,0 +1,43 @@ +--- +title: "messages.editChatAbout" +description: "Edit the description of a [group/supergroup/channel](https://core.telegram.org/api/channel)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editChatAbout.html +--- +# Method: messages.editChatAbout +[Back to methods index](index.html) + + + +Edit the description of a [group/supergroup/channel](https://core.telegram.org/api/channel). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The [group/supergroup/channel](https://core.telegram.org/api/channel). | Optional| +|about|[string](/API_docs/types/string.html) | The new description | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->editChatAbout(peer: $InputPeer, about: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.editChatAdmin.md b/docs/API_docs/methods/messages.editChatAdmin.md new file mode 100644 index 0000000000..0d7f62a92f --- /dev/null +++ b/docs/API_docs/methods/messages.editChatAdmin.md @@ -0,0 +1,44 @@ +--- +title: "messages.editChatAdmin" +description: "Make a user admin in a [basic group](https://core.telegram.org/api/channel#basic-groups)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editChatAdmin.html +--- +# Method: messages.editChatAdmin +[Back to methods index](index.html) + + + +Make a user admin in a [basic group](https://core.telegram.org/api/channel#basic-groups). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The user to make admin | Optional| +|is\_admin|[Bool](/API_docs/types/Bool.html) | Whether to make them admin | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->editChatAdmin(chat_id: $InputPeer, user_id: $InputUser, is_admin: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.editChatDefaultBannedRights.md b/docs/API_docs/methods/messages.editChatDefaultBannedRights.md new file mode 100644 index 0000000000..10b080c87f --- /dev/null +++ b/docs/API_docs/methods/messages.editChatDefaultBannedRights.md @@ -0,0 +1,43 @@ +--- +title: "messages.editChatDefaultBannedRights" +description: "Edit the default banned rights of a [channel/supergroup/group](https://core.telegram.org/api/channel)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editChatDefaultBannedRights.html +--- +# Method: messages.editChatDefaultBannedRights +[Back to methods index](index.html) + + + +Edit the default banned rights of a [channel/supergroup/group](https://core.telegram.org/api/channel). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer | Optional| +|banned\_rights|[ChatBannedRights](/API_docs/types/ChatBannedRights.html) | The new global rights | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->editChatDefaultBannedRights(peer: $InputPeer, banned_rights: $ChatBannedRights, ); +``` + diff --git a/docs/API_docs/methods/messages.editChatPhoto.md b/docs/API_docs/methods/messages.editChatPhoto.md new file mode 100644 index 0000000000..0227da9dda --- /dev/null +++ b/docs/API_docs/methods/messages.editChatPhoto.md @@ -0,0 +1,43 @@ +--- +title: "messages.editChatPhoto" +description: "Changes chat photo and sends a service message on it" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editChatPhoto.html +--- +# Method: messages.editChatPhoto +[Back to methods index](index.html) + + + +Changes chat photo and sends a service message on it + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| +|photo|[InputChatPhoto](/API_docs/types/InputChatPhoto.html) | Photo to be set | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->editChatPhoto(chat_id: $InputPeer, photo: $InputChatPhoto, ); +``` + diff --git a/docs/API_docs/methods/messages.editChatTitle.md b/docs/API_docs/methods/messages.editChatTitle.md new file mode 100644 index 0000000000..5a530086d9 --- /dev/null +++ b/docs/API_docs/methods/messages.editChatTitle.md @@ -0,0 +1,43 @@ +--- +title: "messages.editChatTitle" +description: "Changes chat name and sends a service message on it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editChatTitle.html +--- +# Method: messages.editChatTitle +[Back to methods index](index.html) + + + +Changes chat name and sends a service message on it. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| +|title|[string](/API_docs/types/string.html) | New chat name, different from the old one | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->editChatTitle(chat_id: $InputPeer, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.editExportedChatInvite.md b/docs/API_docs/methods/messages.editExportedChatInvite.md new file mode 100644 index 0000000000..6f44b5074c --- /dev/null +++ b/docs/API_docs/methods/messages.editExportedChatInvite.md @@ -0,0 +1,48 @@ +--- +title: "messages.editExportedChatInvite" +description: "Edit an exported chat invite" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editExportedChatInvite.html +--- +# Method: messages.editExportedChatInvite +[Back to methods index](index.html) + + + +Edit an exported chat invite + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|revoked|[Bool](/API_docs/types/Bool.html) | Whether to revoke the chat invite | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| +|link|[string](/API_docs/types/string.html) | Invite link | Optional| +|expire\_date|[int](/API_docs/types/int.html) | New expiration date | Optional| +|usage\_limit|[int](/API_docs/types/int.html) | Maximum number of users that can join using this link | Optional| +|request\_needed|[Bool](/API_docs/types/Bool.html) | Whether admin confirmation is required before admitting each separate user into the chat | Optional| +|title|[string](/API_docs/types/string.html) | Description of the invite link, visible only to administrators | Optional| + + +### Return type: [messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ExportedChatInvite = $MadelineProto->messages->editExportedChatInvite(revoked: $Bool, peer: $InputPeer, link: 'string', expire_date: $int, usage_limit: $int, request_needed: $Bool, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.editInlineBotMessage.md b/docs/API_docs/methods/messages.editInlineBotMessage.md new file mode 100644 index 0000000000..e2c1645578 --- /dev/null +++ b/docs/API_docs/methods/messages.editInlineBotMessage.md @@ -0,0 +1,121 @@ +--- +title: "messages.editInlineBotMessage" +description: "Edit an inline bot message" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editInlineBotMessage.html +--- +# Method: messages.editInlineBotMessage +[Back to methods index](index.html) + + + +Edit an inline bot message + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Disable webpage preview | Optional| +|invert\_media|[Bool](/API_docs/types/Bool.html) | If set, any eventual webpage preview will be shown on top of the message instead of at the bottom. | Optional| +|id|[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) | Sent inline message ID | Yes| +|message|[string](/API_docs/types/string.html) | Message | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | Media | Optional| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Reply markup for inline keyboards | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | [Message entities for styled text](https://core.telegram.org/api/entities) | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->editInlineBotMessage(no_webpage: $Bool, invert_media: $Bool, id: $InputBotInlineMessageID, message: 'string', media: $InputMedia, reply_markup: $ReplyMarkup, entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', ); +``` + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/messages.editMessage.md b/docs/API_docs/methods/messages.editMessage.md new file mode 100644 index 0000000000..42b371241b --- /dev/null +++ b/docs/API_docs/methods/messages.editMessage.md @@ -0,0 +1,124 @@ +--- +title: "messages.editMessage" +description: "Edit message" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editMessage.html +--- +# Method: messages.editMessage +[Back to methods index](index.html) + + + +Edit message + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Disable webpage preview | Optional| +|invert\_media|[Bool](/API_docs/types/Bool.html) | If set, any eventual webpage preview will be shown on top of the message instead of at the bottom. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Where was the message sent | Optional| +|id|[int](/API_docs/types/int.html) | ID of the message to edit | Optional| +|message|[string](/API_docs/types/string.html) | New message | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | New attached media | Optional| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Reply markup for inline keyboards | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | [Message entities for styled text](https://core.telegram.org/api/entities) | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|schedule\_date|[int](/API_docs/types/int.html) | Scheduled message date for [scheduled messages](https://core.telegram.org/api/scheduled-messages) | Optional| +|quick\_reply\_shortcut\_id|[int](/API_docs/types/int.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->editMessage(no_webpage: $Bool, invert_media: $Bool, peer: $InputPeer, id: $int, message: 'string', media: $InputMedia, reply_markup: $ReplyMarkup, entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', schedule_date: $int, quick_reply_shortcut_id: $int, ); +``` + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Updates](../types/Updates.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/messages.editQuickReplyShortcut.md b/docs/API_docs/methods/messages.editQuickReplyShortcut.md new file mode 100644 index 0000000000..cbf3d56a14 --- /dev/null +++ b/docs/API_docs/methods/messages.editQuickReplyShortcut.md @@ -0,0 +1,41 @@ +--- +title: "messages.editQuickReplyShortcut" +description: "messages.editQuickReplyShortcut parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_editQuickReplyShortcut.html +--- +# Method: messages.editQuickReplyShortcut +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Optional| +|shortcut|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->editQuickReplyShortcut(shortcut_id: $int, shortcut: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.exportChatInvite.md b/docs/API_docs/methods/messages.exportChatInvite.md new file mode 100644 index 0000000000..326e6522a2 --- /dev/null +++ b/docs/API_docs/methods/messages.exportChatInvite.md @@ -0,0 +1,47 @@ +--- +title: "messages.exportChatInvite" +description: "Export an invite link for a chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_exportChatInvite.html +--- +# Method: messages.exportChatInvite +[Back to methods index](index.html) + + + +Export an invite link for a chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|legacy\_revoke\_permanent|[Bool](/API_docs/types/Bool.html) | Legacy flag, reproducing legacy behavior of this method: if set, revokes all previous links before creating a new one. Kept for bot API BC, should not be used by modern clients. | Optional| +|request\_needed|[Bool](/API_docs/types/Bool.html) | Whether admin confirmation is required before admitting each separate user into the chat | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| +|expire\_date|[int](/API_docs/types/int.html) | Expiration date | Optional| +|usage\_limit|[int](/API_docs/types/int.html) | Maximum number of users that can join using this link | Optional| +|title|[string](/API_docs/types/string.html) | Description of the invite link, visible only to administrators | Optional| + + +### Return type: [ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ExportedChatInvite = $MadelineProto->messages->exportChatInvite(legacy_revoke_permanent: $Bool, request_needed: $Bool, peer: $InputPeer, expire_date: $int, usage_limit: $int, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.faveSticker.md b/docs/API_docs/methods/messages.faveSticker.md new file mode 100644 index 0000000000..c96d7dc296 --- /dev/null +++ b/docs/API_docs/methods/messages.faveSticker.md @@ -0,0 +1,43 @@ +--- +title: "messages.faveSticker" +description: "Mark or unmark a sticker as favorite" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_faveSticker.html +--- +# Method: messages.faveSticker +[Back to methods index](index.html) + + + +Mark or unmark a sticker as favorite + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Sticker in question | Optional| +|unfave|[Bool](/API_docs/types/Bool.html) | Whether to add or remove a sticker from favorites | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->faveSticker(id: $InputDocument, unfave: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.forwardMessages.md b/docs/API_docs/methods/messages.forwardMessages.md new file mode 100644 index 0000000000..aa34cda693 --- /dev/null +++ b/docs/API_docs/methods/messages.forwardMessages.md @@ -0,0 +1,54 @@ +--- +title: "messages.forwardMessages" +description: "Forwards messages by their IDs." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_forwardMessages.html +--- +# Method: messages.forwardMessages +[Back to methods index](index.html) + + + +Forwards messages by their IDs. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Whether to send messages silently (no notification will be triggered on the destination clients) | Optional| +|background|[Bool](/API_docs/types/Bool.html) | Whether to send the message in background | Optional| +|with\_my\_score|[Bool](/API_docs/types/Bool.html) | When forwarding games, whether to include your score in the game | Optional| +|drop\_author|[Bool](/API_docs/types/Bool.html) | Whether to forward messages without quoting the original author | Optional| +|drop\_media\_captions|[Bool](/API_docs/types/Bool.html) | Whether to strip captions from media | Optional| +|noforwards|[Bool](/API_docs/types/Bool.html) | Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn't have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled | Optional| +|from\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Source of messages | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of messages | Yes| +|to\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Destination peer | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) | Optional| +|schedule\_date|[int](/API_docs/types/int.html) | Scheduled message date for scheduled messages | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Forward the messages as the specified peer | Optional| +|quick\_reply\_shortcut|[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->forwardMessages(silent: $Bool, background: $Bool, with_my_score: $Bool, drop_author: $Bool, drop_media_captions: $Bool, noforwards: $Bool, from_peer: $InputPeer, id: [$int, $int], to_peer: $InputPeer, top_msg_id: $int, schedule_date: $int, send_as: $InputPeer, quick_reply_shortcut: $InputQuickReplyShortcut, ); +``` + diff --git a/docs/API_docs/methods/messages.getAdminsWithInvites.md b/docs/API_docs/methods/messages.getAdminsWithInvites.md new file mode 100644 index 0000000000..3b905b33d5 --- /dev/null +++ b/docs/API_docs/methods/messages.getAdminsWithInvites.md @@ -0,0 +1,42 @@ +--- +title: "messages.getAdminsWithInvites" +description: "Get info about chat invites generated by admins." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAdminsWithInvites.html +--- +# Method: messages.getAdminsWithInvites +[Back to methods index](index.html) + + + +Get info about chat invites generated by admins. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| + + +### Return type: [messages.ChatAdminsWithInvites](/API_docs/types/messages.ChatAdminsWithInvites.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ChatAdminsWithInvites = $MadelineProto->messages->getAdminsWithInvites(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.getAllDrafts.md b/docs/API_docs/methods/messages.getAllDrafts.md new file mode 100644 index 0000000000..2bc09ec80a --- /dev/null +++ b/docs/API_docs/methods/messages.getAllDrafts.md @@ -0,0 +1,38 @@ +--- +title: "messages.getAllDrafts" +description: "Return all message [drafts](https://core.telegram.org/api/drafts). " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAllDrafts.html +--- +# Method: messages.getAllDrafts +[Back to methods index](index.html) + + + +Return all message [drafts](https://core.telegram.org/api/drafts). +Returns all the latest [updateDraftMessage](../constructors/updateDraftMessage.html) updates related to all chats with drafts. + + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->getAllDrafts(); +``` + diff --git a/docs/API_docs/methods/messages.getAllStickers.md b/docs/API_docs/methods/messages.getAllStickers.md new file mode 100644 index 0000000000..217127ad9e --- /dev/null +++ b/docs/API_docs/methods/messages.getAllStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getAllStickers" +description: "Get all installed stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAllStickers.html +--- +# Method: messages.getAllStickers +[Back to methods index](index.html) + + + +Get all installed stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AllStickers = $MadelineProto->messages->getAllStickers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getArchivedStickers.md b/docs/API_docs/methods/messages.getArchivedStickers.md new file mode 100644 index 0000000000..987e4898a6 --- /dev/null +++ b/docs/API_docs/methods/messages.getArchivedStickers.md @@ -0,0 +1,45 @@ +--- +title: "messages.getArchivedStickers" +description: "Get all archived stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getArchivedStickers.html +--- +# Method: messages.getArchivedStickers +[Back to methods index](index.html) + + + +Get all archived stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|masks|[Bool](/API_docs/types/Bool.html) | Get [mask stickers](https://core.telegram.org/api/stickers#mask-stickers) | Optional| +|emojis|[Bool](/API_docs/types/Bool.html) | Get [custom emoji stickers](https://core.telegram.org/api/custom-emoji) | Optional| +|offset\_id|[long](/API_docs/types/long.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Yes| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.ArchivedStickers](/API_docs/types/messages.ArchivedStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ArchivedStickers = $MadelineProto->messages->getArchivedStickers(masks: $Bool, emojis: $Bool, offset_id: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getAttachMenuBot.md b/docs/API_docs/methods/messages.getAttachMenuBot.md new file mode 100644 index 0000000000..770eb5f740 --- /dev/null +++ b/docs/API_docs/methods/messages.getAttachMenuBot.md @@ -0,0 +1,42 @@ +--- +title: "messages.getAttachMenuBot" +description: "Returns attachment menu entry for a [bot mini app that can be launched from the attachment menu »](https://core.telegram.org/api/bots/attach)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAttachMenuBot.html +--- +# Method: messages.getAttachMenuBot +[Back to methods index](index.html) + + + +Returns attachment menu entry for a [bot mini app that can be launched from the attachment menu »](https://core.telegram.org/api/bots/attach) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Bot ID | Optional| + + +### Return type: [AttachMenuBotsBot](/API_docs/types/AttachMenuBotsBot.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$AttachMenuBotsBot = $MadelineProto->messages->getAttachMenuBot(bot: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/messages.getAttachMenuBots.md b/docs/API_docs/methods/messages.getAttachMenuBots.md new file mode 100644 index 0000000000..ae8ced0562 --- /dev/null +++ b/docs/API_docs/methods/messages.getAttachMenuBots.md @@ -0,0 +1,42 @@ +--- +title: "messages.getAttachMenuBots" +description: "Returns installed attachment menu [bot mini apps »](https://core.telegram.org/api/bots/attach)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAttachMenuBots.html +--- +# Method: messages.getAttachMenuBots +[Back to methods index](index.html) + + + +Returns installed attachment menu [bot mini apps »](https://core.telegram.org/api/bots/attach) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [AttachMenuBots](/API_docs/types/AttachMenuBots.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$AttachMenuBots = $MadelineProto->messages->getAttachMenuBots(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getAttachedStickers.md b/docs/API_docs/methods/messages.getAttachedStickers.md new file mode 100644 index 0000000000..8f4f3b39be --- /dev/null +++ b/docs/API_docs/methods/messages.getAttachedStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getAttachedStickers" +description: "Get stickers attached to a photo or video" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAttachedStickers.html +--- +# Method: messages.getAttachedStickers +[Back to methods index](index.html) + + + +Get stickers attached to a photo or video + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|media|[InputStickeredMedia](/API_docs/types/InputStickeredMedia.html) | Stickered media | Yes| + + +### Return type: [Vector\_of\_StickerSetCovered](/API_docs/types/StickerSetCovered.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_StickerSetCovered = $MadelineProto->messages->getAttachedStickers(media: $InputStickeredMedia, ); +``` + diff --git a/docs/API_docs/methods/messages.getAvailableReactions.md b/docs/API_docs/methods/messages.getAvailableReactions.md new file mode 100644 index 0000000000..e6e0ca804d --- /dev/null +++ b/docs/API_docs/methods/messages.getAvailableReactions.md @@ -0,0 +1,42 @@ +--- +title: "messages.getAvailableReactions" +description: "Obtain available [message reactions »](https://core.telegram.org/api/reactions)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getAvailableReactions.html +--- +# Method: messages.getAvailableReactions +[Back to methods index](index.html) + + + +Obtain available [message reactions »](https://core.telegram.org/api/reactions) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [messages.AvailableReactions](/API_docs/types/messages.AvailableReactions.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AvailableReactions = $MadelineProto->messages->getAvailableReactions(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getBotApp.md b/docs/API_docs/methods/messages.getBotApp.md new file mode 100644 index 0000000000..9fa4d2b1ce --- /dev/null +++ b/docs/API_docs/methods/messages.getBotApp.md @@ -0,0 +1,43 @@ +--- +title: "messages.getBotApp" +description: "Obtain information about a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getBotApp.html +--- +# Method: messages.getBotApp +[Back to methods index](index.html) + + + +Obtain information about a [direct link Mini App](https://core.telegram.org/api/bots/webapps#direct-link-mini-apps) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|app|[InputBotApp](/API_docs/types/InputBotApp.html) | Bot app information obtained from a [Direct Mini App deep link »](https://core.telegram.org/api/links#direct-mini-app-links). | Yes| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.BotApp](/API_docs/types/messages.BotApp.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_BotApp = $MadelineProto->messages->getBotApp(app: $InputBotApp, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getBotCallbackAnswer.md b/docs/API_docs/methods/messages.getBotCallbackAnswer.md new file mode 100644 index 0000000000..532b7900e5 --- /dev/null +++ b/docs/API_docs/methods/messages.getBotCallbackAnswer.md @@ -0,0 +1,46 @@ +--- +title: "messages.getBotCallbackAnswer" +description: "Press an inline callback button and get a callback answer from the bot" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getBotCallbackAnswer.html +--- +# Method: messages.getBotCallbackAnswer +[Back to methods index](index.html) + + + +Press an inline callback button and get a callback answer from the bot + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|game|[Bool](/API_docs/types/Bool.html) | Whether this is a "play game" button | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Where was the inline keyboard sent | Optional| +|msg\_id|[int](/API_docs/types/int.html) | ID of the Message with the inline keyboard | Optional| +|data|[bytes](/API_docs/types/bytes.html) | Callback data | Optional| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | For buttons [requiring you to verify your identity with your 2FA password](../constructors/keyboardButtonCallback.html), the SRP payload generated using [SRP](https://core.telegram.org/api/srp). | Optional| + + +### Return type: [messages.BotCallbackAnswer](/API_docs/types/messages.BotCallbackAnswer.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_BotCallbackAnswer = $MadelineProto->messages->getBotCallbackAnswer(game: $Bool, peer: $InputPeer, msg_id: $int, data: 'bytes', password: $InputCheckPasswordSRP, ); +``` + diff --git a/docs/API_docs/methods/messages.getChatInviteImporters.md b/docs/API_docs/methods/messages.getChatInviteImporters.md new file mode 100644 index 0000000000..5d72516b54 --- /dev/null +++ b/docs/API_docs/methods/messages.getChatInviteImporters.md @@ -0,0 +1,48 @@ +--- +title: "messages.getChatInviteImporters" +description: "Get info about the users that joined the chat using a specific chat invite" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getChatInviteImporters.html +--- +# Method: messages.getChatInviteImporters +[Back to methods index](index.html) + + + +Get info about the users that joined the chat using a specific chat invite + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|requested|[Bool](/API_docs/types/Bool.html) | If set, only returns info about users with pending [join requests »](https://core.telegram.org/api/invites#join-requests) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| +|link|[string](/API_docs/types/string.html) | Invite link | Optional| +|q|[string](/API_docs/types/string.html) | Search for a user in the pending [join requests »](https://core.telegram.org/api/invites#join-requests) list: only available when the `requested` flag is set, cannot be used together with a specific `link`. | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_user|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID for [pagination](https://core.telegram.org/api/offsets): if set, `offset_date` must also be set. | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.ChatInviteImporters](/API_docs/types/messages.ChatInviteImporters.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ChatInviteImporters = $MadelineProto->messages->getChatInviteImporters(requested: $Bool, peer: $InputPeer, link: 'string', q: 'string', offset_date: $int, offset_user: $InputUser, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getChats.md b/docs/API_docs/methods/messages.getChats.md new file mode 100644 index 0000000000..d1347ae6ed --- /dev/null +++ b/docs/API_docs/methods/messages.getChats.md @@ -0,0 +1,42 @@ +--- +title: "messages.getChats" +description: "Returns chat basic info on their IDs." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getChats.html +--- +# Method: messages.getChats +[Back to methods index](index.html) + + + +Returns chat basic info on their IDs. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [long](/API_docs/types/long.html) | List of chat IDs | Yes| + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->messages->getChats(id: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getCommonChats.md b/docs/API_docs/methods/messages.getCommonChats.md new file mode 100644 index 0000000000..75c3eafab9 --- /dev/null +++ b/docs/API_docs/methods/messages.getCommonChats.md @@ -0,0 +1,44 @@ +--- +title: "messages.getCommonChats" +description: "Get chats in common with a user" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getCommonChats.html +--- +# Method: messages.getCommonChats +[Back to methods index](index.html) + + + +Get chats in common with a user + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID | Optional| +|max\_id|[long](/API_docs/types/long.html) | Maximum ID of chat to return (see [pagination](https://core.telegram.org/api/offsets)) | Yes| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->messages->getCommonChats(user_id: $InputUser, max_id: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getCustomEmojiDocuments.md b/docs/API_docs/methods/messages.getCustomEmojiDocuments.md new file mode 100644 index 0000000000..0eb301c685 --- /dev/null +++ b/docs/API_docs/methods/messages.getCustomEmojiDocuments.md @@ -0,0 +1,44 @@ +--- +title: "messages.getCustomEmojiDocuments" +description: "Fetch [custom emoji stickers »](https://core.telegram.org/api/custom-emoji)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getCustomEmojiDocuments.html +--- +# Method: messages.getCustomEmojiDocuments +[Back to methods index](index.html) + + + +Fetch [custom emoji stickers »](https://core.telegram.org/api/custom-emoji). + +Returns a list of [documents](../constructors/document.html) with the animated custom emoji in TGS format, and a [documentAttributeCustomEmoji](../constructors/documentAttributeCustomEmoji.html) attribute with the original emoji and info about the emoji stickerset this custom emoji belongs to. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|document\_id|Array of [long](/API_docs/types/long.html) | [Custom emoji](https://core.telegram.org/api/custom-emoji) IDs from a [messageEntityCustomEmoji](../constructors/messageEntityCustomEmoji.html). | Yes| + + +### Return type: [Vector\_of\_Document](/API_docs/types/Document.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_Document = $MadelineProto->messages->getCustomEmojiDocuments(document_id: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getDefaultHistoryTTL.md b/docs/API_docs/methods/messages.getDefaultHistoryTTL.md new file mode 100644 index 0000000000..45e42947d3 --- /dev/null +++ b/docs/API_docs/methods/messages.getDefaultHistoryTTL.md @@ -0,0 +1,37 @@ +--- +title: "messages.getDefaultHistoryTTL" +description: "Gets the default value of the Time-To-Live setting, applied to all new chats." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDefaultHistoryTTL.html +--- +# Method: messages.getDefaultHistoryTTL +[Back to methods index](index.html) + + + +Gets the default value of the Time-To-Live setting, applied to all new chats. + + + +### Return type: [DefaultHistoryTTL](/API_docs/types/DefaultHistoryTTL.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$DefaultHistoryTTL = $MadelineProto->messages->getDefaultHistoryTTL(); +``` + diff --git a/docs/API_docs/methods/messages.getDefaultTagReactions.md b/docs/API_docs/methods/messages.getDefaultTagReactions.md new file mode 100644 index 0000000000..3bbb18fda1 --- /dev/null +++ b/docs/API_docs/methods/messages.getDefaultTagReactions.md @@ -0,0 +1,40 @@ +--- +title: "messages.getDefaultTagReactions" +description: "messages.getDefaultTagReactions parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDefaultTagReactions.html +--- +# Method: messages.getDefaultTagReactions +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | Optional| + + +### Return type: [messages.Reactions](/API_docs/types/messages.Reactions.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Reactions = $MadelineProto->messages->getDefaultTagReactions(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getDhConfig.md b/docs/API_docs/methods/messages.getDhConfig.md new file mode 100644 index 0000000000..3a6ccaedc5 --- /dev/null +++ b/docs/API_docs/methods/messages.getDhConfig.md @@ -0,0 +1,43 @@ +--- +title: "messages.getDhConfig" +description: "You cannot use this method directly, instead use $MadelineProto->getDhConfig();" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDhConfig.html +--- +# Method: messages.getDhConfig +[Back to methods index](index.html) + + + +You cannot use this method directly, instead use $MadelineProto->getDhConfig(); + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|version|[int](/API_docs/types/int.html) | Value of the **version** parameter from [messages.dhConfig](../constructors/messages.dhConfig.html), available at the client | Optional| +|random\_length|[int](/API_docs/types/int.html) | Length of the required random sequence | Optional| + + +### Return type: [messages.DhConfig](/API_docs/types/messages.DhConfig.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_DhConfig = $MadelineProto->messages->getDhConfig(version: $int, random_length: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getDialogFilters.md b/docs/API_docs/methods/messages.getDialogFilters.md new file mode 100644 index 0000000000..24a30ca13d --- /dev/null +++ b/docs/API_docs/methods/messages.getDialogFilters.md @@ -0,0 +1,37 @@ +--- +title: "messages.getDialogFilters" +description: "Get [folders](https://core.telegram.org/api/folders)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDialogFilters.html +--- +# Method: messages.getDialogFilters +[Back to methods index](index.html) + + + +Get [folders](https://core.telegram.org/api/folders) + + + +### Return type: [messages.DialogFilters](/API_docs/types/messages.DialogFilters.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_DialogFilters = $MadelineProto->messages->getDialogFilters(); +``` + diff --git a/docs/API_docs/methods/messages.getDialogUnreadMarks.md b/docs/API_docs/methods/messages.getDialogUnreadMarks.md new file mode 100644 index 0000000000..d6ef9b4861 --- /dev/null +++ b/docs/API_docs/methods/messages.getDialogUnreadMarks.md @@ -0,0 +1,37 @@ +--- +title: "messages.getDialogUnreadMarks" +description: "Get dialogs manually marked as unread" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDialogUnreadMarks.html +--- +# Method: messages.getDialogUnreadMarks +[Back to methods index](index.html) + + + +Get dialogs manually marked as unread + + + +### Return type: [Vector\_of\_DialogPeer](/API_docs/types/DialogPeer.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_DialogPeer = $MadelineProto->messages->getDialogUnreadMarks(); +``` + diff --git a/docs/API_docs/methods/messages.getDialogs.md b/docs/API_docs/methods/messages.getDialogs.md new file mode 100644 index 0000000000..6cfdbd8a12 --- /dev/null +++ b/docs/API_docs/methods/messages.getDialogs.md @@ -0,0 +1,48 @@ +--- +title: "messages.getDialogs" +description: "Returns the current user dialog list." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDialogs.html +--- +# Method: messages.getDialogs +[Back to methods index](index.html) + + + +Returns the current user dialog list. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|exclude\_pinned|[Bool](/API_docs/types/Bool.html) | Exclude pinned dialogs | Optional| +|folder\_id|[int](/API_docs/types/int.html) | [Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders) | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) (`top_message` ID used for pagination) | Optional| +|offset\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | [Offset peer for pagination](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Number of list elements to be returned | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Dialogs](/API_docs/types/messages.Dialogs.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Dialogs = $MadelineProto->messages->getDialogs(exclude_pinned: $Bool, folder_id: $int, offset_date: $int, offset_id: $int, offset_peer: $InputPeer, limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getDiscussionMessage.md b/docs/API_docs/methods/messages.getDiscussionMessage.md new file mode 100644 index 0000000000..ae4b87bb49 --- /dev/null +++ b/docs/API_docs/methods/messages.getDiscussionMessage.md @@ -0,0 +1,43 @@ +--- +title: "messages.getDiscussionMessage" +description: "Get [discussion message](https://core.telegram.org/api/threads) from the [associated discussion group](https://core.telegram.org/api/discussion) of a channel to show it on top of the comment section, without actually joining the group" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDiscussionMessage.html +--- +# Method: messages.getDiscussionMessage +[Back to methods index](index.html) + + + +Get [discussion message](https://core.telegram.org/api/threads) from the [associated discussion group](https://core.telegram.org/api/discussion) of a channel to show it on top of the comment section, without actually joining the group + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | [Channel ID](https://core.telegram.org/api/channel) | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID | Optional| + + +### Return type: [messages.DiscussionMessage](/API_docs/types/messages.DiscussionMessage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_DiscussionMessage = $MadelineProto->messages->getDiscussionMessage(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getDocumentByHash.md b/docs/API_docs/methods/messages.getDocumentByHash.md new file mode 100644 index 0000000000..cac198d278 --- /dev/null +++ b/docs/API_docs/methods/messages.getDocumentByHash.md @@ -0,0 +1,44 @@ +--- +title: "messages.getDocumentByHash" +description: "Get a document by its SHA256 hash, mainly used for gifs" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getDocumentByHash.html +--- +# Method: messages.getDocumentByHash +[Back to methods index](index.html) + + + +Get a document by its SHA256 hash, mainly used for gifs + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|sha256|[bytes](/API_docs/types/bytes.html) | SHA256 of file | Yes| +|size|[long](/API_docs/types/long.html) | Size of the file in bytes | Yes| +|mime\_type|[string](/API_docs/types/string.html) | Mime type | Optional| + + +### Return type: [Document](/API_docs/types/Document.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Document = $MadelineProto->messages->getDocumentByHash(sha256: 'bytes', size: $long, mime_type: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiGroups.md b/docs/API_docs/methods/messages.getEmojiGroups.md new file mode 100644 index 0000000000..98f3a1f79c --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiGroups.md @@ -0,0 +1,42 @@ +--- +title: "messages.getEmojiGroups" +description: "Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories), to be used when selecting [custom emojis](https://core.telegram.org/api/custom-emoji)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiGroups.html +--- +# Method: messages.getEmojiGroups +[Back to methods index](index.html) + + + +Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories), to be used when selecting [custom emojis](https://core.telegram.org/api/custom-emoji). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_EmojiGroups = $MadelineProto->messages->getEmojiGroups(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiKeywords.md b/docs/API_docs/methods/messages.getEmojiKeywords.md new file mode 100644 index 0000000000..4639b879e8 --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiKeywords.md @@ -0,0 +1,42 @@ +--- +title: "messages.getEmojiKeywords" +description: "Get localized [emoji keywords »](https://core.telegram.org/api/custom-emoji#emoji-keywords)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiKeywords.html +--- +# Method: messages.getEmojiKeywords +[Back to methods index](index.html) + + + +Get localized [emoji keywords »](https://core.telegram.org/api/custom-emoji#emoji-keywords). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| + + +### Return type: [EmojiKeywordsDifference](/API_docs/types/EmojiKeywordsDifference.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiKeywordsDifference = $MadelineProto->messages->getEmojiKeywords(lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiKeywordsDifference.md b/docs/API_docs/methods/messages.getEmojiKeywordsDifference.md new file mode 100644 index 0000000000..8488c3c819 --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiKeywordsDifference.md @@ -0,0 +1,43 @@ +--- +title: "messages.getEmojiKeywordsDifference" +description: "Get changed [emoji keywords »](https://core.telegram.org/api/custom-emoji#emoji-keywords)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiKeywordsDifference.html +--- +# Method: messages.getEmojiKeywordsDifference +[Back to methods index](index.html) + + + +Get changed [emoji keywords »](https://core.telegram.org/api/custom-emoji#emoji-keywords). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_code|[string](/API_docs/types/string.html) | Language code | Optional| +|from\_version|[int](/API_docs/types/int.html) | Previous stored emoji keyword list `version` | Optional| + + +### Return type: [EmojiKeywordsDifference](/API_docs/types/EmojiKeywordsDifference.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiKeywordsDifference = $MadelineProto->messages->getEmojiKeywordsDifference(lang_code: 'string', from_version: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiKeywordsLanguages.md b/docs/API_docs/methods/messages.getEmojiKeywordsLanguages.md new file mode 100644 index 0000000000..609bad1f65 --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiKeywordsLanguages.md @@ -0,0 +1,44 @@ +--- +title: "messages.getEmojiKeywordsLanguages" +description: "Obtain a list of related languages that must be used when fetching [emoji keyword lists »](https://core.telegram.org/api/custom-emoji#emoji-keywords)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiKeywordsLanguages.html +--- +# Method: messages.getEmojiKeywordsLanguages +[Back to methods index](index.html) + + + +Obtain a list of related languages that must be used when fetching [emoji keyword lists »](https://core.telegram.org/api/custom-emoji#emoji-keywords). + +Usually the method will return the passed language codes (if localized) + `en` + some language codes for similar languages (if applicable). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_codes|Array of [string](/API_docs/types/string.html) | The user's language codes | Yes| + + +### Return type: [Vector\_of\_EmojiLanguage](/API_docs/types/EmojiLanguage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_EmojiLanguage = $MadelineProto->messages->getEmojiKeywordsLanguages(lang_codes: ['string', 'string'], ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiProfilePhotoGroups.md b/docs/API_docs/methods/messages.getEmojiProfilePhotoGroups.md new file mode 100644 index 0000000000..dd8efb597f --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiProfilePhotoGroups.md @@ -0,0 +1,42 @@ +--- +title: "messages.getEmojiProfilePhotoGroups" +description: "Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories), to be used when selecting custom emojis to set as [profile picture](https://core.telegram.org/api/files#sticker-profile-pictures)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiProfilePhotoGroups.html +--- +# Method: messages.getEmojiProfilePhotoGroups +[Back to methods index](index.html) + + + +Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories), to be used when selecting custom emojis to set as [profile picture](https://core.telegram.org/api/files#sticker-profile-pictures). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_EmojiGroups = $MadelineProto->messages->getEmojiProfilePhotoGroups(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiStatusGroups.md b/docs/API_docs/methods/messages.getEmojiStatusGroups.md new file mode 100644 index 0000000000..ee8f86bde0 --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiStatusGroups.md @@ -0,0 +1,42 @@ +--- +title: "messages.getEmojiStatusGroups" +description: "Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories), to be used when selecting custom emojis to set as [custom emoji status](https://core.telegram.org/api)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiStatusGroups.html +--- +# Method: messages.getEmojiStatusGroups +[Back to methods index](index.html) + + + +Represents a list of [emoji categories](https://core.telegram.org/api/custom-emoji#emoji-categories), to be used when selecting custom emojis to set as [custom emoji status](https://core.telegram.org/api). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_EmojiGroups = $MadelineProto->messages->getEmojiStatusGroups(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiStickerGroups.md b/docs/API_docs/methods/messages.getEmojiStickerGroups.md new file mode 100644 index 0000000000..ef77c9f451 --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiStickerGroups.md @@ -0,0 +1,40 @@ +--- +title: "messages.getEmojiStickerGroups" +description: "messages.getEmojiStickerGroups parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiStickerGroups.html +--- +# Method: messages.getEmojiStickerGroups +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | Optional| + + +### Return type: [messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_EmojiGroups = $MadelineProto->messages->getEmojiStickerGroups(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiStickers.md b/docs/API_docs/methods/messages.getEmojiStickers.md new file mode 100644 index 0000000000..e00d219b1e --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getEmojiStickers" +description: "Gets the list of currently installed [custom emoji stickersets](https://core.telegram.org/api/custom-emoji)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiStickers.html +--- +# Method: messages.getEmojiStickers +[Back to methods index](index.html) + + + +Gets the list of currently installed [custom emoji stickersets](https://core.telegram.org/api/custom-emoji). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AllStickers = $MadelineProto->messages->getEmojiStickers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getEmojiURL.md b/docs/API_docs/methods/messages.getEmojiURL.md new file mode 100644 index 0000000000..8da7ed334d --- /dev/null +++ b/docs/API_docs/methods/messages.getEmojiURL.md @@ -0,0 +1,42 @@ +--- +title: "messages.getEmojiURL" +description: "Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new [emoji keywords »](https://core.telegram.org/api/custom-emoji#emoji-keywords). The URL will be valid for 30 seconds after generation." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getEmojiURL.html +--- +# Method: messages.getEmojiURL +[Back to methods index](index.html) + + + +Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new [emoji keywords »](https://core.telegram.org/api/custom-emoji#emoji-keywords). The URL will be valid for 30 seconds after generation. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|lang\_code|[string](/API_docs/types/string.html) | Language code for which the emoji keywords will be suggested | Optional| + + +### Return type: [EmojiURL](/API_docs/types/EmojiURL.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiURL = $MadelineProto->messages->getEmojiURL(lang_code: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.getExportedChatInvite.md b/docs/API_docs/methods/messages.getExportedChatInvite.md new file mode 100644 index 0000000000..4fbcc562cc --- /dev/null +++ b/docs/API_docs/methods/messages.getExportedChatInvite.md @@ -0,0 +1,43 @@ +--- +title: "messages.getExportedChatInvite" +description: "Get info about a chat invite" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getExportedChatInvite.html +--- +# Method: messages.getExportedChatInvite +[Back to methods index](index.html) + + + +Get info about a chat invite + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| +|link|[string](/API_docs/types/string.html) | Invite link | Optional| + + +### Return type: [messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ExportedChatInvite = $MadelineProto->messages->getExportedChatInvite(peer: $InputPeer, link: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.getExportedChatInvites.md b/docs/API_docs/methods/messages.getExportedChatInvites.md new file mode 100644 index 0000000000..67ba327eaf --- /dev/null +++ b/docs/API_docs/methods/messages.getExportedChatInvites.md @@ -0,0 +1,47 @@ +--- +title: "messages.getExportedChatInvites" +description: "Get info about the chat invites of a specific chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getExportedChatInvites.html +--- +# Method: messages.getExportedChatInvites +[Back to methods index](index.html) + + + +Get info about the chat invites of a specific chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|revoked|[Bool](/API_docs/types/Bool.html) | Whether to fetch revoked chat invites | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat | Optional| +|admin\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Whether to only fetch chat invites from this admin | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_link|[string](/API_docs/types/string.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.ExportedChatInvites](/API_docs/types/messages.ExportedChatInvites.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ExportedChatInvites = $MadelineProto->messages->getExportedChatInvites(revoked: $Bool, peer: $InputPeer, admin_id: $InputUser, offset_date: $int, offset_link: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getExtendedMedia.md b/docs/API_docs/methods/messages.getExtendedMedia.md new file mode 100644 index 0000000000..6f837fd764 --- /dev/null +++ b/docs/API_docs/methods/messages.getExtendedMedia.md @@ -0,0 +1,43 @@ +--- +title: "messages.getExtendedMedia" +description: "Get information about extended media" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getExtendedMedia.html +--- +# Method: messages.getExtendedMedia +[Back to methods index](index.html) + + + +Get information about extended media + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|Array of [int](/API_docs/types/int.html) | Message IDs | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->getExtendedMedia(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.getFavedStickers.md b/docs/API_docs/methods/messages.getFavedStickers.md new file mode 100644 index 0000000000..9bf05db122 --- /dev/null +++ b/docs/API_docs/methods/messages.getFavedStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getFavedStickers" +description: "Get faved stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getFavedStickers.html +--- +# Method: messages.getFavedStickers +[Back to methods index](index.html) + + + +Get faved stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.FavedStickers](/API_docs/types/messages.FavedStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_FavedStickers = $MadelineProto->messages->getFavedStickers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getFeaturedEmojiStickers.md b/docs/API_docs/methods/messages.getFeaturedEmojiStickers.md new file mode 100644 index 0000000000..d2cf6524c4 --- /dev/null +++ b/docs/API_docs/methods/messages.getFeaturedEmojiStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getFeaturedEmojiStickers" +description: "Gets featured custom emoji stickersets." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getFeaturedEmojiStickers.html +--- +# Method: messages.getFeaturedEmojiStickers +[Back to methods index](index.html) + + + +Gets featured custom emoji stickersets. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_FeaturedStickers = $MadelineProto->messages->getFeaturedEmojiStickers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getFeaturedStickers.md b/docs/API_docs/methods/messages.getFeaturedStickers.md new file mode 100644 index 0000000000..7bfc995554 --- /dev/null +++ b/docs/API_docs/methods/messages.getFeaturedStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getFeaturedStickers" +description: "Get featured stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getFeaturedStickers.html +--- +# Method: messages.getFeaturedStickers +[Back to methods index](index.html) + + + +Get featured stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_FeaturedStickers = $MadelineProto->messages->getFeaturedStickers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getFullChat.md b/docs/API_docs/methods/messages.getFullChat.md new file mode 100644 index 0000000000..0dd20dccff --- /dev/null +++ b/docs/API_docs/methods/messages.getFullChat.md @@ -0,0 +1,42 @@ +--- +title: "messages.getFullChat" +description: "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getFullChat.html +--- +# Method: messages.getFullChat +[Back to methods index](index.html) + + + +You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| + + +### Return type: [messages.ChatFull](/API_docs/types/messages.ChatFull.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_ChatFull = $MadelineProto->messages->getFullChat(chat_id: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.getGameHighScores.md b/docs/API_docs/methods/messages.getGameHighScores.md new file mode 100644 index 0000000000..8f2e4e954b --- /dev/null +++ b/docs/API_docs/methods/messages.getGameHighScores.md @@ -0,0 +1,44 @@ +--- +title: "messages.getGameHighScores" +description: "Get highscores of a game" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getGameHighScores.html +--- +# Method: messages.getGameHighScores +[Back to methods index](index.html) + + + +Get highscores of a game + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Where was the game sent | Optional| +|id|[int](/API_docs/types/int.html) | ID of message with game media attachment | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Get high scores made by a certain user | Optional| + + +### Return type: [messages.HighScores](/API_docs/types/messages.HighScores.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_HighScores = $MadelineProto->messages->getGameHighScores(peer: $InputPeer, id: $int, user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/messages.getHistory.md b/docs/API_docs/methods/messages.getHistory.md new file mode 100644 index 0000000000..770b86c75b --- /dev/null +++ b/docs/API_docs/methods/messages.getHistory.md @@ -0,0 +1,58 @@ +--- +title: "messages.getHistory" +description: "Returns the conversation history with one interlocutor / within a chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getHistory.html +--- +# Method: messages.getHistory +[Back to methods index](index.html) + + + +# Warning: flood wait +**Warning: this method is prone to rate limiting with flood waits, **which can lead to !!! ACCOUNT BANS !!!**, please use the [updates event handler, instead (which is 100% safe) »](/docs/UPDATES.html#async-event-driven)** + +# Warning: non-realtime results +**Warning: this method is not suitable for receiving messages in real-time from chats and users, please use the [updates event handler, instead »](/docs/UPDATES.html#async-event-driven)** + +# Warning: this is probably NOT what you need +You probably need to use the [updates event handler, instead »](/docs/UPDATES.html#async-event-driven) :) + +Returns the conversation history with one interlocutor / within a chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Target peer | Optional| +|offset\_id|[int](/API_docs/types/int.html) | Only return messages starting from the specified message ID | Optional| +|offset\_date|[int](/API_docs/types/int.html) | Only return messages sent before the specified date | Optional| +|add\_offset|[int](/API_docs/types/int.html) | Number of list elements to be skipped, negative values are also accepted. | Optional| +|limit|[int](/API_docs/types/int.html) | Number of results to return | Optional| +|max\_id|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with IDs less than **max\_id** | Optional| +|min\_id|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with IDs more than **min\_id** | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Result hash](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getHistory(peer: $InputPeer, offset_id: $int, offset_date: $int, add_offset: $int, limit: $int, max_id: $int, min_id: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getInlineBotResults.md b/docs/API_docs/methods/messages.getInlineBotResults.md new file mode 100644 index 0000000000..c3ad439047 --- /dev/null +++ b/docs/API_docs/methods/messages.getInlineBotResults.md @@ -0,0 +1,46 @@ +--- +title: "messages.getInlineBotResults" +description: "Query an inline bot" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getInlineBotResults.html +--- +# Method: messages.getInlineBotResults +[Back to methods index](index.html) + + + +Query an inline bot + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The bot to query | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The currently opened chat | Optional| +|geo\_point|[InputGeoPoint](/API_docs/types/InputGeoPoint.html) | The geolocation, if requested | Optional| +|query|[string](/API_docs/types/string.html) | The query | Optional| +|offset|[string](/API_docs/types/string.html) | The offset within the results, will be passed directly as-is to the bot. | Optional| + + +### Return type: [messages.BotResults](/API_docs/types/messages.BotResults.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_BotResults = $MadelineProto->messages->getInlineBotResults(bot: $InputUser, peer: $InputPeer, geo_point: $InputGeoPoint, query: 'string', offset: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.getInlineGameHighScores.md b/docs/API_docs/methods/messages.getInlineGameHighScores.md new file mode 100644 index 0000000000..1205112169 --- /dev/null +++ b/docs/API_docs/methods/messages.getInlineGameHighScores.md @@ -0,0 +1,43 @@ +--- +title: "messages.getInlineGameHighScores" +description: "Get highscores of a game sent using an inline bot" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getInlineGameHighScores.html +--- +# Method: messages.getInlineGameHighScores +[Back to methods index](index.html) + + + +Get highscores of a game sent using an inline bot + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) | ID of inline message | Yes| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Get high scores of a certain user | Optional| + + +### Return type: [messages.HighScores](/API_docs/types/messages.HighScores.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_HighScores = $MadelineProto->messages->getInlineGameHighScores(id: $InputBotInlineMessageID, user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/messages.getMaskStickers.md b/docs/API_docs/methods/messages.getMaskStickers.md new file mode 100644 index 0000000000..e12eb44284 --- /dev/null +++ b/docs/API_docs/methods/messages.getMaskStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.getMaskStickers" +description: "Get installed mask stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMaskStickers.html +--- +# Method: messages.getMaskStickers +[Back to methods index](index.html) + + + +Get installed mask stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AllStickers = $MadelineProto->messages->getMaskStickers(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getMessageEditData.md b/docs/API_docs/methods/messages.getMessageEditData.md new file mode 100644 index 0000000000..2aaa97b465 --- /dev/null +++ b/docs/API_docs/methods/messages.getMessageEditData.md @@ -0,0 +1,43 @@ +--- +title: "messages.getMessageEditData" +description: "Find out if a media message's caption can be edited" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMessageEditData.html +--- +# Method: messages.getMessageEditData +[Back to methods index](index.html) + + + +Find out if a media message's caption can be edited + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the media was sent | Optional| +|id|[int](/API_docs/types/int.html) | ID of message | Optional| + + +### Return type: [messages.MessageEditData](/API_docs/types/messages.MessageEditData.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_MessageEditData = $MadelineProto->messages->getMessageEditData(peer: $InputPeer, id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getMessageReactionsList.md b/docs/API_docs/methods/messages.getMessageReactionsList.md new file mode 100644 index 0000000000..6283a0f19c --- /dev/null +++ b/docs/API_docs/methods/messages.getMessageReactionsList.md @@ -0,0 +1,46 @@ +--- +title: "messages.getMessageReactionsList" +description: "Get [message reaction](https://core.telegram.org/api/reactions) list, along with the sender of each reaction." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMessageReactionsList.html +--- +# Method: messages.getMessageReactionsList +[Back to methods index](index.html) + + + +Get [message reaction](https://core.telegram.org/api/reactions) list, along with the sender of each reaction. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|[int](/API_docs/types/int.html) | Message ID | Optional| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Get only reactions of this type | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for pagination (taken from the `next_offset` field of the returned [messages.MessageReactionsList](../types/messages.MessageReactionsList.html)); empty in the first request. | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.MessageReactionsList](/API_docs/types/messages.MessageReactionsList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_MessageReactionsList = $MadelineProto->messages->getMessageReactionsList(peer: $InputPeer, id: $int, reaction: $Reaction, offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getMessageReadParticipants.md b/docs/API_docs/methods/messages.getMessageReadParticipants.md new file mode 100644 index 0000000000..388c33c336 --- /dev/null +++ b/docs/API_docs/methods/messages.getMessageReadParticipants.md @@ -0,0 +1,43 @@ +--- +title: "messages.getMessageReadParticipants" +description: "Get which users read a specific message: only available for groups and supergroups with less than [`chat_read_mark_size_threshold` members](https://core.telegram.org/api/config#chat-read-mark-size-threshold), read receipts will be stored for [`chat_read_mark_expire_period` seconds after the message was sent](https://core.telegram.org/api/config#chat-read-mark-expire-period), see [client configuration for more info »](https://core.telegram.org/api/config#client-configuration)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMessageReadParticipants.html +--- +# Method: messages.getMessageReadParticipants +[Back to methods index](index.html) + + + +Get which users read a specific message: only available for groups and supergroups with less than [`chat_read_mark_size_threshold` members](https://core.telegram.org/api/config#chat-read-mark-size-threshold), read receipts will be stored for [`chat_read_mark_expire_period` seconds after the message was sent](https://core.telegram.org/api/config#chat-read-mark-expire-period), see [client configuration for more info »](https://core.telegram.org/api/config#client-configuration). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Dialog | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID | Optional| + + +### Return type: [Vector\_of\_ReadParticipantDate](/API_docs/types/ReadParticipantDate.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_ReadParticipantDate = $MadelineProto->messages->getMessageReadParticipants(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getMessages.md b/docs/API_docs/methods/messages.getMessages.md new file mode 100644 index 0000000000..7334366cf5 --- /dev/null +++ b/docs/API_docs/methods/messages.getMessages.md @@ -0,0 +1,51 @@ +--- +title: "messages.getMessages" +description: "Returns the list of messages by their IDs." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMessages.html +--- +# Method: messages.getMessages +[Back to methods index](index.html) + + + +# Warning: flood wait +**Warning: this method is prone to rate limiting with flood waits, **which can lead to !!! ACCOUNT BANS !!!**, please use the [updates event handler, instead (which is 100% safe) »](/docs/UPDATES.html#async-event-driven)** + +# Warning: non-realtime results +**Warning: this method is not suitable for receiving messages in real-time from chats and users, please use the [updates event handler, instead »](/docs/UPDATES.html#async-event-driven)** + +# Warning: this is probably NOT what you need +You probably need to use the [updates event handler, instead »](/docs/UPDATES.html#async-event-driven) :) + +Returns the list of messages by their IDs. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [Message ID or InputMessage](/API_docs/types/InputMessage.html) | Message ID list | Yes| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getMessages(id: [$InputMessage, $InputMessage], ); +``` + diff --git a/docs/API_docs/methods/messages.getMessagesReactions.md b/docs/API_docs/methods/messages.getMessagesReactions.md new file mode 100644 index 0000000000..15adfb21bf --- /dev/null +++ b/docs/API_docs/methods/messages.getMessagesReactions.md @@ -0,0 +1,43 @@ +--- +title: "messages.getMessagesReactions" +description: "Get [message reactions »](https://core.telegram.org/api/reactions)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMessagesReactions.html +--- +# Method: messages.getMessagesReactions +[Back to methods index](index.html) + + + +Get [message reactions »](https://core.telegram.org/api/reactions) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|Array of [int](/API_docs/types/int.html) | Message IDs | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->getMessagesReactions(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.getMessagesViews.md b/docs/API_docs/methods/messages.getMessagesViews.md new file mode 100644 index 0000000000..5c95d70097 --- /dev/null +++ b/docs/API_docs/methods/messages.getMessagesViews.md @@ -0,0 +1,44 @@ +--- +title: "messages.getMessagesViews" +description: "Get and increase the view counter of a message sent or forwarded from a [channel](https://core.telegram.org/api/channel)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMessagesViews.html +--- +# Method: messages.getMessagesViews +[Back to methods index](index.html) + + + +Get and increase the view counter of a message sent or forwarded from a [channel](https://core.telegram.org/api/channel) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the message was found | Optional| +|id|Array of [int](/API_docs/types/int.html) | ID of message | Yes| +|increment|[Bool](/API_docs/types/Bool.html) | Whether to mark the message as viewed and increment the view counter | Yes| + + +### Return type: [messages.MessageViews](/API_docs/types/messages.MessageViews.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_MessageViews = $MadelineProto->messages->getMessagesViews(peer: $InputPeer, id: [$int, $int], increment: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.getMyStickers.md b/docs/API_docs/methods/messages.getMyStickers.md new file mode 100644 index 0000000000..f889fb050d --- /dev/null +++ b/docs/API_docs/methods/messages.getMyStickers.md @@ -0,0 +1,41 @@ +--- +title: "messages.getMyStickers" +description: "messages.getMyStickers parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getMyStickers.html +--- +# Method: messages.getMyStickers +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|offset\_id|[long](/API_docs/types/long.html) | Yes| +|limit|[int](/API_docs/types/int.html) | Optional| + + +### Return type: [messages.MyStickers](/API_docs/types/messages.MyStickers.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_MyStickers = $MadelineProto->messages->getMyStickers(offset_id: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getOldFeaturedStickers.md b/docs/API_docs/methods/messages.getOldFeaturedStickers.md new file mode 100644 index 0000000000..ec7969f30a --- /dev/null +++ b/docs/API_docs/methods/messages.getOldFeaturedStickers.md @@ -0,0 +1,44 @@ +--- +title: "messages.getOldFeaturedStickers" +description: "Method for fetching previously featured stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getOldFeaturedStickers.html +--- +# Method: messages.getOldFeaturedStickers +[Back to methods index](index.html) + + + +Method for fetching previously featured stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|offset|[int](/API_docs/types/int.html) | Offset | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_FeaturedStickers = $MadelineProto->messages->getOldFeaturedStickers(offset: $int, limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getOnlines.md b/docs/API_docs/methods/messages.getOnlines.md new file mode 100644 index 0000000000..20425ad12b --- /dev/null +++ b/docs/API_docs/methods/messages.getOnlines.md @@ -0,0 +1,42 @@ +--- +title: "messages.getOnlines" +description: "Get count of online users in a chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getOnlines.html +--- +# Method: messages.getOnlines +[Back to methods index](index.html) + + + +Get count of online users in a chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat | Optional| + + +### Return type: [ChatOnlines](/API_docs/types/ChatOnlines.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ChatOnlines = $MadelineProto->messages->getOnlines(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.getOutboxReadDate.md b/docs/API_docs/methods/messages.getOutboxReadDate.md new file mode 100644 index 0000000000..f77f743f7b --- /dev/null +++ b/docs/API_docs/methods/messages.getOutboxReadDate.md @@ -0,0 +1,41 @@ +--- +title: "messages.getOutboxReadDate" +description: "messages.getOutboxReadDate parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getOutboxReadDate.html +--- +# Method: messages.getOutboxReadDate +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Optional| + + +### Return type: [OutboxReadDate](/API_docs/types/OutboxReadDate.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$OutboxReadDate = $MadelineProto->messages->getOutboxReadDate(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getPeerDialogs.md b/docs/API_docs/methods/messages.getPeerDialogs.md new file mode 100644 index 0000000000..4d08e9d219 --- /dev/null +++ b/docs/API_docs/methods/messages.getPeerDialogs.md @@ -0,0 +1,42 @@ +--- +title: "messages.getPeerDialogs" +description: "Get dialog info of specified peers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getPeerDialogs.html +--- +# Method: messages.getPeerDialogs +[Back to methods index](index.html) + + + +Get dialog info of specified peers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peers|Array of [InputDialogPeer](/API_docs/types/InputDialogPeer.html) | Peers | Yes| + + +### Return type: [messages.PeerDialogs](/API_docs/types/messages.PeerDialogs.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_PeerDialogs = $MadelineProto->messages->getPeerDialogs(peers: [$InputDialogPeer, $InputDialogPeer], ); +``` + diff --git a/docs/API_docs/methods/messages.getPeerSettings.md b/docs/API_docs/methods/messages.getPeerSettings.md new file mode 100644 index 0000000000..eb6337a12e --- /dev/null +++ b/docs/API_docs/methods/messages.getPeerSettings.md @@ -0,0 +1,42 @@ +--- +title: "messages.getPeerSettings" +description: "Get peer settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getPeerSettings.html +--- +# Method: messages.getPeerSettings +[Back to methods index](index.html) + + + +Get peer settings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer | Optional| + + +### Return type: [messages.PeerSettings](/API_docs/types/messages.PeerSettings.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_PeerSettings = $MadelineProto->messages->getPeerSettings(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.getPinnedDialogs.md b/docs/API_docs/methods/messages.getPinnedDialogs.md new file mode 100644 index 0000000000..7fe104e3e3 --- /dev/null +++ b/docs/API_docs/methods/messages.getPinnedDialogs.md @@ -0,0 +1,42 @@ +--- +title: "messages.getPinnedDialogs" +description: "Get pinned dialogs" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getPinnedDialogs.html +--- +# Method: messages.getPinnedDialogs +[Back to methods index](index.html) + + + +Get pinned dialogs + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|folder\_id|[int](/API_docs/types/int.html) | [Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders) | Optional| + + +### Return type: [messages.PeerDialogs](/API_docs/types/messages.PeerDialogs.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_PeerDialogs = $MadelineProto->messages->getPinnedDialogs(folder_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getPinnedSavedDialogs.md b/docs/API_docs/methods/messages.getPinnedSavedDialogs.md new file mode 100644 index 0000000000..5efe677d91 --- /dev/null +++ b/docs/API_docs/methods/messages.getPinnedSavedDialogs.md @@ -0,0 +1,37 @@ +--- +title: "messages.getPinnedSavedDialogs" +description: "Get pinned [saved dialogs, see here »](https://core.telegram.org/api/saved-messages) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getPinnedSavedDialogs.html +--- +# Method: messages.getPinnedSavedDialogs +[Back to methods index](index.html) + + + +Get pinned [saved dialogs, see here »](https://core.telegram.org/api/saved-messages) for more info. + + + +### Return type: [messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SavedDialogs = $MadelineProto->messages->getPinnedSavedDialogs(); +``` + diff --git a/docs/API_docs/methods/messages.getPollResults.md b/docs/API_docs/methods/messages.getPollResults.md new file mode 100644 index 0000000000..ecaed37bcb --- /dev/null +++ b/docs/API_docs/methods/messages.getPollResults.md @@ -0,0 +1,43 @@ +--- +title: "messages.getPollResults" +description: "Get poll results" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getPollResults.html +--- +# Method: messages.getPollResults +[Back to methods index](index.html) + + + +Get poll results + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the poll was found | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID of poll message | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->getPollResults(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getPollVotes.md b/docs/API_docs/methods/messages.getPollVotes.md new file mode 100644 index 0000000000..ac40cbb62c --- /dev/null +++ b/docs/API_docs/methods/messages.getPollVotes.md @@ -0,0 +1,46 @@ +--- +title: "messages.getPollVotes" +description: "Get poll results for non-anonymous polls" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getPollVotes.html +--- +# Method: messages.getPollVotes +[Back to methods index](index.html) + + + +Get poll results for non-anonymous polls + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat where the poll was sent | Optional| +|id|[int](/API_docs/types/int.html) | Message ID | Optional| +|option|[bytes](/API_docs/types/bytes.html) | Get only results for the specified poll `option` | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for results, taken from the `next_offset` field of [messages.votesList](../constructors/messages.votesList.html), initially an empty string.
Note: if no more results are available, the method call will return an empty `next_offset`; thus, avoid providing the `next_offset` returned in [messages.votesList](../constructors/messages.votesList.html) if it is empty, to avoid an infinite loop. | Optional| +|limit|[int](/API_docs/types/int.html) | Number of results to return | Optional| + + +### Return type: [messages.VotesList](/API_docs/types/messages.VotesList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_VotesList = $MadelineProto->messages->getPollVotes(peer: $InputPeer, id: $int, option: 'bytes', offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getQuickReplies.md b/docs/API_docs/methods/messages.getQuickReplies.md new file mode 100644 index 0000000000..4452ac86ee --- /dev/null +++ b/docs/API_docs/methods/messages.getQuickReplies.md @@ -0,0 +1,40 @@ +--- +title: "messages.getQuickReplies" +description: "messages.getQuickReplies parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getQuickReplies.html +--- +# Method: messages.getQuickReplies +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | Optional| + + +### Return type: [messages.QuickReplies](/API_docs/types/messages.QuickReplies.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_QuickReplies = $MadelineProto->messages->getQuickReplies(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getQuickReplyMessages.md b/docs/API_docs/methods/messages.getQuickReplyMessages.md new file mode 100644 index 0000000000..0ff44da9a3 --- /dev/null +++ b/docs/API_docs/methods/messages.getQuickReplyMessages.md @@ -0,0 +1,42 @@ +--- +title: "messages.getQuickReplyMessages" +description: "messages.getQuickReplyMessages parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getQuickReplyMessages.html +--- +# Method: messages.getQuickReplyMessages +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|shortcut\_id|[int](/API_docs/types/int.html) | Optional| +|id|Array of [int](/API_docs/types/int.html) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getQuickReplyMessages(shortcut_id: $int, id: [$int, $int], hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getRecentLocations.md b/docs/API_docs/methods/messages.getRecentLocations.md new file mode 100644 index 0000000000..d46869c756 --- /dev/null +++ b/docs/API_docs/methods/messages.getRecentLocations.md @@ -0,0 +1,44 @@ +--- +title: "messages.getRecentLocations" +description: "Get live location history of a certain user" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getRecentLocations.html +--- +# Method: messages.getRecentLocations +[Back to methods index](index.html) + + + +Get live location history of a certain user + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | User | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getRecentLocations(peer: $InputPeer, limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getRecentReactions.md b/docs/API_docs/methods/messages.getRecentReactions.md new file mode 100644 index 0000000000..d522a65977 --- /dev/null +++ b/docs/API_docs/methods/messages.getRecentReactions.md @@ -0,0 +1,43 @@ +--- +title: "messages.getRecentReactions" +description: "Get recently used [message reactions](https://core.telegram.org/api/reactions)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getRecentReactions.html +--- +# Method: messages.getRecentReactions +[Back to methods index](index.html) + + + +Get recently used [message reactions](https://core.telegram.org/api/reactions) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Reactions](/API_docs/types/messages.Reactions.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Reactions = $MadelineProto->messages->getRecentReactions(limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getRecentStickers.md b/docs/API_docs/methods/messages.getRecentStickers.md new file mode 100644 index 0000000000..f87268c9b0 --- /dev/null +++ b/docs/API_docs/methods/messages.getRecentStickers.md @@ -0,0 +1,43 @@ +--- +title: "messages.getRecentStickers" +description: "Get recent stickers" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getRecentStickers.html +--- +# Method: messages.getRecentStickers +[Back to methods index](index.html) + + + +Get recent stickers + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|attached|[Bool](/API_docs/types/Bool.html) | Get stickers recently attached to photo or video files | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.RecentStickers](/API_docs/types/messages.RecentStickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_RecentStickers = $MadelineProto->messages->getRecentStickers(attached: $Bool, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getReplies.md b/docs/API_docs/methods/messages.getReplies.md new file mode 100644 index 0000000000..db8ae03bd1 --- /dev/null +++ b/docs/API_docs/methods/messages.getReplies.md @@ -0,0 +1,50 @@ +--- +title: "messages.getReplies" +description: "Get messages in a reply thread" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getReplies.html +--- +# Method: messages.getReplies +[Back to methods index](index.html) + + + +Get messages in a reply thread + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|add\_offset|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|max\_id|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with ID smaller than max\_id | Optional| +|min\_id|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with ID bigger than min\_id | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getReplies(peer: $InputPeer, msg_id: $int, offset_id: $int, offset_date: $int, add_offset: $int, limit: $int, max_id: $int, min_id: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getSavedDialogs.md b/docs/API_docs/methods/messages.getSavedDialogs.md new file mode 100644 index 0000000000..2ac38424b0 --- /dev/null +++ b/docs/API_docs/methods/messages.getSavedDialogs.md @@ -0,0 +1,47 @@ +--- +title: "messages.getSavedDialogs" +description: "Returns the current saved dialog list, see [here »](https://core.telegram.org/api/saved-messages) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSavedDialogs.html +--- +# Method: messages.getSavedDialogs +[Back to methods index](index.html) + + + +Returns the current saved dialog list, see [here »](https://core.telegram.org/api/saved-messages) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|exclude\_pinned|[Bool](/API_docs/types/Bool.html) | Exclude pinned dialogs | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) (`top_message` ID used for pagination) | Optional| +|offset\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | [Offset peer for pagination](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Number of list elements to be returned | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SavedDialogs = $MadelineProto->messages->getSavedDialogs(exclude_pinned: $Bool, offset_date: $int, offset_id: $int, offset_peer: $InputPeer, limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getSavedGifs.md b/docs/API_docs/methods/messages.getSavedGifs.md new file mode 100644 index 0000000000..b9f30499eb --- /dev/null +++ b/docs/API_docs/methods/messages.getSavedGifs.md @@ -0,0 +1,42 @@ +--- +title: "messages.getSavedGifs" +description: "Get saved GIFs" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSavedGifs.html +--- +# Method: messages.getSavedGifs +[Back to methods index](index.html) + + + +Get saved GIFs + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.SavedGifs](/API_docs/types/messages.SavedGifs.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SavedGifs = $MadelineProto->messages->getSavedGifs(hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getSavedHistory.md b/docs/API_docs/methods/messages.getSavedHistory.md new file mode 100644 index 0000000000..94a84314d2 --- /dev/null +++ b/docs/API_docs/methods/messages.getSavedHistory.md @@ -0,0 +1,49 @@ +--- +title: "messages.getSavedHistory" +description: "Returns [saved messages »](https://core.telegram.org/api/saved-messages) forwarded from a specific peer" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSavedHistory.html +--- +# Method: messages.getSavedHistory +[Back to methods index](index.html) + + + +Returns [saved messages »](https://core.telegram.org/api/saved-messages) forwarded from a specific peer + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Target peer | Optional| +|offset\_id|[int](/API_docs/types/int.html) | Only return messages starting from the specified message ID | Optional| +|offset\_date|[int](/API_docs/types/int.html) | Only return messages sent before the specified date | Optional| +|add\_offset|[int](/API_docs/types/int.html) | Number of list elements to be skipped, negative values are also accepted. | Optional| +|limit|[int](/API_docs/types/int.html) | Number of results to return | Optional| +|max\_id|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with IDs less than **max\_id** | Optional| +|min\_id|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with IDs more than **min\_id** | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Result hash](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getSavedHistory(peer: $InputPeer, offset_id: $int, offset_date: $int, add_offset: $int, limit: $int, max_id: $int, min_id: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getSavedReactionTags.md b/docs/API_docs/methods/messages.getSavedReactionTags.md new file mode 100644 index 0000000000..b25314aa0f --- /dev/null +++ b/docs/API_docs/methods/messages.getSavedReactionTags.md @@ -0,0 +1,41 @@ +--- +title: "messages.getSavedReactionTags" +description: "messages.getSavedReactionTags parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSavedReactionTags.html +--- +# Method: messages.getSavedReactionTags +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | Optional| + + +### Return type: [messages.SavedReactionTags](/API_docs/types/messages.SavedReactionTags.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SavedReactionTags = $MadelineProto->messages->getSavedReactionTags(peer: $InputPeer, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getScheduledHistory.md b/docs/API_docs/methods/messages.getScheduledHistory.md new file mode 100644 index 0000000000..062d6cdaa3 --- /dev/null +++ b/docs/API_docs/methods/messages.getScheduledHistory.md @@ -0,0 +1,43 @@ +--- +title: "messages.getScheduledHistory" +description: "Get scheduled messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getScheduledHistory.html +--- +# Method: messages.getScheduledHistory +[Back to methods index](index.html) + + + +Get scheduled messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getScheduledHistory(peer: $InputPeer, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getScheduledMessages.md b/docs/API_docs/methods/messages.getScheduledMessages.md new file mode 100644 index 0000000000..c9375d6c58 --- /dev/null +++ b/docs/API_docs/methods/messages.getScheduledMessages.md @@ -0,0 +1,43 @@ +--- +title: "messages.getScheduledMessages" +description: "Get scheduled messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getScheduledMessages.html +--- +# Method: messages.getScheduledMessages +[Back to methods index](index.html) + + + +Get scheduled messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of scheduled messages | Yes| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getScheduledMessages(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.getSearchCounters.md b/docs/API_docs/methods/messages.getSearchCounters.md new file mode 100644 index 0000000000..816ed1e0c1 --- /dev/null +++ b/docs/API_docs/methods/messages.getSearchCounters.md @@ -0,0 +1,45 @@ +--- +title: "messages.getSearchCounters" +description: "Get the number of results that would be found by a [messages.search](../methods/messages.search.html) call with the same parameters" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSearchCounters.html +--- +# Method: messages.getSearchCounters +[Back to methods index](index.html) + + + +Get the number of results that would be found by a [messages.search](../methods/messages.search.html) call with the same parameters + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where to search | Optional| +|saved\_peer\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Search within the [saved message dialog »](https://core.telegram.org/api/saved-messages) with this ID. | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | If set, consider only messages within the specified [forum topic](https://core.telegram.org/api/forum#forum-topics) | Optional| +|filters|Array of [MessagesFilter](/API_docs/types/MessagesFilter.html) | Search filters | Yes| + + +### Return type: [Vector\_of\_messages.SearchCounter](/API_docs/types/messages.SearchCounter.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_messages_SearchCounter = $MadelineProto->messages->getSearchCounters(peer: $InputPeer, saved_peer_id: $InputPeer, top_msg_id: $int, filters: [$MessagesFilter, $MessagesFilter], ); +``` + diff --git a/docs/API_docs/methods/messages.getSearchResultsCalendar.md b/docs/API_docs/methods/messages.getSearchResultsCalendar.md new file mode 100644 index 0000000000..a61ea5e2dd --- /dev/null +++ b/docs/API_docs/methods/messages.getSearchResultsCalendar.md @@ -0,0 +1,49 @@ +--- +title: "messages.getSearchResultsCalendar" +description: "Returns information about the next messages of the specified type in the chat split by days." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSearchResultsCalendar.html +--- +# Method: messages.getSearchResultsCalendar +[Back to methods index](index.html) + + + +Returns information about the next messages of the specified type in the chat split by days. + +Returns the results in reverse chronological order. +Can return partial results for the last returned day. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where to search | Optional| +|saved\_peer\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Search within the [saved message dialog »](https://core.telegram.org/api/saved-messages) with this ID. | Optional| +|filter|[MessagesFilter](/API_docs/types/MessagesFilter.html) | Message filter, [inputMessagesFilterEmpty](../constructors/inputMessagesFilterEmpty.html), [inputMessagesFilterMyMentions](../constructors/inputMessagesFilterMyMentions.html) filters are not supported by this method. | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_date|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.SearchResultsCalendar](/API_docs/types/messages.SearchResultsCalendar.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SearchResultsCalendar = $MadelineProto->messages->getSearchResultsCalendar(peer: $InputPeer, saved_peer_id: $InputPeer, filter: $MessagesFilter, offset_id: $int, offset_date: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getSearchResultsPositions.md b/docs/API_docs/methods/messages.getSearchResultsPositions.md new file mode 100644 index 0000000000..06bb9611a7 --- /dev/null +++ b/docs/API_docs/methods/messages.getSearchResultsPositions.md @@ -0,0 +1,48 @@ +--- +title: "messages.getSearchResultsPositions" +description: "Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSearchResultsPositions.html +--- +# Method: messages.getSearchResultsPositions +[Back to methods index](index.html) + + + +Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation. + +Returns the results in reverse chronological order (i.e., in order of decreasing message\_id). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where to search | Optional| +|saved\_peer\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Search within the [saved message dialog »](https://core.telegram.org/api/saved-messages) with this ID. | Optional| +|filter|[MessagesFilter](/API_docs/types/MessagesFilter.html) | Message filter, [inputMessagesFilterEmpty](../constructors/inputMessagesFilterEmpty.html), [inputMessagesFilterMyMentions](../constructors/inputMessagesFilterMyMentions.html) filters are not supported by this method. | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.SearchResultsPositions](/API_docs/types/messages.SearchResultsPositions.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SearchResultsPositions = $MadelineProto->messages->getSearchResultsPositions(peer: $InputPeer, saved_peer_id: $InputPeer, filter: $MessagesFilter, offset_id: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getSplitRanges.md b/docs/API_docs/methods/messages.getSplitRanges.md new file mode 100644 index 0000000000..db3e08fb9e --- /dev/null +++ b/docs/API_docs/methods/messages.getSplitRanges.md @@ -0,0 +1,37 @@ +--- +title: "messages.getSplitRanges" +description: "Get message ranges for saving the user's chat history" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSplitRanges.html +--- +# Method: messages.getSplitRanges +[Back to methods index](index.html) + + + +Get message ranges for saving the user's chat history + + + +### Return type: [Vector\_of\_MessageRange](/API_docs/types/MessageRange.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_MessageRange = $MadelineProto->messages->getSplitRanges(); +``` + diff --git a/docs/API_docs/methods/messages.getStickerSet.md b/docs/API_docs/methods/messages.getStickerSet.md new file mode 100644 index 0000000000..025860db6c --- /dev/null +++ b/docs/API_docs/methods/messages.getStickerSet.md @@ -0,0 +1,43 @@ +--- +title: "messages.getStickerSet" +description: "Get info about a stickerset" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getStickerSet.html +--- +# Method: messages.getStickerSet +[Back to methods index](index.html) + + + +Get info about a stickerset + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Stickerset | Optional| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->messages->getStickerSet(stickerset: $InputStickerSet, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getStickers.md b/docs/API_docs/methods/messages.getStickers.md new file mode 100644 index 0000000000..ed2f17aeb9 --- /dev/null +++ b/docs/API_docs/methods/messages.getStickers.md @@ -0,0 +1,43 @@ +--- +title: "messages.getStickers" +description: "Get stickers by emoji" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getStickers.html +--- +# Method: messages.getStickers +[Back to methods index](index.html) + + + +Get stickers by emoji + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|emoticon|[string](/API_docs/types/string.html) | The emoji | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Stickers](/API_docs/types/messages.Stickers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Stickers = $MadelineProto->messages->getStickers(emoticon: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getSuggestedDialogFilters.md b/docs/API_docs/methods/messages.getSuggestedDialogFilters.md new file mode 100644 index 0000000000..c1b6a380f5 --- /dev/null +++ b/docs/API_docs/methods/messages.getSuggestedDialogFilters.md @@ -0,0 +1,37 @@ +--- +title: "messages.getSuggestedDialogFilters" +description: "Get [suggested folders](https://core.telegram.org/api/folders)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getSuggestedDialogFilters.html +--- +# Method: messages.getSuggestedDialogFilters +[Back to methods index](index.html) + + + +Get [suggested folders](https://core.telegram.org/api/folders) + + + +### Return type: [Vector\_of\_DialogFilterSuggested](/API_docs/types/DialogFilterSuggested.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_DialogFilterSuggested = $MadelineProto->messages->getSuggestedDialogFilters(); +``` + diff --git a/docs/API_docs/methods/messages.getTopReactions.md b/docs/API_docs/methods/messages.getTopReactions.md new file mode 100644 index 0000000000..c0af37f645 --- /dev/null +++ b/docs/API_docs/methods/messages.getTopReactions.md @@ -0,0 +1,43 @@ +--- +title: "messages.getTopReactions" +description: "Got popular [message reactions](https://core.telegram.org/api/reactions)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getTopReactions.html +--- +# Method: messages.getTopReactions +[Back to methods index](index.html) + + + +Got popular [message reactions](https://core.telegram.org/api/reactions) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.Reactions](/API_docs/types/messages.Reactions.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Reactions = $MadelineProto->messages->getTopReactions(limit: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getUnreadMentions.md b/docs/API_docs/methods/messages.getUnreadMentions.md new file mode 100644 index 0000000000..36580ecb70 --- /dev/null +++ b/docs/API_docs/methods/messages.getUnreadMentions.md @@ -0,0 +1,48 @@ +--- +title: "messages.getUnreadMentions" +description: "Get unread messages where we were mentioned" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getUnreadMentions.html +--- +# Method: messages.getUnreadMentions +[Back to methods index](index.html) + + + +Get unread messages where we were mentioned + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where to look for mentions | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | If set, considers only messages within the specified [forum topic](https://core.telegram.org/api/forum#forum-topics) | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|add\_offset|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|max\_id|[int](/API_docs/types/int.html) | Maximum message ID to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|min\_id|[int](/API_docs/types/int.html) | Minimum message ID to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getUnreadMentions(peer: $InputPeer, top_msg_id: $int, offset_id: $int, add_offset: $int, limit: $int, max_id: $int, min_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getUnreadReactions.md b/docs/API_docs/methods/messages.getUnreadReactions.md new file mode 100644 index 0000000000..c7232aab13 --- /dev/null +++ b/docs/API_docs/methods/messages.getUnreadReactions.md @@ -0,0 +1,48 @@ +--- +title: "messages.getUnreadReactions" +description: "Get unread reactions to messages you sent" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getUnreadReactions.html +--- +# Method: messages.getUnreadReactions +[Back to methods index](index.html) + + + +Get unread reactions to messages you sent + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | If set, considers only reactions to messages within the specified [forum topic](https://core.telegram.org/api/forum#forum-topics) | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|add\_offset|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| +|max\_id|[int](/API_docs/types/int.html) | Only return reactions for messages up until this message ID | Optional| +|min\_id|[int](/API_docs/types/int.html) | Only return reactions for messages starting from this message ID | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->getUnreadReactions(peer: $InputPeer, top_msg_id: $int, offset_id: $int, add_offset: $int, limit: $int, max_id: $int, min_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.getWebPage.md b/docs/API_docs/methods/messages.getWebPage.md new file mode 100644 index 0000000000..b7c114e365 --- /dev/null +++ b/docs/API_docs/methods/messages.getWebPage.md @@ -0,0 +1,43 @@ +--- +title: "messages.getWebPage" +description: "Get [instant view](https://instantview.telegram.org) page" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getWebPage.html +--- +# Method: messages.getWebPage +[Back to methods index](index.html) + + + +Get [instant view](https://instantview.telegram.org) page + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|url|[string](/API_docs/types/string.html) | URL of IV page to fetch | Optional| +|hash|Array of [long](/API_docs/types/long.html) | | Optional| + + +### Return type: [messages.WebPage](/API_docs/types/messages.WebPage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_WebPage = $MadelineProto->messages->getWebPage(url: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.getWebPagePreview.md b/docs/API_docs/methods/messages.getWebPagePreview.md new file mode 100644 index 0000000000..1c7c965ee5 --- /dev/null +++ b/docs/API_docs/methods/messages.getWebPagePreview.md @@ -0,0 +1,110 @@ +--- +title: "messages.getWebPagePreview" +description: "Get preview of webpage" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_getWebPagePreview.html +--- +# Method: messages.getWebPagePreview +[Back to methods index](index.html) + + + +Get preview of webpage + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|message|[string](/API_docs/types/string.html) | Message from which to extract the preview | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | [Message entities for styled text](https://core.telegram.org/api/entities) | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | + + +### Return type: [MessageMedia](/API_docs/types/MessageMedia.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$MessageMedia = $MadelineProto->messages->getWebPagePreview(message: 'string', entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [MessageMedia](../types/MessageMedia.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/messages.hideAllChatJoinRequests.md b/docs/API_docs/methods/messages.hideAllChatJoinRequests.md new file mode 100644 index 0000000000..94e3f0ccda --- /dev/null +++ b/docs/API_docs/methods/messages.hideAllChatJoinRequests.md @@ -0,0 +1,44 @@ +--- +title: "messages.hideAllChatJoinRequests" +description: "Dismiss or approve all [join requests](https://core.telegram.org/api/invites#join-requests) related to a specific chat or channel." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_hideAllChatJoinRequests.html +--- +# Method: messages.hideAllChatJoinRequests +[Back to methods index](index.html) + + + +Dismiss or approve all [join requests](https://core.telegram.org/api/invites#join-requests) related to a specific chat or channel. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|approved|[Bool](/API_docs/types/Bool.html) | Whether to dismiss or approve all chat [join requests »](https://core.telegram.org/api/invites#join-requests) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat or channel | Optional| +|link|[string](/API_docs/types/string.html) | Only dismiss or approve [join requests »](https://core.telegram.org/api/invites#join-requests) initiated using this invite link | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->hideAllChatJoinRequests(approved: $Bool, peer: $InputPeer, link: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.hideChatJoinRequest.md b/docs/API_docs/methods/messages.hideChatJoinRequest.md new file mode 100644 index 0000000000..d11e57e53f --- /dev/null +++ b/docs/API_docs/methods/messages.hideChatJoinRequest.md @@ -0,0 +1,44 @@ +--- +title: "messages.hideChatJoinRequest" +description: "Dismiss or approve a chat [join request](https://core.telegram.org/api/invites#join-requests) related to a specific chat or channel." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_hideChatJoinRequest.html +--- +# Method: messages.hideChatJoinRequest +[Back to methods index](index.html) + + + +Dismiss or approve a chat [join request](https://core.telegram.org/api/invites#join-requests) related to a specific chat or channel. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|approved|[Bool](/API_docs/types/Bool.html) | Whether to dismiss or approve the chat [join request »](https://core.telegram.org/api/invites#join-requests) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat or channel | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The user whose [join request »](https://core.telegram.org/api/invites#join-requests) should be dismissed or approved | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->hideChatJoinRequest(approved: $Bool, peer: $InputPeer, user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/messages.hidePeerSettingsBar.md b/docs/API_docs/methods/messages.hidePeerSettingsBar.md new file mode 100644 index 0000000000..88742b6d02 --- /dev/null +++ b/docs/API_docs/methods/messages.hidePeerSettingsBar.md @@ -0,0 +1,42 @@ +--- +title: "messages.hidePeerSettingsBar" +description: "Should be called after the user hides the [report spam/add as contact bar](https://core.telegram.org/api/action-bar) of a new chat, effectively prevents the user from executing the actions specified in the [action bar »](https://core.telegram.org/api/action-bar)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_hidePeerSettingsBar.html +--- +# Method: messages.hidePeerSettingsBar +[Back to methods index](index.html) + + + +Should be called after the user hides the [report spam/add as contact bar](https://core.telegram.org/api/action-bar) of a new chat, effectively prevents the user from executing the actions specified in the [action bar »](https://core.telegram.org/api/action-bar). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->hidePeerSettingsBar(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.importChatInvite.md b/docs/API_docs/methods/messages.importChatInvite.md new file mode 100644 index 0000000000..ad0b5fe5ab --- /dev/null +++ b/docs/API_docs/methods/messages.importChatInvite.md @@ -0,0 +1,42 @@ +--- +title: "messages.importChatInvite" +description: "Import a chat invite and join a private chat/supergroup/channel" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_importChatInvite.html +--- +# Method: messages.importChatInvite +[Back to methods index](index.html) + + + +Import a chat invite and join a private chat/supergroup/channel + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hash|[string](/API_docs/types/string.html) | `hash` from a [chat invite deep link](https://core.telegram.org/api/links#chat-invite-links) | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->importChatInvite(hash: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.initHistoryImport.md b/docs/API_docs/methods/messages.initHistoryImport.md new file mode 100644 index 0000000000..558fb42473 --- /dev/null +++ b/docs/API_docs/methods/messages.initHistoryImport.md @@ -0,0 +1,44 @@ +--- +title: "messages.initHistoryImport" +description: "Import chat history from a foreign chat app into a specific Telegram chat, [click here for more info about imported chats »](https://core.telegram.org/api/import)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_initHistoryImport.html +--- +# Method: messages.initHistoryImport +[Back to methods index](index.html) + + + +Import chat history from a foreign chat app into a specific Telegram chat, [click here for more info about imported chats »](https://core.telegram.org/api/import). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The Telegram chat where the [history should be imported](https://core.telegram.org/api/import). | Optional| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | File with messages to import. | Yes| +|media\_count|[int](/API_docs/types/int.html) | Number of media files associated with the chat that will be uploaded using [messages.uploadImportedMedia](../methods/messages.uploadImportedMedia.html). | Optional| + + +### Return type: [messages.HistoryImport](/API_docs/types/messages.HistoryImport.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_HistoryImport = $MadelineProto->messages->initHistoryImport(peer: $InputPeer, file: $InputFile, media_count: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.installStickerSet.md b/docs/API_docs/methods/messages.installStickerSet.md new file mode 100644 index 0000000000..38e6f2d7e3 --- /dev/null +++ b/docs/API_docs/methods/messages.installStickerSet.md @@ -0,0 +1,43 @@ +--- +title: "messages.installStickerSet" +description: "Install a stickerset" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_installStickerSet.html +--- +# Method: messages.installStickerSet +[Back to methods index](index.html) + + + +Install a stickerset + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Stickerset to install | Optional| +|archived|[Bool](/API_docs/types/Bool.html) | Whether to archive stickerset | Yes| + + +### Return type: [messages.StickerSetInstallResult](/API_docs/types/messages.StickerSetInstallResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSetInstallResult = $MadelineProto->messages->installStickerSet(stickerset: $InputStickerSet, archived: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.markDialogUnread.md b/docs/API_docs/methods/messages.markDialogUnread.md new file mode 100644 index 0000000000..451d056848 --- /dev/null +++ b/docs/API_docs/methods/messages.markDialogUnread.md @@ -0,0 +1,43 @@ +--- +title: "messages.markDialogUnread" +description: "Manually mark dialog as unread" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_markDialogUnread.html +--- +# Method: messages.markDialogUnread +[Back to methods index](index.html) + + + +Manually mark dialog as unread + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|unread|[Bool](/API_docs/types/Bool.html) | Mark as unread/read | Optional| +|peer|[InputDialogPeer](/API_docs/types/InputDialogPeer.html) | Dialog | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->markDialogUnread(unread: $Bool, peer: $InputDialogPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.migrateChat.md b/docs/API_docs/methods/messages.migrateChat.md new file mode 100644 index 0000000000..fb6aac437d --- /dev/null +++ b/docs/API_docs/methods/messages.migrateChat.md @@ -0,0 +1,42 @@ +--- +title: "messages.migrateChat" +description: "Turn a [basic group into a supergroup](https://core.telegram.org/api/channel#migration)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_migrateChat.html +--- +# Method: messages.migrateChat +[Back to methods index](index.html) + + + +Turn a [basic group into a supergroup](https://core.telegram.org/api/channel#migration) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|chat\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->migrateChat(chat_id: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.prolongWebView.md b/docs/API_docs/methods/messages.prolongWebView.md new file mode 100644 index 0000000000..3f01fb7b86 --- /dev/null +++ b/docs/API_docs/methods/messages.prolongWebView.md @@ -0,0 +1,49 @@ +--- +title: "messages.prolongWebView" +description: "Indicate to the server (from the user side) that the user is still using a web app." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_prolongWebView.html +--- +# Method: messages.prolongWebView +[Back to methods index](index.html) + + + +Indicate to the server (from the user side) that the user is still using a web app. + +If the method returns a `QUERY_ID_INVALID` error, the webview must be closed. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Whether the inline message that will be sent by the bot on behalf of the user once the web app interaction is [terminated](../methods/messages.sendWebViewResultMessage.html) should be sent silently (no notifications for the receivers). | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Dialog where the web app was opened. | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Bot that owns the [web app](https://core.telegram.org/api/bots/webapps) | Optional| +|query\_id|[long](/API_docs/types/long.html) | Web app interaction ID obtained from [messages.requestWebView](../methods/messages.requestWebView.html) | Yes| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the inline message that will be sent by the bot on behalf of the user once the web app interaction is [terminated](../methods/messages.sendWebViewResultMessage.html) should be sent in reply to the specified message or story. | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Open the web app as the specified peer | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->prolongWebView(silent: $Bool, peer: $InputPeer, bot: $InputUser, query_id: $long, reply_to: $InputReplyTo, send_as: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.rateTranscribedAudio.md b/docs/API_docs/methods/messages.rateTranscribedAudio.md new file mode 100644 index 0000000000..8195526e63 --- /dev/null +++ b/docs/API_docs/methods/messages.rateTranscribedAudio.md @@ -0,0 +1,45 @@ +--- +title: "messages.rateTranscribedAudio" +description: "Rate [transcribed voice message](https://core.telegram.org/api/transcribe)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_rateTranscribedAudio.html +--- +# Method: messages.rateTranscribedAudio +[Back to methods index](index.html) + + + +Rate [transcribed voice message](https://core.telegram.org/api/transcribe) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the voice message was sent | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID | Optional| +|transcription\_id|[long](/API_docs/types/long.html) | Transcription ID | Yes| +|good|[Bool](/API_docs/types/Bool.html) | Whether the transcription was correct | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->rateTranscribedAudio(peer: $InputPeer, msg_id: $int, transcription_id: $long, good: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.readDiscussion.md b/docs/API_docs/methods/messages.readDiscussion.md new file mode 100644 index 0000000000..dd6c11ec09 --- /dev/null +++ b/docs/API_docs/methods/messages.readDiscussion.md @@ -0,0 +1,44 @@ +--- +title: "messages.readDiscussion" +description: "Mark a [thread](https://core.telegram.org/api/threads) as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readDiscussion.html +--- +# Method: messages.readDiscussion +[Back to methods index](index.html) + + + +Mark a [thread](https://core.telegram.org/api/threads) as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Group ID | Optional| +|msg\_id|[int](/API_docs/types/int.html) | ID of message that started the thread | Optional| +|read\_max\_id|[int](/API_docs/types/int.html) | ID up to which thread messages were read | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->readDiscussion(peer: $InputPeer, msg_id: $int, read_max_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.readEncryptedHistory.md b/docs/API_docs/methods/messages.readEncryptedHistory.md new file mode 100644 index 0000000000..e2e908b47a --- /dev/null +++ b/docs/API_docs/methods/messages.readEncryptedHistory.md @@ -0,0 +1,43 @@ +--- +title: "messages.readEncryptedHistory" +description: "Marks message history within a secret chat as read." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readEncryptedHistory.html +--- +# Method: messages.readEncryptedHistory +[Back to methods index](index.html) + + + +Marks message history within a secret chat as read. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | Secret chat ID | Yes| +|max\_date|[int](/API_docs/types/int.html) | Maximum date value for received messages in history | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->readEncryptedHistory(peer: $InputEncryptedChat, max_date: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.readFeaturedStickers.md b/docs/API_docs/methods/messages.readFeaturedStickers.md new file mode 100644 index 0000000000..a5abf39dd1 --- /dev/null +++ b/docs/API_docs/methods/messages.readFeaturedStickers.md @@ -0,0 +1,42 @@ +--- +title: "messages.readFeaturedStickers" +description: "Mark new featured stickers as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readFeaturedStickers.html +--- +# Method: messages.readFeaturedStickers +[Back to methods index](index.html) + + + +Mark new featured stickers as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [long](/API_docs/types/long.html) | IDs of stickersets to mark as read | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->readFeaturedStickers(id: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.readHistory.md b/docs/API_docs/methods/messages.readHistory.md new file mode 100644 index 0000000000..b384153c2c --- /dev/null +++ b/docs/API_docs/methods/messages.readHistory.md @@ -0,0 +1,43 @@ +--- +title: "messages.readHistory" +description: "Marks message history as read." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readHistory.html +--- +# Method: messages.readHistory +[Back to methods index](index.html) + + + +Marks message history as read. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Target user or group | Optional| +|max\_id|[int](/API_docs/types/int.html) | If a positive value is passed, only messages with identifiers less or equal than the given one will be read | Optional| + + +### Return type: [messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedMessages = $MadelineProto->messages->readHistory(peer: $InputPeer, max_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.readMentions.md b/docs/API_docs/methods/messages.readMentions.md new file mode 100644 index 0000000000..2a1f261afd --- /dev/null +++ b/docs/API_docs/methods/messages.readMentions.md @@ -0,0 +1,43 @@ +--- +title: "messages.readMentions" +description: "Mark mentions as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readMentions.html +--- +# Method: messages.readMentions +[Back to methods index](index.html) + + + +Mark mentions as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Dialog | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | Mark as read only mentions within the specified [forum topic](https://core.telegram.org/api/forum#forum-topics) | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->messages->readMentions(peer: $InputPeer, top_msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.readMessageContents.md b/docs/API_docs/methods/messages.readMessageContents.md new file mode 100644 index 0000000000..f24c457cf3 --- /dev/null +++ b/docs/API_docs/methods/messages.readMessageContents.md @@ -0,0 +1,42 @@ +--- +title: "messages.readMessageContents" +description: "Notifies the sender about the recipient having listened a voice message or watched a video." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readMessageContents.html +--- +# Method: messages.readMessageContents +[Back to methods index](index.html) + + + +Notifies the sender about the recipient having listened a voice message or watched a video. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [int](/API_docs/types/int.html) | Message ID list | Yes| + + +### Return type: [messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedMessages = $MadelineProto->messages->readMessageContents(id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.readReactions.md b/docs/API_docs/methods/messages.readReactions.md new file mode 100644 index 0000000000..66ebe44c3f --- /dev/null +++ b/docs/API_docs/methods/messages.readReactions.md @@ -0,0 +1,43 @@ +--- +title: "messages.readReactions" +description: "Mark [message reactions »](https://core.telegram.org/api/reactions) as read" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_readReactions.html +--- +# Method: messages.readReactions +[Back to methods index](index.html) + + + +Mark [message reactions »](https://core.telegram.org/api/reactions) as read + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | Mark as read only reactions to messages within the specified [forum topic](https://core.telegram.org/api/forum#forum-topics) | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->messages->readReactions(peer: $InputPeer, top_msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.receivedMessages.md b/docs/API_docs/methods/messages.receivedMessages.md new file mode 100644 index 0000000000..f7679079df --- /dev/null +++ b/docs/API_docs/methods/messages.receivedMessages.md @@ -0,0 +1,42 @@ +--- +title: "messages.receivedMessages" +description: "Confirms receipt of messages by a client, cancels PUSH-notification sending." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_receivedMessages.html +--- +# Method: messages.receivedMessages +[Back to methods index](index.html) + + + +Confirms receipt of messages by a client, cancels PUSH-notification sending. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|max\_id|[int](/API_docs/types/int.html) | Maximum message ID available in a client. | Optional| + + +### Return type: [Vector\_of\_ReceivedNotifyMessage](/API_docs/types/ReceivedNotifyMessage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_ReceivedNotifyMessage = $MadelineProto->messages->receivedMessages(max_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.receivedQueue.md b/docs/API_docs/methods/messages.receivedQueue.md new file mode 100644 index 0000000000..17803a4707 --- /dev/null +++ b/docs/API_docs/methods/messages.receivedQueue.md @@ -0,0 +1,42 @@ +--- +title: "messages.receivedQueue" +description: "You cannot use this method directly" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_receivedQueue.html +--- +# Method: messages.receivedQueue +[Back to methods index](index.html) + + + +You cannot use this method directly + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|max\_qts|[int](/API_docs/types/int.html) | Maximum qts value available at the client | Optional| + + +### Return type: [Vector\_of\_long](/API_docs/types/long.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_long = $MadelineProto->messages->receivedQueue(max_qts: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.reorderPinnedDialogs.md b/docs/API_docs/methods/messages.reorderPinnedDialogs.md new file mode 100644 index 0000000000..a453d4e3ee --- /dev/null +++ b/docs/API_docs/methods/messages.reorderPinnedDialogs.md @@ -0,0 +1,44 @@ +--- +title: "messages.reorderPinnedDialogs" +description: "Reorder pinned dialogs" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reorderPinnedDialogs.html +--- +# Method: messages.reorderPinnedDialogs +[Back to methods index](index.html) + + + +Reorder pinned dialogs + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|force|[Bool](/API_docs/types/Bool.html) | If set, dialogs pinned server-side but not present in the `order` field will be unpinned. | Optional| +|folder\_id|[int](/API_docs/types/int.html) | [Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders) | Optional| +|order|Array of [InputDialogPeer](/API_docs/types/InputDialogPeer.html) | New dialog order | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reorderPinnedDialogs(force: $Bool, folder_id: $int, order: [$InputDialogPeer, $InputDialogPeer], ); +``` + diff --git a/docs/API_docs/methods/messages.reorderPinnedSavedDialogs.md b/docs/API_docs/methods/messages.reorderPinnedSavedDialogs.md new file mode 100644 index 0000000000..0e62976e88 --- /dev/null +++ b/docs/API_docs/methods/messages.reorderPinnedSavedDialogs.md @@ -0,0 +1,43 @@ +--- +title: "messages.reorderPinnedSavedDialogs" +description: "Reorder pinned [saved message dialogs »](https://core.telegram.org/api/saved-messages)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reorderPinnedSavedDialogs.html +--- +# Method: messages.reorderPinnedSavedDialogs +[Back to methods index](index.html) + + + +Reorder pinned [saved message dialogs »](https://core.telegram.org/api/saved-messages). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|force|[Bool](/API_docs/types/Bool.html) | If set, dialogs pinned server-side but not present in the `order` field will be unpinned. | Optional| +|order|Array of [InputDialogPeer](/API_docs/types/InputDialogPeer.html) | New dialog order | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reorderPinnedSavedDialogs(force: $Bool, order: [$InputDialogPeer, $InputDialogPeer], ); +``` + diff --git a/docs/API_docs/methods/messages.reorderQuickReplies.md b/docs/API_docs/methods/messages.reorderQuickReplies.md new file mode 100644 index 0000000000..c8e242b0fd --- /dev/null +++ b/docs/API_docs/methods/messages.reorderQuickReplies.md @@ -0,0 +1,40 @@ +--- +title: "messages.reorderQuickReplies" +description: "messages.reorderQuickReplies parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reorderQuickReplies.html +--- +# Method: messages.reorderQuickReplies +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|order|Array of [int](/API_docs/types/int.html) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reorderQuickReplies(order: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.reorderStickerSets.md b/docs/API_docs/methods/messages.reorderStickerSets.md new file mode 100644 index 0000000000..def0146076 --- /dev/null +++ b/docs/API_docs/methods/messages.reorderStickerSets.md @@ -0,0 +1,44 @@ +--- +title: "messages.reorderStickerSets" +description: "Reorder installed stickersets" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reorderStickerSets.html +--- +# Method: messages.reorderStickerSets +[Back to methods index](index.html) + + + +Reorder installed stickersets + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|masks|[Bool](/API_docs/types/Bool.html) | Reorder mask stickersets | Optional| +|emojis|[Bool](/API_docs/types/Bool.html) | Reorder [custom emoji stickersets](https://core.telegram.org/api/custom-emoji) | Optional| +|order|Array of [long](/API_docs/types/long.html) | New stickerset order by stickerset IDs | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reorderStickerSets(masks: $Bool, emojis: $Bool, order: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.report.md b/docs/API_docs/methods/messages.report.md new file mode 100644 index 0000000000..f574f00ce0 --- /dev/null +++ b/docs/API_docs/methods/messages.report.md @@ -0,0 +1,51 @@ +--- +title: "messages.report" +description: "Report a message in a chat for violation of telegram's Terms of Service" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_report.html +--- +# Method: messages.report +[Back to methods index](index.html) + + + +Report a message in a chat for violation of telegram's Terms of Service + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of messages to report | Yes| +|reason|[ReportReason](/API_docs/types/ReportReason.html) | Why are these messages being reported | Yes| +|message|[string](/API_docs/types/string.html) | Comment for report moderation | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->report(peer: $InputPeer, id: [$int, $int], reason: $ReportReason, message: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/messages.reportEncryptedSpam.md b/docs/API_docs/methods/messages.reportEncryptedSpam.md new file mode 100644 index 0000000000..9578f31235 --- /dev/null +++ b/docs/API_docs/methods/messages.reportEncryptedSpam.md @@ -0,0 +1,42 @@ +--- +title: "messages.reportEncryptedSpam" +description: "Report a secret chat for spam" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reportEncryptedSpam.html +--- +# Method: messages.reportEncryptedSpam +[Back to methods index](index.html) + + + +Report a secret chat for spam + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | The secret chat to report | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reportEncryptedSpam(peer: $InputEncryptedChat, ); +``` + diff --git a/docs/API_docs/methods/messages.reportReaction.md b/docs/API_docs/methods/messages.reportReaction.md new file mode 100644 index 0000000000..52870d2034 --- /dev/null +++ b/docs/API_docs/methods/messages.reportReaction.md @@ -0,0 +1,44 @@ +--- +title: "messages.reportReaction" +description: "Report a [message reaction](https://core.telegram.org/api/reactions)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reportReaction.html +--- +# Method: messages.reportReaction +[Back to methods index](index.html) + + + +Report a [message reaction](https://core.telegram.org/api/reactions) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the message was sent | Optional| +|id|[int](/API_docs/types/int.html) | Message ID | Optional| +|reaction\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer that sent the reaction | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reportReaction(peer: $InputPeer, id: $int, reaction_peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.reportSpam.md b/docs/API_docs/methods/messages.reportSpam.md new file mode 100644 index 0000000000..b9436c8192 --- /dev/null +++ b/docs/API_docs/methods/messages.reportSpam.md @@ -0,0 +1,42 @@ +--- +title: "messages.reportSpam" +description: "Report a new incoming chat for spam, if the [peer settings](../constructors/peerSettings.html) of the chat allow us to do that" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_reportSpam.html +--- +# Method: messages.reportSpam +[Back to methods index](index.html) + + + +Report a new incoming chat for spam, if the [peer settings](../constructors/peerSettings.html) of the chat allow us to do that + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer to report | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->reportSpam(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.requestAppWebView.md b/docs/API_docs/methods/messages.requestAppWebView.md new file mode 100644 index 0000000000..cbba980837 --- /dev/null +++ b/docs/API_docs/methods/messages.requestAppWebView.md @@ -0,0 +1,49 @@ +--- +title: "messages.requestAppWebView" +description: "Open a [bot mini app](https://core.telegram.org/bots/webapps) from a [direct Mini App deep link](https://core.telegram.org/api/links#direct-mini-app-links), sending over user information after user confirmation." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_requestAppWebView.html +--- +# Method: messages.requestAppWebView +[Back to methods index](index.html) + + + +Open a [bot mini app](https://core.telegram.org/bots/webapps) from a [direct Mini App deep link](https://core.telegram.org/api/links#direct-mini-app-links), sending over user information after user confirmation. + +After calling this method, until the user closes the webview, [messages.prolongWebView](../methods/messages.prolongWebView.html) must be called every 60 seconds. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|write\_allowed|[Bool](/API_docs/types/Bool.html) | Set this flag if the bot is asking permission to send messages to the user as specified in the [direct Mini App deep link](https://core.telegram.org/api/links#direct-mini-app-links) docs, and the user agreed. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | If the client has clicked on the link in a Telegram chat, pass the chat's peer information; otherwise pass the bot's peer information, instead. | Optional| +|app|[InputBotApp](/API_docs/types/InputBotApp.html) | The app obtained by invoking [messages.getBotApp](../methods/messages.getBotApp.html) as specified in the [direct Mini App deep link](https://core.telegram.org/api/links#direct-mini-app-links) docs. | Yes| +|start\_param|[string](/API_docs/types/string.html) | If the `startapp` query string parameter is present in the [direct Mini App deep link](https://core.telegram.org/api/links#direct-mini-app-links), pass it to `start_param`. | Optional| +|theme\_params|[DataJSON](/API_docs/types/DataJSON.html) | [Theme parameters »](https://core.telegram.org/api/bots/webapps#theme-parameters) | Optional| +|platform|[string](/API_docs/types/string.html) | Short name of the application; 0-64 English letters, digits, and underscores | Optional| + + +### Return type: [AppWebViewResult](/API_docs/types/AppWebViewResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$AppWebViewResult = $MadelineProto->messages->requestAppWebView(write_allowed: $Bool, peer: $InputPeer, app: $InputBotApp, start_param: 'string', theme_params: $DataJSON, platform: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.requestEncryption.md b/docs/API_docs/methods/messages.requestEncryption.md new file mode 100644 index 0000000000..065d58a3e4 --- /dev/null +++ b/docs/API_docs/methods/messages.requestEncryption.md @@ -0,0 +1,43 @@ +--- +title: "messages.requestEncryption" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_requestEncryption.html +--- +# Method: messages.requestEncryption +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz for more info on handling secret chats + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID | Optional| +|g\_a|[bytes](/API_docs/types/bytes.html) | `A = g ^ a mod p`, see [Wikipedia](https://en.wikipedia.org/wiki/Diffie%E2%80%93Hellman_key_exchange) | Yes| + + +### Return type: [EncryptedChat](/API_docs/types/EncryptedChat.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EncryptedChat = $MadelineProto->messages->requestEncryption(user_id: $InputUser, g_a: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/messages.requestSimpleWebView.md b/docs/API_docs/methods/messages.requestSimpleWebView.md new file mode 100644 index 0000000000..dda02d3373 --- /dev/null +++ b/docs/API_docs/methods/messages.requestSimpleWebView.md @@ -0,0 +1,48 @@ +--- +title: "messages.requestSimpleWebView" +description: "Open a [bot mini app](https://core.telegram.org/api/bots/webapps)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_requestSimpleWebView.html +--- +# Method: messages.requestSimpleWebView +[Back to methods index](index.html) + + + +Open a [bot mini app](https://core.telegram.org/api/bots/webapps). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|from\_switch\_webview|[Bool](/API_docs/types/Bool.html) | Whether the webapp was opened by clicking on the `switch_webview` button shown on top of the inline results list returned by [messages.getInlineBotResults](../methods/messages.getInlineBotResults.html). | Optional| +|from\_side\_menu|[Bool](/API_docs/types/Bool.html) | Set this flag if opening the Mini App from the installed [side menu entry »](https://core.telegram.org/api/bots/attach) or from a [Mini App link »](https://core.telegram.org/api/links#mini-app-links). | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Bot that owns the mini app | Optional| +|url|[string](/API_docs/types/string.html) | Web app URL, if opening from a keyboard button or inline result | Optional| +|start\_param|[string](/API_docs/types/string.html) | Start parameter, if opening from a [Mini App link »](https://core.telegram.org/api/links#mini-app-links). | Optional| +|theme\_params|[DataJSON](/API_docs/types/DataJSON.html) | [Theme parameters »](https://core.telegram.org/api/bots/webapps#theme-parameters) | Optional| +|platform|[string](/API_docs/types/string.html) | Short name of the application; 0-64 English letters, digits, and underscores | Optional| + + +### Return type: [SimpleWebViewResult](/API_docs/types/SimpleWebViewResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$SimpleWebViewResult = $MadelineProto->messages->requestSimpleWebView(from_switch_webview: $Bool, from_side_menu: $Bool, bot: $InputUser, url: 'string', start_param: 'string', theme_params: $DataJSON, platform: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.requestUrlAuth.md b/docs/API_docs/methods/messages.requestUrlAuth.md new file mode 100644 index 0000000000..b5843e60ae --- /dev/null +++ b/docs/API_docs/methods/messages.requestUrlAuth.md @@ -0,0 +1,45 @@ +--- +title: "messages.requestUrlAuth" +description: "Get more info about a Seamless Telegram Login authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_requestUrlAuth.html +--- +# Method: messages.requestUrlAuth +[Back to methods index](index.html) + + + +Get more info about a Seamless Telegram Login authorization request, for more info [click here »](https://core.telegram.org/api/url-authorization) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the message is located | Optional| +|msg\_id|[int](/API_docs/types/int.html) | The message | Optional| +|button\_id|[int](/API_docs/types/int.html) | The ID of the button with the authorization request | Optional| +|url|[string](/API_docs/types/string.html) | URL used for [link URL authorization, click here for more info »](https://core.telegram.org/api/url-authorization#link-url-authorization) | Optional| + + +### Return type: [UrlAuthResult](/API_docs/types/UrlAuthResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$UrlAuthResult = $MadelineProto->messages->requestUrlAuth(peer: $InputPeer, msg_id: $int, button_id: $int, url: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.requestWebView.md b/docs/API_docs/methods/messages.requestWebView.md new file mode 100644 index 0000000000..0a9de94cc9 --- /dev/null +++ b/docs/API_docs/methods/messages.requestWebView.md @@ -0,0 +1,53 @@ +--- +title: "messages.requestWebView" +description: "Open a [bot mini app](https://core.telegram.org/bots/webapps), sending over user information after user confirmation." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_requestWebView.html +--- +# Method: messages.requestWebView +[Back to methods index](index.html) + + + +Open a [bot mini app](https://core.telegram.org/bots/webapps), sending over user information after user confirmation. + +After calling this method, until the user closes the webview, [messages.prolongWebView](../methods/messages.prolongWebView.html) must be called every 60 seconds. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|from\_bot\_menu|[Bool](/API_docs/types/Bool.html) | Whether the webview was opened by clicking on the bot's [menu button »](https://core.telegram.org/api/bots/menu). | Optional| +|silent|[Bool](/API_docs/types/Bool.html) | Whether the inline message that will be sent by the bot on behalf of the user once the web app interaction is [terminated](../methods/messages.sendWebViewResultMessage.html) should be sent silently (no notifications for the receivers). | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Dialog where the web app is being opened, and where the resulting message will be sent (see the [docs for more info »](https://core.telegram.org/api/bots/webapps)). | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Bot that owns the [web app](https://core.telegram.org/api/bots/webapps) | Optional| +|url|[string](/API_docs/types/string.html) | [Web app URL](https://core.telegram.org/api/bots/webapps) | Optional| +|start\_param|[string](/API_docs/types/string.html) | If the web app was opened from the attachment menu using a [attachment menu deep link](https://core.telegram.org/api/links#bot-attachment-or-side-menu-links), `start_param` should contain the `data` from the `startattach` parameter. | Optional| +|theme\_params|[DataJSON](/API_docs/types/DataJSON.html) | [Theme parameters »](https://core.telegram.org/api/bots/webapps#theme-parameters) | Optional| +|platform|[string](/API_docs/types/string.html) | Short name of the application; 0-64 English letters, digits, and underscores | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the inline message that will be sent by the bot on behalf of the user once the web app interaction is [terminated](../methods/messages.sendWebViewResultMessage.html) should be sent in reply to the specified message or story. | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Open the web app as the specified peer, sending the resulting the message as the specified peer. | Optional| + + +### Return type: [WebViewResult](/API_docs/types/WebViewResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$WebViewResult = $MadelineProto->messages->requestWebView(from_bot_menu: $Bool, silent: $Bool, peer: $InputPeer, bot: $InputUser, url: 'string', start_param: 'string', theme_params: $DataJSON, platform: 'string', reply_to: $InputReplyTo, send_as: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.saveDefaultSendAs.md b/docs/API_docs/methods/messages.saveDefaultSendAs.md new file mode 100644 index 0000000000..6bfa4ab270 --- /dev/null +++ b/docs/API_docs/methods/messages.saveDefaultSendAs.md @@ -0,0 +1,43 @@ +--- +title: "messages.saveDefaultSendAs" +description: "Change the default peer that should be used when sending messages, reactions, poll votes to a specific group" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_saveDefaultSendAs.html +--- +# Method: messages.saveDefaultSendAs +[Back to methods index](index.html) + + + +Change the default peer that should be used when sending messages, reactions, poll votes to a specific group + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Group | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The default peer that should be used when sending messages to the group | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->saveDefaultSendAs(peer: $InputPeer, send_as: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.saveDraft.md b/docs/API_docs/methods/messages.saveDraft.md new file mode 100644 index 0000000000..5a5eee8def --- /dev/null +++ b/docs/API_docs/methods/messages.saveDraft.md @@ -0,0 +1,115 @@ +--- +title: "messages.saveDraft" +description: "Save a message [draft](https://core.telegram.org/api/drafts) associated to a chat." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_saveDraft.html +--- +# Method: messages.saveDraft +[Back to methods index](index.html) + + + +Save a message [draft](https://core.telegram.org/api/drafts) associated to a chat. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Disable generation of the webpage preview | Optional| +|invert\_media|[Bool](/API_docs/types/Bool.html) | If set, any eventual webpage preview will be shown on top of the message instead of at the bottom. | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the message should be sent in reply to the specified message or story. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Destination of the message that should be sent | Optional| +|message|[string](/API_docs/types/string.html) | The draft | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Message [entities](https://core.telegram.org/api/entities) for styled text | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | Attached media | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->saveDraft(no_webpage: $Bool, invert_media: $Bool, reply_to: $InputReplyTo, peer: $InputPeer, message: 'string', entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', media: $InputMedia, ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/messages.saveGif.md b/docs/API_docs/methods/messages.saveGif.md new file mode 100644 index 0000000000..ba0d42ce5d --- /dev/null +++ b/docs/API_docs/methods/messages.saveGif.md @@ -0,0 +1,43 @@ +--- +title: "messages.saveGif" +description: "Add GIF to saved gifs list" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_saveGif.html +--- +# Method: messages.saveGif +[Back to methods index](index.html) + + + +Add GIF to saved gifs list + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | GIF to save | Optional| +|unsave|[Bool](/API_docs/types/Bool.html) | Whether to remove GIF from saved gifs list | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->saveGif(id: $InputDocument, unsave: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.saveRecentSticker.md b/docs/API_docs/methods/messages.saveRecentSticker.md new file mode 100644 index 0000000000..31f50549f2 --- /dev/null +++ b/docs/API_docs/methods/messages.saveRecentSticker.md @@ -0,0 +1,44 @@ +--- +title: "messages.saveRecentSticker" +description: "Add/remove sticker from recent stickers list" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_saveRecentSticker.html +--- +# Method: messages.saveRecentSticker +[Back to methods index](index.html) + + + +Add/remove sticker from recent stickers list + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|attached|[Bool](/API_docs/types/Bool.html) | Whether to add/remove stickers recently attached to photo or video files | Optional| +|id|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Sticker | Optional| +|unsave|[Bool](/API_docs/types/Bool.html) | Whether to save or unsave the sticker | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->saveRecentSticker(attached: $Bool, id: $InputDocument, unsave: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.search.md b/docs/API_docs/methods/messages.search.md new file mode 100644 index 0000000000..6be94f88df --- /dev/null +++ b/docs/API_docs/methods/messages.search.md @@ -0,0 +1,56 @@ +--- +title: "messages.search" +description: "Search for messages." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_search.html +--- +# Method: messages.search +[Back to methods index](index.html) + + + +Search for messages. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | User or chat, histories with which are searched, or [(inputPeerEmpty)](../constructors/inputPeerEmpty.html) constructor to search in all private chats and [normal groups (not channels) »](https://core.telegram.org/api/channel). Use [messages.searchGlobal](../methods/messages.searchGlobal.html) to search globally in all chats, groups, supergroups and channels. | Optional| +|q|[string](/API_docs/types/string.html) | Text search request | Optional| +|from\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Only return messages sent by the specified user ID | Optional| +|saved\_peer\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Search within the [saved message dialog »](https://core.telegram.org/api/saved-messages) with this ID. | Optional| +|saved\_reaction|Array of [Reaction](/API_docs/types/Reaction.html) | | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | [Thread ID](https://core.telegram.org/api/threads) | Optional| +|filter|[MessagesFilter](/API_docs/types/MessagesFilter.html) | Filter to return only specified message types | Optional| +|min\_date|[int](/API_docs/types/int.html) | If a positive value was transferred, only messages with a sending date bigger than the transferred one will be returned | Optional| +|max\_date|[int](/API_docs/types/int.html) | If a positive value was transferred, only messages with a sending date smaller than the transferred one will be returned | Optional| +|offset\_id|[int](/API_docs/types/int.html) | Only return messages starting from the specified message ID | Optional| +|add\_offset|[int](/API_docs/types/int.html) | [Additional offset](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | [Number of results to return](https://core.telegram.org/api/offsets) | Optional| +|max\_id|[int](/API_docs/types/int.html) | [Maximum message ID to return](https://core.telegram.org/api/offsets) | Optional| +|min\_id|[int](/API_docs/types/int.html) | [Minimum message ID to return](https://core.telegram.org/api/offsets) | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->search(peer: $InputPeer, q: 'string', from_id: $InputPeer, saved_peer_id: $InputPeer, saved_reaction: [$Reaction, $Reaction], top_msg_id: $int, filter: $MessagesFilter, min_date: $int, max_date: $int, offset_id: $int, add_offset: $int, limit: $int, max_id: $int, min_id: $int, hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.searchCustomEmoji.md b/docs/API_docs/methods/messages.searchCustomEmoji.md new file mode 100644 index 0000000000..43e985e984 --- /dev/null +++ b/docs/API_docs/methods/messages.searchCustomEmoji.md @@ -0,0 +1,43 @@ +--- +title: "messages.searchCustomEmoji" +description: "Look for [custom emojis](https://core.telegram.org/api/custom-emoji) associated to a UTF8 emoji" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_searchCustomEmoji.html +--- +# Method: messages.searchCustomEmoji +[Back to methods index](index.html) + + + +Look for [custom emojis](https://core.telegram.org/api/custom-emoji) associated to a UTF8 emoji + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|emoticon|[string](/API_docs/types/string.html) | The emoji | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [EmojiList](/API_docs/types/EmojiList.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EmojiList = $MadelineProto->messages->searchCustomEmoji(emoticon: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.searchEmojiStickerSets.md b/docs/API_docs/methods/messages.searchEmojiStickerSets.md new file mode 100644 index 0000000000..717acafce6 --- /dev/null +++ b/docs/API_docs/methods/messages.searchEmojiStickerSets.md @@ -0,0 +1,44 @@ +--- +title: "messages.searchEmojiStickerSets" +description: "Search for [custom emoji stickersets »](https://core.telegram.org/api/custom-emoji)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_searchEmojiStickerSets.html +--- +# Method: messages.searchEmojiStickerSets +[Back to methods index](index.html) + + + +Search for [custom emoji stickersets »](https://core.telegram.org/api/custom-emoji) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|exclude\_featured|[Bool](/API_docs/types/Bool.html) | Exclude featured stickersets from results | Optional| +|q|[string](/API_docs/types/string.html) | Query string | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_FoundStickerSets = $MadelineProto->messages->searchEmojiStickerSets(exclude_featured: $Bool, q: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.searchGlobal.md b/docs/API_docs/methods/messages.searchGlobal.md new file mode 100644 index 0000000000..8b84d4486c --- /dev/null +++ b/docs/API_docs/methods/messages.searchGlobal.md @@ -0,0 +1,51 @@ +--- +title: "messages.searchGlobal" +description: "Search for messages and peers globally" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_searchGlobal.html +--- +# Method: messages.searchGlobal +[Back to methods index](index.html) + + + +Search for messages and peers globally + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|broadcasts\_only|[Bool](/API_docs/types/Bool.html) | | Optional| +|folder\_id|[int](/API_docs/types/int.html) | [Peer folder ID, for more info click here](https://core.telegram.org/api/folders#peer-folders) | Optional| +|q|[string](/API_docs/types/string.html) | Query | Optional| +|filter|[MessagesFilter](/API_docs/types/MessagesFilter.html) | Global search filter | Optional| +|min\_date|[int](/API_docs/types/int.html) | If a positive value was specified, the method will return only messages with date bigger than min\_date | Optional| +|max\_date|[int](/API_docs/types/int.html) | If a positive value was transferred, the method will return only messages with date smaller than max\_date | Optional| +|offset\_rate|[int](/API_docs/types/int.html) | Initially 0, then set to the [`next_rate` parameter of messages.messagesSlice](../constructors/messages.messagesSlice.html) | Optional| +|offset\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->searchGlobal(broadcasts_only: $Bool, folder_id: $int, q: 'string', filter: $MessagesFilter, min_date: $int, max_date: $int, offset_rate: $int, offset_peer: $InputPeer, offset_id: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.searchSentMedia.md b/docs/API_docs/methods/messages.searchSentMedia.md new file mode 100644 index 0000000000..72dee72c7b --- /dev/null +++ b/docs/API_docs/methods/messages.searchSentMedia.md @@ -0,0 +1,45 @@ +--- +title: "messages.searchSentMedia" +description: "View and search recently sent media. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_searchSentMedia.html +--- +# Method: messages.searchSentMedia +[Back to methods index](index.html) + + + +View and search recently sent media. +This method does not support pagination. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|q|[string](/API_docs/types/string.html) | Optional search query | Optional| +|filter|[MessagesFilter](/API_docs/types/MessagesFilter.html) | Message filter | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return (max 100). | Optional| + + +### Return type: [messages.Messages](/API_docs/types/messages.Messages.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Messages = $MadelineProto->messages->searchSentMedia(q: 'string', filter: $MessagesFilter, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.searchStickerSets.md b/docs/API_docs/methods/messages.searchStickerSets.md new file mode 100644 index 0000000000..289643fc42 --- /dev/null +++ b/docs/API_docs/methods/messages.searchStickerSets.md @@ -0,0 +1,44 @@ +--- +title: "messages.searchStickerSets" +description: "Search for stickersets" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_searchStickerSets.html +--- +# Method: messages.searchStickerSets +[Back to methods index](index.html) + + + +Search for stickersets + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|exclude\_featured|[Bool](/API_docs/types/Bool.html) | Exclude featured stickersets from results | Optional| +|q|[string](/API_docs/types/string.html) | Query string | Optional| +|hash|Array of [long](/API_docs/types/long.html) | [Hash for pagination, for more info click here](https://core.telegram.org/api/offsets#hash-generation) | Optional| + + +### Return type: [messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_FoundStickerSets = $MadelineProto->messages->searchStickerSets(exclude_featured: $Bool, q: 'string', hash: [$long, $long], ); +``` + diff --git a/docs/API_docs/methods/messages.sendBotRequestedPeer.md b/docs/API_docs/methods/messages.sendBotRequestedPeer.md new file mode 100644 index 0000000000..4ba510323c --- /dev/null +++ b/docs/API_docs/methods/messages.sendBotRequestedPeer.md @@ -0,0 +1,45 @@ +--- +title: "messages.sendBotRequestedPeer" +description: "Send one or more chosen peers, as requested by a [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html) button." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendBotRequestedPeer.html +--- +# Method: messages.sendBotRequestedPeer +[Back to methods index](index.html) + + + +Send one or more chosen peers, as requested by a [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html) button. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The bot that sent the [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html) button. | Optional| +|msg\_id|[int](/API_docs/types/int.html) | ID of the message that contained the reply keyboard with the [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html) button. | Optional| +|button\_id|[int](/API_docs/types/int.html) | The `button_id` field from the [keyboardButtonRequestPeer](../constructors/keyboardButtonRequestPeer.html) constructor. | Optional| +|requested\_peers|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chosen peers. | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendBotRequestedPeer(peer: $InputPeer, msg_id: $int, button_id: $int, requested_peers: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/messages.sendEncrypted.md b/docs/API_docs/methods/messages.sendEncrypted.md new file mode 100644 index 0000000000..41791149aa --- /dev/null +++ b/docs/API_docs/methods/messages.sendEncrypted.md @@ -0,0 +1,44 @@ +--- +title: "messages.sendEncrypted" +description: "Sends a text message to a secret chat." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendEncrypted.html +--- +# Method: messages.sendEncrypted +[Back to methods index](index.html) + + + +Sends a text message to a secret chat. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Send encrypted message without a notification | Optional| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | Secret chat ID | Yes| +|data|[bytes](/API_docs/types/bytes.html) | TL-serialization of [DecryptedMessage](../types/DecryptedMessage.html) type, encrypted with a key that was created during chat initialization | Yes| + + +### Return type: [messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SentEncryptedMessage = $MadelineProto->messages->sendEncrypted(silent: $Bool, peer: $InputEncryptedChat, data: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/messages.sendEncryptedFile.md b/docs/API_docs/methods/messages.sendEncryptedFile.md new file mode 100644 index 0000000000..609f1b90be --- /dev/null +++ b/docs/API_docs/methods/messages.sendEncryptedFile.md @@ -0,0 +1,45 @@ +--- +title: "messages.sendEncryptedFile" +description: "Sends a message with a file attachment to a secret chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendEncryptedFile.html +--- +# Method: messages.sendEncryptedFile +[Back to methods index](index.html) + + + +Sends a message with a file attachment to a secret chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Whether to send the file without triggering a notification | Optional| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | Secret chat ID | Yes| +|data|[bytes](/API_docs/types/bytes.html) | TL-serialization of [DecryptedMessage](../types/DecryptedMessage.html) type, encrypted with a key generated during chat initialization | Yes| +|file|[File path or InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) | File attachment for the secret chat | Optional| + + +### Return type: [messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SentEncryptedMessage = $MadelineProto->messages->sendEncryptedFile(silent: $Bool, peer: $InputEncryptedChat, data: 'bytes', file: $InputEncryptedFile, ); +``` + diff --git a/docs/API_docs/methods/messages.sendEncryptedService.md b/docs/API_docs/methods/messages.sendEncryptedService.md new file mode 100644 index 0000000000..a97d2ba946 --- /dev/null +++ b/docs/API_docs/methods/messages.sendEncryptedService.md @@ -0,0 +1,43 @@ +--- +title: "messages.sendEncryptedService" +description: "Sends a service message to a secret chat." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendEncryptedService.html +--- +# Method: messages.sendEncryptedService +[Back to methods index](index.html) + + + +Sends a service message to a secret chat. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | Secret chat ID | Yes| +|data|[bytes](/API_docs/types/bytes.html) | TL-serialization of [DecryptedMessage](../types/DecryptedMessage.html) type, encrypted with a key generated during chat initialization | Yes| + + +### Return type: [messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_SentEncryptedMessage = $MadelineProto->messages->sendEncryptedService(peer: $InputEncryptedChat, data: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/messages.sendInlineBotResult.md b/docs/API_docs/methods/messages.sendInlineBotResult.md new file mode 100644 index 0000000000..0859f0d429 --- /dev/null +++ b/docs/API_docs/methods/messages.sendInlineBotResult.md @@ -0,0 +1,52 @@ +--- +title: "messages.sendInlineBotResult" +description: "Send a result obtained using [messages.getInlineBotResults](../methods/messages.getInlineBotResults.html)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendInlineBotResult.html +--- +# Method: messages.sendInlineBotResult +[Back to methods index](index.html) + + + +Send a result obtained using [messages.getInlineBotResults](../methods/messages.getInlineBotResults.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Whether to send the message silently (no notification will be triggered on the other client) | Optional| +|background|[Bool](/API_docs/types/Bool.html) | Whether to send the message in background | Optional| +|clear\_draft|[Bool](/API_docs/types/Bool.html) | Whether to clear the [draft](https://core.telegram.org/api/drafts) | Optional| +|hide\_via|[Bool](/API_docs/types/Bool.html) | Whether to hide the `via @botname` in the resulting message (only for bot usernames encountered in the [config](../constructors/config.html)) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Destination | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the message should be sent in reply to the specified message or story. | Optional| +|query\_id|[long](/API_docs/types/long.html) | Query ID from [messages.getInlineBotResults](../methods/messages.getInlineBotResults.html) | Yes| +|id|[string](/API_docs/types/string.html) | Result ID from [messages.getInlineBotResults](../methods/messages.getInlineBotResults.html) | Optional| +|schedule\_date|[int](/API_docs/types/int.html) | Scheduled message date for scheduled messages | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Send this message as the specified peer | Optional| +|quick\_reply\_shortcut|[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendInlineBotResult(silent: $Bool, background: $Bool, clear_draft: $Bool, hide_via: $Bool, peer: $InputPeer, reply_to: $InputReplyTo, query_id: $long, id: 'string', schedule_date: $int, send_as: $InputPeer, quick_reply_shortcut: $InputQuickReplyShortcut, ); +``` + diff --git a/docs/API_docs/methods/messages.sendMedia.md b/docs/API_docs/methods/messages.sendMedia.md new file mode 100644 index 0000000000..22a3ba5692 --- /dev/null +++ b/docs/API_docs/methods/messages.sendMedia.md @@ -0,0 +1,129 @@ +--- +title: "messages.sendMedia" +description: "Send a media" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendMedia.html +--- +# Method: messages.sendMedia +[Back to methods index](index.html) + + + +Send a media + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Send message silently (no notification should be triggered) | Optional| +|background|[Bool](/API_docs/types/Bool.html) | Send message in background | Optional| +|clear\_draft|[Bool](/API_docs/types/Bool.html) | Clear the draft | Optional| +|noforwards|[Bool](/API_docs/types/Bool.html) | Only for bots, disallows forwarding and saving of the messages, even if the destination chat doesn't have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled | Optional| +|update\_stickersets\_order|[Bool](/API_docs/types/Bool.html) | Whether to move used stickersets to top, [see here for more info on this flag »](https://core.telegram.org/api/stickers#recent-stickersets) | Optional| +|invert\_media|[Bool](/API_docs/types/Bool.html) | If set, any eventual webpage preview will be shown on top of the message instead of at the bottom. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Destination | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the message should be sent in reply to the specified message or story. | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | Attached media | Optional| +|message|[string](/API_docs/types/string.html) | Caption | Optional| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Reply markup for bot keyboards | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Message [entities](https://core.telegram.org/api/entities) for styled text | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|schedule\_date|[int](/API_docs/types/int.html) | Scheduled message date for [scheduled messages](https://core.telegram.org/api/scheduled-messages) | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Send this message as the specified peer | Optional| +|quick\_reply\_shortcut|[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendMedia(silent: $Bool, background: $Bool, clear_draft: $Bool, noforwards: $Bool, update_stickersets_order: $Bool, invert_media: $Bool, peer: $InputPeer, reply_to: $InputReplyTo, media: $InputMedia, message: 'string', reply_markup: $ReplyMarkup, entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', schedule_date: $int, send_as: $InputPeer, quick_reply_shortcut: $InputQuickReplyShortcut, ); +``` + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Updates](../types/Updates.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/messages.sendMessage.md b/docs/API_docs/methods/messages.sendMessage.md new file mode 100644 index 0000000000..5b5d689e52 --- /dev/null +++ b/docs/API_docs/methods/messages.sendMessage.md @@ -0,0 +1,129 @@ +--- +title: "messages.sendMessage" +description: "Sends a message to a chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendMessage.html +--- +# Method: messages.sendMessage +[Back to methods index](index.html) + + + +Sends a message to a chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|no\_webpage|[Bool](/API_docs/types/Bool.html) | Set this flag to disable generation of the webpage preview | Optional| +|silent|[Bool](/API_docs/types/Bool.html) | Send this message silently (no notifications for the receivers) | Optional| +|background|[Bool](/API_docs/types/Bool.html) | Send this message as background message | Optional| +|clear\_draft|[Bool](/API_docs/types/Bool.html) | Clear the draft field | Optional| +|noforwards|[Bool](/API_docs/types/Bool.html) | Only for bots, disallows forwarding and saving of the messages, even if the destination chat doesn't have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled | Optional| +|update\_stickersets\_order|[Bool](/API_docs/types/Bool.html) | Whether to move used stickersets to top, [see here for more info on this flag »](https://core.telegram.org/api/stickers#recent-stickersets) | Optional| +|invert\_media|[Bool](/API_docs/types/Bool.html) | If set, any eventual webpage preview will be shown on top of the message instead of at the bottom. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The destination where the message will be sent | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the message should be sent in reply to the specified message or story. | Optional| +|message|[string](/API_docs/types/string.html) | The message | Optional| +|reply\_markup|[ReplyMarkup](/API_docs/types/ReplyMarkup.html) | Reply markup for sending bot buttons | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | Message [entities](https://core.telegram.org/api/entities) for sending styled text | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|schedule\_date|[int](/API_docs/types/int.html) | Scheduled message date for [scheduled messages](https://core.telegram.org/api/scheduled-messages) | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Send this message as the specified peer | Optional| +|quick\_reply\_shortcut|[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendMessage(no_webpage: $Bool, silent: $Bool, background: $Bool, clear_draft: $Bool, noforwards: $Bool, update_stickersets_order: $Bool, invert_media: $Bool, peer: $InputPeer, reply_to: $InputReplyTo, message: 'string', reply_markup: $ReplyMarkup, entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', schedule_date: $int, send_as: $InputPeer, quick_reply_shortcut: $InputQuickReplyShortcut, ); +``` + + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Updates](../types/Updates.html) will be returned instead. + + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/messages.sendMultiMedia.md b/docs/API_docs/methods/messages.sendMultiMedia.md new file mode 100644 index 0000000000..c6c5734132 --- /dev/null +++ b/docs/API_docs/methods/messages.sendMultiMedia.md @@ -0,0 +1,53 @@ +--- +title: "messages.sendMultiMedia" +description: "Send an [album or grouped media](https://core.telegram.org/api/files#albums-grouped-media)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendMultiMedia.html +--- +# Method: messages.sendMultiMedia +[Back to methods index](index.html) + + + +Send an [album or grouped media](https://core.telegram.org/api/files#albums-grouped-media) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Whether to send the album silently (no notification triggered) | Optional| +|background|[Bool](/API_docs/types/Bool.html) | Send in background? | Optional| +|clear\_draft|[Bool](/API_docs/types/Bool.html) | Whether to clear [drafts](https://core.telegram.org/api/drafts) | Optional| +|noforwards|[Bool](/API_docs/types/Bool.html) | Only for bots, disallows forwarding and saving of the messages, even if the destination chat doesn't have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled | Optional| +|update\_stickersets\_order|[Bool](/API_docs/types/Bool.html) | Whether to move used stickersets to top, [see here for more info on this flag »](https://core.telegram.org/api/stickers#recent-stickersets) | Optional| +|invert\_media|[Bool](/API_docs/types/Bool.html) | If set, any eventual webpage preview will be shown on top of the message instead of at the bottom. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The destination chat | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | If set, indicates that the message should be sent in reply to the specified message or story. | Optional| +|multi\_media|Array of [InputSingleMedia](/API_docs/types/InputSingleMedia.html) | The medias to send | Yes| +|schedule\_date|[int](/API_docs/types/int.html) | Scheduled message date for scheduled messages | Optional| +|send\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Send this message as the specified peer | Optional| +|quick\_reply\_shortcut|[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendMultiMedia(silent: $Bool, background: $Bool, clear_draft: $Bool, noforwards: $Bool, update_stickersets_order: $Bool, invert_media: $Bool, peer: $InputPeer, reply_to: $InputReplyTo, multi_media: [$InputSingleMedia, $InputSingleMedia], schedule_date: $int, send_as: $InputPeer, quick_reply_shortcut: $InputQuickReplyShortcut, ); +``` + diff --git a/docs/API_docs/methods/messages.sendQuickReplyMessages.md b/docs/API_docs/methods/messages.sendQuickReplyMessages.md new file mode 100644 index 0000000000..8b781ff000 --- /dev/null +++ b/docs/API_docs/methods/messages.sendQuickReplyMessages.md @@ -0,0 +1,42 @@ +--- +title: "messages.sendQuickReplyMessages" +description: "messages.sendQuickReplyMessages parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendQuickReplyMessages.html +--- +# Method: messages.sendQuickReplyMessages +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| +|shortcut\_id|[int](/API_docs/types/int.html) | Optional| +|id|Array of [int](/API_docs/types/int.html) | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendQuickReplyMessages(peer: $InputPeer, shortcut_id: $int, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.sendReaction.md b/docs/API_docs/methods/messages.sendReaction.md new file mode 100644 index 0000000000..19dcc528ce --- /dev/null +++ b/docs/API_docs/methods/messages.sendReaction.md @@ -0,0 +1,48 @@ +--- +title: "messages.sendReaction" +description: "React to message." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendReaction.html +--- +# Method: messages.sendReaction +[Back to methods index](index.html) + + + +React to message. + +Starting from layer 159, the reaction will be sent from the peer specified using [messages.saveDefaultSendAs](../methods/messages.saveDefaultSendAs.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|big|[Bool](/API_docs/types/Bool.html) | Whether a bigger and longer reaction should be shown | Optional| +|add\_to\_recent|[Bool](/API_docs/types/Bool.html) | Whether to add this reaction to the [recent reactions list »](https://core.telegram.org/api/reactions#recent-reactions). | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID to react to | Optional| +|reaction|Array of [Reaction](/API_docs/types/Reaction.html) | A list of reactions | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendReaction(big: $Bool, add_to_recent: $Bool, peer: $InputPeer, msg_id: $int, reaction: [$Reaction, $Reaction], ); +``` + diff --git a/docs/API_docs/methods/messages.sendScheduledMessages.md b/docs/API_docs/methods/messages.sendScheduledMessages.md new file mode 100644 index 0000000000..5aea1a2e57 --- /dev/null +++ b/docs/API_docs/methods/messages.sendScheduledMessages.md @@ -0,0 +1,43 @@ +--- +title: "messages.sendScheduledMessages" +description: "Send scheduled messages right away" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendScheduledMessages.html +--- +# Method: messages.sendScheduledMessages +[Back to methods index](index.html) + + + +Send scheduled messages right away + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer | Optional| +|id|Array of [int](/API_docs/types/int.html) | Scheduled message IDs | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendScheduledMessages(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.sendScreenshotNotification.md b/docs/API_docs/methods/messages.sendScreenshotNotification.md new file mode 100644 index 0000000000..8a12414ea2 --- /dev/null +++ b/docs/API_docs/methods/messages.sendScreenshotNotification.md @@ -0,0 +1,43 @@ +--- +title: "messages.sendScreenshotNotification" +description: "Notify the other user in a private chat that a screenshot of the chat was taken" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendScreenshotNotification.html +--- +# Method: messages.sendScreenshotNotification +[Back to methods index](index.html) + + + +Notify the other user in a private chat that a screenshot of the chat was taken + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Other user | Optional| +|reply\_to|[InputReplyTo](/API_docs/types/InputReplyTo.html) | Indicates the message that was screenshotted (the specified message ID can also be `0` to avoid indicating any specific message). | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendScreenshotNotification(peer: $InputPeer, reply_to: $InputReplyTo, ); +``` + diff --git a/docs/API_docs/methods/messages.sendVote.md b/docs/API_docs/methods/messages.sendVote.md new file mode 100644 index 0000000000..ee4dda52ae --- /dev/null +++ b/docs/API_docs/methods/messages.sendVote.md @@ -0,0 +1,46 @@ +--- +title: "messages.sendVote" +description: "Vote in a [poll](../constructors/poll.html)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendVote.html +--- +# Method: messages.sendVote +[Back to methods index](index.html) + + + +Vote in a [poll](../constructors/poll.html) + +Starting from layer 159, the vote will be sent from the peer specified using [messages.saveDefaultSendAs](../methods/messages.saveDefaultSendAs.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat where the poll was sent | Optional| +|msg\_id|[int](/API_docs/types/int.html) | The message ID of the poll | Optional| +|options|Array of [bytes](/API_docs/types/bytes.html) | The options that were chosen | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendVote(peer: $InputPeer, msg_id: $int, options: ['bytes', 'bytes'], ); +``` + diff --git a/docs/API_docs/methods/messages.sendWebViewData.md b/docs/API_docs/methods/messages.sendWebViewData.md new file mode 100644 index 0000000000..7b3446176d --- /dev/null +++ b/docs/API_docs/methods/messages.sendWebViewData.md @@ -0,0 +1,44 @@ +--- +title: "messages.sendWebViewData" +description: "Used by the user to relay data from an opened [reply keyboard bot mini app](https://core.telegram.org/api/bots/webapps) to the bot that owns it." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendWebViewData.html +--- +# Method: messages.sendWebViewData +[Back to methods index](index.html) + + + +Used by the user to relay data from an opened [reply keyboard bot mini app](https://core.telegram.org/api/bots/webapps) to the bot that owns it. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Bot that owns the web app | Optional| +|button\_text|[string](/API_docs/types/string.html) | Text of the [keyboardButtonSimpleWebView](../constructors/keyboardButtonSimpleWebView.html) that was pressed to open the web app. | Optional| +|data|[string](/API_docs/types/string.html) | Data to relay to the bot, obtained from a [`web_app_data_send` JS event](https://core.telegram.org/api/web-events#web-app-data-send). | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->sendWebViewData(bot: $InputUser, button_text: 'string', data: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.sendWebViewResultMessage.md b/docs/API_docs/methods/messages.sendWebViewResultMessage.md new file mode 100644 index 0000000000..93c0d062e9 --- /dev/null +++ b/docs/API_docs/methods/messages.sendWebViewResultMessage.md @@ -0,0 +1,43 @@ +--- +title: "messages.sendWebViewResultMessage" +description: "Terminate webview interaction started with [messages.requestWebView](../methods/messages.requestWebView.html), sending the specified message to the chat on behalf of the user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_sendWebViewResultMessage.html +--- +# Method: messages.sendWebViewResultMessage +[Back to methods index](index.html) + + + +Terminate webview interaction started with [messages.requestWebView](../methods/messages.requestWebView.html), sending the specified message to the chat on behalf of the user. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot\_query\_id|[string](/API_docs/types/string.html) | Webview interaction ID obtained from [messages.requestWebView](../methods/messages.requestWebView.html) | Optional| +|result|[InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) | Message to send | Yes| + + +### Return type: [WebViewMessageSent](/API_docs/types/WebViewMessageSent.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$WebViewMessageSent = $MadelineProto->messages->sendWebViewResultMessage(bot_query_id: 'string', result: $InputBotInlineResult, ); +``` + diff --git a/docs/API_docs/methods/messages.setBotCallbackAnswer.md b/docs/API_docs/methods/messages.setBotCallbackAnswer.md new file mode 100644 index 0000000000..ef0a57e57f --- /dev/null +++ b/docs/API_docs/methods/messages.setBotCallbackAnswer.md @@ -0,0 +1,52 @@ +--- +title: "messages.setBotCallbackAnswer" +description: "Set the callback answer to a user button press (bots only)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setBotCallbackAnswer.html +--- +# Method: messages.setBotCallbackAnswer +[Back to methods index](index.html) + + + +Set the callback answer to a user button press (bots only) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|alert|[Bool](/API_docs/types/Bool.html) | Whether to show the message as a popup instead of a toast notification | Optional| +|query\_id|[long](/API_docs/types/long.html) | Query ID | Yes| +|message|[string](/API_docs/types/string.html) | Popup to show | Optional| +|url|[string](/API_docs/types/string.html) | URL to open | Optional| +|cache\_time|[int](/API_docs/types/int.html) | Cache validity | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setBotCallbackAnswer(alert: $Bool, query_id: $long, message: 'string', url: 'string', cache_time: $int, ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/messages.setBotPrecheckoutResults.md b/docs/API_docs/methods/messages.setBotPrecheckoutResults.md new file mode 100644 index 0000000000..08d3555e3b --- /dev/null +++ b/docs/API_docs/methods/messages.setBotPrecheckoutResults.md @@ -0,0 +1,46 @@ +--- +title: "messages.setBotPrecheckoutResults" +description: "Once the user has confirmed their payment and shipping details, the bot receives an [updateBotPrecheckoutQuery](../constructors/updateBotPrecheckoutQuery.html) update. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setBotPrecheckoutResults.html +--- +# Method: messages.setBotPrecheckoutResults +[Back to methods index](index.html) + + + +Once the user has confirmed their payment and shipping details, the bot receives an [updateBotPrecheckoutQuery](../constructors/updateBotPrecheckoutQuery.html) update. +Use this method to respond to such pre-checkout queries. +**Note**: Telegram must receive an answer within 10 seconds after the pre-checkout query was sent. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|success|[Bool](/API_docs/types/Bool.html) | Set this flag if everything is alright (goods are available, etc.) and the bot is ready to proceed with the order, otherwise do not set it, and set the `error` field, instead | Optional| +|query\_id|[long](/API_docs/types/long.html) | Unique identifier for the query to be answered | Yes| +|error|[string](/API_docs/types/string.html) | Required if the `success` isn't set. Error message in human readable form that explains the reason for failure to proceed with the checkout (e.g. "Sorry, somebody just bought the last of our amazing black T-shirts while you were busy filling out your payment details. Please choose a different color or garment!"). Telegram will display this message to the user. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setBotPrecheckoutResults(success: $Bool, query_id: $long, error: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.setBotShippingResults.md b/docs/API_docs/methods/messages.setBotShippingResults.md new file mode 100644 index 0000000000..a0b640c1d3 --- /dev/null +++ b/docs/API_docs/methods/messages.setBotShippingResults.md @@ -0,0 +1,44 @@ +--- +title: "messages.setBotShippingResults" +description: "If you sent an invoice requesting a shipping address and the parameter is\_flexible was specified, the bot will receive an [updateBotShippingQuery](../constructors/updateBotShippingQuery.html) update. Use this method to reply to shipping queries." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setBotShippingResults.html +--- +# Method: messages.setBotShippingResults +[Back to methods index](index.html) + + + +If you sent an invoice requesting a shipping address and the parameter is\_flexible was specified, the bot will receive an [updateBotShippingQuery](../constructors/updateBotShippingQuery.html) update. Use this method to reply to shipping queries. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|query\_id|[long](/API_docs/types/long.html) | Unique identifier for the query to be answered | Yes| +|error|[string](/API_docs/types/string.html) | Error message in human readable form that explains why it is impossible to complete the order (e.g. "Sorry, delivery to your desired address is unavailable"). Telegram will display this message to the user. | Optional| +|shipping\_options|Array of [ShippingOption](/API_docs/types/ShippingOption.html) | A vector of available shipping options. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setBotShippingResults(query_id: $long, error: 'string', shipping_options: [$ShippingOption, $ShippingOption], ); +``` + diff --git a/docs/API_docs/methods/messages.setChatAvailableReactions.md b/docs/API_docs/methods/messages.setChatAvailableReactions.md new file mode 100644 index 0000000000..5b61499679 --- /dev/null +++ b/docs/API_docs/methods/messages.setChatAvailableReactions.md @@ -0,0 +1,44 @@ +--- +title: "messages.setChatAvailableReactions" +description: "Change the set of [message reactions »](https://core.telegram.org/api/reactions) that can be used in a certain group, supergroup or channel" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setChatAvailableReactions.html +--- +# Method: messages.setChatAvailableReactions +[Back to methods index](index.html) + + + +Change the set of [message reactions »](https://core.telegram.org/api/reactions) that can be used in a certain group, supergroup or channel + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Group where to apply changes | Optional| +|available\_reactions|[ChatReactions](/API_docs/types/ChatReactions.html) | Allowed reaction emojis | Yes| +|reactions\_limit|[int](/API_docs/types/int.html) | | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->setChatAvailableReactions(peer: $InputPeer, available_reactions: $ChatReactions, reactions_limit: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.setChatTheme.md b/docs/API_docs/methods/messages.setChatTheme.md new file mode 100644 index 0000000000..9be51338b1 --- /dev/null +++ b/docs/API_docs/methods/messages.setChatTheme.md @@ -0,0 +1,43 @@ +--- +title: "messages.setChatTheme" +description: "Change the chat theme of a certain chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setChatTheme.html +--- +# Method: messages.setChatTheme +[Back to methods index](index.html) + + + +Change the chat theme of a certain chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Private chat where to change theme | Optional| +|emoticon|[string](/API_docs/types/string.html) | Emoji, identifying a specific chat theme; a list of chat themes can be fetched using [account.getChatThemes](../methods/account.getChatThemes.html) | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->setChatTheme(peer: $InputPeer, emoticon: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.setChatWallPaper.md b/docs/API_docs/methods/messages.setChatWallPaper.md new file mode 100644 index 0000000000..af21adba4f --- /dev/null +++ b/docs/API_docs/methods/messages.setChatWallPaper.md @@ -0,0 +1,47 @@ +--- +title: "messages.setChatWallPaper" +description: "Set a custom [wallpaper »](https://core.telegram.org/api/wallpapers) in a specific private chat with another user." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setChatWallPaper.html +--- +# Method: messages.setChatWallPaper +[Back to methods index](index.html) + + + +Set a custom [wallpaper »](https://core.telegram.org/api/wallpapers) in a specific private chat with another user. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|for\_both|[Bool](/API_docs/types/Bool.html) | Only for [Premium](https://core.telegram.org/api/premium) users, sets the specified wallpaper for both users of the chat, without requiring confirmation from the other user. | Optional| +|revert|[Bool](/API_docs/types/Bool.html) | If we don't like the new wallpaper the other user of the chat has chosen for us using the `for_both` flag, we can re-set our previous wallpaper just on our side using this flag. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The private chat where the wallpaper will be set | Optional| +|wallpaper|[InputWallPaper](/API_docs/types/InputWallPaper.html) | The [wallpaper »](https://core.telegram.org/api/wallpapers), obtained as described in the [wallpaper documentation »](https://core.telegram.org/api/wallpapers#uploading-wallpapers); must **not** be provided when installing a wallpaper obtained from a [messageActionSetChatWallPaper](../constructors/messageActionSetChatWallPaper.html) service message (`id` must be provided, instead). | Optional| +|settings|[WallPaperSettings](/API_docs/types/WallPaperSettings.html) | Wallpaper settings, obtained as described in the [wallpaper documentation »](https://core.telegram.org/api/wallpapers#uploading-wallpapers) or from [messageActionSetChatWallPaper](../constructors/messageActionSetChatWallPaper.html).`wallpaper`.`settings`. | Optional| +|id|[int](/API_docs/types/int.html) | If the wallpaper was obtained from a [messageActionSetChatWallPaper](../constructors/messageActionSetChatWallPaper.html) service message, must contain the ID of that message. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->setChatWallPaper(for_both: $Bool, revert: $Bool, peer: $InputPeer, wallpaper: $InputWallPaper, settings: $WallPaperSettings, id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.setDefaultHistoryTTL.md b/docs/API_docs/methods/messages.setDefaultHistoryTTL.md new file mode 100644 index 0000000000..7d0f725f89 --- /dev/null +++ b/docs/API_docs/methods/messages.setDefaultHistoryTTL.md @@ -0,0 +1,42 @@ +--- +title: "messages.setDefaultHistoryTTL" +description: "Changes the default value of the Time-To-Live setting, applied to all new chats." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setDefaultHistoryTTL.html +--- +# Method: messages.setDefaultHistoryTTL +[Back to methods index](index.html) + + + +Changes the default value of the Time-To-Live setting, applied to all new chats. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|period|[int](/API_docs/types/int.html) | The new default Time-To-Live of all messages sent in new chats. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setDefaultHistoryTTL(period: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.setDefaultReaction.md b/docs/API_docs/methods/messages.setDefaultReaction.md new file mode 100644 index 0000000000..3bc51498af --- /dev/null +++ b/docs/API_docs/methods/messages.setDefaultReaction.md @@ -0,0 +1,42 @@ +--- +title: "messages.setDefaultReaction" +description: "Change default emoji reaction to use in the quick reaction menu: the value is synced across devices and can be fetched using [help.getConfig, `reactions_default` field](../methods/help.getConfig.html)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setDefaultReaction.html +--- +# Method: messages.setDefaultReaction +[Back to methods index](index.html) + + + +Change default emoji reaction to use in the quick reaction menu: the value is synced across devices and can be fetched using [help.getConfig, `reactions_default` field](../methods/help.getConfig.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|reaction|[Reaction](/API_docs/types/Reaction.html) | New emoji reaction | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setDefaultReaction(reaction: $Reaction, ); +``` + diff --git a/docs/API_docs/methods/messages.setEncryptedTyping.md b/docs/API_docs/methods/messages.setEncryptedTyping.md new file mode 100644 index 0000000000..70af896e03 --- /dev/null +++ b/docs/API_docs/methods/messages.setEncryptedTyping.md @@ -0,0 +1,43 @@ +--- +title: "messages.setEncryptedTyping" +description: "Send typing event by the current user to a secret chat." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setEncryptedTyping.html +--- +# Method: messages.setEncryptedTyping +[Back to methods index](index.html) + + + +Send typing event by the current user to a secret chat. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | Secret chat ID | Yes| +|typing|[Bool](/API_docs/types/Bool.html) | Typing.
**Possible values**:
[(boolTrue)](../constructors/boolTrue.html), if the user started typing and more than **5 seconds** have passed since the last request
[(boolFalse)](../constructors/boolFalse.html), if the user stopped typing | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setEncryptedTyping(peer: $InputEncryptedChat, typing: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.setGameScore.md b/docs/API_docs/methods/messages.setGameScore.md new file mode 100644 index 0000000000..a5fc369ba5 --- /dev/null +++ b/docs/API_docs/methods/messages.setGameScore.md @@ -0,0 +1,47 @@ +--- +title: "messages.setGameScore" +description: "Use this method to set the score of the specified user in a game sent as a normal message (bots only)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setGameScore.html +--- +# Method: messages.setGameScore +[Back to methods index](index.html) + + + +Use this method to set the score of the specified user in a game sent as a normal message (bots only). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|edit\_message|[Bool](/API_docs/types/Bool.html) | Set this flag if the game message should be automatically edited to include the current scoreboard | Optional| +|force|[Bool](/API_docs/types/Bool.html) | Set this flag if the high score is allowed to decrease. This can be useful when fixing mistakes or banning cheaters | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Unique identifier of target chat | Optional| +|id|[int](/API_docs/types/int.html) | Identifier of the sent message | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User identifier | Optional| +|score|[int](/API_docs/types/int.html) | New score | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->setGameScore(edit_message: $Bool, force: $Bool, peer: $InputPeer, id: $int, user_id: $InputUser, score: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.setHistoryTTL.md b/docs/API_docs/methods/messages.setHistoryTTL.md new file mode 100644 index 0000000000..e629645fd9 --- /dev/null +++ b/docs/API_docs/methods/messages.setHistoryTTL.md @@ -0,0 +1,43 @@ +--- +title: "messages.setHistoryTTL" +description: "Set maximum Time-To-Live of all messages in the specified chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setHistoryTTL.html +--- +# Method: messages.setHistoryTTL +[Back to methods index](index.html) + + + +Set maximum Time-To-Live of all messages in the specified chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The dialog | Optional| +|period|[int](/API_docs/types/int.html) | Automatically delete all messages sent in the chat after this many seconds | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->setHistoryTTL(peer: $InputPeer, period: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.setInlineBotResults.md b/docs/API_docs/methods/messages.setInlineBotResults.md new file mode 100644 index 0000000000..c7444e7248 --- /dev/null +++ b/docs/API_docs/methods/messages.setInlineBotResults.md @@ -0,0 +1,49 @@ +--- +title: "messages.setInlineBotResults" +description: "Answer an inline query, for bots only" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setInlineBotResults.html +--- +# Method: messages.setInlineBotResults +[Back to methods index](index.html) + + + +Answer an inline query, for bots only + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|gallery|[Bool](/API_docs/types/Bool.html) | Set this flag if the results are composed of media files | Optional| +|private|[Bool](/API_docs/types/Bool.html) | Set this flag if results may be cached on the server side only for the user that sent the query. By default, results may be returned to any user who sends the same query | Optional| +|query\_id|[long](/API_docs/types/long.html) | Unique identifier for the answered query | Yes| +|results|Array of [InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) | Vector of results for the inline query | Yes| +|cache\_time|[int](/API_docs/types/int.html) | The maximum amount of time in seconds that the result of the inline query may be cached on the server. Defaults to 300. | Optional| +|next\_offset|[string](/API_docs/types/string.html) | Pass the offset that a client should send in the next query with the same text to receive more results. Pass an empty string if there are no more results or if you don't support pagination. Offset length can't exceed 64 bytes. | Optional| +|switch\_pm|[InlineBotSwitchPM](/API_docs/types/InlineBotSwitchPM.html) | If passed, clients will display a button on top of the remaining inline result list with the specified text, that switches the user to a private chat with the bot and sends the bot a start message with a certain parameter. | Optional| +|switch\_webview|[InlineBotWebView](/API_docs/types/InlineBotWebView.html) | If passed, clients will display a button on top of the remaining inline result list with the specified text, that switches the user to the specified [inline mode mini app](https://core.telegram.org/api/bots/webapps#inline-mode-mini-apps). | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setInlineBotResults(gallery: $Bool, private: $Bool, query_id: $long, results: [$InputBotInlineResult, $InputBotInlineResult], cache_time: $int, next_offset: 'string', switch_pm: $InlineBotSwitchPM, switch_webview: $InlineBotWebView, ); +``` + diff --git a/docs/API_docs/methods/messages.setInlineGameScore.md b/docs/API_docs/methods/messages.setInlineGameScore.md new file mode 100644 index 0000000000..70b7c87ff9 --- /dev/null +++ b/docs/API_docs/methods/messages.setInlineGameScore.md @@ -0,0 +1,46 @@ +--- +title: "messages.setInlineGameScore" +description: "Use this method to set the score of the specified user in a game sent as an inline message (bots only)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setInlineGameScore.html +--- +# Method: messages.setInlineGameScore +[Back to methods index](index.html) + + + +Use this method to set the score of the specified user in a game sent as an inline message (bots only). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|edit\_message|[Bool](/API_docs/types/Bool.html) | Set this flag if the game message should be automatically edited to include the current scoreboard | Optional| +|force|[Bool](/API_docs/types/Bool.html) | Set this flag if the high score is allowed to decrease. This can be useful when fixing mistakes or banning cheaters | Optional| +|id|[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) | ID of the inline message | Yes| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User identifier | Optional| +|score|[int](/API_docs/types/int.html) | New score | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setInlineGameScore(edit_message: $Bool, force: $Bool, id: $InputBotInlineMessageID, user_id: $InputUser, score: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.setTyping.md b/docs/API_docs/methods/messages.setTyping.md new file mode 100644 index 0000000000..3efcf802cf --- /dev/null +++ b/docs/API_docs/methods/messages.setTyping.md @@ -0,0 +1,44 @@ +--- +title: "messages.setTyping" +description: "Sends a current user typing event (see [SendMessageAction](../types/SendMessageAction.html) for all event types) to a conversation partner or group." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_setTyping.html +--- +# Method: messages.setTyping +[Back to methods index](index.html) + + + +Sends a current user typing event (see [SendMessageAction](../types/SendMessageAction.html) for all event types) to a conversation partner or group. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Target user or group | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | [Topic ID](https://core.telegram.org/api/threads) | Optional| +|action|[SendMessageAction](/API_docs/types/SendMessageAction.html) | Type of action | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->setTyping(peer: $InputPeer, top_msg_id: $int, action: $SendMessageAction, ); +``` + diff --git a/docs/API_docs/methods/messages.startBot.md b/docs/API_docs/methods/messages.startBot.md new file mode 100644 index 0000000000..a45a37eb77 --- /dev/null +++ b/docs/API_docs/methods/messages.startBot.md @@ -0,0 +1,44 @@ +--- +title: "messages.startBot" +description: "Start a conversation with a bot using a [deep linking parameter](https://core.telegram.org/api/links#bot-links)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_startBot.html +--- +# Method: messages.startBot +[Back to methods index](index.html) + + + +Start a conversation with a bot using a [deep linking parameter](https://core.telegram.org/api/links#bot-links) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The bot | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat where to start the bot, can be the bot's private chat or a group | Optional| +|start\_param|[string](/API_docs/types/string.html) | [Deep linking parameter](https://core.telegram.org/api/links#bot-links) | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->startBot(bot: $InputUser, peer: $InputPeer, start_param: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.startHistoryImport.md b/docs/API_docs/methods/messages.startHistoryImport.md new file mode 100644 index 0000000000..7f1233e315 --- /dev/null +++ b/docs/API_docs/methods/messages.startHistoryImport.md @@ -0,0 +1,44 @@ +--- +title: "messages.startHistoryImport" +description: "Complete the [history import process](https://core.telegram.org/api/import), importing all messages into the chat. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_startHistoryImport.html +--- +# Method: messages.startHistoryImport +[Back to methods index](index.html) + + + +Complete the [history import process](https://core.telegram.org/api/import), importing all messages into the chat. +To be called only after initializing the import with [messages.initHistoryImport](../methods/messages.initHistoryImport.html) and uploading all files using [messages.uploadImportedMedia](../methods/messages.uploadImportedMedia.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The Telegram chat where the messages should be [imported, click here for more info »](https://core.telegram.org/api/import) | Optional| +|import\_id|[long](/API_docs/types/long.html) | Identifier of a history import session, returned by [messages.initHistoryImport](../methods/messages.initHistoryImport.html). | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->startHistoryImport(peer: $InputPeer, import_id: $long, ); +``` + diff --git a/docs/API_docs/methods/messages.toggleBotInAttachMenu.md b/docs/API_docs/methods/messages.toggleBotInAttachMenu.md new file mode 100644 index 0000000000..00386e9cf9 --- /dev/null +++ b/docs/API_docs/methods/messages.toggleBotInAttachMenu.md @@ -0,0 +1,44 @@ +--- +title: "messages.toggleBotInAttachMenu" +description: "Enable or disable [web bot attachment menu »](https://core.telegram.org/api/bots/attach)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_toggleBotInAttachMenu.html +--- +# Method: messages.toggleBotInAttachMenu +[Back to methods index](index.html) + + + +Enable or disable [web bot attachment menu »](https://core.telegram.org/api/bots/attach) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|write\_allowed|[Bool](/API_docs/types/Bool.html) | Whether the user authorizes the bot to write messages to them, if requested by [attachMenuBot](../constructors/attachMenuBot.html).`request_write_access` | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Bot ID | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Toggle | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->toggleBotInAttachMenu(write_allowed: $Bool, bot: $InputUser, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.toggleDialogFilterTags.md b/docs/API_docs/methods/messages.toggleDialogFilterTags.md new file mode 100644 index 0000000000..fab64cfdcd --- /dev/null +++ b/docs/API_docs/methods/messages.toggleDialogFilterTags.md @@ -0,0 +1,40 @@ +--- +title: "messages.toggleDialogFilterTags" +description: "messages.toggleDialogFilterTags parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_toggleDialogFilterTags.html +--- +# Method: messages.toggleDialogFilterTags +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|enabled|[Bool](/API_docs/types/Bool.html) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->toggleDialogFilterTags(enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.toggleDialogPin.md b/docs/API_docs/methods/messages.toggleDialogPin.md new file mode 100644 index 0000000000..d164c170df --- /dev/null +++ b/docs/API_docs/methods/messages.toggleDialogPin.md @@ -0,0 +1,43 @@ +--- +title: "messages.toggleDialogPin" +description: "Pin/unpin a dialog" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_toggleDialogPin.html +--- +# Method: messages.toggleDialogPin +[Back to methods index](index.html) + + + +Pin/unpin a dialog + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|pinned|[Bool](/API_docs/types/Bool.html) | Whether to pin or unpin the dialog | Optional| +|peer|[InputDialogPeer](/API_docs/types/InputDialogPeer.html) | The dialog to pin | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->toggleDialogPin(pinned: $Bool, peer: $InputDialogPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.toggleNoForwards.md b/docs/API_docs/methods/messages.toggleNoForwards.md new file mode 100644 index 0000000000..bbe7d4b7af --- /dev/null +++ b/docs/API_docs/methods/messages.toggleNoForwards.md @@ -0,0 +1,43 @@ +--- +title: "messages.toggleNoForwards" +description: "Enable or disable [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) on a channel or chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_toggleNoForwards.html +--- +# Method: messages.toggleNoForwards +[Back to methods index](index.html) + + + +Enable or disable [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) on a channel or chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat or channel | Optional| +|enabled|[Bool](/API_docs/types/Bool.html) | Enable or disable content protection | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->toggleNoForwards(peer: $InputPeer, enabled: $Bool, ); +``` + diff --git a/docs/API_docs/methods/messages.togglePeerTranslations.md b/docs/API_docs/methods/messages.togglePeerTranslations.md new file mode 100644 index 0000000000..feade248e6 --- /dev/null +++ b/docs/API_docs/methods/messages.togglePeerTranslations.md @@ -0,0 +1,43 @@ +--- +title: "messages.togglePeerTranslations" +description: "Show or hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_togglePeerTranslations.html +--- +# Method: messages.togglePeerTranslations +[Back to methods index](index.html) + + + +Show or hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|disabled|[Bool](/API_docs/types/Bool.html) | Whether to disable or enable the real-time chat translation popup | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->togglePeerTranslations(disabled: $Bool, peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.toggleSavedDialogPin.md b/docs/API_docs/methods/messages.toggleSavedDialogPin.md new file mode 100644 index 0000000000..82f2ef9f60 --- /dev/null +++ b/docs/API_docs/methods/messages.toggleSavedDialogPin.md @@ -0,0 +1,43 @@ +--- +title: "messages.toggleSavedDialogPin" +description: "Pin or unpin a [saved message dialog »](https://core.telegram.org/api/saved-messages)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_toggleSavedDialogPin.html +--- +# Method: messages.toggleSavedDialogPin +[Back to methods index](index.html) + + + +Pin or unpin a [saved message dialog »](https://core.telegram.org/api/saved-messages). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|pinned|[Bool](/API_docs/types/Bool.html) | Whether to pin or unpin the dialog | Optional| +|peer|[InputDialogPeer](/API_docs/types/InputDialogPeer.html) | The dialog to pin | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->toggleSavedDialogPin(pinned: $Bool, peer: $InputDialogPeer, ); +``` + diff --git a/docs/API_docs/methods/messages.toggleStickerSets.md b/docs/API_docs/methods/messages.toggleStickerSets.md new file mode 100644 index 0000000000..0cb7a97c83 --- /dev/null +++ b/docs/API_docs/methods/messages.toggleStickerSets.md @@ -0,0 +1,45 @@ +--- +title: "messages.toggleStickerSets" +description: "Apply changes to multiple stickersets" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_toggleStickerSets.html +--- +# Method: messages.toggleStickerSets +[Back to methods index](index.html) + + + +Apply changes to multiple stickersets + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|uninstall|[Bool](/API_docs/types/Bool.html) | Uninstall the specified stickersets | Optional| +|archive|[Bool](/API_docs/types/Bool.html) | Archive the specified stickersets | Optional| +|unarchive|[Bool](/API_docs/types/Bool.html) | Unarchive the specified stickersets | Optional| +|stickersets|Array of [InputStickerSet](/API_docs/types/InputStickerSet.html) | Stickersets to act upon | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->toggleStickerSets(uninstall: $Bool, archive: $Bool, unarchive: $Bool, stickersets: [$InputStickerSet, $InputStickerSet], ); +``` + diff --git a/docs/API_docs/methods/messages.transcribeAudio.md b/docs/API_docs/methods/messages.transcribeAudio.md new file mode 100644 index 0000000000..ac3b44d62b --- /dev/null +++ b/docs/API_docs/methods/messages.transcribeAudio.md @@ -0,0 +1,43 @@ +--- +title: "messages.transcribeAudio" +description: "[Transcribe voice message](https://core.telegram.org/api/transcribe)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_transcribeAudio.html +--- +# Method: messages.transcribeAudio +[Back to methods index](index.html) + + + +[Transcribe voice message](https://core.telegram.org/api/transcribe) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer ID where the voice message was sent | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Voice message ID | Optional| + + +### Return type: [messages.TranscribedAudio](/API_docs/types/messages.TranscribedAudio.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_TranscribedAudio = $MadelineProto->messages->transcribeAudio(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.translateText.md b/docs/API_docs/methods/messages.translateText.md new file mode 100644 index 0000000000..ae90cd0848 --- /dev/null +++ b/docs/API_docs/methods/messages.translateText.md @@ -0,0 +1,47 @@ +--- +title: "messages.translateText" +description: "Translate a given text." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_translateText.html +--- +# Method: messages.translateText +[Back to methods index](index.html) + + + +Translate a given text. + +[Styled text entities](https://core.telegram.org/api/entities) will only be preserved for [Telegram Premium](https://core.telegram.org/api/premium) users. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | If the text is a chat message, the peer ID | Optional| +|id|Array of [int](/API_docs/types/int.html) | A list of message IDs to translate | Optional| +|text|Array of [TextWithEntities](/API_docs/types/TextWithEntities.html) | A list of styled messages to translate | Optional| +|to\_lang|[string](/API_docs/types/string.html) | Two-letter ISO 639-1 language code of the language to which the message is translated | Optional| + + +### Return type: [messages.TranslatedText](/API_docs/types/messages.TranslatedText.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_TranslatedText = $MadelineProto->messages->translateText(peer: $InputPeer, id: [$int, $int], text: [$TextWithEntities, $TextWithEntities], to_lang: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.uninstallStickerSet.md b/docs/API_docs/methods/messages.uninstallStickerSet.md new file mode 100644 index 0000000000..ec4752ef56 --- /dev/null +++ b/docs/API_docs/methods/messages.uninstallStickerSet.md @@ -0,0 +1,42 @@ +--- +title: "messages.uninstallStickerSet" +description: "Uninstall a stickerset" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_uninstallStickerSet.html +--- +# Method: messages.uninstallStickerSet +[Back to methods index](index.html) + + + +Uninstall a stickerset + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | The stickerset to uninstall | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->uninstallStickerSet(stickerset: $InputStickerSet, ); +``` + diff --git a/docs/API_docs/methods/messages.unpinAllMessages.md b/docs/API_docs/methods/messages.unpinAllMessages.md new file mode 100644 index 0000000000..1d37802f5d --- /dev/null +++ b/docs/API_docs/methods/messages.unpinAllMessages.md @@ -0,0 +1,43 @@ +--- +title: "messages.unpinAllMessages" +description: "[Unpin](https://core.telegram.org/api/pin) all pinned messages" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_unpinAllMessages.html +--- +# Method: messages.unpinAllMessages +[Back to methods index](index.html) + + + +[Unpin](https://core.telegram.org/api/pin) all pinned messages + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Chat where to unpin | Optional| +|top\_msg\_id|[int](/API_docs/types/int.html) | [Forum topic](https://core.telegram.org/api/forum#forum-topics) where to unpin | Optional| + + +### Return type: [messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_AffectedHistory = $MadelineProto->messages->unpinAllMessages(peer: $InputPeer, top_msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.updateDialogFilter.md b/docs/API_docs/methods/messages.updateDialogFilter.md new file mode 100644 index 0000000000..c3550d27e5 --- /dev/null +++ b/docs/API_docs/methods/messages.updateDialogFilter.md @@ -0,0 +1,43 @@ +--- +title: "messages.updateDialogFilter" +description: "Update [folder](https://core.telegram.org/api/folders)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_updateDialogFilter.html +--- +# Method: messages.updateDialogFilter +[Back to methods index](index.html) + + + +Update [folder](https://core.telegram.org/api/folders) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[int](/API_docs/types/int.html) | [Folder](https://core.telegram.org/api/folders) ID | Optional| +|filter|[DialogFilter](/API_docs/types/DialogFilter.html) | [Folder](https://core.telegram.org/api/folders) info | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->updateDialogFilter(id: $int, filter: $DialogFilter, ); +``` + diff --git a/docs/API_docs/methods/messages.updateDialogFiltersOrder.md b/docs/API_docs/methods/messages.updateDialogFiltersOrder.md new file mode 100644 index 0000000000..dd087522a8 --- /dev/null +++ b/docs/API_docs/methods/messages.updateDialogFiltersOrder.md @@ -0,0 +1,42 @@ +--- +title: "messages.updateDialogFiltersOrder" +description: "Reorder [folders](https://core.telegram.org/api/folders)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_updateDialogFiltersOrder.html +--- +# Method: messages.updateDialogFiltersOrder +[Back to methods index](index.html) + + + +Reorder [folders](https://core.telegram.org/api/folders) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|order|Array of [int](/API_docs/types/int.html) | New [folder](https://core.telegram.org/api/folders) order | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->updateDialogFiltersOrder(order: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/messages.updatePinnedMessage.md b/docs/API_docs/methods/messages.updatePinnedMessage.md new file mode 100644 index 0000000000..e69be46342 --- /dev/null +++ b/docs/API_docs/methods/messages.updatePinnedMessage.md @@ -0,0 +1,46 @@ +--- +title: "messages.updatePinnedMessage" +description: "Pin a message" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_updatePinnedMessage.html +--- +# Method: messages.updatePinnedMessage +[Back to methods index](index.html) + + + +Pin a message + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|silent|[Bool](/API_docs/types/Bool.html) | Pin the message silently, without triggering a notification | Optional| +|unpin|[Bool](/API_docs/types/Bool.html) | Whether the message should unpinned or pinned | Optional| +|pm\_oneside|[Bool](/API_docs/types/Bool.html) | Whether the message should only be pinned on the local side of a one-to-one chat | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer where to pin the message | Optional| +|id|[int](/API_docs/types/int.html) | The message to pin or unpin | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->messages->updatePinnedMessage(silent: $Bool, unpin: $Bool, pm_oneside: $Bool, peer: $InputPeer, id: $int, ); +``` + diff --git a/docs/API_docs/methods/messages.updateSavedReactionTag.md b/docs/API_docs/methods/messages.updateSavedReactionTag.md new file mode 100644 index 0000000000..2044f0e6ca --- /dev/null +++ b/docs/API_docs/methods/messages.updateSavedReactionTag.md @@ -0,0 +1,41 @@ +--- +title: "messages.updateSavedReactionTag" +description: "messages.updateSavedReactionTag parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_updateSavedReactionTag.html +--- +# Method: messages.updateSavedReactionTag +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Optional| +|title|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->messages->updateSavedReactionTag(reaction: $Reaction, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/messages.uploadEncryptedFile.md b/docs/API_docs/methods/messages.uploadEncryptedFile.md new file mode 100644 index 0000000000..814f93bb5d --- /dev/null +++ b/docs/API_docs/methods/messages.uploadEncryptedFile.md @@ -0,0 +1,43 @@ +--- +title: "messages.uploadEncryptedFile" +description: "Upload encrypted file and associate it to a secret chat" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_uploadEncryptedFile.html +--- +# Method: messages.uploadEncryptedFile +[Back to methods index](index.html) + + + +Upload encrypted file and associate it to a secret chat + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Secret chat ID, Update, EncryptedMessage or InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) | The secret chat to associate the file to | Yes| +|file|[File path or InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) | The file | Optional| + + +### Return type: [EncryptedFile](/API_docs/types/EncryptedFile.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$EncryptedFile = $MadelineProto->messages->uploadEncryptedFile(peer: $InputEncryptedChat, file: $InputEncryptedFile, ); +``` + diff --git a/docs/API_docs/methods/messages.uploadImportedMedia.md b/docs/API_docs/methods/messages.uploadImportedMedia.md new file mode 100644 index 0000000000..72962c2f17 --- /dev/null +++ b/docs/API_docs/methods/messages.uploadImportedMedia.md @@ -0,0 +1,45 @@ +--- +title: "messages.uploadImportedMedia" +description: "Upload a media file associated with an [imported chat, click here for more info »](https://core.telegram.org/api/import)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_uploadImportedMedia.html +--- +# Method: messages.uploadImportedMedia +[Back to methods index](index.html) + + + +Upload a media file associated with an [imported chat, click here for more info »](https://core.telegram.org/api/import). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The Telegram chat where the media will be imported | Optional| +|import\_id|[long](/API_docs/types/long.html) | Identifier of a [history import session](https://core.telegram.org/api/import), returned by [messages.initHistoryImport](../methods/messages.initHistoryImport.html) | Yes| +|file\_name|[string](/API_docs/types/string.html) | File name | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | Media metadata | Optional| + + +### Return type: [MessageMedia](/API_docs/types/MessageMedia.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$MessageMedia = $MadelineProto->messages->uploadImportedMedia(peer: $InputPeer, import_id: $long, file_name: 'string', media: $InputMedia, ); +``` + diff --git a/docs/API_docs/methods/messages.uploadMedia.md b/docs/API_docs/methods/messages.uploadMedia.md new file mode 100644 index 0000000000..bcafbddfa3 --- /dev/null +++ b/docs/API_docs/methods/messages.uploadMedia.md @@ -0,0 +1,44 @@ +--- +title: "messages.uploadMedia" +description: "Upload a file and associate it to a chat (without actually sending it to the chat)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/messages_uploadMedia.html +--- +# Method: messages.uploadMedia +[Back to methods index](index.html) + + + +Upload a file and associate it to a chat (without actually sending it to the chat) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|business\_connection\_id|[string](/API_docs/types/string.html) | | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The chat, can be [inputPeerEmpty](../constructors/inputPeerEmpty.html) for bots and [inputPeerSelf](../constructors/inputPeerSelf.html) for users. | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | File uploaded in chunks as described in [files »](https://core.telegram.org/api/files) | Optional| + + +### Return type: [MessageMedia](/API_docs/types/MessageMedia.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$MessageMedia = $MadelineProto->messages->uploadMedia(business_connection_id: 'string', peer: $InputPeer, media: $InputMedia, ); +``` + diff --git a/docs/API_docs/methods/payments.applyGiftCode.md b/docs/API_docs/methods/payments.applyGiftCode.md new file mode 100644 index 0000000000..f263da036e --- /dev/null +++ b/docs/API_docs/methods/payments.applyGiftCode.md @@ -0,0 +1,42 @@ +--- +title: "payments.applyGiftCode" +description: "Apply a [Telegram Premium giftcode »](https://core.telegram.org/api/giveaways)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_applyGiftCode.html +--- +# Method: payments.applyGiftCode +[Back to methods index](index.html) + + + +Apply a [Telegram Premium giftcode »](https://core.telegram.org/api/giveaways) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|slug|[string](/API_docs/types/string.html) | The code to apply | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->payments->applyGiftCode(slug: 'string', ); +``` + diff --git a/docs/API_docs/methods/payments.assignAppStoreTransaction.md b/docs/API_docs/methods/payments.assignAppStoreTransaction.md new file mode 100644 index 0000000000..615e655ce4 --- /dev/null +++ b/docs/API_docs/methods/payments.assignAppStoreTransaction.md @@ -0,0 +1,43 @@ +--- +title: "payments.assignAppStoreTransaction" +description: "Informs server about a purchase made through the App Store: for official applications only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_assignAppStoreTransaction.html +--- +# Method: payments.assignAppStoreTransaction +[Back to methods index](index.html) + + + +Informs server about a purchase made through the App Store: for official applications only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|receipt|[bytes](/API_docs/types/bytes.html) | Receipt | Yes| +|purpose|[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) | Payment purpose | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->payments->assignAppStoreTransaction(receipt: 'bytes', purpose: $InputStorePaymentPurpose, ); +``` + diff --git a/docs/API_docs/methods/payments.assignPlayMarketTransaction.md b/docs/API_docs/methods/payments.assignPlayMarketTransaction.md new file mode 100644 index 0000000000..3e85accfa7 --- /dev/null +++ b/docs/API_docs/methods/payments.assignPlayMarketTransaction.md @@ -0,0 +1,43 @@ +--- +title: "payments.assignPlayMarketTransaction" +description: "Informs server about a purchase made through the Play Store: for official applications only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_assignPlayMarketTransaction.html +--- +# Method: payments.assignPlayMarketTransaction +[Back to methods index](index.html) + + + +Informs server about a purchase made through the Play Store: for official applications only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|receipt|[DataJSON](/API_docs/types/DataJSON.html) | Receipt | Yes| +|purpose|[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) | Payment purpose | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->payments->assignPlayMarketTransaction(receipt: $DataJSON, purpose: $InputStorePaymentPurpose, ); +``` + diff --git a/docs/API_docs/methods/payments.canPurchasePremium.md b/docs/API_docs/methods/payments.canPurchasePremium.md new file mode 100644 index 0000000000..034e41213b --- /dev/null +++ b/docs/API_docs/methods/payments.canPurchasePremium.md @@ -0,0 +1,42 @@ +--- +title: "payments.canPurchasePremium" +description: "Checks whether Telegram Premium purchase is possible. Must be called before in-store Premium purchase, official apps only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_canPurchasePremium.html +--- +# Method: payments.canPurchasePremium +[Back to methods index](index.html) + + + +Checks whether Telegram Premium purchase is possible. Must be called before in-store Premium purchase, official apps only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|purpose|[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) | Payment purpose | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->payments->canPurchasePremium(purpose: $InputStorePaymentPurpose, ); +``` + diff --git a/docs/API_docs/methods/payments.checkGiftCode.md b/docs/API_docs/methods/payments.checkGiftCode.md new file mode 100644 index 0000000000..958e29b8e2 --- /dev/null +++ b/docs/API_docs/methods/payments.checkGiftCode.md @@ -0,0 +1,42 @@ +--- +title: "payments.checkGiftCode" +description: "Obtain information about a [Telegram Premium giftcode »](https://core.telegram.org/api/giveaways)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_checkGiftCode.html +--- +# Method: payments.checkGiftCode +[Back to methods index](index.html) + + + +Obtain information about a [Telegram Premium giftcode »](https://core.telegram.org/api/giveaways) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|slug|[string](/API_docs/types/string.html) | The giftcode to check | Optional| + + +### Return type: [payments.CheckedGiftCode](/API_docs/types/payments.CheckedGiftCode.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_CheckedGiftCode = $MadelineProto->payments->checkGiftCode(slug: 'string', ); +``` + diff --git a/docs/API_docs/methods/payments.clearSavedInfo.md b/docs/API_docs/methods/payments.clearSavedInfo.md new file mode 100644 index 0000000000..8633807c42 --- /dev/null +++ b/docs/API_docs/methods/payments.clearSavedInfo.md @@ -0,0 +1,43 @@ +--- +title: "payments.clearSavedInfo" +description: "Clear saved payment information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_clearSavedInfo.html +--- +# Method: payments.clearSavedInfo +[Back to methods index](index.html) + + + +Clear saved payment information + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|credentials|[Bool](/API_docs/types/Bool.html) | Remove saved payment credentials | Optional| +|info|[Bool](/API_docs/types/Bool.html) | Clear the last order settings saved by the user | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->payments->clearSavedInfo(credentials: $Bool, info: $Bool, ); +``` + diff --git a/docs/API_docs/methods/payments.exportInvoice.md b/docs/API_docs/methods/payments.exportInvoice.md new file mode 100644 index 0000000000..39c9179638 --- /dev/null +++ b/docs/API_docs/methods/payments.exportInvoice.md @@ -0,0 +1,42 @@ +--- +title: "payments.exportInvoice" +description: "Generate an [invoice deep link](https://core.telegram.org/api/links#invoice-links)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_exportInvoice.html +--- +# Method: payments.exportInvoice +[Back to methods index](index.html) + + + +Generate an [invoice deep link](https://core.telegram.org/api/links#invoice-links) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|invoice\_media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | Invoice | Optional| + + +### Return type: [payments.ExportedInvoice](/API_docs/types/payments.ExportedInvoice.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_ExportedInvoice = $MadelineProto->payments->exportInvoice(invoice_media: $InputMedia, ); +``` + diff --git a/docs/API_docs/methods/payments.getBankCardData.md b/docs/API_docs/methods/payments.getBankCardData.md new file mode 100644 index 0000000000..6650eb2955 --- /dev/null +++ b/docs/API_docs/methods/payments.getBankCardData.md @@ -0,0 +1,42 @@ +--- +title: "payments.getBankCardData" +description: "Get info about a credit card" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_getBankCardData.html +--- +# Method: payments.getBankCardData +[Back to methods index](index.html) + + + +Get info about a credit card + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|number|[string](/API_docs/types/string.html) | Credit card number | Optional| + + +### Return type: [payments.BankCardData](/API_docs/types/payments.BankCardData.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_BankCardData = $MadelineProto->payments->getBankCardData(number: 'string', ); +``` + diff --git a/docs/API_docs/methods/payments.getGiveawayInfo.md b/docs/API_docs/methods/payments.getGiveawayInfo.md new file mode 100644 index 0000000000..f0ae6ff69e --- /dev/null +++ b/docs/API_docs/methods/payments.getGiveawayInfo.md @@ -0,0 +1,43 @@ +--- +title: "payments.getGiveawayInfo" +description: "Obtain information about a [Telegram Premium giveaway »](https://core.telegram.org/api/giveaways)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_getGiveawayInfo.html +--- +# Method: payments.getGiveawayInfo +[Back to methods index](index.html) + + + +Obtain information about a [Telegram Premium giveaway »](https://core.telegram.org/api/giveaways). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer where the giveaway was posted. | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID of the [messageActionGiveawayLaunch](../constructors/messageActionGiveawayLaunch.html) service message | Optional| + + +### Return type: [payments.GiveawayInfo](/API_docs/types/payments.GiveawayInfo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_GiveawayInfo = $MadelineProto->payments->getGiveawayInfo(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/payments.getPaymentForm.md b/docs/API_docs/methods/payments.getPaymentForm.md new file mode 100644 index 0000000000..583c09c463 --- /dev/null +++ b/docs/API_docs/methods/payments.getPaymentForm.md @@ -0,0 +1,43 @@ +--- +title: "payments.getPaymentForm" +description: "Get a payment form" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_getPaymentForm.html +--- +# Method: payments.getPaymentForm +[Back to methods index](index.html) + + + +Get a payment form + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|invoice|[InputInvoice](/API_docs/types/InputInvoice.html) | Invoice | Yes| +|theme\_params|[DataJSON](/API_docs/types/DataJSON.html) | A JSON object with the following keys, containing color theme information (integers, RGB24) to pass to the payment provider, to apply in eventual verification pages:
`bg_color` \- Background color
`text_color` \- Text color
`hint_color` \- Hint text color
`link_color` \- Link color
`button_color` \- Button color
`button_text_color` \- Button text color | Optional| + + +### Return type: [payments.PaymentForm](/API_docs/types/payments.PaymentForm.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_PaymentForm = $MadelineProto->payments->getPaymentForm(invoice: $InputInvoice, theme_params: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/payments.getPaymentReceipt.md b/docs/API_docs/methods/payments.getPaymentReceipt.md new file mode 100644 index 0000000000..3afd6177cc --- /dev/null +++ b/docs/API_docs/methods/payments.getPaymentReceipt.md @@ -0,0 +1,43 @@ +--- +title: "payments.getPaymentReceipt" +description: "Get payment receipt" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_getPaymentReceipt.html +--- +# Method: payments.getPaymentReceipt +[Back to methods index](index.html) + + + +Get payment receipt + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer where the payment receipt was sent | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID of receipt | Optional| + + +### Return type: [payments.PaymentReceipt](/API_docs/types/payments.PaymentReceipt.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_PaymentReceipt = $MadelineProto->payments->getPaymentReceipt(peer: $InputPeer, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/payments.getPremiumGiftCodeOptions.md b/docs/API_docs/methods/payments.getPremiumGiftCodeOptions.md new file mode 100644 index 0000000000..d1038c54fa --- /dev/null +++ b/docs/API_docs/methods/payments.getPremiumGiftCodeOptions.md @@ -0,0 +1,42 @@ +--- +title: "payments.getPremiumGiftCodeOptions" +description: "Obtain a list of Telegram Premium [giveaway/gift code »](https://core.telegram.org/api/giveaways) options." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_getPremiumGiftCodeOptions.html +--- +# Method: payments.getPremiumGiftCodeOptions +[Back to methods index](index.html) + + + +Obtain a list of Telegram Premium [giveaway/gift code »](https://core.telegram.org/api/giveaways) options. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|boost\_peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The channel that will start the giveaway | Optional| + + +### Return type: [Vector\_of\_PremiumGiftCodeOption](/API_docs/types/PremiumGiftCodeOption.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_PremiumGiftCodeOption = $MadelineProto->payments->getPremiumGiftCodeOptions(boost_peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/payments.getSavedInfo.md b/docs/API_docs/methods/payments.getSavedInfo.md new file mode 100644 index 0000000000..e78b9d6ced --- /dev/null +++ b/docs/API_docs/methods/payments.getSavedInfo.md @@ -0,0 +1,37 @@ +--- +title: "payments.getSavedInfo" +description: "Get saved payment information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_getSavedInfo.html +--- +# Method: payments.getSavedInfo +[Back to methods index](index.html) + + + +Get saved payment information + + + +### Return type: [payments.SavedInfo](/API_docs/types/payments.SavedInfo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_SavedInfo = $MadelineProto->payments->getSavedInfo(); +``` + diff --git a/docs/API_docs/methods/payments.launchPrepaidGiveaway.md b/docs/API_docs/methods/payments.launchPrepaidGiveaway.md new file mode 100644 index 0000000000..557649c5cd --- /dev/null +++ b/docs/API_docs/methods/payments.launchPrepaidGiveaway.md @@ -0,0 +1,44 @@ +--- +title: "payments.launchPrepaidGiveaway" +description: "Launch a [prepaid giveaway »](https://core.telegram.org/api/giveaways)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_launchPrepaidGiveaway.html +--- +# Method: payments.launchPrepaidGiveaway +[Back to methods index](index.html) + + + +Launch a [prepaid giveaway »](https://core.telegram.org/api/giveaways). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer where to launch the giveaway. | Optional| +|giveaway\_id|[long](/API_docs/types/long.html) | The prepaid giveaway ID. | Yes| +|purpose|[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) | Giveway parameters | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->payments->launchPrepaidGiveaway(peer: $InputPeer, giveaway_id: $long, purpose: $InputStorePaymentPurpose, ); +``` + diff --git a/docs/API_docs/methods/payments.sendPaymentForm.md b/docs/API_docs/methods/payments.sendPaymentForm.md new file mode 100644 index 0000000000..293650f514 --- /dev/null +++ b/docs/API_docs/methods/payments.sendPaymentForm.md @@ -0,0 +1,47 @@ +--- +title: "payments.sendPaymentForm" +description: "Send compiled payment form" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_sendPaymentForm.html +--- +# Method: payments.sendPaymentForm +[Back to methods index](index.html) + + + +Send compiled payment form + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|form\_id|[long](/API_docs/types/long.html) | Form ID | Yes| +|invoice|[InputInvoice](/API_docs/types/InputInvoice.html) | Invoice | Yes| +|requested\_info\_id|[string](/API_docs/types/string.html) | ID of saved and validated [order info](../constructors/payments.validatedRequestedInfo.html) | Optional| +|shipping\_option\_id|[string](/API_docs/types/string.html) | Chosen shipping option ID | Optional| +|credentials|[InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html) | Payment credentials | Yes| +|tip\_amount|[long](/API_docs/types/long.html) | Tip, in the smallest units of the currency (integer, not float/double). For example, for a price of `US$ 1.45` pass `amount = 145`. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies). | Optional| + + +### Return type: [payments.PaymentResult](/API_docs/types/payments.PaymentResult.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_PaymentResult = $MadelineProto->payments->sendPaymentForm(form_id: $long, invoice: $InputInvoice, requested_info_id: 'string', shipping_option_id: 'string', credentials: $InputPaymentCredentials, tip_amount: $long, ); +``` + diff --git a/docs/API_docs/methods/payments.validateRequestedInfo.md b/docs/API_docs/methods/payments.validateRequestedInfo.md new file mode 100644 index 0000000000..3e47fa4fce --- /dev/null +++ b/docs/API_docs/methods/payments.validateRequestedInfo.md @@ -0,0 +1,44 @@ +--- +title: "payments.validateRequestedInfo" +description: "Submit requested order information for validation" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/payments_validateRequestedInfo.html +--- +# Method: payments.validateRequestedInfo +[Back to methods index](index.html) + + + +Submit requested order information for validation + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|save|[Bool](/API_docs/types/Bool.html) | Save order information to re-use it for future orders | Optional| +|invoice|[InputInvoice](/API_docs/types/InputInvoice.html) | Invoice | Yes| +|info|[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) | Requested order information | Yes| + + +### Return type: [payments.ValidatedRequestedInfo](/API_docs/types/payments.ValidatedRequestedInfo.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$payments_ValidatedRequestedInfo = $MadelineProto->payments->validateRequestedInfo(save: $Bool, invoice: $InputInvoice, info: $PaymentRequestedInfo, ); +``` + diff --git a/docs/API_docs/methods/phone.acceptCall.md b/docs/API_docs/methods/phone.acceptCall.md new file mode 100644 index 0000000000..81facc33d4 --- /dev/null +++ b/docs/API_docs/methods/phone.acceptCall.md @@ -0,0 +1,44 @@ +--- +title: "phone.acceptCall" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_acceptCall.html +--- +# Method: phone.acceptCall +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | The call to accept | Yes| +|g\_b|[bytes](/API_docs/types/bytes.html) | [Parameter for E2E encryption key exchange »](https://core.telegram.org/api/end-to-end/voice-calls) | Yes| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Phone call settings | Yes| + + +### Return type: [phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_PhoneCall = $MadelineProto->phone->acceptCall(peer: $InputPhoneCall, g_b: 'bytes', protocol: $PhoneCallProtocol, ); +``` + diff --git a/docs/API_docs/methods/phone.checkGroupCall.md b/docs/API_docs/methods/phone.checkGroupCall.md new file mode 100644 index 0000000000..c0ee4a5be7 --- /dev/null +++ b/docs/API_docs/methods/phone.checkGroupCall.md @@ -0,0 +1,44 @@ +--- +title: "phone.checkGroupCall" +description: "Check whether the group call Server Forwarding Unit is currently receiving the streams with the specified WebRTC source IDs. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_checkGroupCall.html +--- +# Method: phone.checkGroupCall +[Back to methods index](index.html) + + + +Check whether the group call Server Forwarding Unit is currently receiving the streams with the specified WebRTC source IDs. +Returns an intersection of the source IDs specified in `sources`, and the source IDs currently being forwarded by the SFU. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Group call | Yes| +|sources|Array of [int](/API_docs/types/int.html) | Source IDs | Yes| + + +### Return type: [Vector\_of\_int](/API_docs/types/int.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_int = $MadelineProto->phone->checkGroupCall(call: $InputGroupCall, sources: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/phone.confirmCall.md b/docs/API_docs/methods/phone.confirmCall.md new file mode 100644 index 0000000000..3044c3d3a5 --- /dev/null +++ b/docs/API_docs/methods/phone.confirmCall.md @@ -0,0 +1,45 @@ +--- +title: "phone.confirmCall" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_confirmCall.html +--- +# Method: phone.confirmCall +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | The phone call | Yes| +|g\_a|[bytes](/API_docs/types/bytes.html) | [Parameter for E2E encryption key exchange »](https://core.telegram.org/api/end-to-end/voice-calls) | Yes| +|key\_fingerprint|[strlong](/API_docs/constructors/strlong.html) | | Yes| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Phone call settings | Yes| + + +### Return type: [phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_PhoneCall = $MadelineProto->phone->confirmCall(peer: $InputPhoneCall, g_a: 'bytes', key_fingerprint: $strlong, protocol: $PhoneCallProtocol, ); +``` + diff --git a/docs/API_docs/methods/phone.createGroupCall.md b/docs/API_docs/methods/phone.createGroupCall.md new file mode 100644 index 0000000000..81e4005ba5 --- /dev/null +++ b/docs/API_docs/methods/phone.createGroupCall.md @@ -0,0 +1,45 @@ +--- +title: "phone.createGroupCall" +description: "Create a group call or livestream" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_createGroupCall.html +--- +# Method: phone.createGroupCall +[Back to methods index](index.html) + + + +Create a group call or livestream + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|rtmp\_stream|[Bool](/API_docs/types/Bool.html) | Whether RTMP stream support should be enabled: only the [group/supergroup/channel](https://core.telegram.org/api/channel) owner can use this flag. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Associate the group call or livestream to the provided [group/supergroup/channel](https://core.telegram.org/api/channel) | Optional| +|title|[string](/API_docs/types/string.html) | Call title | Optional| +|schedule\_date|[int](/API_docs/types/int.html) | For scheduled group call or livestreams, the absolute date when the group call will start | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->createGroupCall(rtmp_stream: $Bool, peer: $InputPeer, title: 'string', schedule_date: $int, ); +``` + diff --git a/docs/API_docs/methods/phone.discardCall.md b/docs/API_docs/methods/phone.discardCall.md new file mode 100644 index 0000000000..cb33d08636 --- /dev/null +++ b/docs/API_docs/methods/phone.discardCall.md @@ -0,0 +1,46 @@ +--- +title: "phone.discardCall" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_discardCall.html +--- +# Method: phone.discardCall +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|video|[Bool](/API_docs/types/Bool.html) | Whether this is a video call | Optional| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | The phone call | Yes| +|duration|[int](/API_docs/types/int.html) | Call duration | Optional| +|reason|[PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) | Why was the call discarded | Yes| +|connection\_id|[long](/API_docs/types/long.html) | Preferred libtgvoip relay ID | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->discardCall(video: $Bool, peer: $InputPhoneCall, duration: $int, reason: $PhoneCallDiscardReason, connection_id: $long, ); +``` + diff --git a/docs/API_docs/methods/phone.discardGroupCall.md b/docs/API_docs/methods/phone.discardGroupCall.md new file mode 100644 index 0000000000..32951fd23e --- /dev/null +++ b/docs/API_docs/methods/phone.discardGroupCall.md @@ -0,0 +1,42 @@ +--- +title: "phone.discardGroupCall" +description: "Terminate a group call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_discardGroupCall.html +--- +# Method: phone.discardGroupCall +[Back to methods index](index.html) + + + +Terminate a group call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call to terminate | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->discardGroupCall(call: $InputGroupCall, ); +``` + diff --git a/docs/API_docs/methods/phone.editGroupCallParticipant.md b/docs/API_docs/methods/phone.editGroupCallParticipant.md new file mode 100644 index 0000000000..e71c3ca61e --- /dev/null +++ b/docs/API_docs/methods/phone.editGroupCallParticipant.md @@ -0,0 +1,55 @@ +--- +title: "phone.editGroupCallParticipant" +description: "Edit information about a given group call participant" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_editGroupCallParticipant.html +--- +# Method: phone.editGroupCallParticipant +[Back to methods index](index.html) + + + +Edit information about a given group call participant + +Note: [flags](https://core.telegram.org/mtproto/TL-combinators#conditional-fields).N?[Bool](../types/Bool.html) parameters can have three possible values: + +- If the [TL flag](https://core.telegram.org/mtproto/TL-combinators#conditional-fields) is not set, the previous value will not be changed. +- If the [TL flag](https://core.telegram.org/mtproto/TL-combinators#conditional-fields) is set and contains a [boolTrue](../constructors/boolTrue.html), the previous value will be overwritten to `true`. +- If the [TL flag](https://core.telegram.org/mtproto/TL-combinators#conditional-fields) is set and contains a [boolFalse](../constructors/boolFalse.html), the previous value will be overwritten to `false`. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| +|participant|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The group call participant (can also be the user itself) | Optional| +|muted|[Bool](/API_docs/types/Bool.html) | Whether to mute or unmute the specified participant | Optional| +|volume|[int](/API_docs/types/int.html) | New volume | Optional| +|raise\_hand|[Bool](/API_docs/types/Bool.html) | Raise or lower hand | Optional| +|video\_stopped|[Bool](/API_docs/types/Bool.html) | Start or stop the video stream | Optional| +|video\_paused|[Bool](/API_docs/types/Bool.html) | Pause or resume the video stream | Optional| +|presentation\_paused|[Bool](/API_docs/types/Bool.html) | Pause or resume the screen sharing stream | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->editGroupCallParticipant(call: $InputGroupCall, participant: $InputPeer, muted: $Bool, volume: $int, raise_hand: $Bool, video_stopped: $Bool, video_paused: $Bool, presentation_paused: $Bool, ); +``` + diff --git a/docs/API_docs/methods/phone.editGroupCallTitle.md b/docs/API_docs/methods/phone.editGroupCallTitle.md new file mode 100644 index 0000000000..556c8f46fe --- /dev/null +++ b/docs/API_docs/methods/phone.editGroupCallTitle.md @@ -0,0 +1,43 @@ +--- +title: "phone.editGroupCallTitle" +description: "Edit the title of a group call or livestream" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_editGroupCallTitle.html +--- +# Method: phone.editGroupCallTitle +[Back to methods index](index.html) + + + +Edit the title of a group call or livestream + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Group call | Yes| +|title|[string](/API_docs/types/string.html) | New title | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->editGroupCallTitle(call: $InputGroupCall, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/phone.exportGroupCallInvite.md b/docs/API_docs/methods/phone.exportGroupCallInvite.md new file mode 100644 index 0000000000..7b8594658f --- /dev/null +++ b/docs/API_docs/methods/phone.exportGroupCallInvite.md @@ -0,0 +1,43 @@ +--- +title: "phone.exportGroupCallInvite" +description: "Get an [invite link](https://core.telegram.org/api/links#video-chat-livestream-links) for a group call or livestream" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_exportGroupCallInvite.html +--- +# Method: phone.exportGroupCallInvite +[Back to methods index](index.html) + + + +Get an [invite link](https://core.telegram.org/api/links#video-chat-livestream-links) for a group call or livestream + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|can\_self\_unmute|[Bool](/API_docs/types/Bool.html) | For livestreams or muted group chats, if set, users that join using this link will be able to speak without explicitly requesting permission by (for example by raising their hand). | Optional| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| + + +### Return type: [phone.ExportedGroupCallInvite](/API_docs/types/phone.ExportedGroupCallInvite.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_ExportedGroupCallInvite = $MadelineProto->phone->exportGroupCallInvite(can_self_unmute: $Bool, call: $InputGroupCall, ); +``` + diff --git a/docs/API_docs/methods/phone.getCallConfig.md b/docs/API_docs/methods/phone.getCallConfig.md new file mode 100644 index 0000000000..829c08d184 --- /dev/null +++ b/docs/API_docs/methods/phone.getCallConfig.md @@ -0,0 +1,37 @@ +--- +title: "phone.getCallConfig" +description: "Get phone call configuration to be passed to libtgvoip's shared config" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_getCallConfig.html +--- +# Method: phone.getCallConfig +[Back to methods index](index.html) + + + +Get phone call configuration to be passed to libtgvoip's shared config + + + +### Return type: [DataJSON](/API_docs/types/DataJSON.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$DataJSON = $MadelineProto->phone->getCallConfig(); +``` + diff --git a/docs/API_docs/methods/phone.getGroupCall.md b/docs/API_docs/methods/phone.getGroupCall.md new file mode 100644 index 0000000000..8ee1c0a87f --- /dev/null +++ b/docs/API_docs/methods/phone.getGroupCall.md @@ -0,0 +1,43 @@ +--- +title: "phone.getGroupCall" +description: "Get info about a group call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_getGroupCall.html +--- +# Method: phone.getGroupCall +[Back to methods index](index.html) + + + +Get info about a group call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [phone.GroupCall](/API_docs/types/phone.GroupCall.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_GroupCall = $MadelineProto->phone->getGroupCall(call: $InputGroupCall, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/phone.getGroupCallJoinAs.md b/docs/API_docs/methods/phone.getGroupCallJoinAs.md new file mode 100644 index 0000000000..a6da3c1655 --- /dev/null +++ b/docs/API_docs/methods/phone.getGroupCallJoinAs.md @@ -0,0 +1,42 @@ +--- +title: "phone.getGroupCallJoinAs" +description: "Get a list of peers that can be used to join a group call, presenting yourself as a specific user/channel." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_getGroupCallJoinAs.html +--- +# Method: phone.getGroupCallJoinAs +[Back to methods index](index.html) + + + +Get a list of peers that can be used to join a group call, presenting yourself as a specific user/channel. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The dialog whose group call or livestream we're trying to join | Optional| + + +### Return type: [phone.JoinAsPeers](/API_docs/types/phone.JoinAsPeers.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_JoinAsPeers = $MadelineProto->phone->getGroupCallJoinAs(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/phone.getGroupCallStreamChannels.md b/docs/API_docs/methods/phone.getGroupCallStreamChannels.md new file mode 100644 index 0000000000..839d612062 --- /dev/null +++ b/docs/API_docs/methods/phone.getGroupCallStreamChannels.md @@ -0,0 +1,44 @@ +--- +title: "phone.getGroupCallStreamChannels" +description: "Get info about RTMP streams in a group call or livestream. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_getGroupCallStreamChannels.html +--- +# Method: phone.getGroupCallStreamChannels +[Back to methods index](index.html) + + + +Get info about RTMP streams in a group call or livestream. +This method should be invoked to the same group/channel-related DC used for [downloading livestream chunks](https://core.telegram.org/api/files#downloading-files). +As usual, the media DC is preferred, if available. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Group call or livestream | Yes| + + +### Return type: [phone.GroupCallStreamChannels](/API_docs/types/phone.GroupCallStreamChannels.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_GroupCallStreamChannels = $MadelineProto->phone->getGroupCallStreamChannels(call: $InputGroupCall, ); +``` + diff --git a/docs/API_docs/methods/phone.getGroupCallStreamRtmpUrl.md b/docs/API_docs/methods/phone.getGroupCallStreamRtmpUrl.md new file mode 100644 index 0000000000..6153bda0f9 --- /dev/null +++ b/docs/API_docs/methods/phone.getGroupCallStreamRtmpUrl.md @@ -0,0 +1,43 @@ +--- +title: "phone.getGroupCallStreamRtmpUrl" +description: "Get RTMP URL and stream key for RTMP livestreams. Can be used even before creating the actual RTMP livestream with [phone.createGroupCall](../methods/phone.createGroupCall.html) (the `rtmp_stream` flag must be set)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_getGroupCallStreamRtmpUrl.html +--- +# Method: phone.getGroupCallStreamRtmpUrl +[Back to methods index](index.html) + + + +Get RTMP URL and stream key for RTMP livestreams. Can be used even before creating the actual RTMP livestream with [phone.createGroupCall](../methods/phone.createGroupCall.html) (the `rtmp_stream` flag must be set). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer to livestream into | Optional| +|revoke|[Bool](/API_docs/types/Bool.html) | Whether to revoke the previous stream key or simply return the existing one | Yes| + + +### Return type: [phone.GroupCallStreamRtmpUrl](/API_docs/types/phone.GroupCallStreamRtmpUrl.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_GroupCallStreamRtmpUrl = $MadelineProto->phone->getGroupCallStreamRtmpUrl(peer: $InputPeer, revoke: $Bool, ); +``` + diff --git a/docs/API_docs/methods/phone.getGroupParticipants.md b/docs/API_docs/methods/phone.getGroupParticipants.md new file mode 100644 index 0000000000..cdb3558a7c --- /dev/null +++ b/docs/API_docs/methods/phone.getGroupParticipants.md @@ -0,0 +1,46 @@ +--- +title: "phone.getGroupParticipants" +description: "Get group call participants" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_getGroupParticipants.html +--- +# Method: phone.getGroupParticipants +[Back to methods index](index.html) + + + +Get group call participants + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Group call | Yes| +|ids|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | If specified, will fetch group participant info about the specified peers | Yes| +|sources|Array of [int](/API_docs/types/int.html) | If specified, will fetch group participant info about the specified WebRTC source IDs | Yes| +|offset|[string](/API_docs/types/string.html) | Offset for results, taken from the `next_offset` field of [phone.groupParticipants](../constructors/phone.groupParticipants.html), initially an empty string.
Note: if no more results are available, the method call will return an empty `next_offset`; thus, avoid providing the `next_offset` returned in [phone.groupParticipants](../constructors/phone.groupParticipants.html) if it is empty, to avoid an infinite loop. | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [phone.GroupParticipants](/API_docs/types/phone.GroupParticipants.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_GroupParticipants = $MadelineProto->phone->getGroupParticipants(call: $InputGroupCall, ids: [$InputPeer, $InputPeer], sources: [$int, $int], offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/phone.inviteToGroupCall.md b/docs/API_docs/methods/phone.inviteToGroupCall.md new file mode 100644 index 0000000000..055dda92a3 --- /dev/null +++ b/docs/API_docs/methods/phone.inviteToGroupCall.md @@ -0,0 +1,43 @@ +--- +title: "phone.inviteToGroupCall" +description: "Invite a set of users to a group call." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_inviteToGroupCall.html +--- +# Method: phone.inviteToGroupCall +[Back to methods index](index.html) + + + +Invite a set of users to a group call. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| +|users|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The users to invite. | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->inviteToGroupCall(call: $InputGroupCall, users: [$InputUser, $InputUser], ); +``` + diff --git a/docs/API_docs/methods/phone.joinGroupCall.md b/docs/API_docs/methods/phone.joinGroupCall.md new file mode 100644 index 0000000000..5ca8893b59 --- /dev/null +++ b/docs/API_docs/methods/phone.joinGroupCall.md @@ -0,0 +1,47 @@ +--- +title: "phone.joinGroupCall" +description: "Join a group call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_joinGroupCall.html +--- +# Method: phone.joinGroupCall +[Back to methods index](index.html) + + + +Join a group call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|muted|[Bool](/API_docs/types/Bool.html) | If set, the user will be muted by default upon joining. | Optional| +|video\_stopped|[Bool](/API_docs/types/Bool.html) | If set, the user's video will be disabled by default upon joining. | Optional| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| +|join\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Join the group call, presenting yourself as the specified user/channel | Optional| +|invite\_hash|[string](/API_docs/types/string.html) | The invitation hash from the [invite link »](https://core.telegram.org/api/links#video-chat-livestream-links), if provided allows speaking in a livestream or muted group chat. | Optional| +|params|[DataJSON](/API_docs/types/DataJSON.html) | WebRTC parameters | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->joinGroupCall(muted: $Bool, video_stopped: $Bool, call: $InputGroupCall, join_as: $InputPeer, invite_hash: 'string', params: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/phone.joinGroupCallPresentation.md b/docs/API_docs/methods/phone.joinGroupCallPresentation.md new file mode 100644 index 0000000000..57106ddae2 --- /dev/null +++ b/docs/API_docs/methods/phone.joinGroupCallPresentation.md @@ -0,0 +1,43 @@ +--- +title: "phone.joinGroupCallPresentation" +description: "Start screen sharing in a call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_joinGroupCallPresentation.html +--- +# Method: phone.joinGroupCallPresentation +[Back to methods index](index.html) + + + +Start screen sharing in a call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| +|params|[DataJSON](/API_docs/types/DataJSON.html) | WebRTC parameters | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->joinGroupCallPresentation(call: $InputGroupCall, params: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/phone.leaveGroupCall.md b/docs/API_docs/methods/phone.leaveGroupCall.md new file mode 100644 index 0000000000..054afeecb8 --- /dev/null +++ b/docs/API_docs/methods/phone.leaveGroupCall.md @@ -0,0 +1,43 @@ +--- +title: "phone.leaveGroupCall" +description: "Leave a group call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_leaveGroupCall.html +--- +# Method: phone.leaveGroupCall +[Back to methods index](index.html) + + + +Leave a group call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| +|source|[int](/API_docs/types/int.html) | Your source ID | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->leaveGroupCall(call: $InputGroupCall, source: $int, ); +``` + diff --git a/docs/API_docs/methods/phone.leaveGroupCallPresentation.md b/docs/API_docs/methods/phone.leaveGroupCallPresentation.md new file mode 100644 index 0000000000..8bc2186d1f --- /dev/null +++ b/docs/API_docs/methods/phone.leaveGroupCallPresentation.md @@ -0,0 +1,42 @@ +--- +title: "phone.leaveGroupCallPresentation" +description: "Stop screen sharing in a group call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_leaveGroupCallPresentation.html +--- +# Method: phone.leaveGroupCallPresentation +[Back to methods index](index.html) + + + +Stop screen sharing in a group call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->leaveGroupCallPresentation(call: $InputGroupCall, ); +``` + diff --git a/docs/API_docs/methods/phone.receivedCall.md b/docs/API_docs/methods/phone.receivedCall.md new file mode 100644 index 0000000000..79086514b2 --- /dev/null +++ b/docs/API_docs/methods/phone.receivedCall.md @@ -0,0 +1,42 @@ +--- +title: "phone.receivedCall" +description: "Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_receivedCall.html +--- +# Method: phone.receivedCall +[Back to methods index](index.html) + + + +Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | The phone call we're currently in | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->phone->receivedCall(peer: $InputPhoneCall, ); +``` + diff --git a/docs/API_docs/methods/phone.requestCall.md b/docs/API_docs/methods/phone.requestCall.md new file mode 100644 index 0000000000..3cdc8af88d --- /dev/null +++ b/docs/API_docs/methods/phone.requestCall.md @@ -0,0 +1,45 @@ +--- +title: "phone.requestCall" +description: "You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_requestCall.html +--- +# Method: phone.requestCall +[Back to methods index](index.html) + + + +You cannot use this method directly, see https://docs.madelineproto.xyz#calls for more info on handling calls + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|video|[Bool](/API_docs/types/Bool.html) | Whether to start a video call | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Destination of the phone call | Optional| +|g\_a\_hash|[bytes](/API_docs/types/bytes.html) | [Parameter for E2E encryption key exchange »](https://core.telegram.org/api/end-to-end/voice-calls) | Yes| +|protocol|[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) | Phone call settings | Yes| + + +### Return type: [phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$phone_PhoneCall = $MadelineProto->phone->requestCall(video: $Bool, user_id: $InputUser, g_a_hash: 'bytes', protocol: $PhoneCallProtocol, ); +``` + diff --git a/docs/API_docs/methods/phone.saveCallDebug.md b/docs/API_docs/methods/phone.saveCallDebug.md new file mode 100644 index 0000000000..a321cd6494 --- /dev/null +++ b/docs/API_docs/methods/phone.saveCallDebug.md @@ -0,0 +1,43 @@ +--- +title: "phone.saveCallDebug" +description: "Send phone call debug data to server" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_saveCallDebug.html +--- +# Method: phone.saveCallDebug +[Back to methods index](index.html) + + + +Send phone call debug data to server + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | Phone call | Yes| +|debug|[DataJSON](/API_docs/types/DataJSON.html) | Debug statistics obtained from libtgvoip | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->phone->saveCallDebug(peer: $InputPhoneCall, debug: $DataJSON, ); +``` + diff --git a/docs/API_docs/methods/phone.saveCallLog.md b/docs/API_docs/methods/phone.saveCallLog.md new file mode 100644 index 0000000000..5459e70778 --- /dev/null +++ b/docs/API_docs/methods/phone.saveCallLog.md @@ -0,0 +1,43 @@ +--- +title: "phone.saveCallLog" +description: "Save phone call debug information" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_saveCallLog.html +--- +# Method: phone.saveCallLog +[Back to methods index](index.html) + + + +Save phone call debug information + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | Phone call | Yes| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Logs | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->phone->saveCallLog(peer: $InputPhoneCall, file: $InputFile, ); +``` + diff --git a/docs/API_docs/methods/phone.saveDefaultGroupCallJoinAs.md b/docs/API_docs/methods/phone.saveDefaultGroupCallJoinAs.md new file mode 100644 index 0000000000..93144f823a --- /dev/null +++ b/docs/API_docs/methods/phone.saveDefaultGroupCallJoinAs.md @@ -0,0 +1,43 @@ +--- +title: "phone.saveDefaultGroupCallJoinAs" +description: "Set the default peer that will be used to join a group call in a specific dialog." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_saveDefaultGroupCallJoinAs.html +--- +# Method: phone.saveDefaultGroupCallJoinAs +[Back to methods index](index.html) + + + +Set the default peer that will be used to join a group call in a specific dialog. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The dialog | Optional| +|join\_as|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The default peer that will be used to join group calls in this dialog, presenting yourself as a specific user/channel. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->phone->saveDefaultGroupCallJoinAs(peer: $InputPeer, join_as: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/phone.sendSignalingData.md b/docs/API_docs/methods/phone.sendSignalingData.md new file mode 100644 index 0000000000..701ddefce2 --- /dev/null +++ b/docs/API_docs/methods/phone.sendSignalingData.md @@ -0,0 +1,43 @@ +--- +title: "phone.sendSignalingData" +description: "Send VoIP signaling data" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_sendSignalingData.html +--- +# Method: phone.sendSignalingData +[Back to methods index](index.html) + + + +Send VoIP signaling data + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | Phone call | Yes| +|data|[bytes](/API_docs/types/bytes.html) | Signaling payload | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->phone->sendSignalingData(peer: $InputPhoneCall, data: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/phone.setCallRating.md b/docs/API_docs/methods/phone.setCallRating.md new file mode 100644 index 0000000000..c47dc0086e --- /dev/null +++ b/docs/API_docs/methods/phone.setCallRating.md @@ -0,0 +1,45 @@ +--- +title: "phone.setCallRating" +description: "Rate a call, returns info about the rating message sent to the official VoIP bot." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_setCallRating.html +--- +# Method: phone.setCallRating +[Back to methods index](index.html) + + + +Rate a call, returns info about the rating message sent to the official VoIP bot. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_initiative|[Bool](/API_docs/types/Bool.html) | Whether the user decided on their own initiative to rate the call | Optional| +|peer|[InputPhoneCall](/API_docs/types/InputPhoneCall.html) | The call to rate | Yes| +|rating|[int](/API_docs/types/int.html) | Rating in `1-5` stars | Optional| +|comment|[string](/API_docs/types/string.html) | An additional comment | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->setCallRating(user_initiative: $Bool, peer: $InputPhoneCall, rating: $int, comment: 'string', ); +``` + diff --git a/docs/API_docs/methods/phone.startScheduledGroupCall.md b/docs/API_docs/methods/phone.startScheduledGroupCall.md new file mode 100644 index 0000000000..ceaa0ab949 --- /dev/null +++ b/docs/API_docs/methods/phone.startScheduledGroupCall.md @@ -0,0 +1,42 @@ +--- +title: "phone.startScheduledGroupCall" +description: "Start a scheduled group call." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_startScheduledGroupCall.html +--- +# Method: phone.startScheduledGroupCall +[Back to methods index](index.html) + + + +Start a scheduled group call. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The scheduled group call | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->startScheduledGroupCall(call: $InputGroupCall, ); +``` + diff --git a/docs/API_docs/methods/phone.toggleGroupCallRecord.md b/docs/API_docs/methods/phone.toggleGroupCallRecord.md new file mode 100644 index 0000000000..e93791035b --- /dev/null +++ b/docs/API_docs/methods/phone.toggleGroupCallRecord.md @@ -0,0 +1,46 @@ +--- +title: "phone.toggleGroupCallRecord" +description: "Start or stop recording a group call: the recorded audio and video streams will be automatically sent to `Saved messages` (the chat with ourselves)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_toggleGroupCallRecord.html +--- +# Method: phone.toggleGroupCallRecord +[Back to methods index](index.html) + + + +Start or stop recording a group call: the recorded audio and video streams will be automatically sent to `Saved messages` (the chat with ourselves). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|start|[Bool](/API_docs/types/Bool.html) | Whether to start or stop recording | Optional| +|video|[Bool](/API_docs/types/Bool.html) | Whether to also record video streams | Optional| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | The group call or livestream | Yes| +|title|[string](/API_docs/types/string.html) | Recording title | Optional| +|video\_portrait|[Bool](/API_docs/types/Bool.html) | If video stream recording is enabled, whether to record in portrait or landscape mode | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->toggleGroupCallRecord(start: $Bool, video: $Bool, call: $InputGroupCall, title: 'string', video_portrait: $Bool, ); +``` + diff --git a/docs/API_docs/methods/phone.toggleGroupCallSettings.md b/docs/API_docs/methods/phone.toggleGroupCallSettings.md new file mode 100644 index 0000000000..77c5348b8c --- /dev/null +++ b/docs/API_docs/methods/phone.toggleGroupCallSettings.md @@ -0,0 +1,44 @@ +--- +title: "phone.toggleGroupCallSettings" +description: "Change group call settings" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_toggleGroupCallSettings.html +--- +# Method: phone.toggleGroupCallSettings +[Back to methods index](index.html) + + + +Change group call settings + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|reset\_invite\_hash|[Bool](/API_docs/types/Bool.html) | Invalidate existing invite links | Optional| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Group call | Yes| +|join\_muted|[Bool](/API_docs/types/Bool.html) | Whether all users will that join this group call are muted by default upon joining the group call | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->toggleGroupCallSettings(reset_invite_hash: $Bool, call: $InputGroupCall, join_muted: $Bool, ); +``` + diff --git a/docs/API_docs/methods/phone.toggleGroupCallStartSubscription.md b/docs/API_docs/methods/phone.toggleGroupCallStartSubscription.md new file mode 100644 index 0000000000..385587c568 --- /dev/null +++ b/docs/API_docs/methods/phone.toggleGroupCallStartSubscription.md @@ -0,0 +1,43 @@ +--- +title: "phone.toggleGroupCallStartSubscription" +description: "Subscribe or unsubscribe to a scheduled group call" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/phone_toggleGroupCallStartSubscription.html +--- +# Method: phone.toggleGroupCallStartSubscription +[Back to methods index](index.html) + + + +Subscribe or unsubscribe to a scheduled group call + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|call|[InputGroupCall](/API_docs/types/InputGroupCall.html) | Scheduled group call | Yes| +|subscribed|[Bool](/API_docs/types/Bool.html) | Enable or disable subscription | Yes| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->phone->toggleGroupCallStartSubscription(call: $InputGroupCall, subscribed: $Bool, ); +``` + diff --git a/docs/API_docs/methods/photos.deletePhotos.md b/docs/API_docs/methods/photos.deletePhotos.md new file mode 100644 index 0000000000..f962b5baca --- /dev/null +++ b/docs/API_docs/methods/photos.deletePhotos.md @@ -0,0 +1,42 @@ +--- +title: "photos.deletePhotos" +description: "Deletes profile photos. The method returns a list of successfully deleted photo IDs." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/photos_deletePhotos.html +--- +# Method: photos.deletePhotos +[Back to methods index](index.html) + + + +Deletes profile photos. The method returns a list of successfully deleted photo IDs. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [MessageMedia, Update, Message or InputPhoto](/API_docs/types/InputPhoto.html) | Input photos to delete | Yes| + + +### Return type: [Vector\_of\_long](/API_docs/types/long.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_long = $MadelineProto->photos->deletePhotos(id: [$InputPhoto, $InputPhoto], ); +``` + diff --git a/docs/API_docs/methods/photos.getUserPhotos.md b/docs/API_docs/methods/photos.getUserPhotos.md new file mode 100644 index 0000000000..c789522d9c --- /dev/null +++ b/docs/API_docs/methods/photos.getUserPhotos.md @@ -0,0 +1,45 @@ +--- +title: "photos.getUserPhotos" +description: "Returns the list of user photos." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/photos_getUserPhotos.html +--- +# Method: photos.getUserPhotos +[Back to methods index](index.html) + + + +Returns the list of user photos. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID | Optional| +|offset|[int](/API_docs/types/int.html) | Number of list elements to be skipped | Optional| +|max\_id|[long](/API_docs/types/long.html) | If a positive value was transferred, the method will return only photos with IDs less than the set one. This parameter is often useful when [refetching file references »](https://core.telegram.org/api/file_reference), as in conjuction with `limit=1` and `offset=-1` the [photo](../constructors/photo.html) object with the `id` specified in `max_id` can be fetched. | Yes| +|limit|[int](/API_docs/types/int.html) | Number of list elements to be returned | Optional| + + +### Return type: [photos.Photos](/API_docs/types/photos.Photos.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$photos_Photos = $MadelineProto->photos->getUserPhotos(user_id: $InputUser, offset: $int, max_id: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/photos.updateProfilePhoto.md b/docs/API_docs/methods/photos.updateProfilePhoto.md new file mode 100644 index 0000000000..2b0b2abcbc --- /dev/null +++ b/docs/API_docs/methods/photos.updateProfilePhoto.md @@ -0,0 +1,44 @@ +--- +title: "photos.updateProfilePhoto" +description: "Installs a previously uploaded photo as a profile photo." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/photos_updateProfilePhoto.html +--- +# Method: photos.updateProfilePhoto +[Back to methods index](index.html) + + + +Installs a previously uploaded photo as a profile photo. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|fallback|[Bool](/API_docs/types/Bool.html) | If set, the chosen profile photo will be shown to users that can't display your main profile photo due to your privacy settings. | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Can contain info of a bot we own, to change the profile photo of that bot, instead of the current user. | Optional| +|id|[MessageMedia, Update, Message or InputPhoto](/API_docs/types/InputPhoto.html) | Input photo | Optional| + + +### Return type: [photos.Photo](/API_docs/types/photos.Photo.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$photos_Photo = $MadelineProto->photos->updateProfilePhoto(fallback: $Bool, bot: $InputUser, id: $InputPhoto, ); +``` + diff --git a/docs/API_docs/methods/photos.uploadContactProfilePhoto.md b/docs/API_docs/methods/photos.uploadContactProfilePhoto.md new file mode 100644 index 0000000000..437f4e2807 --- /dev/null +++ b/docs/API_docs/methods/photos.uploadContactProfilePhoto.md @@ -0,0 +1,50 @@ +--- +title: "photos.uploadContactProfilePhoto" +description: "Upload a custom profile picture for a contact, or suggest a new profile picture to a contact." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/photos_uploadContactProfilePhoto.html +--- +# Method: photos.uploadContactProfilePhoto +[Back to methods index](index.html) + + + +Upload a custom profile picture for a contact, or suggest a new profile picture to a contact. + +The `file`, `video` and `video_emoji_markup` flags are mutually exclusive. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|suggest|[Bool](/API_docs/types/Bool.html) | If set, will send a [messageActionSuggestProfilePhoto](../constructors/messageActionSuggestProfilePhoto.html) service message to `user_id`, suggesting them to use the specified profile picture; otherwise, will set a personal profile picture for the user (only visible to the current user). | Optional| +|save|[Bool](/API_docs/types/Bool.html) | If set, removes a previously set personal profile picture (does not affect suggested profile pictures, to remove them simply deleted the [messageActionSuggestProfilePhoto](../constructors/messageActionSuggestProfilePhoto.html) service message with [messages.deleteMessages](../methods/messages.deleteMessages.html)). | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The contact | Optional| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Profile photo | Optional| +|video|[File path or InputFile](/API_docs/types/InputFile.html) | [Animated profile picture](https://core.telegram.org/api/files#animated-profile-pictures) video | Optional| +|video\_start\_ts|[double](/API_docs/types/double.html) | Floating point UNIX timestamp in seconds, indicating the frame of the video/sticker that should be used as static preview; can only be used if `video` or `video_emoji_markup` is set. | Optional| +|video\_emoji\_markup|[VideoSize](/API_docs/types/VideoSize.html) | Animated sticker profile picture, must contain either a [videoSizeEmojiMarkup](../constructors/videoSizeEmojiMarkup.html) or a [videoSizeStickerMarkup](../constructors/videoSizeStickerMarkup.html) constructor. | Optional| + + +### Return type: [photos.Photo](/API_docs/types/photos.Photo.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$photos_Photo = $MadelineProto->photos->uploadContactProfilePhoto(suggest: $Bool, save: $Bool, user_id: $InputUser, file: $InputFile, video: $InputFile, video_start_ts: $double, video_emoji_markup: $VideoSize, ); +``` + diff --git a/docs/API_docs/methods/photos.uploadProfilePhoto.md b/docs/API_docs/methods/photos.uploadProfilePhoto.md new file mode 100644 index 0000000000..b5d091c46a --- /dev/null +++ b/docs/API_docs/methods/photos.uploadProfilePhoto.md @@ -0,0 +1,49 @@ +--- +title: "photos.uploadProfilePhoto" +description: "Updates current user profile photo." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/photos_uploadProfilePhoto.html +--- +# Method: photos.uploadProfilePhoto +[Back to methods index](index.html) + + + +Updates current user profile photo. + +The `file`, `video` and `video_emoji_markup` flags are mutually exclusive. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|fallback|[Bool](/API_docs/types/Bool.html) | If set, the chosen profile photo will be shown to users that can't display your main profile photo due to your privacy settings. | Optional| +|bot|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Can contain info of a bot we own, to change the profile photo of that bot, instead of the current user. | Optional| +|file|[File path or InputFile](/API_docs/types/InputFile.html) | Profile photo | Optional| +|video|[File path or InputFile](/API_docs/types/InputFile.html) | [Animated profile picture](https://core.telegram.org/api/files#animated-profile-pictures) video | Optional| +|video\_start\_ts|[double](/API_docs/types/double.html) | Floating point UNIX timestamp in seconds, indicating the frame of the video/sticker that should be used as static preview; can only be used if `video` or `video_emoji_markup` is set. | Optional| +|video\_emoji\_markup|[VideoSize](/API_docs/types/VideoSize.html) | Animated sticker profile picture, must contain either a [videoSizeEmojiMarkup](../constructors/videoSizeEmojiMarkup.html) or a [videoSizeStickerMarkup](../constructors/videoSizeStickerMarkup.html) constructor. | Optional| + + +### Return type: [photos.Photo](/API_docs/types/photos.Photo.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$photos_Photo = $MadelineProto->photos->uploadProfilePhoto(fallback: $Bool, bot: $InputUser, file: $InputFile, video: $InputFile, video_start_ts: $double, video_emoji_markup: $VideoSize, ); +``` + diff --git a/docs/API_docs/methods/premium.applyBoost.md b/docs/API_docs/methods/premium.applyBoost.md new file mode 100644 index 0000000000..d8a4efd658 --- /dev/null +++ b/docs/API_docs/methods/premium.applyBoost.md @@ -0,0 +1,43 @@ +--- +title: "premium.applyBoost" +description: "Apply one or more [boosts »](https://core.telegram.org/api/boost) to a peer." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/premium_applyBoost.html +--- +# Method: premium.applyBoost +[Back to methods index](index.html) + + + +Apply one or more [boosts »](https://core.telegram.org/api/boost) to a peer. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|slots|Array of [int](/API_docs/types/int.html) | Which [boost slots](https://core.telegram.org/api/boost) to assign to this peer. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer to boost. | Optional| + + +### Return type: [premium.MyBoosts](/API_docs/types/premium.MyBoosts.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$premium_MyBoosts = $MadelineProto->premium->applyBoost(slots: [$int, $int], peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/premium.getBoostsList.md b/docs/API_docs/methods/premium.getBoostsList.md new file mode 100644 index 0000000000..8801012dee --- /dev/null +++ b/docs/API_docs/methods/premium.getBoostsList.md @@ -0,0 +1,45 @@ +--- +title: "premium.getBoostsList" +description: "Obtains info about the boosts that were applied to a certain channel (admins only)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/premium_getBoostsList.html +--- +# Method: premium.getBoostsList +[Back to methods index](index.html) + + + +Obtains info about the boosts that were applied to a certain channel (admins only) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|gifts|[Bool](/API_docs/types/Bool.html) | Whether to return only info about boosts received from [gift codes and giveaways created by the channel »](https://core.telegram.org/api/giveaways) | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The channel | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for pagination, obtained from [premium.boostsList](../constructors/premium.boostsList.html).`next_offset` | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [premium.BoostsList](/API_docs/types/premium.BoostsList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$premium_BoostsList = $MadelineProto->premium->getBoostsList(gifts: $Bool, peer: $InputPeer, offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/premium.getBoostsStatus.md b/docs/API_docs/methods/premium.getBoostsStatus.md new file mode 100644 index 0000000000..4b47c039ae --- /dev/null +++ b/docs/API_docs/methods/premium.getBoostsStatus.md @@ -0,0 +1,42 @@ +--- +title: "premium.getBoostsStatus" +description: "Gets the current [number of boosts](https://core.telegram.org/api/boost) of a channel." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/premium_getBoostsStatus.html +--- +# Method: premium.getBoostsStatus +[Back to methods index](index.html) + + + +Gets the current [number of boosts](https://core.telegram.org/api/boost) of a channel. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer. | Optional| + + +### Return type: [premium.BoostsStatus](/API_docs/types/premium.BoostsStatus.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$premium_BoostsStatus = $MadelineProto->premium->getBoostsStatus(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/premium.getMyBoosts.md b/docs/API_docs/methods/premium.getMyBoosts.md new file mode 100644 index 0000000000..9d4070a12e --- /dev/null +++ b/docs/API_docs/methods/premium.getMyBoosts.md @@ -0,0 +1,37 @@ +--- +title: "premium.getMyBoosts" +description: "Obtain which peers are we currently [boosting](https://core.telegram.org/api/boost), and how many [boost slots](https://core.telegram.org/api/boost) we have left." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/premium_getMyBoosts.html +--- +# Method: premium.getMyBoosts +[Back to methods index](index.html) + + + +Obtain which peers are we currently [boosting](https://core.telegram.org/api/boost), and how many [boost slots](https://core.telegram.org/api/boost) we have left. + + + +### Return type: [premium.MyBoosts](/API_docs/types/premium.MyBoosts.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$premium_MyBoosts = $MadelineProto->premium->getMyBoosts(); +``` + diff --git a/docs/API_docs/methods/premium.getUserBoosts.md b/docs/API_docs/methods/premium.getUserBoosts.md new file mode 100644 index 0000000000..5c5fe6a63a --- /dev/null +++ b/docs/API_docs/methods/premium.getUserBoosts.md @@ -0,0 +1,43 @@ +--- +title: "premium.getUserBoosts" +description: "Returns the lists of boost that were applied to a channel by a specific user (admins only)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/premium_getUserBoosts.html +--- +# Method: premium.getUserBoosts +[Back to methods index](index.html) + + + +Returns the lists of boost that were applied to a channel by a specific user (admins only) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The channel | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The user | Optional| + + +### Return type: [premium.BoostsList](/API_docs/types/premium.BoostsList.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$premium_BoostsList = $MadelineProto->premium->getUserBoosts(peer: $InputPeer, user_id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/smsjobs.finishJob.md b/docs/API_docs/methods/smsjobs.finishJob.md new file mode 100644 index 0000000000..44506f4cdc --- /dev/null +++ b/docs/API_docs/methods/smsjobs.finishJob.md @@ -0,0 +1,41 @@ +--- +title: "smsjobs.finishJob" +description: "smsjobs.finishJob parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_finishJob.html +--- +# Method: smsjobs.finishJob +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|job\_id|[string](/API_docs/types/string.html) | Optional| +|error|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->smsjobs->finishJob(job_id: 'string', error: 'string', ); +``` + diff --git a/docs/API_docs/methods/smsjobs.getSmsJob.md b/docs/API_docs/methods/smsjobs.getSmsJob.md new file mode 100644 index 0000000000..d700a41300 --- /dev/null +++ b/docs/API_docs/methods/smsjobs.getSmsJob.md @@ -0,0 +1,40 @@ +--- +title: "smsjobs.getSmsJob" +description: "smsjobs.getSmsJob parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_getSmsJob.html +--- +# Method: smsjobs.getSmsJob +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|job\_id|[string](/API_docs/types/string.html) | Optional| + + +### Return type: [SmsJob](/API_docs/types/SmsJob.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$SmsJob = $MadelineProto->smsjobs->getSmsJob(job_id: 'string', ); +``` + diff --git a/docs/API_docs/methods/smsjobs.getStatus.md b/docs/API_docs/methods/smsjobs.getStatus.md new file mode 100644 index 0000000000..3e71d1abdc --- /dev/null +++ b/docs/API_docs/methods/smsjobs.getStatus.md @@ -0,0 +1,35 @@ +--- +title: "smsjobs.getStatus" +description: "smsjobs.getStatus parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_getStatus.html +--- +# Method: smsjobs.getStatus +[Back to methods index](index.html) + + + + + +### Return type: [smsjobs.Status](/API_docs/types/smsjobs.Status.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$smsjobs_Status = $MadelineProto->smsjobs->getStatus(); +``` + diff --git a/docs/API_docs/methods/smsjobs.isEligibleToJoin.md b/docs/API_docs/methods/smsjobs.isEligibleToJoin.md new file mode 100644 index 0000000000..1461e4df03 --- /dev/null +++ b/docs/API_docs/methods/smsjobs.isEligibleToJoin.md @@ -0,0 +1,35 @@ +--- +title: "smsjobs.isEligibleToJoin" +description: "smsjobs.isEligibleToJoin parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_isEligibleToJoin.html +--- +# Method: smsjobs.isEligibleToJoin +[Back to methods index](index.html) + + + + + +### Return type: [smsjobs.EligibilityToJoin](/API_docs/types/smsjobs.EligibilityToJoin.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$smsjobs_EligibilityToJoin = $MadelineProto->smsjobs->isEligibleToJoin(); +``` + diff --git a/docs/API_docs/methods/smsjobs.join.md b/docs/API_docs/methods/smsjobs.join.md new file mode 100644 index 0000000000..f23173317b --- /dev/null +++ b/docs/API_docs/methods/smsjobs.join.md @@ -0,0 +1,35 @@ +--- +title: "smsjobs.join" +description: "smsjobs.join parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_join.html +--- +# Method: smsjobs.join +[Back to methods index](index.html) + + + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->smsjobs->join(); +``` + diff --git a/docs/API_docs/methods/smsjobs.leave.md b/docs/API_docs/methods/smsjobs.leave.md new file mode 100644 index 0000000000..60260789d3 --- /dev/null +++ b/docs/API_docs/methods/smsjobs.leave.md @@ -0,0 +1,35 @@ +--- +title: "smsjobs.leave" +description: "smsjobs.leave parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_leave.html +--- +# Method: smsjobs.leave +[Back to methods index](index.html) + + + + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->smsjobs->leave(); +``` + diff --git a/docs/API_docs/methods/smsjobs.updateSettings.md b/docs/API_docs/methods/smsjobs.updateSettings.md new file mode 100644 index 0000000000..64c0b6300d --- /dev/null +++ b/docs/API_docs/methods/smsjobs.updateSettings.md @@ -0,0 +1,40 @@ +--- +title: "smsjobs.updateSettings" +description: "smsjobs.updateSettings parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/smsjobs_updateSettings.html +--- +# Method: smsjobs.updateSettings +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|allow\_international|[Bool](/API_docs/types/Bool.html) | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->smsjobs->updateSettings(allow_international: $Bool, ); +``` + diff --git a/docs/API_docs/methods/stats.getBroadcastRevenueStats.md b/docs/API_docs/methods/stats.getBroadcastRevenueStats.md new file mode 100644 index 0000000000..5598a53a52 --- /dev/null +++ b/docs/API_docs/methods/stats.getBroadcastRevenueStats.md @@ -0,0 +1,41 @@ +--- +title: "stats.getBroadcastRevenueStats" +description: "stats.getBroadcastRevenueStats parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getBroadcastRevenueStats.html +--- +# Method: stats.getBroadcastRevenueStats +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|dark|[Bool](/API_docs/types/Bool.html) | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| + + +### Return type: [stats.BroadcastRevenueStats](/API_docs/types/stats.BroadcastRevenueStats.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_BroadcastRevenueStats = $MadelineProto->stats->getBroadcastRevenueStats(dark: $Bool, channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/stats.getBroadcastRevenueTransactions.md b/docs/API_docs/methods/stats.getBroadcastRevenueTransactions.md new file mode 100644 index 0000000000..f02324d7a4 --- /dev/null +++ b/docs/API_docs/methods/stats.getBroadcastRevenueTransactions.md @@ -0,0 +1,42 @@ +--- +title: "stats.getBroadcastRevenueTransactions" +description: "stats.getBroadcastRevenueTransactions parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getBroadcastRevenueTransactions.html +--- +# Method: stats.getBroadcastRevenueTransactions +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| +|offset|[int](/API_docs/types/int.html) | Optional| +|limit|[int](/API_docs/types/int.html) | Optional| + + +### Return type: [stats.BroadcastRevenueTransactions](/API_docs/types/stats.BroadcastRevenueTransactions.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_BroadcastRevenueTransactions = $MadelineProto->stats->getBroadcastRevenueTransactions(channel: $InputChannel, offset: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stats.getBroadcastRevenueWithdrawalUrl.md b/docs/API_docs/methods/stats.getBroadcastRevenueWithdrawalUrl.md new file mode 100644 index 0000000000..6bb3d54f56 --- /dev/null +++ b/docs/API_docs/methods/stats.getBroadcastRevenueWithdrawalUrl.md @@ -0,0 +1,41 @@ +--- +title: "stats.getBroadcastRevenueWithdrawalUrl" +description: "stats.getBroadcastRevenueWithdrawalUrl parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getBroadcastRevenueWithdrawalUrl.html +--- +# Method: stats.getBroadcastRevenueWithdrawalUrl +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Optional| +|password|[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) | Yes| + + +### Return type: [stats.BroadcastRevenueWithdrawalUrl](/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_BroadcastRevenueWithdrawalUrl = $MadelineProto->stats->getBroadcastRevenueWithdrawalUrl(channel: $InputChannel, password: $InputCheckPasswordSRP, ); +``` + diff --git a/docs/API_docs/methods/stats.getBroadcastStats.md b/docs/API_docs/methods/stats.getBroadcastStats.md new file mode 100644 index 0000000000..2af7eda1d8 --- /dev/null +++ b/docs/API_docs/methods/stats.getBroadcastStats.md @@ -0,0 +1,43 @@ +--- +title: "stats.getBroadcastStats" +description: "Get [channel statistics](https://core.telegram.org/api/stats)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getBroadcastStats.html +--- +# Method: stats.getBroadcastStats +[Back to methods index](index.html) + + + +Get [channel statistics](https://core.telegram.org/api/stats) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|dark|[Bool](/API_docs/types/Bool.html) | Whether to enable dark theme for graph colors | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The channel | Optional| + + +### Return type: [stats.BroadcastStats](/API_docs/types/stats.BroadcastStats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_BroadcastStats = $MadelineProto->stats->getBroadcastStats(dark: $Bool, channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/stats.getMegagroupStats.md b/docs/API_docs/methods/stats.getMegagroupStats.md new file mode 100644 index 0000000000..255dbc8907 --- /dev/null +++ b/docs/API_docs/methods/stats.getMegagroupStats.md @@ -0,0 +1,43 @@ +--- +title: "stats.getMegagroupStats" +description: "Get [supergroup statistics](https://core.telegram.org/api/stats)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getMegagroupStats.html +--- +# Method: stats.getMegagroupStats +[Back to methods index](index.html) + + + +Get [supergroup statistics](https://core.telegram.org/api/stats) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|dark|[Bool](/API_docs/types/Bool.html) | Whether to enable dark theme for graph colors | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | [Supergroup ID](https://core.telegram.org/api/channel) | Optional| + + +### Return type: [stats.MegagroupStats](/API_docs/types/stats.MegagroupStats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_MegagroupStats = $MadelineProto->stats->getMegagroupStats(dark: $Bool, channel: $InputChannel, ); +``` + diff --git a/docs/API_docs/methods/stats.getMessagePublicForwards.md b/docs/API_docs/methods/stats.getMessagePublicForwards.md new file mode 100644 index 0000000000..6364e50c7b --- /dev/null +++ b/docs/API_docs/methods/stats.getMessagePublicForwards.md @@ -0,0 +1,46 @@ +--- +title: "stats.getMessagePublicForwards" +description: "Obtains a list of messages, indicating to which other public channels was a channel message forwarded. " +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getMessagePublicForwards.html +--- +# Method: stats.getMessagePublicForwards +[Back to methods index](index.html) + + + +Obtains a list of messages, indicating to which other public channels was a channel message forwarded. +Will return a list of [messages](../constructors/message.html) with `peer_id` equal to the public channel to which this message was forwarded. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Source channel | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Source message ID | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for [pagination](https://core.telegram.org/api/offsets), empty string on first call, then use the `next_offset` field of the returned constructor (if present, otherwise no more results are available). | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [stats.PublicForwards](/API_docs/types/stats.PublicForwards.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_PublicForwards = $MadelineProto->stats->getMessagePublicForwards(channel: $InputChannel, msg_id: $int, offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stats.getMessageStats.md b/docs/API_docs/methods/stats.getMessageStats.md new file mode 100644 index 0000000000..9221c3094d --- /dev/null +++ b/docs/API_docs/methods/stats.getMessageStats.md @@ -0,0 +1,44 @@ +--- +title: "stats.getMessageStats" +description: "Get [message statistics](https://core.telegram.org/api/stats)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getMessageStats.html +--- +# Method: stats.getMessageStats +[Back to methods index](index.html) + + + +Get [message statistics](https://core.telegram.org/api/stats) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|dark|[Bool](/API_docs/types/Bool.html) | Whether to enable dark theme for graph colors | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | Channel ID | Optional| +|msg\_id|[int](/API_docs/types/int.html) | Message ID | Optional| + + +### Return type: [stats.MessageStats](/API_docs/types/stats.MessageStats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_MessageStats = $MadelineProto->stats->getMessageStats(dark: $Bool, channel: $InputChannel, msg_id: $int, ); +``` + diff --git a/docs/API_docs/methods/stats.getStoryPublicForwards.md b/docs/API_docs/methods/stats.getStoryPublicForwards.md new file mode 100644 index 0000000000..7baf78dd7d --- /dev/null +++ b/docs/API_docs/methods/stats.getStoryPublicForwards.md @@ -0,0 +1,45 @@ +--- +title: "stats.getStoryPublicForwards" +description: "Obtain forwards of a [story](https://core.telegram.org/api/stories) as a message to public chats and reposts by public channels." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getStoryPublicForwards.html +--- +# Method: stats.getStoryPublicForwards +[Back to methods index](index.html) + + + +Obtain forwards of a [story](https://core.telegram.org/api/stories) as a message to public chats and reposts by public channels. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the story was originally posted | Optional| +|id|[int](/API_docs/types/int.html) | [Story](https://core.telegram.org/api/stories) ID | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for pagination, from [stats.PublicForwards](../constructors/stats.publicForwards.html).`next_offset`. | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [stats.PublicForwards](/API_docs/types/stats.PublicForwards.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_PublicForwards = $MadelineProto->stats->getStoryPublicForwards(peer: $InputPeer, id: $int, offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stats.getStoryStats.md b/docs/API_docs/methods/stats.getStoryStats.md new file mode 100644 index 0000000000..4a4d7ff83d --- /dev/null +++ b/docs/API_docs/methods/stats.getStoryStats.md @@ -0,0 +1,44 @@ +--- +title: "stats.getStoryStats" +description: "Get [statistics](https://core.telegram.org/api/stats) for a certain [story](https://core.telegram.org/api/stories)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_getStoryStats.html +--- +# Method: stats.getStoryStats +[Back to methods index](index.html) + + + +Get [statistics](https://core.telegram.org/api/stats) for a certain [story](https://core.telegram.org/api/stories). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|dark|[Bool](/API_docs/types/Bool.html) | Whether to enable the dark theme for graph colors | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer that posted the story | Optional| +|id|[int](/API_docs/types/int.html) | Story ID | Optional| + + +### Return type: [stats.StoryStats](/API_docs/types/stats.StoryStats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stats_StoryStats = $MadelineProto->stats->getStoryStats(dark: $Bool, peer: $InputPeer, id: $int, ); +``` + diff --git a/docs/API_docs/methods/stats.loadAsyncGraph.md b/docs/API_docs/methods/stats.loadAsyncGraph.md new file mode 100644 index 0000000000..4eab95ab7d --- /dev/null +++ b/docs/API_docs/methods/stats.loadAsyncGraph.md @@ -0,0 +1,43 @@ +--- +title: "stats.loadAsyncGraph" +description: "Load [channel statistics graph](https://core.telegram.org/api/stats) asynchronously" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stats_loadAsyncGraph.html +--- +# Method: stats.loadAsyncGraph +[Back to methods index](index.html) + + + +Load [channel statistics graph](https://core.telegram.org/api/stats) asynchronously + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|token|[string](/API_docs/types/string.html) | Graph token from [statsGraphAsync](../constructors/statsGraphAsync.html) constructor | Optional| +|x|[long](/API_docs/types/long.html) | Zoom value, if required | Optional| + + +### Return type: [StatsGraph](/API_docs/types/StatsGraph.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$StatsGraph = $MadelineProto->stats->loadAsyncGraph(token: 'string', x: $long, ); +``` + diff --git a/docs/API_docs/methods/stickers.addStickerToSet.md b/docs/API_docs/methods/stickers.addStickerToSet.md new file mode 100644 index 0000000000..f93ba5ca0e --- /dev/null +++ b/docs/API_docs/methods/stickers.addStickerToSet.md @@ -0,0 +1,43 @@ +--- +title: "stickers.addStickerToSet" +description: "Add a sticker to a stickerset, bots only. The sticker set must have been created by the bot." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_addStickerToSet.html +--- +# Method: stickers.addStickerToSet +[Back to methods index](index.html) + + + +Add a sticker to a stickerset, bots only. The sticker set must have been created by the bot. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | The stickerset | Optional| +|sticker|[InputStickerSetItem](/API_docs/types/InputStickerSetItem.html) | The sticker | Yes| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->addStickerToSet(stickerset: $InputStickerSet, sticker: $InputStickerSetItem, ); +``` + diff --git a/docs/API_docs/methods/stickers.changeSticker.md b/docs/API_docs/methods/stickers.changeSticker.md new file mode 100644 index 0000000000..18b1f0d49d --- /dev/null +++ b/docs/API_docs/methods/stickers.changeSticker.md @@ -0,0 +1,45 @@ +--- +title: "stickers.changeSticker" +description: "Update the keywords, emojis or [mask coordinates](https://core.telegram.org/api/stickers#mask-stickers) of a sticker, bots only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_changeSticker.html +--- +# Method: stickers.changeSticker +[Back to methods index](index.html) + + + +Update the keywords, emojis or [mask coordinates](https://core.telegram.org/api/stickers#mask-stickers) of a sticker, bots only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|sticker|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | The sticker | Optional| +|emoji|[string](/API_docs/types/string.html) | If set, updates the emoji list associated to the sticker | Optional| +|mask\_coords|[MaskCoords](/API_docs/types/MaskCoords.html) | If set, updates the [mask coordinates](https://core.telegram.org/api/stickers#mask-stickers) | Optional| +|keywords|[string](/API_docs/types/string.html) | If set, updates the sticker keywords (separated by commas). Can't be provided for mask stickers. | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->changeSticker(sticker: $InputDocument, emoji: 'string', mask_coords: $MaskCoords, keywords: 'string', ); +``` + diff --git a/docs/API_docs/methods/stickers.changeStickerPosition.md b/docs/API_docs/methods/stickers.changeStickerPosition.md new file mode 100644 index 0000000000..5e9f5370bf --- /dev/null +++ b/docs/API_docs/methods/stickers.changeStickerPosition.md @@ -0,0 +1,43 @@ +--- +title: "stickers.changeStickerPosition" +description: "Changes the absolute position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_changeStickerPosition.html +--- +# Method: stickers.changeStickerPosition +[Back to methods index](index.html) + + + +Changes the absolute position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|sticker|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | The sticker | Optional| +|position|[int](/API_docs/types/int.html) | The new position of the sticker, zero-based | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->changeStickerPosition(sticker: $InputDocument, position: $int, ); +``` + diff --git a/docs/API_docs/methods/stickers.checkShortName.md b/docs/API_docs/methods/stickers.checkShortName.md new file mode 100644 index 0000000000..e304bca1b8 --- /dev/null +++ b/docs/API_docs/methods/stickers.checkShortName.md @@ -0,0 +1,42 @@ +--- +title: "stickers.checkShortName" +description: "Check whether the given short name is available" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_checkShortName.html +--- +# Method: stickers.checkShortName +[Back to methods index](index.html) + + + +Check whether the given short name is available + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|short\_name|[string](/API_docs/types/string.html) | Short name | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stickers->checkShortName(short_name: 'string', ); +``` + diff --git a/docs/API_docs/methods/stickers.createStickerSet.md b/docs/API_docs/methods/stickers.createStickerSet.md new file mode 100644 index 0000000000..0a52716514 --- /dev/null +++ b/docs/API_docs/methods/stickers.createStickerSet.md @@ -0,0 +1,50 @@ +--- +title: "stickers.createStickerSet" +description: "Create a stickerset, bots only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_createStickerSet.html +--- +# Method: stickers.createStickerSet +[Back to methods index](index.html) + + + +Create a stickerset, bots only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|masks|[Bool](/API_docs/types/Bool.html) | Whether this is a mask stickerset | Optional| +|emojis|[Bool](/API_docs/types/Bool.html) | Whether this is a [custom emoji](https://core.telegram.org/api/custom-emoji) stickerset. | Optional| +|text\_color|[Bool](/API_docs/types/Bool.html) | Whether the color of TGS custom emojis contained in this set should be changed to the text color when used in messages, the accent color if used as emoji status, white on chat photos, or another appropriate color based on context. For custom emoji stickersets only. | Optional| +|user\_id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Stickerset owner | Optional| +|title|[string](/API_docs/types/string.html) | Stickerset name, `1-64` chars | Optional| +|short\_name|[string](/API_docs/types/string.html) | Short name of sticker set, to be used in [sticker deep links »](https://core.telegram.org/api/links#stickerset-links). Can contain only english letters, digits and underscores. Must begin with a letter, can't contain consecutive underscores and, **if called by a bot**, must end in `"_by_"`. `` is case insensitive. 1-64 characters. | Optional| +|thumb|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Thumbnail | Optional| +|stickers|Array of [InputStickerSetItem](/API_docs/types/InputStickerSetItem.html) | Stickers | Yes| +|software|[string](/API_docs/types/string.html) | Used when [importing stickers using the sticker import SDKs](https://core.telegram.org/import-stickers), specifies the name of the software that created the stickers | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->createStickerSet(masks: $Bool, emojis: $Bool, text_color: $Bool, user_id: $InputUser, title: 'string', short_name: 'string', thumb: $InputDocument, stickers: [$InputStickerSetItem, $InputStickerSetItem], software: 'string', ); +``` + diff --git a/docs/API_docs/methods/stickers.deleteStickerSet.md b/docs/API_docs/methods/stickers.deleteStickerSet.md new file mode 100644 index 0000000000..fe92efac8b --- /dev/null +++ b/docs/API_docs/methods/stickers.deleteStickerSet.md @@ -0,0 +1,42 @@ +--- +title: "stickers.deleteStickerSet" +description: "Deletes a stickerset we created, bots only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_deleteStickerSet.html +--- +# Method: stickers.deleteStickerSet +[Back to methods index](index.html) + + + +Deletes a stickerset we created, bots only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Stickerset to delete | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stickers->deleteStickerSet(stickerset: $InputStickerSet, ); +``` + diff --git a/docs/API_docs/methods/stickers.removeStickerFromSet.md b/docs/API_docs/methods/stickers.removeStickerFromSet.md new file mode 100644 index 0000000000..e2ca9b8b3f --- /dev/null +++ b/docs/API_docs/methods/stickers.removeStickerFromSet.md @@ -0,0 +1,42 @@ +--- +title: "stickers.removeStickerFromSet" +description: "Remove a sticker from the set where it belongs, bots only. The sticker set must have been created by the bot." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_removeStickerFromSet.html +--- +# Method: stickers.removeStickerFromSet +[Back to methods index](index.html) + + + +Remove a sticker from the set where it belongs, bots only. The sticker set must have been created by the bot. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|sticker|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | The sticker to remove | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->removeStickerFromSet(sticker: $InputDocument, ); +``` + diff --git a/docs/API_docs/methods/stickers.renameStickerSet.md b/docs/API_docs/methods/stickers.renameStickerSet.md new file mode 100644 index 0000000000..1c941eaaf8 --- /dev/null +++ b/docs/API_docs/methods/stickers.renameStickerSet.md @@ -0,0 +1,43 @@ +--- +title: "stickers.renameStickerSet" +description: "Renames a stickerset, bots only." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_renameStickerSet.html +--- +# Method: stickers.renameStickerSet +[Back to methods index](index.html) + + + +Renames a stickerset, bots only. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Stickerset to rename | Optional| +|title|[string](/API_docs/types/string.html) | New stickerset title | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->renameStickerSet(stickerset: $InputStickerSet, title: 'string', ); +``` + diff --git a/docs/API_docs/methods/stickers.replaceSticker.md b/docs/API_docs/methods/stickers.replaceSticker.md new file mode 100644 index 0000000000..8034f6ac57 --- /dev/null +++ b/docs/API_docs/methods/stickers.replaceSticker.md @@ -0,0 +1,41 @@ +--- +title: "stickers.replaceSticker" +description: "stickers.replaceSticker parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_replaceSticker.html +--- +# Method: stickers.replaceSticker +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|sticker|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Optional| +|new\_sticker|[InputStickerSetItem](/API_docs/types/InputStickerSetItem.html) | Yes| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->replaceSticker(sticker: $InputDocument, new_sticker: $InputStickerSetItem, ); +``` + diff --git a/docs/API_docs/methods/stickers.setStickerSetThumb.md b/docs/API_docs/methods/stickers.setStickerSetThumb.md new file mode 100644 index 0000000000..fcab5fbd4c --- /dev/null +++ b/docs/API_docs/methods/stickers.setStickerSetThumb.md @@ -0,0 +1,44 @@ +--- +title: "stickers.setStickerSetThumb" +description: "Set stickerset thumbnail" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_setStickerSetThumb.html +--- +# Method: stickers.setStickerSetThumb +[Back to methods index](index.html) + + + +Set stickerset thumbnail + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|stickerset|[InputStickerSet](/API_docs/types/InputStickerSet.html) | Stickerset | Optional| +|thumb|[MessageMedia, Update, Message or InputDocument](/API_docs/types/InputDocument.html) | Thumbnail (only for normal stickersets, not custom emoji stickersets). | Optional| +|thumb\_document\_id|[long](/API_docs/types/long.html) | Only for [custom emoji stickersets](https://core.telegram.org/api/custom-emoji), ID of a custom emoji present in the set to use as thumbnail; pass 0 to fallback to the first custom emoji of the set. | Optional| + + +### Return type: [messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_StickerSet = $MadelineProto->stickers->setStickerSetThumb(stickerset: $InputStickerSet, thumb: $InputDocument, thumb_document_id: $long, ); +``` + diff --git a/docs/API_docs/methods/stickers.suggestShortName.md b/docs/API_docs/methods/stickers.suggestShortName.md new file mode 100644 index 0000000000..e8b8c0ddc1 --- /dev/null +++ b/docs/API_docs/methods/stickers.suggestShortName.md @@ -0,0 +1,42 @@ +--- +title: "stickers.suggestShortName" +description: "Suggests a short name for a given stickerpack name" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stickers_suggestShortName.html +--- +# Method: stickers.suggestShortName +[Back to methods index](index.html) + + + +Suggests a short name for a given stickerpack name + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|title|[string](/API_docs/types/string.html) | Sticker pack name | Optional| + + +### Return type: [stickers.SuggestedShortName](/API_docs/types/stickers.SuggestedShortName.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stickers_SuggestedShortName = $MadelineProto->stickers->suggestShortName(title: 'string', ); +``` + diff --git a/docs/API_docs/methods/stories.activateStealthMode.md b/docs/API_docs/methods/stories.activateStealthMode.md new file mode 100644 index 0000000000..ca0c854a6f --- /dev/null +++ b/docs/API_docs/methods/stories.activateStealthMode.md @@ -0,0 +1,45 @@ +--- +title: "stories.activateStealthMode" +description: "Activates [stories stealth mode](https://core.telegram.org/api/stories#stealth-mode), see [here »](https://core.telegram.org/api/stories#stealth-mode) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_activateStealthMode.html +--- +# Method: stories.activateStealthMode +[Back to methods index](index.html) + + + +Activates [stories stealth mode](https://core.telegram.org/api/stories#stealth-mode), see [here »](https://core.telegram.org/api/stories#stealth-mode) for more info. + +Will return an [updateStoriesStealthMode](../constructors/updateStoriesStealthMode.html). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|past|[Bool](/API_docs/types/Bool.html) | Whether to erase views from any stories opened in the past [`stories_stealth_past_period` seconds »](https://core.telegram.org/api/config#stories-stealth-past-period), as specified by the [client configuration](https://core.telegram.org/api/config#client-configuration). | Optional| +|future|[Bool](/API_docs/types/Bool.html) | Whether to hide future story views for the next [`stories_stealth_future_period` seconds »](https://core.telegram.org/api/config#stories-stealth-future-period), as specified by the [client configuration](https://core.telegram.org/api/config#client-configuration). | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->stories->activateStealthMode(past: $Bool, future: $Bool, ); +``` + diff --git a/docs/API_docs/methods/stories.canSendStory.md b/docs/API_docs/methods/stories.canSendStory.md new file mode 100644 index 0000000000..bc4ab5b982 --- /dev/null +++ b/docs/API_docs/methods/stories.canSendStory.md @@ -0,0 +1,42 @@ +--- +title: "stories.canSendStory" +description: "Check whether we can post stories as the specified peer." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_canSendStory.html +--- +# Method: stories.canSendStory +[Back to methods index](index.html) + + + +Check whether we can post stories as the specified peer. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer from which we wish to post stories. | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stories->canSendStory(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/stories.deleteStories.md b/docs/API_docs/methods/stories.deleteStories.md new file mode 100644 index 0000000000..8452d950e5 --- /dev/null +++ b/docs/API_docs/methods/stories.deleteStories.md @@ -0,0 +1,43 @@ +--- +title: "stories.deleteStories" +description: "Deletes some posted [stories](https://core.telegram.org/api/stories)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_deleteStories.html +--- +# Method: stories.deleteStories +[Back to methods index](index.html) + + + +Deletes some posted [stories](https://core.telegram.org/api/stories). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Channel/user from where to delete stories. | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of stories to delete. | Yes| + + +### Return type: [Vector\_of\_int](/API_docs/types/int.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_int = $MadelineProto->stories->deleteStories(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/stories.editStory.md b/docs/API_docs/methods/stories.editStory.md new file mode 100644 index 0000000000..67d00795db --- /dev/null +++ b/docs/API_docs/methods/stories.editStory.md @@ -0,0 +1,109 @@ +--- +title: "stories.editStory" +description: "Edit an uploaded [story](https://core.telegram.org/api/stories)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_editStory.html +--- +# Method: stories.editStory +[Back to methods index](index.html) + + + +Edit an uploaded [story](https://core.telegram.org/api/stories) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the story was posted. | Optional| +|id|[int](/API_docs/types/int.html) | ID of story to edit. | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | If specified, replaces the story media. | Optional| +|media\_areas|Array of [MediaArea](/API_docs/types/MediaArea.html) | [Media areas](https://core.telegram.org/api/stories#media-areas) associated to the story, see [here »](https://core.telegram.org/api/stories#media-areas) for more info. | Optional| +|caption|[string](/API_docs/types/string.html) | If specified, replaces the story caption. | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | [Message entities for styled text in the caption](https://core.telegram.org/api/entities), if allowed by the [`stories_entities` client configuration parameter »](https://core.telegram.org/api/config#stories-entities). | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|privacy\_rules|Array of [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) | If specified, alters the [privacy settings »](https://core.telegram.org/api/privacy) of the story, changing who can or can't view the story. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->stories->editStory(peer: $InputPeer, id: $int, media: $InputMedia, media_areas: [$MediaArea, $MediaArea], caption: 'string', entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', privacy_rules: [$InputPrivacyRule, $InputPrivacyRule], ); +``` + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/stories.exportStoryLink.md b/docs/API_docs/methods/stories.exportStoryLink.md new file mode 100644 index 0000000000..16fa6534d9 --- /dev/null +++ b/docs/API_docs/methods/stories.exportStoryLink.md @@ -0,0 +1,43 @@ +--- +title: "stories.exportStoryLink" +description: "Generate a [story deep link](https://core.telegram.org/api/links#story-links) for a specific story" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_exportStoryLink.html +--- +# Method: stories.exportStoryLink +[Back to methods index](index.html) + + + +Generate a [story deep link](https://core.telegram.org/api/links#story-links) for a specific story + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the story was posted | Optional| +|id|[int](/API_docs/types/int.html) | Story ID | Optional| + + +### Return type: [ExportedStoryLink](/API_docs/types/ExportedStoryLink.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$ExportedStoryLink = $MadelineProto->stories->exportStoryLink(peer: $InputPeer, id: $int, ); +``` + diff --git a/docs/API_docs/methods/stories.getAllReadPeerStories.md b/docs/API_docs/methods/stories.getAllReadPeerStories.md new file mode 100644 index 0000000000..784c078723 --- /dev/null +++ b/docs/API_docs/methods/stories.getAllReadPeerStories.md @@ -0,0 +1,37 @@ +--- +title: "stories.getAllReadPeerStories" +description: "Obtain the latest read story ID for all peers when first logging in, returned as a list of [updateReadStories](../constructors/updateReadStories.html) updates, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getAllReadPeerStories.html +--- +# Method: stories.getAllReadPeerStories +[Back to methods index](index.html) + + + +Obtain the latest read story ID for all peers when first logging in, returned as a list of [updateReadStories](../constructors/updateReadStories.html) updates, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info. + + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->stories->getAllReadPeerStories(); +``` + diff --git a/docs/API_docs/methods/stories.getAllStories.md b/docs/API_docs/methods/stories.getAllStories.md new file mode 100644 index 0000000000..eedec4e579 --- /dev/null +++ b/docs/API_docs/methods/stories.getAllStories.md @@ -0,0 +1,44 @@ +--- +title: "stories.getAllStories" +description: "Fetch the List of active (or active and hidden) stories, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info on watching stories." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getAllStories.html +--- +# Method: stories.getAllStories +[Back to methods index](index.html) + + + +Fetch the List of active (or active and hidden) stories, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info on watching stories. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|next|[Bool](/API_docs/types/Bool.html) | If `next` and `state` are both set, uses the passed `state` to paginate to the next results; if neither `state` nor `next` are set, fetches the initial page; if `state` is set and `next` is not set, check for changes in the active/hidden peerset, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info on the full flow. | Optional| +|hidden|[Bool](/API_docs/types/Bool.html) | If set, fetches the hidden active story list, otherwise fetches the active story list, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info on the full flow. | Optional| +|state|[string](/API_docs/types/string.html) | If `next` and `state` are both set, uses the passed `state` to paginate to the next results; if neither `state` nor `next` are set, fetches the initial page; if `state` is set and `next` is not set, check for changes in the active/hidden peerset, see [here »](https://core.telegram.org/api/stories#watching-stories) for more info on the full flow. | Optional| + + +### Return type: [stories.AllStories](/API_docs/types/stories.AllStories.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_AllStories = $MadelineProto->stories->getAllStories(next: $Bool, hidden: $Bool, state: 'string', ); +``` + diff --git a/docs/API_docs/methods/stories.getChatsToSend.md b/docs/API_docs/methods/stories.getChatsToSend.md new file mode 100644 index 0000000000..d9c9ec8110 --- /dev/null +++ b/docs/API_docs/methods/stories.getChatsToSend.md @@ -0,0 +1,37 @@ +--- +title: "stories.getChatsToSend" +description: "Obtain a list of channels where the user can post [stories](https://core.telegram.org/api/stories)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getChatsToSend.html +--- +# Method: stories.getChatsToSend +[Back to methods index](index.html) + + + +Obtain a list of channels where the user can post [stories](https://core.telegram.org/api/stories) + + + +### Return type: [messages.Chats](/API_docs/types/messages.Chats.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$messages_Chats = $MadelineProto->stories->getChatsToSend(); +``` + diff --git a/docs/API_docs/methods/stories.getPeerMaxIDs.md b/docs/API_docs/methods/stories.getPeerMaxIDs.md new file mode 100644 index 0000000000..39c5a74cee --- /dev/null +++ b/docs/API_docs/methods/stories.getPeerMaxIDs.md @@ -0,0 +1,42 @@ +--- +title: "stories.getPeerMaxIDs" +description: "Get the IDs of the maximum read stories for a set of peers." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getPeerMaxIDs.html +--- +# Method: stories.getPeerMaxIDs +[Back to methods index](index.html) + + + +Get the IDs of the maximum read stories for a set of peers. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peers | Yes| + + +### Return type: [Vector\_of\_int](/API_docs/types/int.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_int = $MadelineProto->stories->getPeerMaxIDs(id: [$InputPeer, $InputPeer], ); +``` + diff --git a/docs/API_docs/methods/stories.getPeerStories.md b/docs/API_docs/methods/stories.getPeerStories.md new file mode 100644 index 0000000000..3c30bdb212 --- /dev/null +++ b/docs/API_docs/methods/stories.getPeerStories.md @@ -0,0 +1,42 @@ +--- +title: "stories.getPeerStories" +description: "Fetch the full active [story list](https://core.telegram.org/api/stories#watching-stories) of a specific peer." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getPeerStories.html +--- +# Method: stories.getPeerStories +[Back to methods index](index.html) + + + +Fetch the full active [story list](https://core.telegram.org/api/stories#watching-stories) of a specific peer. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer whose stories should be fetched | Optional| + + +### Return type: [stories.PeerStories](/API_docs/types/stories.PeerStories.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_PeerStories = $MadelineProto->stories->getPeerStories(peer: $InputPeer, ); +``` + diff --git a/docs/API_docs/methods/stories.getPinnedStories.md b/docs/API_docs/methods/stories.getPinnedStories.md new file mode 100644 index 0000000000..2ac5bd8241 --- /dev/null +++ b/docs/API_docs/methods/stories.getPinnedStories.md @@ -0,0 +1,44 @@ +--- +title: "stories.getPinnedStories" +description: "Fetch the [stories](https://core.telegram.org/api/stories#pinned-or-archived-stories) pinned on a peer's profile." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getPinnedStories.html +--- +# Method: stories.getPinnedStories +[Back to methods index](index.html) + + + +Fetch the [stories](https://core.telegram.org/api/stories#pinned-or-archived-stories) pinned on a peer's profile. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer whose pinned stories should be fetched | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [stories.Stories](/API_docs/types/stories.Stories.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_Stories = $MadelineProto->stories->getPinnedStories(peer: $InputPeer, offset_id: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stories.getStoriesArchive.md b/docs/API_docs/methods/stories.getStoriesArchive.md new file mode 100644 index 0000000000..3ce43a5557 --- /dev/null +++ b/docs/API_docs/methods/stories.getStoriesArchive.md @@ -0,0 +1,44 @@ +--- +title: "stories.getStoriesArchive" +description: "Fetch the [story archive »](https://core.telegram.org/api/stories#pinned-or-archived-stories) of a peer we control." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getStoriesArchive.html +--- +# Method: stories.getStoriesArchive +[Back to methods index](index.html) + + + +Fetch the [story archive »](https://core.telegram.org/api/stories#pinned-or-archived-stories) of a peer we control. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer whose archived stories should be fetched | Optional| +|offset\_id|[int](/API_docs/types/int.html) | [Offsets for pagination, for more info click here](https://core.telegram.org/api/offsets) | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [stories.Stories](/API_docs/types/stories.Stories.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_Stories = $MadelineProto->stories->getStoriesArchive(peer: $InputPeer, offset_id: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stories.getStoriesByID.md b/docs/API_docs/methods/stories.getStoriesByID.md new file mode 100644 index 0000000000..3143fe6d86 --- /dev/null +++ b/docs/API_docs/methods/stories.getStoriesByID.md @@ -0,0 +1,43 @@ +--- +title: "stories.getStoriesByID" +description: "Obtain full info about a set of [stories](https://core.telegram.org/api/stories) by their IDs." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getStoriesByID.html +--- +# Method: stories.getStoriesByID +[Back to methods index](index.html) + + + +Obtain full info about a set of [stories](https://core.telegram.org/api/stories) by their IDs. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the stories were posted | Optional| +|id|Array of [int](/API_docs/types/int.html) | Story IDs | Yes| + + +### Return type: [stories.Stories](/API_docs/types/stories.Stories.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_Stories = $MadelineProto->stories->getStoriesByID(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/stories.getStoriesViews.md b/docs/API_docs/methods/stories.getStoriesViews.md new file mode 100644 index 0000000000..43a365a24c --- /dev/null +++ b/docs/API_docs/methods/stories.getStoriesViews.md @@ -0,0 +1,43 @@ +--- +title: "stories.getStoriesViews" +description: "Obtain info about the view count, forward count, reactions and recent viewers of one or more [stories](https://core.telegram.org/api/stories)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getStoriesViews.html +--- +# Method: stories.getStoriesViews +[Back to methods index](index.html) + + + +Obtain info about the view count, forward count, reactions and recent viewers of one or more [stories](https://core.telegram.org/api/stories). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer whose stories should be fetched | Optional| +|id|Array of [int](/API_docs/types/int.html) | Story IDs | Yes| + + +### Return type: [stories.StoryViews](/API_docs/types/stories.StoryViews.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_StoryViews = $MadelineProto->stories->getStoriesViews(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/stories.getStoryReactionsList.md b/docs/API_docs/methods/stories.getStoryReactionsList.md new file mode 100644 index 0000000000..a53d4345a5 --- /dev/null +++ b/docs/API_docs/methods/stories.getStoryReactionsList.md @@ -0,0 +1,49 @@ +--- +title: "stories.getStoryReactionsList" +description: "Get the [reaction](https://core.telegram.org/api/reactions) and interaction list of a [story](https://core.telegram.org/api/stories) posted to a channel, along with the sender of each reaction." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getStoryReactionsList.html +--- +# Method: stories.getStoryReactionsList +[Back to methods index](index.html) + + + +Get the [reaction](https://core.telegram.org/api/reactions) and interaction list of a [story](https://core.telegram.org/api/stories) posted to a channel, along with the sender of each reaction. + +Can only be used by channel admins. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|forwards\_first|[Bool](/API_docs/types/Bool.html) | If set, returns forwards and reposts first, then reactions, then other views; otherwise returns interactions sorted just by interaction date. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Channel | Optional| +|id|[int](/API_docs/types/int.html) | [Story](https://core.telegram.org/api/stories) ID | Optional| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Get only reactions of this type | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for pagination (taken from the `next_offset` field of the returned [stories.StoryReactionsList](../types/stories.StoryReactionsList.html)); empty in the first request. | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [stories.StoryReactionsList](/API_docs/types/stories.StoryReactionsList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_StoryReactionsList = $MadelineProto->stories->getStoryReactionsList(forwards_first: $Bool, peer: $InputPeer, id: $int, reaction: $Reaction, offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stories.getStoryViewsList.md b/docs/API_docs/methods/stories.getStoryViewsList.md new file mode 100644 index 0000000000..14db4b0d8e --- /dev/null +++ b/docs/API_docs/methods/stories.getStoryViewsList.md @@ -0,0 +1,49 @@ +--- +title: "stories.getStoryViewsList" +description: "Obtain the list of users that have viewed a specific [story we posted](https://core.telegram.org/api/stories)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_getStoryViewsList.html +--- +# Method: stories.getStoryViewsList +[Back to methods index](index.html) + + + +Obtain the list of users that have viewed a specific [story we posted](https://core.telegram.org/api/stories) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|just\_contacts|[Bool](/API_docs/types/Bool.html) | Whether to only fetch view reaction/views made by our [contacts](https://core.telegram.org/api/contacts) | Optional| +|reactions\_first|[Bool](/API_docs/types/Bool.html) | Whether to return [storyView](../constructors/storyView.html) info about users that reacted to the story (i.e. if set, the server will first sort results by view date as usual, and then also additionally sort the list by putting [storyView](../constructors/storyView.html)s with an associated reaction first in the list). Ignored if `forwards_first` is set. | Optional| +|forwards\_first|[Bool](/API_docs/types/Bool.html) | If set, returns forwards and reposts first, then reactions, then other views; otherwise returns interactions sorted just by interaction date. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the story was posted | Optional| +|q|[string](/API_docs/types/string.html) | Search for specific peers | Optional| +|id|[int](/API_docs/types/int.html) | Story ID | Optional| +|offset|[string](/API_docs/types/string.html) | Offset for pagination, obtained from [stories.storyViewsList](../constructors/stories.storyViewsList.html).`next_offset` | Optional| +|limit|[int](/API_docs/types/int.html) | Maximum number of results to return, [see pagination](https://core.telegram.org/api/offsets) | Optional| + + +### Return type: [stories.StoryViewsList](/API_docs/types/stories.StoryViewsList.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$stories_StoryViewsList = $MadelineProto->stories->getStoryViewsList(just_contacts: $Bool, reactions_first: $Bool, forwards_first: $Bool, peer: $InputPeer, q: 'string', id: $int, offset: 'string', limit: $int, ); +``` + diff --git a/docs/API_docs/methods/stories.incrementStoryViews.md b/docs/API_docs/methods/stories.incrementStoryViews.md new file mode 100644 index 0000000000..b9278159ea --- /dev/null +++ b/docs/API_docs/methods/stories.incrementStoryViews.md @@ -0,0 +1,43 @@ +--- +title: "stories.incrementStoryViews" +description: "Increment the view counter of one or more stories." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_incrementStoryViews.html +--- +# Method: stories.incrementStoryViews +[Back to methods index](index.html) + + + +Increment the view counter of one or more stories. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where the stories were posted. | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of the stories (maximum 200 at a time). | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stories->incrementStoryViews(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/stories.readStories.md b/docs/API_docs/methods/stories.readStories.md new file mode 100644 index 0000000000..5985b9bb50 --- /dev/null +++ b/docs/API_docs/methods/stories.readStories.md @@ -0,0 +1,43 @@ +--- +title: "stories.readStories" +description: "Mark all stories up to a certain ID as read, for a given peer; will emit an [updateReadStories](../constructors/updateReadStories.html) update to all logged-in sessions." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_readStories.html +--- +# Method: stories.readStories +[Back to methods index](index.html) + + + +Mark all stories up to a certain ID as read, for a given peer; will emit an [updateReadStories](../constructors/updateReadStories.html) update to all logged-in sessions. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer whose stories should be marked as read. | Optional| +|max\_id|[int](/API_docs/types/int.html) | Mark all stories up to and including this ID as read | Optional| + + +### Return type: [Vector\_of\_int](/API_docs/types/int.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_int = $MadelineProto->stories->readStories(peer: $InputPeer, max_id: $int, ); +``` + diff --git a/docs/API_docs/methods/stories.report.md b/docs/API_docs/methods/stories.report.md new file mode 100644 index 0000000000..721a10e35f --- /dev/null +++ b/docs/API_docs/methods/stories.report.md @@ -0,0 +1,51 @@ +--- +title: "stories.report" +description: "Report a story." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_report.html +--- +# Method: stories.report +[Back to methods index](index.html) + + + +Report a story. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer that uploaded the story. | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of the stories to report. | Yes| +|reason|[ReportReason](/API_docs/types/ReportReason.html) | Why are these storeis being reported. | Yes| +|message|[string](/API_docs/types/string.html) | Comment for report moderation | Optional| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stories->report(peer: $InputPeer, id: [$int, $int], reason: $ReportReason, message: 'string', ); +``` + + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [Bool](../types/Bool.html) will be returned instead. + + diff --git a/docs/API_docs/methods/stories.sendReaction.md b/docs/API_docs/methods/stories.sendReaction.md new file mode 100644 index 0000000000..361b8b10d4 --- /dev/null +++ b/docs/API_docs/methods/stories.sendReaction.md @@ -0,0 +1,45 @@ +--- +title: "stories.sendReaction" +description: "React to a story." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_sendReaction.html +--- +# Method: stories.sendReaction +[Back to methods index](index.html) + + + +React to a story. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|add\_to\_recent|[Bool](/API_docs/types/Bool.html) | Whether to add this reaction to the [recent reactions list »](https://core.telegram.org/api/reactions#recent-reactions). | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer that sent the story | Optional| +|story\_id|[int](/API_docs/types/int.html) | ID of the story to react to | Optional| +|reaction|[Reaction](/API_docs/types/Reaction.html) | Reaction | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->stories->sendReaction(add_to_recent: $Bool, peer: $InputPeer, story_id: $int, reaction: $Reaction, ); +``` + diff --git a/docs/API_docs/methods/stories.sendStory.md b/docs/API_docs/methods/stories.sendStory.md new file mode 100644 index 0000000000..8143a908d3 --- /dev/null +++ b/docs/API_docs/methods/stories.sendStory.md @@ -0,0 +1,114 @@ +--- +title: "stories.sendStory" +description: "Uploads a [Telegram Story](https://core.telegram.org/api/stories)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_sendStory.html +--- +# Method: stories.sendStory +[Back to methods index](index.html) + + + +Uploads a [Telegram Story](https://core.telegram.org/api/stories). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|pinned|[Bool](/API_docs/types/Bool.html) | Whether to add the story to the profile automatically upon expiration. If not set, the story will only be added to the archive, see [here »](https://core.telegram.org/api/stories) for more info. | Optional| +|noforwards|[Bool](/API_docs/types/Bool.html) | If set, disables forwards, screenshots, and downloads. | Optional| +|fwd\_modified|[Bool](/API_docs/types/Bool.html) | Set this flag when reposting stories with `fwd_from_id`+`fwd_from_id`, if the `media` was modified before reposting. | Optional| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | The peer to send the story as. | Optional| +|media|[MessageMedia, Update, Message or InputMedia](/API_docs/types/InputMedia.html) | The story media. | Optional| +|media\_areas|Array of [MediaArea](/API_docs/types/MediaArea.html) | [Media areas](https://core.telegram.org/api/stories#media-areas) associated to the story, see [here »](https://core.telegram.org/api/stories#media-areas) for more info. | Optional| +|caption|[string](/API_docs/types/string.html) | Story caption. | Optional| +|entities|Array of [MessageEntity](/API_docs/types/MessageEntity.html) | [Message entities for styled text](https://core.telegram.org/api/entities), if allowed by the [`stories_entities` client configuration parameter »](https://core.telegram.org/api/config#stories-entities). | Optional| +|parse\_mode| [string](/API_docs/types/string.html) | Whether to parse HTML or Markdown markup in the message| Optional | +|privacy\_rules|Array of [InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) | [Privacy rules](https://core.telegram.org/api/privacy) for the story, indicating who can or can't view the story. | Yes| +|period|[int](/API_docs/types/int.html) | Period after which the story is moved to archive (and to the profile if `pinned` is set), in seconds; must be one of `6 * 3600`, `12 * 3600`, `86400`, or `2 * 86400` for Telegram Premium users, and `86400` otherwise. | Optional| +|fwd\_from\_id|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | If set, indicates that this story is a repost of story with ID `fwd_from_story` posted by the peer in `fwd_from_id`. | Optional| +|fwd\_from\_story|[int](/API_docs/types/int.html) | If set, indicates that this story is a repost of story with ID `fwd_from_story` posted by the peer in `fwd_from_id`. | Optional| + + +### Return type: [Updates](/API_docs/types/Updates.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Updates = $MadelineProto->stories->sendStory(pinned: $Bool, noforwards: $Bool, fwd_modified: $Bool, peer: $InputPeer, media: $InputMedia, media_areas: [$MediaArea, $MediaArea], caption: 'string', entities: [$MessageEntity, $MessageEntity], parse_mode: 'string', privacy_rules: [$InputPrivacyRule, $InputPrivacyRule], period: $int, fwd_from_id: $InputPeer, fwd_from_story: $int, ); +``` + + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/docs/API_docs/methods/stories.toggleAllStoriesHidden.md b/docs/API_docs/methods/stories.toggleAllStoriesHidden.md new file mode 100644 index 0000000000..61086782c4 --- /dev/null +++ b/docs/API_docs/methods/stories.toggleAllStoriesHidden.md @@ -0,0 +1,42 @@ +--- +title: "stories.toggleAllStoriesHidden" +description: "Hide the active stories of a specific peer, preventing them from being displayed on the action bar on the homescreen." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_toggleAllStoriesHidden.html +--- +# Method: stories.toggleAllStoriesHidden +[Back to methods index](index.html) + + + +Hide the active stories of a specific peer, preventing them from being displayed on the action bar on the homescreen. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|hidden|[Bool](/API_docs/types/Bool.html) | Whether to hide or unhide all active stories of the peer | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stories->toggleAllStoriesHidden(hidden: $Bool, ); +``` + diff --git a/docs/API_docs/methods/stories.togglePeerStoriesHidden.md b/docs/API_docs/methods/stories.togglePeerStoriesHidden.md new file mode 100644 index 0000000000..320f527132 --- /dev/null +++ b/docs/API_docs/methods/stories.togglePeerStoriesHidden.md @@ -0,0 +1,43 @@ +--- +title: "stories.togglePeerStoriesHidden" +description: "Hide the active stories of a user, preventing them from being displayed on the action bar on the homescreen, see [here »](https://core.telegram.org/api/stories#hiding-stories-of-other-users) for more info." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_togglePeerStoriesHidden.html +--- +# Method: stories.togglePeerStoriesHidden +[Back to methods index](index.html) + + + +Hide the active stories of a user, preventing them from being displayed on the action bar on the homescreen, see [here »](https://core.telegram.org/api/stories#hiding-stories-of-other-users) for more info. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer whose stories should be (un)hidden. | Optional| +|hidden|[Bool](/API_docs/types/Bool.html) | Whether to hide or unhide stories. | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stories->togglePeerStoriesHidden(peer: $InputPeer, hidden: $Bool, ); +``` + diff --git a/docs/API_docs/methods/stories.togglePinned.md b/docs/API_docs/methods/stories.togglePinned.md new file mode 100644 index 0000000000..748ab4cb50 --- /dev/null +++ b/docs/API_docs/methods/stories.togglePinned.md @@ -0,0 +1,44 @@ +--- +title: "stories.togglePinned" +description: "Pin or unpin one or more stories" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_togglePinned.html +--- +# Method: stories.togglePinned +[Back to methods index](index.html) + + + +Pin or unpin one or more stories + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Peer where to pin or unpin stories | Optional| +|id|Array of [int](/API_docs/types/int.html) | IDs of stories to pin or unpin | Yes| +|pinned|[Bool](/API_docs/types/Bool.html) | Whether to pin or unpin the stories | Yes| + + +### Return type: [Vector\_of\_int](/API_docs/types/int.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_int = $MadelineProto->stories->togglePinned(peer: $InputPeer, id: [$int, $int], pinned: $Bool, ); +``` + diff --git a/docs/API_docs/methods/stories.togglePinnedToTop.md b/docs/API_docs/methods/stories.togglePinnedToTop.md new file mode 100644 index 0000000000..47356bf004 --- /dev/null +++ b/docs/API_docs/methods/stories.togglePinnedToTop.md @@ -0,0 +1,41 @@ +--- +title: "stories.togglePinnedToTop" +description: "stories.togglePinnedToTop parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/stories_togglePinnedToTop.html +--- +# Method: stories.togglePinnedToTop +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|peer|[Username, chat ID, Update, Message or InputPeer](/API_docs/types/InputPeer.html) | Optional| +|id|Array of [int](/API_docs/types/int.html) | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->stories->togglePinnedToTop(peer: $InputPeer, id: [$int, $int], ); +``` + diff --git a/docs/API_docs/methods/updates.getChannelDifference.md b/docs/API_docs/methods/updates.getChannelDifference.md new file mode 100644 index 0000000000..d012133603 --- /dev/null +++ b/docs/API_docs/methods/updates.getChannelDifference.md @@ -0,0 +1,50 @@ +--- +title: "updates.getChannelDifference" +description: "You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/updates_getChannelDifference.html +--- +# Method: updates.getChannelDifference +[Back to methods index](index.html) + + + +# Warning: this is a low-level, complex method that **must never** be used directly. +The [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html) provides a high-level abstraction that **must** be used instead of this method to fetch updates. +If you want to fetch all users of a bot using a bot token, use [getDialogIds](https://docs.madelineproto.xyz/docs/DIALOGS.html) or the high-level [broadcast API](https://docs.madelineproto.xyz/docs/BROADCAST.html), instead. + +You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|force|[Bool](/API_docs/types/Bool.html) | Set to true to skip some possibly unneeded updates and reduce server-side load | Optional| +|channel|[Username, chat ID, Update, Message or InputChannel](/API_docs/types/InputChannel.html) | The channel | Optional| +|filter|[ChannelMessagesFilter](/API_docs/types/ChannelMessagesFilter.html) | Messsage filter | Optional| +|pts|[int](/API_docs/types/int.html) | Persistent timestamp (see [updates](https://core.telegram.org/api/updates)) | Optional| +|limit|[int](/API_docs/types/int.html) | How many updates to fetch, max `100000`
Ordinary (non-bot) users are supposed to pass `10-100` | Optional| + + +### Return type: [updates.ChannelDifference](/API_docs/types/updates.ChannelDifference.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$updates_ChannelDifference = $MadelineProto->updates->getChannelDifference(force: $Bool, channel: $InputChannel, filter: $ChannelMessagesFilter, pts: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/updates.getDifference.md b/docs/API_docs/methods/updates.getDifference.md new file mode 100644 index 0000000000..cc260d2ceb --- /dev/null +++ b/docs/API_docs/methods/updates.getDifference.md @@ -0,0 +1,51 @@ +--- +title: "updates.getDifference" +description: "You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/updates_getDifference.html +--- +# Method: updates.getDifference +[Back to methods index](index.html) + + + +# Warning: this is a low-level, complex method that **must never** be used directly. +The [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html) provides a high-level abstraction that **must** be used instead of this method to fetch updates. +If you want to fetch all users of a bot using a bot token, use [getDialogIds](https://docs.madelineproto.xyz/docs/DIALOGS.html) or the high-level [broadcast API](https://docs.madelineproto.xyz/docs/BROADCAST.html), instead. + +You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|pts|[int](/API_docs/types/int.html) | PTS, see [updates](https://core.telegram.org/api/updates). | Optional| +|pts\_limit|[int](/API_docs/types/int.html) | PTS limit | Optional| +|pts\_total\_limit|[int](/API_docs/types/int.html) | For fast updating: if provided and `pts + pts_total_limit < remote pts`, [updates.differenceTooLong](../constructors/updates.differenceTooLong.html) will be returned.
Simply tells the server to not return the difference if it is bigger than `pts_total_limit`
If the remote pts is too big (> ~4000000), this field will default to 1000000 | Optional| +|date|[int](/API_docs/types/int.html) | date, see [updates](https://core.telegram.org/api/updates). | Optional| +|qts|[int](/API_docs/types/int.html) | QTS, see [updates](https://core.telegram.org/api/updates). | Optional| +|qts\_limit|[int](/API_docs/types/int.html) | QTS limit | Optional| + + +### Return type: [updates.Difference](/API_docs/types/updates.Difference.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$updates_Difference = $MadelineProto->updates->getDifference(pts: $int, pts_limit: $int, pts_total_limit: $int, date: $int, qts: $int, qts_limit: $int, ); +``` + diff --git a/docs/API_docs/methods/updates.getState.md b/docs/API_docs/methods/updates.getState.md new file mode 100644 index 0000000000..b55c355c47 --- /dev/null +++ b/docs/API_docs/methods/updates.getState.md @@ -0,0 +1,41 @@ +--- +title: "updates.getState" +description: "You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/updates_getState.html +--- +# Method: updates.getState +[Back to methods index](index.html) + + + +# Warning: this is a low-level, complex method that **must never** be used directly. +The [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html) provides a high-level abstraction that **must** be used instead of this method to fetch updates. +If you want to fetch all users of a bot using a bot token, use [getDialogIds](https://docs.madelineproto.xyz/docs/DIALOGS.html) or the high-level [broadcast API](https://docs.madelineproto.xyz/docs/BROADCAST.html), instead. + +You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead. + + + +### Return type: [updates.State](/API_docs/types/updates.State.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$updates_State = $MadelineProto->updates->getState(); +``` + diff --git a/docs/API_docs/methods/upload.getCdnFile.md b/docs/API_docs/methods/upload.getCdnFile.md new file mode 100644 index 0000000000..b83002552f --- /dev/null +++ b/docs/API_docs/methods/upload.getCdnFile.md @@ -0,0 +1,44 @@ +--- +title: "upload.getCdnFile" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_getCdnFile.html +--- +# Method: upload.getCdnFile +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file\_token|[string](/API_docs/types/string.html) | | Optional| +|offset|[long](/API_docs/types/long.html) | Offset of chunk to download | Yes| +|limit|[int](/API_docs/types/int.html) | Length of chunk to download | Optional| + + +### Return type: [upload.CdnFile](/API_docs/types/upload.CdnFile.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$upload_CdnFile = $MadelineProto->upload->getCdnFile(file_token: 'string', offset: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/upload.getCdnFileHashes.md b/docs/API_docs/methods/upload.getCdnFileHashes.md new file mode 100644 index 0000000000..2c62c25481 --- /dev/null +++ b/docs/API_docs/methods/upload.getCdnFileHashes.md @@ -0,0 +1,43 @@ +--- +title: "upload.getCdnFileHashes" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_getCdnFileHashes.html +--- +# Method: upload.getCdnFileHashes +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file\_token|[string](/API_docs/types/string.html) | | Optional| +|offset|[long](/API_docs/types/long.html) | Offset from which to start getting hashes | Yes| + + +### Return type: [Vector\_of\_FileHash](/API_docs/types/FileHash.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_FileHash = $MadelineProto->upload->getCdnFileHashes(file_token: 'string', offset: $long, ); +``` + diff --git a/docs/API_docs/methods/upload.getFile.md b/docs/API_docs/methods/upload.getFile.md new file mode 100644 index 0000000000..79161e5fec --- /dev/null +++ b/docs/API_docs/methods/upload.getFile.md @@ -0,0 +1,46 @@ +--- +title: "upload.getFile" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_getFile.html +--- +# Method: upload.getFile +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|precise|[Bool](/API_docs/types/Bool.html) | Disable some checks on limit and offset values, useful for example to stream videos by keyframes | Optional| +|cdn\_supported|[Bool](/API_docs/types/Bool.html) | Whether the current client supports [CDN downloads](https://core.telegram.org/cdn) | Optional| +|location|[InputFileLocation](/API_docs/types/InputFileLocation.html) | File location | Yes| +|offset|[long](/API_docs/types/long.html) | Number of bytes to be skipped | Yes| +|limit|[int](/API_docs/types/int.html) | Number of bytes to be returned | Optional| + + +### Return type: [upload.File](/API_docs/types/upload.File.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$upload_File = $MadelineProto->upload->getFile(precise: $Bool, cdn_supported: $Bool, location: $InputFileLocation, offset: $long, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/upload.getFileHashes.md b/docs/API_docs/methods/upload.getFileHashes.md new file mode 100644 index 0000000000..b985438b2d --- /dev/null +++ b/docs/API_docs/methods/upload.getFileHashes.md @@ -0,0 +1,43 @@ +--- +title: "upload.getFileHashes" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_getFileHashes.html +--- +# Method: upload.getFileHashes +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|location|[InputFileLocation](/API_docs/types/InputFileLocation.html) | File | Yes| +|offset|[long](/API_docs/types/long.html) | Offset from which to get file hashes | Yes| + + +### Return type: [Vector\_of\_FileHash](/API_docs/types/FileHash.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_FileHash = $MadelineProto->upload->getFileHashes(location: $InputFileLocation, offset: $long, ); +``` + diff --git a/docs/API_docs/methods/upload.getWebFile.md b/docs/API_docs/methods/upload.getWebFile.md new file mode 100644 index 0000000000..b69fa53e1f --- /dev/null +++ b/docs/API_docs/methods/upload.getWebFile.md @@ -0,0 +1,46 @@ +--- +title: "upload.getWebFile" +description: "Returns content of a web file, by proxying the request through telegram, see the [webfile docs for more info](https://core.telegram.org/api/files#downloading-webfiles)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_getWebFile.html +--- +# Method: upload.getWebFile +[Back to methods index](index.html) + + + +Returns content of a web file, by proxying the request through telegram, see the [webfile docs for more info](https://core.telegram.org/api/files#downloading-webfiles). + +**Note**: the query must be sent to the DC specified in the `webfile_dc_id` [MTProto configuration field](https://core.telegram.org/api/config#mtproto-configuration). + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|location|[InputWebFileLocation](/API_docs/types/InputWebFileLocation.html) | The file to download | Yes| +|offset|[int](/API_docs/types/int.html) | Number of bytes to be skipped | Optional| +|limit|[int](/API_docs/types/int.html) | Number of bytes to be returned | Optional| + + +### Return type: [upload.WebFile](/API_docs/types/upload.WebFile.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$upload_WebFile = $MadelineProto->upload->getWebFile(location: $InputWebFileLocation, offset: $int, limit: $int, ); +``` + diff --git a/docs/API_docs/methods/upload.reuploadCdnFile.md b/docs/API_docs/methods/upload.reuploadCdnFile.md new file mode 100644 index 0000000000..6dd0ba4101 --- /dev/null +++ b/docs/API_docs/methods/upload.reuploadCdnFile.md @@ -0,0 +1,43 @@ +--- +title: "upload.reuploadCdnFile" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_reuploadCdnFile.html +--- +# Method: upload.reuploadCdnFile +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file\_token|[string](/API_docs/types/string.html) | | Optional| +|request\_token|[bytes](/API_docs/types/bytes.html) | Request token | Yes| + + +### Return type: [Vector\_of\_FileHash](/API_docs/types/FileHash.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_FileHash = $MadelineProto->upload->reuploadCdnFile(file_token: 'string', request_token: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/upload.saveBigFilePart.md b/docs/API_docs/methods/upload.saveBigFilePart.md new file mode 100644 index 0000000000..34c9a9ebde --- /dev/null +++ b/docs/API_docs/methods/upload.saveBigFilePart.md @@ -0,0 +1,45 @@ +--- +title: "upload.saveBigFilePart" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_saveBigFilePart.html +--- +# Method: upload.saveBigFilePart +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file\_id|[long](/API_docs/types/long.html) | Random file id, created by the client | Yes| +|file\_part|[int](/API_docs/types/int.html) | Part sequence number | Optional| +|file\_total\_parts|[int](/API_docs/types/int.html) | Total number of parts | Optional| +|bytes|[bytes](/API_docs/types/bytes.html) | Binary data, part contents | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->upload->saveBigFilePart(file_id: $long, file_part: $int, file_total_parts: $int, bytes: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/upload.saveFilePart.md b/docs/API_docs/methods/upload.saveFilePart.md new file mode 100644 index 0000000000..413790e3b4 --- /dev/null +++ b/docs/API_docs/methods/upload.saveFilePart.md @@ -0,0 +1,44 @@ +--- +title: "upload.saveFilePart" +description: "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/upload_saveFilePart.html +--- +# Method: upload.saveFilePart +[Back to methods index](index.html) + + + +You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https://docs.madelineproto.xyz for more info + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|file\_id|[long](/API_docs/types/long.html) | Random file identifier created by the client | Yes| +|file\_part|[int](/API_docs/types/int.html) | Numerical order of a part | Optional| +|bytes|[bytes](/API_docs/types/bytes.html) | Binary data, content of a part | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->upload->saveFilePart(file_id: $long, file_part: $int, bytes: 'bytes', ); +``` + diff --git a/docs/API_docs/methods/users.getFullUser.md b/docs/API_docs/methods/users.getFullUser.md new file mode 100644 index 0000000000..01fe8c4771 --- /dev/null +++ b/docs/API_docs/methods/users.getFullUser.md @@ -0,0 +1,42 @@ +--- +title: "users.getFullUser" +description: "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/users_getFullUser.html +--- +# Method: users.getFullUser +[Back to methods index](index.html) + + + +You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | User ID | Optional| + + +### Return type: [users.UserFull](/API_docs/types/users.UserFull.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$users_UserFull = $MadelineProto->users->getFullUser(id: $InputUser, ); +``` + diff --git a/docs/API_docs/methods/users.getIsPremiumRequiredToContact.md b/docs/API_docs/methods/users.getIsPremiumRequiredToContact.md new file mode 100644 index 0000000000..12e4f0a275 --- /dev/null +++ b/docs/API_docs/methods/users.getIsPremiumRequiredToContact.md @@ -0,0 +1,40 @@ +--- +title: "users.getIsPremiumRequiredToContact" +description: "users.getIsPremiumRequiredToContact parameters, return type and example" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/users_getIsPremiumRequiredToContact.html +--- +# Method: users.getIsPremiumRequiredToContact +[Back to methods index](index.html) + + + +### Parameters: + +| Name | Type | Required | +|----------|---------------|----------| +|id|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | Yes| + + +### Return type: [Vector\_of\_Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **NO** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_Bool = $MadelineProto->users->getIsPremiumRequiredToContact(id: [$InputUser, $InputUser], ); +``` + diff --git a/docs/API_docs/methods/users.getUsers.md b/docs/API_docs/methods/users.getUsers.md new file mode 100644 index 0000000000..389fbc099d --- /dev/null +++ b/docs/API_docs/methods/users.getUsers.md @@ -0,0 +1,42 @@ +--- +title: "users.getUsers" +description: "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info)" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/users_getUsers.html +--- +# Method: users.getUsers +[Back to methods index](index.html) + + + +You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https://docs.madelineproto.xyz for more info) + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|Array of [Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | List of user identifiers | Yes| + + +### Return type: [Vector\_of\_User](/API_docs/types/User.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Vector_of_User = $MadelineProto->users->getUsers(id: [$InputUser, $InputUser], ); +``` + diff --git a/docs/API_docs/methods/users.setSecureValueErrors.md b/docs/API_docs/methods/users.setSecureValueErrors.md new file mode 100644 index 0000000000..d65729d31b --- /dev/null +++ b/docs/API_docs/methods/users.setSecureValueErrors.md @@ -0,0 +1,45 @@ +--- +title: "users.setSecureValueErrors" +description: "Notify the user that the sent [passport](https://core.telegram.org/passport) data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change)." +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/methods/users_setSecureValueErrors.html +--- +# Method: users.setSecureValueErrors +[Back to methods index](index.html) + + + +Notify the user that the sent [passport](https://core.telegram.org/passport) data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change). + +Use this if the data submitted by the user doesn't satisfy the standards your service requires for any reason. For example, if a birthday date seems invalid, a submitted document is blurry, a scan shows evidence of tampering, etc. Supply some details in the error message to make sure the user knows how to correct the issues. + +### Parameters: + +| Name | Type | Description | Required | +|----------|---------------|-------------|----------| +|id|[Username, chat ID, Update, Message or InputUser](/API_docs/types/InputUser.html) | The user | Optional| +|errors|Array of [SecureValueError](/API_docs/types/SecureValueError.html) | Errors | Yes| + + +### Return type: [Bool](/API_docs/types/Bool.html) + +### Can bots use this method: **YES** + + +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$Bool = $MadelineProto->users->setSecureValueErrors(id: $InputUser, errors: [$SecureValueError, $SecureValueError], ); +``` + diff --git a/docs/API_docs/types/!X.md b/docs/API_docs/types/!X.md new file mode 100644 index 0000000000..ec30994107 --- /dev/null +++ b/docs/API_docs/types/!X.md @@ -0,0 +1,11 @@ +--- +title: !X +description: Represents a TL serialized payload +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: !X +[Back to constructor index](index.html) + +Represents a TL serialized payload. +Typically you would want to provide a simple constructor or a method array here (method name under `_` as with constructors). diff --git a/docs/API_docs/types/AccountDaysTTL.md b/docs/API_docs/types/AccountDaysTTL.md new file mode 100644 index 0000000000..29627c6245 --- /dev/null +++ b/docs/API_docs/types/AccountDaysTTL.md @@ -0,0 +1,23 @@ +--- +title: AccountDaysTTL +description: constructors and methods of type AccountDaysTTL +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AccountDaysTTL +[Back to types index](index.html) + + + +### Possible values (constructors): + +[accountDaysTTL](/API_docs/constructors/accountDaysTTL.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getAccountTTL](/API_docs/methods/account.getAccountTTL.html) + + + diff --git a/docs/API_docs/types/AppWebViewResult.md b/docs/API_docs/types/AppWebViewResult.md new file mode 100644 index 0000000000..433de58a10 --- /dev/null +++ b/docs/API_docs/types/AppWebViewResult.md @@ -0,0 +1,23 @@ +--- +title: AppWebViewResult +description: constructors and methods of type AppWebViewResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AppWebViewResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[appWebViewResultUrl](/API_docs/constructors/appWebViewResultUrl.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->requestAppWebView](/API_docs/methods/messages.requestAppWebView.html) + + + diff --git a/docs/API_docs/types/AttachMenuBot.md b/docs/API_docs/types/AttachMenuBot.md new file mode 100644 index 0000000000..a6732f4ebc --- /dev/null +++ b/docs/API_docs/types/AttachMenuBot.md @@ -0,0 +1,21 @@ +--- +title: AttachMenuBot +description: constructors and methods of type AttachMenuBot +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AttachMenuBot +[Back to types index](index.html) + + + +### Possible values (constructors): + +[attachMenuBot](/API_docs/constructors/attachMenuBot.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/AttachMenuBotIcon.md b/docs/API_docs/types/AttachMenuBotIcon.md new file mode 100644 index 0000000000..62600540b0 --- /dev/null +++ b/docs/API_docs/types/AttachMenuBotIcon.md @@ -0,0 +1,21 @@ +--- +title: AttachMenuBotIcon +description: constructors and methods of type AttachMenuBotIcon +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AttachMenuBotIcon +[Back to types index](index.html) + + + +### Possible values (constructors): + +[attachMenuBotIcon](/API_docs/constructors/attachMenuBotIcon.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/AttachMenuBotIconColor.md b/docs/API_docs/types/AttachMenuBotIconColor.md new file mode 100644 index 0000000000..4c0aa199c1 --- /dev/null +++ b/docs/API_docs/types/AttachMenuBotIconColor.md @@ -0,0 +1,21 @@ +--- +title: AttachMenuBotIconColor +description: constructors and methods of type AttachMenuBotIconColor +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AttachMenuBotIconColor +[Back to types index](index.html) + + + +### Possible values (constructors): + +[attachMenuBotIconColor](/API_docs/constructors/attachMenuBotIconColor.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/AttachMenuBots.md b/docs/API_docs/types/AttachMenuBots.md new file mode 100644 index 0000000000..15bc4ab0f5 --- /dev/null +++ b/docs/API_docs/types/AttachMenuBots.md @@ -0,0 +1,25 @@ +--- +title: AttachMenuBots +description: constructors and methods of type AttachMenuBots +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AttachMenuBots +[Back to types index](index.html) + + + +### Possible values (constructors): + +[attachMenuBotsNotModified](/API_docs/constructors/attachMenuBotsNotModified.html) + +[attachMenuBots](/API_docs/constructors/attachMenuBots.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getAttachMenuBots](/API_docs/methods/messages.getAttachMenuBots.html) + + + diff --git a/docs/API_docs/types/AttachMenuBotsBot.md b/docs/API_docs/types/AttachMenuBotsBot.md new file mode 100644 index 0000000000..eaf20dabe9 --- /dev/null +++ b/docs/API_docs/types/AttachMenuBotsBot.md @@ -0,0 +1,23 @@ +--- +title: AttachMenuBotsBot +description: constructors and methods of type AttachMenuBotsBot +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AttachMenuBotsBot +[Back to types index](index.html) + + + +### Possible values (constructors): + +[attachMenuBotsBot](/API_docs/constructors/attachMenuBotsBot.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getAttachMenuBot](/API_docs/methods/messages.getAttachMenuBot.html) + + + diff --git a/docs/API_docs/types/AttachMenuPeerType.md b/docs/API_docs/types/AttachMenuPeerType.md new file mode 100644 index 0000000000..0102dbc169 --- /dev/null +++ b/docs/API_docs/types/AttachMenuPeerType.md @@ -0,0 +1,29 @@ +--- +title: AttachMenuPeerType +description: constructors and methods of type AttachMenuPeerType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AttachMenuPeerType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[attachMenuPeerTypeSameBotPM](/API_docs/constructors/attachMenuPeerTypeSameBotPM.html) + +[attachMenuPeerTypeBotPM](/API_docs/constructors/attachMenuPeerTypeBotPM.html) + +[attachMenuPeerTypePM](/API_docs/constructors/attachMenuPeerTypePM.html) + +[attachMenuPeerTypeChat](/API_docs/constructors/attachMenuPeerTypeChat.html) + +[attachMenuPeerTypeBroadcast](/API_docs/constructors/attachMenuPeerTypeBroadcast.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Authorization.md b/docs/API_docs/types/Authorization.md new file mode 100644 index 0000000000..c3c7160bf8 --- /dev/null +++ b/docs/API_docs/types/Authorization.md @@ -0,0 +1,23 @@ +--- +title: Authorization +description: constructors and methods of type Authorization +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Authorization +[Back to types index](index.html) + + + +### Possible values (constructors): + +[authorization](/API_docs/constructors/authorization.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->acceptLoginToken](/API_docs/methods/auth.acceptLoginToken.html) + + + diff --git a/docs/API_docs/types/AutoDownloadSettings.md b/docs/API_docs/types/AutoDownloadSettings.md new file mode 100644 index 0000000000..09c7041262 --- /dev/null +++ b/docs/API_docs/types/AutoDownloadSettings.md @@ -0,0 +1,21 @@ +--- +title: AutoDownloadSettings +description: constructors and methods of type AutoDownloadSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AutoDownloadSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[autoDownloadSettings](/API_docs/constructors/autoDownloadSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/AutoSaveException.md b/docs/API_docs/types/AutoSaveException.md new file mode 100644 index 0000000000..0382716ae0 --- /dev/null +++ b/docs/API_docs/types/AutoSaveException.md @@ -0,0 +1,21 @@ +--- +title: AutoSaveException +description: constructors and methods of type AutoSaveException +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AutoSaveException +[Back to types index](index.html) + + + +### Possible values (constructors): + +[autoSaveException](/API_docs/constructors/autoSaveException.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/AutoSaveSettings.md b/docs/API_docs/types/AutoSaveSettings.md new file mode 100644 index 0000000000..a4eed87e3a --- /dev/null +++ b/docs/API_docs/types/AutoSaveSettings.md @@ -0,0 +1,21 @@ +--- +title: AutoSaveSettings +description: constructors and methods of type AutoSaveSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AutoSaveSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[autoSaveSettings](/API_docs/constructors/autoSaveSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/AvailableReaction.md b/docs/API_docs/types/AvailableReaction.md new file mode 100644 index 0000000000..2d2a2c949d --- /dev/null +++ b/docs/API_docs/types/AvailableReaction.md @@ -0,0 +1,21 @@ +--- +title: AvailableReaction +description: constructors and methods of type AvailableReaction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: AvailableReaction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[availableReaction](/API_docs/constructors/availableReaction.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BankCardOpenUrl.md b/docs/API_docs/types/BankCardOpenUrl.md new file mode 100644 index 0000000000..15a45ba9b3 --- /dev/null +++ b/docs/API_docs/types/BankCardOpenUrl.md @@ -0,0 +1,21 @@ +--- +title: BankCardOpenUrl +description: constructors and methods of type BankCardOpenUrl +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BankCardOpenUrl +[Back to types index](index.html) + + + +### Possible values (constructors): + +[bankCardOpenUrl](/API_docs/constructors/bankCardOpenUrl.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BaseTheme.md b/docs/API_docs/types/BaseTheme.md new file mode 100644 index 0000000000..f16b31a6ae --- /dev/null +++ b/docs/API_docs/types/BaseTheme.md @@ -0,0 +1,29 @@ +--- +title: BaseTheme +description: constructors and methods of type BaseTheme +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BaseTheme +[Back to types index](index.html) + + + +### Possible values (constructors): + +[baseThemeClassic](/API_docs/constructors/baseThemeClassic.html) + +[baseThemeDay](/API_docs/constructors/baseThemeDay.html) + +[baseThemeNight](/API_docs/constructors/baseThemeNight.html) + +[baseThemeTinted](/API_docs/constructors/baseThemeTinted.html) + +[baseThemeArctic](/API_docs/constructors/baseThemeArctic.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Birthday.md b/docs/API_docs/types/Birthday.md new file mode 100644 index 0000000000..205aa01c9f --- /dev/null +++ b/docs/API_docs/types/Birthday.md @@ -0,0 +1,21 @@ +--- +title: Birthday +description: constructors and methods of type Birthday +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Birthday +[Back to types index](index.html) + + + +### Possible values (constructors): + +[birthday](/API_docs/constructors/birthday.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Bool.md b/docs/API_docs/types/Bool.md new file mode 100644 index 0000000000..29aa87e0a5 --- /dev/null +++ b/docs/API_docs/types/Bool.md @@ -0,0 +1,10 @@ +--- +title: Bool +description: Represents a boolean. +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Bool +[Back to types index](index.html) + +Represents a boolean. diff --git a/docs/API_docs/types/Boost.md b/docs/API_docs/types/Boost.md new file mode 100644 index 0000000000..55cbe1c4f3 --- /dev/null +++ b/docs/API_docs/types/Boost.md @@ -0,0 +1,21 @@ +--- +title: Boost +description: constructors and methods of type Boost +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Boost +[Back to types index](index.html) + + + +### Possible values (constructors): + +[boost](/API_docs/constructors/boost.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotApp.md b/docs/API_docs/types/BotApp.md new file mode 100644 index 0000000000..69e24f1eea --- /dev/null +++ b/docs/API_docs/types/BotApp.md @@ -0,0 +1,23 @@ +--- +title: BotApp +description: constructors and methods of type BotApp +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotApp +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botAppNotModified](/API_docs/constructors/botAppNotModified.html) + +[botApp](/API_docs/constructors/botApp.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotBusinessConnection.md b/docs/API_docs/types/BotBusinessConnection.md new file mode 100644 index 0000000000..c560c7aeb8 --- /dev/null +++ b/docs/API_docs/types/BotBusinessConnection.md @@ -0,0 +1,21 @@ +--- +title: BotBusinessConnection +description: constructors and methods of type BotBusinessConnection +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotBusinessConnection +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botBusinessConnection](/API_docs/constructors/botBusinessConnection.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotCommand.md b/docs/API_docs/types/BotCommand.md new file mode 100644 index 0000000000..e6b1e8d53a --- /dev/null +++ b/docs/API_docs/types/BotCommand.md @@ -0,0 +1,23 @@ +--- +title: BotCommand +description: constructors and methods of type BotCommand +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotCommand +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botCommand](/API_docs/constructors/botCommand.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->bots->getBotCommands](/API_docs/methods/bots.getBotCommands.html) + + + diff --git a/docs/API_docs/types/BotCommandScope.md b/docs/API_docs/types/BotCommandScope.md new file mode 100644 index 0000000000..799c5cb2f7 --- /dev/null +++ b/docs/API_docs/types/BotCommandScope.md @@ -0,0 +1,33 @@ +--- +title: BotCommandScope +description: constructors and methods of type BotCommandScope +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotCommandScope +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botCommandScopeDefault](/API_docs/constructors/botCommandScopeDefault.html) + +[botCommandScopeUsers](/API_docs/constructors/botCommandScopeUsers.html) + +[botCommandScopeChats](/API_docs/constructors/botCommandScopeChats.html) + +[botCommandScopeChatAdmins](/API_docs/constructors/botCommandScopeChatAdmins.html) + +[botCommandScopePeer](/API_docs/constructors/botCommandScopePeer.html) + +[botCommandScopePeerAdmins](/API_docs/constructors/botCommandScopePeerAdmins.html) + +[botCommandScopePeerUser](/API_docs/constructors/botCommandScopePeerUser.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotInfo.md b/docs/API_docs/types/BotInfo.md new file mode 100644 index 0000000000..ca0bfb7f87 --- /dev/null +++ b/docs/API_docs/types/BotInfo.md @@ -0,0 +1,21 @@ +--- +title: BotInfo +description: constructors and methods of type BotInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botInfo](/API_docs/constructors/botInfo.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotInlineMessage.md b/docs/API_docs/types/BotInlineMessage.md new file mode 100644 index 0000000000..9ececd7452 --- /dev/null +++ b/docs/API_docs/types/BotInlineMessage.md @@ -0,0 +1,33 @@ +--- +title: BotInlineMessage +description: constructors and methods of type BotInlineMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotInlineMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botInlineMessageMediaAuto](/API_docs/constructors/botInlineMessageMediaAuto.html) + +[botInlineMessageText](/API_docs/constructors/botInlineMessageText.html) + +[botInlineMessageMediaGeo](/API_docs/constructors/botInlineMessageMediaGeo.html) + +[botInlineMessageMediaVenue](/API_docs/constructors/botInlineMessageMediaVenue.html) + +[botInlineMessageMediaContact](/API_docs/constructors/botInlineMessageMediaContact.html) + +[botInlineMessageMediaInvoice](/API_docs/constructors/botInlineMessageMediaInvoice.html) + +[botInlineMessageMediaWebPage](/API_docs/constructors/botInlineMessageMediaWebPage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotInlineResult.md b/docs/API_docs/types/BotInlineResult.md new file mode 100644 index 0000000000..1dbaf0e9e3 --- /dev/null +++ b/docs/API_docs/types/BotInlineResult.md @@ -0,0 +1,23 @@ +--- +title: BotInlineResult +description: constructors and methods of type BotInlineResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotInlineResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botInlineResult](/API_docs/constructors/botInlineResult.html) + +[botInlineMediaResult](/API_docs/constructors/botInlineMediaResult.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BotMenuButton.md b/docs/API_docs/types/BotMenuButton.md new file mode 100644 index 0000000000..83cb067b1f --- /dev/null +++ b/docs/API_docs/types/BotMenuButton.md @@ -0,0 +1,27 @@ +--- +title: BotMenuButton +description: constructors and methods of type BotMenuButton +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BotMenuButton +[Back to types index](index.html) + + + +### Possible values (constructors): + +[botMenuButtonDefault](/API_docs/constructors/botMenuButtonDefault.html) + +[botMenuButtonCommands](/API_docs/constructors/botMenuButtonCommands.html) + +[botMenuButton](/API_docs/constructors/botMenuButton.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->bots->getBotMenuButton](/API_docs/methods/bots.getBotMenuButton.html) + + + diff --git a/docs/API_docs/types/BroadcastRevenueBalances.md b/docs/API_docs/types/BroadcastRevenueBalances.md new file mode 100644 index 0000000000..9717d9c5d3 --- /dev/null +++ b/docs/API_docs/types/BroadcastRevenueBalances.md @@ -0,0 +1,21 @@ +--- +title: BroadcastRevenueBalances +description: constructors and methods of type BroadcastRevenueBalances +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BroadcastRevenueBalances +[Back to types index](index.html) + + + +### Possible values (constructors): + +[broadcastRevenueBalances](/API_docs/constructors/broadcastRevenueBalances.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BroadcastRevenueTransaction.md b/docs/API_docs/types/BroadcastRevenueTransaction.md new file mode 100644 index 0000000000..d98efa4734 --- /dev/null +++ b/docs/API_docs/types/BroadcastRevenueTransaction.md @@ -0,0 +1,25 @@ +--- +title: BroadcastRevenueTransaction +description: constructors and methods of type BroadcastRevenueTransaction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BroadcastRevenueTransaction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[broadcastRevenueTransactionProceeds](/API_docs/constructors/broadcastRevenueTransactionProceeds.html) + +[broadcastRevenueTransactionWithdrawal](/API_docs/constructors/broadcastRevenueTransactionWithdrawal.html) + +[broadcastRevenueTransactionRefund](/API_docs/constructors/broadcastRevenueTransactionRefund.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessAwayMessage.md b/docs/API_docs/types/BusinessAwayMessage.md new file mode 100644 index 0000000000..72407e9a15 --- /dev/null +++ b/docs/API_docs/types/BusinessAwayMessage.md @@ -0,0 +1,21 @@ +--- +title: BusinessAwayMessage +description: constructors and methods of type BusinessAwayMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessAwayMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessAwayMessage](/API_docs/constructors/businessAwayMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessAwayMessageSchedule.md b/docs/API_docs/types/BusinessAwayMessageSchedule.md new file mode 100644 index 0000000000..e76e8a85e6 --- /dev/null +++ b/docs/API_docs/types/BusinessAwayMessageSchedule.md @@ -0,0 +1,25 @@ +--- +title: BusinessAwayMessageSchedule +description: constructors and methods of type BusinessAwayMessageSchedule +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessAwayMessageSchedule +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessAwayMessageScheduleAlways](/API_docs/constructors/businessAwayMessageScheduleAlways.html) + +[businessAwayMessageScheduleOutsideWorkHours](/API_docs/constructors/businessAwayMessageScheduleOutsideWorkHours.html) + +[businessAwayMessageScheduleCustom](/API_docs/constructors/businessAwayMessageScheduleCustom.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessBotRecipients.md b/docs/API_docs/types/BusinessBotRecipients.md new file mode 100644 index 0000000000..9a56f089b2 --- /dev/null +++ b/docs/API_docs/types/BusinessBotRecipients.md @@ -0,0 +1,21 @@ +--- +title: BusinessBotRecipients +description: constructors and methods of type BusinessBotRecipients +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessBotRecipients +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessBotRecipients](/API_docs/constructors/businessBotRecipients.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessChatLink.md b/docs/API_docs/types/BusinessChatLink.md new file mode 100644 index 0000000000..594fdf4327 --- /dev/null +++ b/docs/API_docs/types/BusinessChatLink.md @@ -0,0 +1,25 @@ +--- +title: BusinessChatLink +description: constructors and methods of type BusinessChatLink +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessChatLink +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessChatLink](/API_docs/constructors/businessChatLink.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->createBusinessChatLink](/API_docs/methods/account.createBusinessChatLink.html) + +[$MadelineProto->account->editBusinessChatLink](/API_docs/methods/account.editBusinessChatLink.html) + + + diff --git a/docs/API_docs/types/BusinessGreetingMessage.md b/docs/API_docs/types/BusinessGreetingMessage.md new file mode 100644 index 0000000000..5184388410 --- /dev/null +++ b/docs/API_docs/types/BusinessGreetingMessage.md @@ -0,0 +1,21 @@ +--- +title: BusinessGreetingMessage +description: constructors and methods of type BusinessGreetingMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessGreetingMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessGreetingMessage](/API_docs/constructors/businessGreetingMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessIntro.md b/docs/API_docs/types/BusinessIntro.md new file mode 100644 index 0000000000..9904ac182e --- /dev/null +++ b/docs/API_docs/types/BusinessIntro.md @@ -0,0 +1,21 @@ +--- +title: BusinessIntro +description: constructors and methods of type BusinessIntro +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessIntro +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessIntro](/API_docs/constructors/businessIntro.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessLocation.md b/docs/API_docs/types/BusinessLocation.md new file mode 100644 index 0000000000..e76dab19a7 --- /dev/null +++ b/docs/API_docs/types/BusinessLocation.md @@ -0,0 +1,21 @@ +--- +title: BusinessLocation +description: constructors and methods of type BusinessLocation +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessLocation +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessLocation](/API_docs/constructors/businessLocation.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessRecipients.md b/docs/API_docs/types/BusinessRecipients.md new file mode 100644 index 0000000000..87933ac001 --- /dev/null +++ b/docs/API_docs/types/BusinessRecipients.md @@ -0,0 +1,21 @@ +--- +title: BusinessRecipients +description: constructors and methods of type BusinessRecipients +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessRecipients +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessRecipients](/API_docs/constructors/businessRecipients.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessWeeklyOpen.md b/docs/API_docs/types/BusinessWeeklyOpen.md new file mode 100644 index 0000000000..fb9212224a --- /dev/null +++ b/docs/API_docs/types/BusinessWeeklyOpen.md @@ -0,0 +1,21 @@ +--- +title: BusinessWeeklyOpen +description: constructors and methods of type BusinessWeeklyOpen +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessWeeklyOpen +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessWeeklyOpen](/API_docs/constructors/businessWeeklyOpen.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/BusinessWorkHours.md b/docs/API_docs/types/BusinessWorkHours.md new file mode 100644 index 0000000000..49cdf3cdb6 --- /dev/null +++ b/docs/API_docs/types/BusinessWorkHours.md @@ -0,0 +1,21 @@ +--- +title: BusinessWorkHours +description: constructors and methods of type BusinessWorkHours +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: BusinessWorkHours +[Back to types index](index.html) + + + +### Possible values (constructors): + +[businessWorkHours](/API_docs/constructors/businessWorkHours.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/CdnConfig.md b/docs/API_docs/types/CdnConfig.md new file mode 100644 index 0000000000..e710e2760d --- /dev/null +++ b/docs/API_docs/types/CdnConfig.md @@ -0,0 +1,23 @@ +--- +title: CdnConfig +description: constructors and methods of type CdnConfig +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: CdnConfig +[Back to types index](index.html) + + + +### Possible values (constructors): + +[cdnConfig](/API_docs/constructors/cdnConfig.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getCdnConfig](/API_docs/methods/help.getCdnConfig.html) + + + diff --git a/docs/API_docs/types/CdnPublicKey.md b/docs/API_docs/types/CdnPublicKey.md new file mode 100644 index 0000000000..e418be0ba8 --- /dev/null +++ b/docs/API_docs/types/CdnPublicKey.md @@ -0,0 +1,21 @@ +--- +title: CdnPublicKey +description: constructors and methods of type CdnPublicKey +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: CdnPublicKey +[Back to types index](index.html) + + + +### Possible values (constructors): + +[cdnPublicKey](/API_docs/constructors/cdnPublicKey.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelAdminLogEvent.md b/docs/API_docs/types/ChannelAdminLogEvent.md new file mode 100644 index 0000000000..22398a477c --- /dev/null +++ b/docs/API_docs/types/ChannelAdminLogEvent.md @@ -0,0 +1,21 @@ +--- +title: ChannelAdminLogEvent +description: constructors and methods of type ChannelAdminLogEvent +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelAdminLogEvent +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelAdminLogEvent](/API_docs/constructors/channelAdminLogEvent.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelAdminLogEventAction.md b/docs/API_docs/types/ChannelAdminLogEventAction.md new file mode 100644 index 0000000000..267286345e --- /dev/null +++ b/docs/API_docs/types/ChannelAdminLogEventAction.md @@ -0,0 +1,115 @@ +--- +title: ChannelAdminLogEventAction +description: constructors and methods of type ChannelAdminLogEventAction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelAdminLogEventAction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelAdminLogEventActionChangeTitle](/API_docs/constructors/channelAdminLogEventActionChangeTitle.html) + +[channelAdminLogEventActionChangeAbout](/API_docs/constructors/channelAdminLogEventActionChangeAbout.html) + +[channelAdminLogEventActionChangeUsername](/API_docs/constructors/channelAdminLogEventActionChangeUsername.html) + +[channelAdminLogEventActionChangePhoto](/API_docs/constructors/channelAdminLogEventActionChangePhoto.html) + +[channelAdminLogEventActionToggleInvites](/API_docs/constructors/channelAdminLogEventActionToggleInvites.html) + +[channelAdminLogEventActionToggleSignatures](/API_docs/constructors/channelAdminLogEventActionToggleSignatures.html) + +[channelAdminLogEventActionUpdatePinned](/API_docs/constructors/channelAdminLogEventActionUpdatePinned.html) + +[channelAdminLogEventActionEditMessage](/API_docs/constructors/channelAdminLogEventActionEditMessage.html) + +[channelAdminLogEventActionDeleteMessage](/API_docs/constructors/channelAdminLogEventActionDeleteMessage.html) + +[channelAdminLogEventActionParticipantJoin](/API_docs/constructors/channelAdminLogEventActionParticipantJoin.html) + +[channelAdminLogEventActionParticipantLeave](/API_docs/constructors/channelAdminLogEventActionParticipantLeave.html) + +[channelAdminLogEventActionParticipantInvite](/API_docs/constructors/channelAdminLogEventActionParticipantInvite.html) + +[channelAdminLogEventActionParticipantToggleBan](/API_docs/constructors/channelAdminLogEventActionParticipantToggleBan.html) + +[channelAdminLogEventActionParticipantToggleAdmin](/API_docs/constructors/channelAdminLogEventActionParticipantToggleAdmin.html) + +[channelAdminLogEventActionChangeStickerSet](/API_docs/constructors/channelAdminLogEventActionChangeStickerSet.html) + +[channelAdminLogEventActionTogglePreHistoryHidden](/API_docs/constructors/channelAdminLogEventActionTogglePreHistoryHidden.html) + +[channelAdminLogEventActionDefaultBannedRights](/API_docs/constructors/channelAdminLogEventActionDefaultBannedRights.html) + +[channelAdminLogEventActionStopPoll](/API_docs/constructors/channelAdminLogEventActionStopPoll.html) + +[channelAdminLogEventActionChangeLinkedChat](/API_docs/constructors/channelAdminLogEventActionChangeLinkedChat.html) + +[channelAdminLogEventActionChangeLocation](/API_docs/constructors/channelAdminLogEventActionChangeLocation.html) + +[channelAdminLogEventActionToggleSlowMode](/API_docs/constructors/channelAdminLogEventActionToggleSlowMode.html) + +[channelAdminLogEventActionStartGroupCall](/API_docs/constructors/channelAdminLogEventActionStartGroupCall.html) + +[channelAdminLogEventActionDiscardGroupCall](/API_docs/constructors/channelAdminLogEventActionDiscardGroupCall.html) + +[channelAdminLogEventActionParticipantMute](/API_docs/constructors/channelAdminLogEventActionParticipantMute.html) + +[channelAdminLogEventActionParticipantUnmute](/API_docs/constructors/channelAdminLogEventActionParticipantUnmute.html) + +[channelAdminLogEventActionToggleGroupCallSetting](/API_docs/constructors/channelAdminLogEventActionToggleGroupCallSetting.html) + +[channelAdminLogEventActionParticipantJoinByInvite](/API_docs/constructors/channelAdminLogEventActionParticipantJoinByInvite.html) + +[channelAdminLogEventActionExportedInviteDelete](/API_docs/constructors/channelAdminLogEventActionExportedInviteDelete.html) + +[channelAdminLogEventActionExportedInviteRevoke](/API_docs/constructors/channelAdminLogEventActionExportedInviteRevoke.html) + +[channelAdminLogEventActionExportedInviteEdit](/API_docs/constructors/channelAdminLogEventActionExportedInviteEdit.html) + +[channelAdminLogEventActionParticipantVolume](/API_docs/constructors/channelAdminLogEventActionParticipantVolume.html) + +[channelAdminLogEventActionChangeHistoryTTL](/API_docs/constructors/channelAdminLogEventActionChangeHistoryTTL.html) + +[channelAdminLogEventActionParticipantJoinByRequest](/API_docs/constructors/channelAdminLogEventActionParticipantJoinByRequest.html) + +[channelAdminLogEventActionToggleNoForwards](/API_docs/constructors/channelAdminLogEventActionToggleNoForwards.html) + +[channelAdminLogEventActionSendMessage](/API_docs/constructors/channelAdminLogEventActionSendMessage.html) + +[channelAdminLogEventActionChangeAvailableReactions](/API_docs/constructors/channelAdminLogEventActionChangeAvailableReactions.html) + +[channelAdminLogEventActionChangeUsernames](/API_docs/constructors/channelAdminLogEventActionChangeUsernames.html) + +[channelAdminLogEventActionToggleForum](/API_docs/constructors/channelAdminLogEventActionToggleForum.html) + +[channelAdminLogEventActionCreateTopic](/API_docs/constructors/channelAdminLogEventActionCreateTopic.html) + +[channelAdminLogEventActionEditTopic](/API_docs/constructors/channelAdminLogEventActionEditTopic.html) + +[channelAdminLogEventActionDeleteTopic](/API_docs/constructors/channelAdminLogEventActionDeleteTopic.html) + +[channelAdminLogEventActionPinTopic](/API_docs/constructors/channelAdminLogEventActionPinTopic.html) + +[channelAdminLogEventActionToggleAntiSpam](/API_docs/constructors/channelAdminLogEventActionToggleAntiSpam.html) + +[channelAdminLogEventActionChangePeerColor](/API_docs/constructors/channelAdminLogEventActionChangePeerColor.html) + +[channelAdminLogEventActionChangeProfilePeerColor](/API_docs/constructors/channelAdminLogEventActionChangeProfilePeerColor.html) + +[channelAdminLogEventActionChangeWallpaper](/API_docs/constructors/channelAdminLogEventActionChangeWallpaper.html) + +[channelAdminLogEventActionChangeEmojiStatus](/API_docs/constructors/channelAdminLogEventActionChangeEmojiStatus.html) + +[channelAdminLogEventActionChangeEmojiStickerSet](/API_docs/constructors/channelAdminLogEventActionChangeEmojiStickerSet.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelAdminLogEventsFilter.md b/docs/API_docs/types/ChannelAdminLogEventsFilter.md new file mode 100644 index 0000000000..5055a183b1 --- /dev/null +++ b/docs/API_docs/types/ChannelAdminLogEventsFilter.md @@ -0,0 +1,21 @@ +--- +title: ChannelAdminLogEventsFilter +description: constructors and methods of type ChannelAdminLogEventsFilter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelAdminLogEventsFilter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelAdminLogEventsFilter](/API_docs/constructors/channelAdminLogEventsFilter.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelLocation.md b/docs/API_docs/types/ChannelLocation.md new file mode 100644 index 0000000000..82f9471986 --- /dev/null +++ b/docs/API_docs/types/ChannelLocation.md @@ -0,0 +1,23 @@ +--- +title: ChannelLocation +description: constructors and methods of type ChannelLocation +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelLocation +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelLocationEmpty](/API_docs/constructors/channelLocationEmpty.html) + +[channelLocation](/API_docs/constructors/channelLocation.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelMessagesFilter.md b/docs/API_docs/types/ChannelMessagesFilter.md new file mode 100644 index 0000000000..37b8d4dbec --- /dev/null +++ b/docs/API_docs/types/ChannelMessagesFilter.md @@ -0,0 +1,23 @@ +--- +title: ChannelMessagesFilter +description: constructors and methods of type ChannelMessagesFilter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelMessagesFilter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelMessagesFilterEmpty](/API_docs/constructors/channelMessagesFilterEmpty.html) + +[channelMessagesFilter](/API_docs/constructors/channelMessagesFilter.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelParticipant.md b/docs/API_docs/types/ChannelParticipant.md new file mode 100644 index 0000000000..8d2ca6aa54 --- /dev/null +++ b/docs/API_docs/types/ChannelParticipant.md @@ -0,0 +1,31 @@ +--- +title: ChannelParticipant +description: constructors and methods of type ChannelParticipant +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelParticipant +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelParticipant](/API_docs/constructors/channelParticipant.html) + +[channelParticipantSelf](/API_docs/constructors/channelParticipantSelf.html) + +[channelParticipantCreator](/API_docs/constructors/channelParticipantCreator.html) + +[channelParticipantAdmin](/API_docs/constructors/channelParticipantAdmin.html) + +[channelParticipantBanned](/API_docs/constructors/channelParticipantBanned.html) + +[channelParticipantLeft](/API_docs/constructors/channelParticipantLeft.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChannelParticipantsFilter.md b/docs/API_docs/types/ChannelParticipantsFilter.md new file mode 100644 index 0000000000..58db4fb25f --- /dev/null +++ b/docs/API_docs/types/ChannelParticipantsFilter.md @@ -0,0 +1,35 @@ +--- +title: ChannelParticipantsFilter +description: constructors and methods of type ChannelParticipantsFilter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChannelParticipantsFilter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channelParticipantsRecent](/API_docs/constructors/channelParticipantsRecent.html) + +[channelParticipantsAdmins](/API_docs/constructors/channelParticipantsAdmins.html) + +[channelParticipantsKicked](/API_docs/constructors/channelParticipantsKicked.html) + +[channelParticipantsBots](/API_docs/constructors/channelParticipantsBots.html) + +[channelParticipantsBanned](/API_docs/constructors/channelParticipantsBanned.html) + +[channelParticipantsSearch](/API_docs/constructors/channelParticipantsSearch.html) + +[channelParticipantsContacts](/API_docs/constructors/channelParticipantsContacts.html) + +[channelParticipantsMentions](/API_docs/constructors/channelParticipantsMentions.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Chat.md b/docs/API_docs/types/Chat.md new file mode 100644 index 0000000000..6544129580 --- /dev/null +++ b/docs/API_docs/types/Chat.md @@ -0,0 +1,64 @@ +--- +title: Chat +description: constructors and methods of type Chat +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Chat +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$Chat = '@username'; // Username + +$Chat = $update; // Update objects received in the event handler + +$Chat = 'me'; // The currently logged-in user + +$Chat = 44700; // bot API id (users) +$Chat = -492772765; // bot API id (chats) +$Chat = -10038575794; // bot API id (channels) + +$Chat = 'https://t.me/danogentili'; // t.me URLs +$Chat = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + + + +### Possible values (constructors): + +[chatEmpty](/API_docs/constructors/chatEmpty.html) + +[chat](/API_docs/constructors/chat.html) + +[chatForbidden](/API_docs/constructors/chatForbidden.html) + +[channel](/API_docs/constructors/channel.html) + +[channelForbidden](/API_docs/constructors/channelForbidden.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatAdminRights.md b/docs/API_docs/types/ChatAdminRights.md new file mode 100644 index 0000000000..ea4d3cbdd3 --- /dev/null +++ b/docs/API_docs/types/ChatAdminRights.md @@ -0,0 +1,21 @@ +--- +title: ChatAdminRights +description: constructors and methods of type ChatAdminRights +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatAdminRights +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatAdminRights](/API_docs/constructors/chatAdminRights.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatAdminWithInvites.md b/docs/API_docs/types/ChatAdminWithInvites.md new file mode 100644 index 0000000000..b3e690b105 --- /dev/null +++ b/docs/API_docs/types/ChatAdminWithInvites.md @@ -0,0 +1,21 @@ +--- +title: ChatAdminWithInvites +description: constructors and methods of type ChatAdminWithInvites +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatAdminWithInvites +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatAdminWithInvites](/API_docs/constructors/chatAdminWithInvites.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatBannedRights.md b/docs/API_docs/types/ChatBannedRights.md new file mode 100644 index 0000000000..df4d889a28 --- /dev/null +++ b/docs/API_docs/types/ChatBannedRights.md @@ -0,0 +1,21 @@ +--- +title: ChatBannedRights +description: constructors and methods of type ChatBannedRights +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatBannedRights +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatBannedRights](/API_docs/constructors/chatBannedRights.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatFull.md b/docs/API_docs/types/ChatFull.md new file mode 100644 index 0000000000..a387e04cfa --- /dev/null +++ b/docs/API_docs/types/ChatFull.md @@ -0,0 +1,23 @@ +--- +title: ChatFull +description: constructors and methods of type ChatFull +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatFull +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatFull](/API_docs/constructors/chatFull.html) + +[channelFull](/API_docs/constructors/channelFull.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatInvite.md b/docs/API_docs/types/ChatInvite.md new file mode 100644 index 0000000000..bea384c4b0 --- /dev/null +++ b/docs/API_docs/types/ChatInvite.md @@ -0,0 +1,27 @@ +--- +title: ChatInvite +description: constructors and methods of type ChatInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatInviteAlready](/API_docs/constructors/chatInviteAlready.html) + +[chatInvite](/API_docs/constructors/chatInvite.html) + +[chatInvitePeek](/API_docs/constructors/chatInvitePeek.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->checkChatInvite](/API_docs/methods/messages.checkChatInvite.html) + + + diff --git a/docs/API_docs/types/ChatInviteImporter.md b/docs/API_docs/types/ChatInviteImporter.md new file mode 100644 index 0000000000..e7696a6ec8 --- /dev/null +++ b/docs/API_docs/types/ChatInviteImporter.md @@ -0,0 +1,21 @@ +--- +title: ChatInviteImporter +description: constructors and methods of type ChatInviteImporter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatInviteImporter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatInviteImporter](/API_docs/constructors/chatInviteImporter.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatOnlines.md b/docs/API_docs/types/ChatOnlines.md new file mode 100644 index 0000000000..1d682c4e19 --- /dev/null +++ b/docs/API_docs/types/ChatOnlines.md @@ -0,0 +1,23 @@ +--- +title: ChatOnlines +description: constructors and methods of type ChatOnlines +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatOnlines +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatOnlines](/API_docs/constructors/chatOnlines.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getOnlines](/API_docs/methods/messages.getOnlines.html) + + + diff --git a/docs/API_docs/types/ChatParticipant.md b/docs/API_docs/types/ChatParticipant.md new file mode 100644 index 0000000000..bd0dd5a5ec --- /dev/null +++ b/docs/API_docs/types/ChatParticipant.md @@ -0,0 +1,25 @@ +--- +title: ChatParticipant +description: constructors and methods of type ChatParticipant +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatParticipant +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatParticipant](/API_docs/constructors/chatParticipant.html) + +[chatParticipantCreator](/API_docs/constructors/chatParticipantCreator.html) + +[chatParticipantAdmin](/API_docs/constructors/chatParticipantAdmin.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatParticipants.md b/docs/API_docs/types/ChatParticipants.md new file mode 100644 index 0000000000..d70236bbe1 --- /dev/null +++ b/docs/API_docs/types/ChatParticipants.md @@ -0,0 +1,23 @@ +--- +title: ChatParticipants +description: constructors and methods of type ChatParticipants +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatParticipants +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatParticipantsForbidden](/API_docs/constructors/chatParticipantsForbidden.html) + +[chatParticipants](/API_docs/constructors/chatParticipants.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatPhoto.md b/docs/API_docs/types/ChatPhoto.md new file mode 100644 index 0000000000..834d86e06f --- /dev/null +++ b/docs/API_docs/types/ChatPhoto.md @@ -0,0 +1,23 @@ +--- +title: ChatPhoto +description: constructors and methods of type ChatPhoto +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatPhoto +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatPhotoEmpty](/API_docs/constructors/chatPhotoEmpty.html) + +[chatPhoto](/API_docs/constructors/chatPhoto.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ChatReactions.md b/docs/API_docs/types/ChatReactions.md new file mode 100644 index 0000000000..24769cafd2 --- /dev/null +++ b/docs/API_docs/types/ChatReactions.md @@ -0,0 +1,25 @@ +--- +title: ChatReactions +description: constructors and methods of type ChatReactions +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ChatReactions +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatReactionsNone](/API_docs/constructors/chatReactionsNone.html) + +[chatReactionsAll](/API_docs/constructors/chatReactionsAll.html) + +[chatReactionsSome](/API_docs/constructors/chatReactionsSome.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/CodeSettings.md b/docs/API_docs/types/CodeSettings.md new file mode 100644 index 0000000000..4d1c33eadc --- /dev/null +++ b/docs/API_docs/types/CodeSettings.md @@ -0,0 +1,21 @@ +--- +title: CodeSettings +description: constructors and methods of type CodeSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: CodeSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[codeSettings](/API_docs/constructors/codeSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Config.md b/docs/API_docs/types/Config.md new file mode 100644 index 0000000000..7788229a0a --- /dev/null +++ b/docs/API_docs/types/Config.md @@ -0,0 +1,23 @@ +--- +title: Config +description: constructors and methods of type Config +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Config +[Back to types index](index.html) + + + +### Possible values (constructors): + +[config](/API_docs/constructors/config.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getConfig](/API_docs/methods/help.getConfig.html) + + + diff --git a/docs/API_docs/types/ConnectedBot.md b/docs/API_docs/types/ConnectedBot.md new file mode 100644 index 0000000000..c70dd09221 --- /dev/null +++ b/docs/API_docs/types/ConnectedBot.md @@ -0,0 +1,21 @@ +--- +title: ConnectedBot +description: constructors and methods of type ConnectedBot +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ConnectedBot +[Back to types index](index.html) + + + +### Possible values (constructors): + +[connectedBot](/API_docs/constructors/connectedBot.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Contact.md b/docs/API_docs/types/Contact.md new file mode 100644 index 0000000000..ba68b9c437 --- /dev/null +++ b/docs/API_docs/types/Contact.md @@ -0,0 +1,21 @@ +--- +title: Contact +description: constructors and methods of type Contact +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Contact +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contact](/API_docs/constructors/contact.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ContactBirthday.md b/docs/API_docs/types/ContactBirthday.md new file mode 100644 index 0000000000..b51374585a --- /dev/null +++ b/docs/API_docs/types/ContactBirthday.md @@ -0,0 +1,21 @@ +--- +title: ContactBirthday +description: constructors and methods of type ContactBirthday +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ContactBirthday +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contactBirthday](/API_docs/constructors/contactBirthday.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ContactStatus.md b/docs/API_docs/types/ContactStatus.md new file mode 100644 index 0000000000..eb23963c76 --- /dev/null +++ b/docs/API_docs/types/ContactStatus.md @@ -0,0 +1,23 @@ +--- +title: ContactStatus +description: constructors and methods of type ContactStatus +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ContactStatus +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contactStatus](/API_docs/constructors/contactStatus.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->getStatuses](/API_docs/methods/contacts.getStatuses.html) + + + diff --git a/docs/API_docs/types/DataJSON.md b/docs/API_docs/types/DataJSON.md new file mode 100644 index 0000000000..b7fca5c01a --- /dev/null +++ b/docs/API_docs/types/DataJSON.md @@ -0,0 +1,10 @@ +--- +title: DataJSON +description: Any json-encodable data +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: DataJSON +[Back to constructor index](index.html) + +Any json-encodable data. diff --git a/docs/API_docs/types/DcOption.md b/docs/API_docs/types/DcOption.md new file mode 100644 index 0000000000..f572409e7c --- /dev/null +++ b/docs/API_docs/types/DcOption.md @@ -0,0 +1,21 @@ +--- +title: DcOption +description: constructors and methods of type DcOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DcOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[dcOption](/API_docs/constructors/dcOption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DecryptedMessage.md b/docs/API_docs/types/DecryptedMessage.md new file mode 100644 index 0000000000..c5c4365e57 --- /dev/null +++ b/docs/API_docs/types/DecryptedMessage.md @@ -0,0 +1,31 @@ +--- +title: DecryptedMessage +description: constructors and methods of type DecryptedMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DecryptedMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[decryptedMessage\_8](/API_docs/constructors/decryptedMessage_8.html) + +[decryptedMessageService\_8](/API_docs/constructors/decryptedMessageService_8.html) + +[decryptedMessage\_17](/API_docs/constructors/decryptedMessage_17.html) + +[decryptedMessageService\_17](/API_docs/constructors/decryptedMessageService_17.html) + +[decryptedMessage\_45](/API_docs/constructors/decryptedMessage_45.html) + +[decryptedMessage\_73](/API_docs/constructors/decryptedMessage_73.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DecryptedMessageAction.md b/docs/API_docs/types/DecryptedMessageAction.md new file mode 100644 index 0000000000..801dbc9ef2 --- /dev/null +++ b/docs/API_docs/types/DecryptedMessageAction.md @@ -0,0 +1,45 @@ +--- +title: DecryptedMessageAction +description: constructors and methods of type DecryptedMessageAction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DecryptedMessageAction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[decryptedMessageActionSetMessageTTL\_8](/API_docs/constructors/decryptedMessageActionSetMessageTTL_8.html) + +[decryptedMessageActionReadMessages\_8](/API_docs/constructors/decryptedMessageActionReadMessages_8.html) + +[decryptedMessageActionDeleteMessages\_8](/API_docs/constructors/decryptedMessageActionDeleteMessages_8.html) + +[decryptedMessageActionScreenshotMessages\_8](/API_docs/constructors/decryptedMessageActionScreenshotMessages_8.html) + +[decryptedMessageActionFlushHistory\_8](/API_docs/constructors/decryptedMessageActionFlushHistory_8.html) + +[decryptedMessageActionResend\_17](/API_docs/constructors/decryptedMessageActionResend_17.html) + +[decryptedMessageActionNotifyLayer\_17](/API_docs/constructors/decryptedMessageActionNotifyLayer_17.html) + +[decryptedMessageActionTyping\_17](/API_docs/constructors/decryptedMessageActionTyping_17.html) + +[decryptedMessageActionRequestKey\_20](/API_docs/constructors/decryptedMessageActionRequestKey_20.html) + +[decryptedMessageActionAcceptKey\_20](/API_docs/constructors/decryptedMessageActionAcceptKey_20.html) + +[decryptedMessageActionAbortKey\_20](/API_docs/constructors/decryptedMessageActionAbortKey_20.html) + +[decryptedMessageActionCommitKey\_20](/API_docs/constructors/decryptedMessageActionCommitKey_20.html) + +[decryptedMessageActionNoop\_20](/API_docs/constructors/decryptedMessageActionNoop_20.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DecryptedMessageLayer.md b/docs/API_docs/types/DecryptedMessageLayer.md new file mode 100644 index 0000000000..30d24a9ef9 --- /dev/null +++ b/docs/API_docs/types/DecryptedMessageLayer.md @@ -0,0 +1,21 @@ +--- +title: DecryptedMessageLayer +description: constructors and methods of type DecryptedMessageLayer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DecryptedMessageLayer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[decryptedMessageLayer\_17](/API_docs/constructors/decryptedMessageLayer_17.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DecryptedMessageMedia.md b/docs/API_docs/types/DecryptedMessageMedia.md new file mode 100644 index 0000000000..9193bb193b --- /dev/null +++ b/docs/API_docs/types/DecryptedMessageMedia.md @@ -0,0 +1,51 @@ +--- +title: DecryptedMessageMedia +description: constructors and methods of type DecryptedMessageMedia +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DecryptedMessageMedia +[Back to types index](index.html) + + + +### Possible values (constructors): + +[decryptedMessageMediaEmpty\_8](/API_docs/constructors/decryptedMessageMediaEmpty_8.html) + +[decryptedMessageMediaPhoto\_8](/API_docs/constructors/decryptedMessageMediaPhoto_8.html) + +[decryptedMessageMediaVideo\_8](/API_docs/constructors/decryptedMessageMediaVideo_8.html) + +[decryptedMessageMediaGeoPoint\_8](/API_docs/constructors/decryptedMessageMediaGeoPoint_8.html) + +[decryptedMessageMediaContact\_8](/API_docs/constructors/decryptedMessageMediaContact_8.html) + +[decryptedMessageMediaDocument\_8](/API_docs/constructors/decryptedMessageMediaDocument_8.html) + +[decryptedMessageMediaAudio\_8](/API_docs/constructors/decryptedMessageMediaAudio_8.html) + +[decryptedMessageMediaVideo\_17](/API_docs/constructors/decryptedMessageMediaVideo_17.html) + +[decryptedMessageMediaAudio\_17](/API_docs/constructors/decryptedMessageMediaAudio_17.html) + +[decryptedMessageMediaExternalDocument\_23](/API_docs/constructors/decryptedMessageMediaExternalDocument_23.html) + +[decryptedMessageMediaPhoto\_45](/API_docs/constructors/decryptedMessageMediaPhoto_45.html) + +[decryptedMessageMediaVideo\_45](/API_docs/constructors/decryptedMessageMediaVideo_45.html) + +[decryptedMessageMediaDocument\_45](/API_docs/constructors/decryptedMessageMediaDocument_45.html) + +[decryptedMessageMediaVenue\_45](/API_docs/constructors/decryptedMessageMediaVenue_45.html) + +[decryptedMessageMediaWebPage\_45](/API_docs/constructors/decryptedMessageMediaWebPage_45.html) + +[decryptedMessageMediaDocument\_143](/API_docs/constructors/decryptedMessageMediaDocument_143.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DefaultHistoryTTL.md b/docs/API_docs/types/DefaultHistoryTTL.md new file mode 100644 index 0000000000..94907317cb --- /dev/null +++ b/docs/API_docs/types/DefaultHistoryTTL.md @@ -0,0 +1,23 @@ +--- +title: DefaultHistoryTTL +description: constructors and methods of type DefaultHistoryTTL +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DefaultHistoryTTL +[Back to types index](index.html) + + + +### Possible values (constructors): + +[defaultHistoryTTL](/API_docs/constructors/defaultHistoryTTL.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getDefaultHistoryTTL](/API_docs/methods/messages.getDefaultHistoryTTL.html) + + + diff --git a/docs/API_docs/types/Dialog.md b/docs/API_docs/types/Dialog.md new file mode 100644 index 0000000000..e1ddb6fa5b --- /dev/null +++ b/docs/API_docs/types/Dialog.md @@ -0,0 +1,23 @@ +--- +title: Dialog +description: constructors and methods of type Dialog +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Dialog +[Back to types index](index.html) + + + +### Possible values (constructors): + +[dialog](/API_docs/constructors/dialog.html) + +[dialogFolder](/API_docs/constructors/dialogFolder.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DialogFilter.md b/docs/API_docs/types/DialogFilter.md new file mode 100644 index 0000000000..3e765722a2 --- /dev/null +++ b/docs/API_docs/types/DialogFilter.md @@ -0,0 +1,25 @@ +--- +title: DialogFilter +description: constructors and methods of type DialogFilter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DialogFilter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[dialogFilter](/API_docs/constructors/dialogFilter.html) + +[dialogFilterDefault](/API_docs/constructors/dialogFilterDefault.html) + +[dialogFilterChatlist](/API_docs/constructors/dialogFilterChatlist.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DialogFilterSuggested.md b/docs/API_docs/types/DialogFilterSuggested.md new file mode 100644 index 0000000000..85c839bba6 --- /dev/null +++ b/docs/API_docs/types/DialogFilterSuggested.md @@ -0,0 +1,23 @@ +--- +title: DialogFilterSuggested +description: constructors and methods of type DialogFilterSuggested +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DialogFilterSuggested +[Back to types index](index.html) + + + +### Possible values (constructors): + +[dialogFilterSuggested](/API_docs/constructors/dialogFilterSuggested.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSuggestedDialogFilters](/API_docs/methods/messages.getSuggestedDialogFilters.html) + + + diff --git a/docs/API_docs/types/DialogPeer.md b/docs/API_docs/types/DialogPeer.md new file mode 100644 index 0000000000..0c0e9a7935 --- /dev/null +++ b/docs/API_docs/types/DialogPeer.md @@ -0,0 +1,25 @@ +--- +title: DialogPeer +description: constructors and methods of type DialogPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DialogPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[dialogPeer](/API_docs/constructors/dialogPeer.html) + +[dialogPeerFolder](/API_docs/constructors/dialogPeerFolder.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getDialogUnreadMarks](/API_docs/methods/messages.getDialogUnreadMarks.html) + + + diff --git a/docs/API_docs/types/Document.md b/docs/API_docs/types/Document.md new file mode 100644 index 0000000000..3b4c27c38a --- /dev/null +++ b/docs/API_docs/types/Document.md @@ -0,0 +1,31 @@ +--- +title: Document +description: constructors and methods of type Document +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Document +[Back to types index](index.html) + + + +### Possible values (constructors): + +[documentEmpty](/API_docs/constructors/documentEmpty.html) + +[document](/API_docs/constructors/document.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->uploadTheme](/API_docs/methods/account.uploadTheme.html) + +[$MadelineProto->account->uploadRingtone](/API_docs/methods/account.uploadRingtone.html) + +[$MadelineProto->messages->getDocumentByHash](/API_docs/methods/messages.getDocumentByHash.html) + +[$MadelineProto->messages->getCustomEmojiDocuments](/API_docs/methods/messages.getCustomEmojiDocuments.html) + + + diff --git a/docs/API_docs/types/DocumentAttribute.md b/docs/API_docs/types/DocumentAttribute.md new file mode 100644 index 0000000000..a63c36ac2a --- /dev/null +++ b/docs/API_docs/types/DocumentAttribute.md @@ -0,0 +1,47 @@ +--- +title: DocumentAttribute +description: constructors and methods of type DocumentAttribute +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DocumentAttribute +[Back to types index](index.html) + + + +### Possible values (constructors): + +[documentAttributeImageSize](/API_docs/constructors/documentAttributeImageSize.html) + +[documentAttributeAnimated](/API_docs/constructors/documentAttributeAnimated.html) + +[documentAttributeSticker](/API_docs/constructors/documentAttributeSticker.html) + +[documentAttributeVideo](/API_docs/constructors/documentAttributeVideo.html) + +[documentAttributeAudio](/API_docs/constructors/documentAttributeAudio.html) + +[documentAttributeFilename](/API_docs/constructors/documentAttributeFilename.html) + +[documentAttributeHasStickers](/API_docs/constructors/documentAttributeHasStickers.html) + +[documentAttributeCustomEmoji](/API_docs/constructors/documentAttributeCustomEmoji.html) + +[documentAttributeSticker\_23](/API_docs/constructors/documentAttributeSticker_23.html) + +[documentAttributeVideo\_23](/API_docs/constructors/documentAttributeVideo_23.html) + +[documentAttributeAudio\_23](/API_docs/constructors/documentAttributeAudio_23.html) + +[documentAttributeSticker\_45](/API_docs/constructors/documentAttributeSticker_45.html) + +[documentAttributeAudio\_45](/API_docs/constructors/documentAttributeAudio_45.html) + +[documentAttributeVideo\_66](/API_docs/constructors/documentAttributeVideo_66.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/DraftMessage.md b/docs/API_docs/types/DraftMessage.md new file mode 100644 index 0000000000..98cc6a49f6 --- /dev/null +++ b/docs/API_docs/types/DraftMessage.md @@ -0,0 +1,23 @@ +--- +title: DraftMessage +description: constructors and methods of type DraftMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: DraftMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[draftMessageEmpty](/API_docs/constructors/draftMessageEmpty.html) + +[draftMessage](/API_docs/constructors/draftMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/EmailVerification.md b/docs/API_docs/types/EmailVerification.md new file mode 100644 index 0000000000..f20b90a369 --- /dev/null +++ b/docs/API_docs/types/EmailVerification.md @@ -0,0 +1,25 @@ +--- +title: EmailVerification +description: constructors and methods of type EmailVerification +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmailVerification +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emailVerificationCode](/API_docs/constructors/emailVerificationCode.html) + +[emailVerificationGoogle](/API_docs/constructors/emailVerificationGoogle.html) + +[emailVerificationApple](/API_docs/constructors/emailVerificationApple.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/EmailVerifyPurpose.md b/docs/API_docs/types/EmailVerifyPurpose.md new file mode 100644 index 0000000000..581bbc9640 --- /dev/null +++ b/docs/API_docs/types/EmailVerifyPurpose.md @@ -0,0 +1,25 @@ +--- +title: EmailVerifyPurpose +description: constructors and methods of type EmailVerifyPurpose +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmailVerifyPurpose +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emailVerifyPurposeLoginSetup](/API_docs/constructors/emailVerifyPurposeLoginSetup.html) + +[emailVerifyPurposeLoginChange](/API_docs/constructors/emailVerifyPurposeLoginChange.html) + +[emailVerifyPurposePassport](/API_docs/constructors/emailVerifyPurposePassport.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/EmojiGroup.md b/docs/API_docs/types/EmojiGroup.md new file mode 100644 index 0000000000..3ba53f5ea6 --- /dev/null +++ b/docs/API_docs/types/EmojiGroup.md @@ -0,0 +1,25 @@ +--- +title: EmojiGroup +description: constructors and methods of type EmojiGroup +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiGroup +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiGroup](/API_docs/constructors/emojiGroup.html) + +[emojiGroupGreeting](/API_docs/constructors/emojiGroupGreeting.html) + +[emojiGroupPremium](/API_docs/constructors/emojiGroupPremium.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/EmojiKeyword.md b/docs/API_docs/types/EmojiKeyword.md new file mode 100644 index 0000000000..fe5bcd64e2 --- /dev/null +++ b/docs/API_docs/types/EmojiKeyword.md @@ -0,0 +1,23 @@ +--- +title: EmojiKeyword +description: constructors and methods of type EmojiKeyword +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiKeyword +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiKeyword](/API_docs/constructors/emojiKeyword.html) + +[emojiKeywordDeleted](/API_docs/constructors/emojiKeywordDeleted.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/EmojiKeywordsDifference.md b/docs/API_docs/types/EmojiKeywordsDifference.md new file mode 100644 index 0000000000..f0a0dc5bb6 --- /dev/null +++ b/docs/API_docs/types/EmojiKeywordsDifference.md @@ -0,0 +1,25 @@ +--- +title: EmojiKeywordsDifference +description: constructors and methods of type EmojiKeywordsDifference +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiKeywordsDifference +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiKeywordsDifference](/API_docs/constructors/emojiKeywordsDifference.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getEmojiKeywords](/API_docs/methods/messages.getEmojiKeywords.html) + +[$MadelineProto->messages->getEmojiKeywordsDifference](/API_docs/methods/messages.getEmojiKeywordsDifference.html) + + + diff --git a/docs/API_docs/types/EmojiLanguage.md b/docs/API_docs/types/EmojiLanguage.md new file mode 100644 index 0000000000..9458c06056 --- /dev/null +++ b/docs/API_docs/types/EmojiLanguage.md @@ -0,0 +1,23 @@ +--- +title: EmojiLanguage +description: constructors and methods of type EmojiLanguage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiLanguage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiLanguage](/API_docs/constructors/emojiLanguage.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getEmojiKeywordsLanguages](/API_docs/methods/messages.getEmojiKeywordsLanguages.html) + + + diff --git a/docs/API_docs/types/EmojiList.md b/docs/API_docs/types/EmojiList.md new file mode 100644 index 0000000000..154023a82b --- /dev/null +++ b/docs/API_docs/types/EmojiList.md @@ -0,0 +1,33 @@ +--- +title: EmojiList +description: constructors and methods of type EmojiList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiListNotModified](/API_docs/constructors/emojiListNotModified.html) + +[emojiList](/API_docs/constructors/emojiList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getDefaultProfilePhotoEmojis](/API_docs/methods/account.getDefaultProfilePhotoEmojis.html) + +[$MadelineProto->account->getDefaultGroupPhotoEmojis](/API_docs/methods/account.getDefaultGroupPhotoEmojis.html) + +[$MadelineProto->account->getDefaultBackgroundEmojis](/API_docs/methods/account.getDefaultBackgroundEmojis.html) + +[$MadelineProto->account->getChannelRestrictedStatusEmojis](/API_docs/methods/account.getChannelRestrictedStatusEmojis.html) + +[$MadelineProto->messages->searchCustomEmoji](/API_docs/methods/messages.searchCustomEmoji.html) + + + diff --git a/docs/API_docs/types/EmojiStatus.md b/docs/API_docs/types/EmojiStatus.md new file mode 100644 index 0000000000..433abb8b1a --- /dev/null +++ b/docs/API_docs/types/EmojiStatus.md @@ -0,0 +1,25 @@ +--- +title: EmojiStatus +description: constructors and methods of type EmojiStatus +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiStatus +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiStatusEmpty](/API_docs/constructors/emojiStatusEmpty.html) + +[emojiStatus](/API_docs/constructors/emojiStatus.html) + +[emojiStatusUntil](/API_docs/constructors/emojiStatusUntil.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/EmojiURL.md b/docs/API_docs/types/EmojiURL.md new file mode 100644 index 0000000000..6b95de772c --- /dev/null +++ b/docs/API_docs/types/EmojiURL.md @@ -0,0 +1,23 @@ +--- +title: EmojiURL +description: constructors and methods of type EmojiURL +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EmojiURL +[Back to types index](index.html) + + + +### Possible values (constructors): + +[emojiURL](/API_docs/constructors/emojiURL.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getEmojiURL](/API_docs/methods/messages.getEmojiURL.html) + + + diff --git a/docs/API_docs/types/EncryptedChat.md b/docs/API_docs/types/EncryptedChat.md new file mode 100644 index 0000000000..120695d61b --- /dev/null +++ b/docs/API_docs/types/EncryptedChat.md @@ -0,0 +1,33 @@ +--- +title: EncryptedChat +description: constructors and methods of type EncryptedChat +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EncryptedChat +[Back to types index](index.html) + + + +### Possible values (constructors): + +[encryptedChatEmpty](/API_docs/constructors/encryptedChatEmpty.html) + +[encryptedChatWaiting](/API_docs/constructors/encryptedChatWaiting.html) + +[encryptedChatRequested](/API_docs/constructors/encryptedChatRequested.html) + +[encryptedChat](/API_docs/constructors/encryptedChat.html) + +[encryptedChatDiscarded](/API_docs/constructors/encryptedChatDiscarded.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->requestEncryption](/API_docs/methods/messages.requestEncryption.html) + +[$MadelineProto->messages->acceptEncryption](/API_docs/methods/messages.acceptEncryption.html) + + + diff --git a/docs/API_docs/types/EncryptedFile.md b/docs/API_docs/types/EncryptedFile.md new file mode 100644 index 0000000000..8e7957a0a7 --- /dev/null +++ b/docs/API_docs/types/EncryptedFile.md @@ -0,0 +1,25 @@ +--- +title: EncryptedFile +description: constructors and methods of type EncryptedFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EncryptedFile +[Back to types index](index.html) + + + +### Possible values (constructors): + +[encryptedFileEmpty](/API_docs/constructors/encryptedFileEmpty.html) + +[encryptedFile](/API_docs/constructors/encryptedFile.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->uploadEncryptedFile](/API_docs/methods/messages.uploadEncryptedFile.html) + + + diff --git a/docs/API_docs/types/EncryptedMessage.md b/docs/API_docs/types/EncryptedMessage.md new file mode 100644 index 0000000000..49fc8ae76c --- /dev/null +++ b/docs/API_docs/types/EncryptedMessage.md @@ -0,0 +1,23 @@ +--- +title: EncryptedMessage +description: constructors and methods of type EncryptedMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: EncryptedMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[encryptedMessage](/API_docs/constructors/encryptedMessage.html) + +[encryptedMessageService](/API_docs/constructors/encryptedMessageService.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Error.md b/docs/API_docs/types/Error.md new file mode 100644 index 0000000000..2f00003790 --- /dev/null +++ b/docs/API_docs/types/Error.md @@ -0,0 +1,21 @@ +--- +title: Error +description: constructors and methods of type Error +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Error +[Back to types index](index.html) + + + +### Possible values (constructors): + +[error](/API_docs/constructors/error.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ExportedChatInvite.md b/docs/API_docs/types/ExportedChatInvite.md new file mode 100644 index 0000000000..7c0c7f8267 --- /dev/null +++ b/docs/API_docs/types/ExportedChatInvite.md @@ -0,0 +1,25 @@ +--- +title: ExportedChatInvite +description: constructors and methods of type ExportedChatInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ExportedChatInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatInviteExported](/API_docs/constructors/chatInviteExported.html) + +[chatInvitePublicJoinRequests](/API_docs/constructors/chatInvitePublicJoinRequests.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->exportChatInvite](/API_docs/methods/messages.exportChatInvite.html) + + + diff --git a/docs/API_docs/types/ExportedChatlistInvite.md b/docs/API_docs/types/ExportedChatlistInvite.md new file mode 100644 index 0000000000..0a39acd21d --- /dev/null +++ b/docs/API_docs/types/ExportedChatlistInvite.md @@ -0,0 +1,23 @@ +--- +title: ExportedChatlistInvite +description: constructors and methods of type ExportedChatlistInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ExportedChatlistInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[exportedChatlistInvite](/API_docs/constructors/exportedChatlistInvite.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->chatlists->editExportedInvite](/API_docs/methods/chatlists.editExportedInvite.html) + + + diff --git a/docs/API_docs/types/ExportedContactToken.md b/docs/API_docs/types/ExportedContactToken.md new file mode 100644 index 0000000000..f0f6f787a5 --- /dev/null +++ b/docs/API_docs/types/ExportedContactToken.md @@ -0,0 +1,23 @@ +--- +title: ExportedContactToken +description: constructors and methods of type ExportedContactToken +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ExportedContactToken +[Back to types index](index.html) + + + +### Possible values (constructors): + +[exportedContactToken](/API_docs/constructors/exportedContactToken.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->exportContactToken](/API_docs/methods/contacts.exportContactToken.html) + + + diff --git a/docs/API_docs/types/ExportedMessageLink.md b/docs/API_docs/types/ExportedMessageLink.md new file mode 100644 index 0000000000..d160fcaae4 --- /dev/null +++ b/docs/API_docs/types/ExportedMessageLink.md @@ -0,0 +1,23 @@ +--- +title: ExportedMessageLink +description: constructors and methods of type ExportedMessageLink +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ExportedMessageLink +[Back to types index](index.html) + + + +### Possible values (constructors): + +[exportedMessageLink](/API_docs/constructors/exportedMessageLink.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->exportMessageLink](/API_docs/methods/channels.exportMessageLink.html) + + + diff --git a/docs/API_docs/types/ExportedStoryLink.md b/docs/API_docs/types/ExportedStoryLink.md new file mode 100644 index 0000000000..eaa6810e18 --- /dev/null +++ b/docs/API_docs/types/ExportedStoryLink.md @@ -0,0 +1,23 @@ +--- +title: ExportedStoryLink +description: constructors and methods of type ExportedStoryLink +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ExportedStoryLink +[Back to types index](index.html) + + + +### Possible values (constructors): + +[exportedStoryLink](/API_docs/constructors/exportedStoryLink.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->exportStoryLink](/API_docs/methods/stories.exportStoryLink.html) + + + diff --git a/docs/API_docs/types/FileHash.md b/docs/API_docs/types/FileHash.md new file mode 100644 index 0000000000..77fb65b3f4 --- /dev/null +++ b/docs/API_docs/types/FileHash.md @@ -0,0 +1,27 @@ +--- +title: FileHash +description: constructors and methods of type FileHash +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: FileHash +[Back to types index](index.html) + + + +### Possible values (constructors): + +[fileHash](/API_docs/constructors/fileHash.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->upload->reuploadCdnFile](/API_docs/methods/upload.reuploadCdnFile.html) + +[$MadelineProto->upload->getCdnFileHashes](/API_docs/methods/upload.getCdnFileHashes.html) + +[$MadelineProto->upload->getFileHashes](/API_docs/methods/upload.getFileHashes.html) + + + diff --git a/docs/API_docs/types/FileLocation.md b/docs/API_docs/types/FileLocation.md new file mode 100644 index 0000000000..1b557ac3ac --- /dev/null +++ b/docs/API_docs/types/FileLocation.md @@ -0,0 +1,23 @@ +--- +title: FileLocation +description: constructors and methods of type FileLocation +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: FileLocation +[Back to types index](index.html) + + + +### Possible values (constructors): + +[fileLocationUnavailable\_23](/API_docs/constructors/fileLocationUnavailable_23.html) + +[fileLocation\_23](/API_docs/constructors/fileLocation_23.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Folder.md b/docs/API_docs/types/Folder.md new file mode 100644 index 0000000000..1aefcad60b --- /dev/null +++ b/docs/API_docs/types/Folder.md @@ -0,0 +1,21 @@ +--- +title: Folder +description: constructors and methods of type Folder +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Folder +[Back to types index](index.html) + + + +### Possible values (constructors): + +[folder](/API_docs/constructors/folder.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/FolderPeer.md b/docs/API_docs/types/FolderPeer.md new file mode 100644 index 0000000000..8d22ccec8a --- /dev/null +++ b/docs/API_docs/types/FolderPeer.md @@ -0,0 +1,21 @@ +--- +title: FolderPeer +description: constructors and methods of type FolderPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: FolderPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[folderPeer](/API_docs/constructors/folderPeer.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ForumTopic.md b/docs/API_docs/types/ForumTopic.md new file mode 100644 index 0000000000..2423162189 --- /dev/null +++ b/docs/API_docs/types/ForumTopic.md @@ -0,0 +1,23 @@ +--- +title: ForumTopic +description: constructors and methods of type ForumTopic +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ForumTopic +[Back to types index](index.html) + + + +### Possible values (constructors): + +[forumTopicDeleted](/API_docs/constructors/forumTopicDeleted.html) + +[forumTopic](/API_docs/constructors/forumTopic.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Game.md b/docs/API_docs/types/Game.md new file mode 100644 index 0000000000..b84d253dd0 --- /dev/null +++ b/docs/API_docs/types/Game.md @@ -0,0 +1,21 @@ +--- +title: Game +description: constructors and methods of type Game +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Game +[Back to types index](index.html) + + + +### Possible values (constructors): + +[game](/API_docs/constructors/game.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/GeoPoint.md b/docs/API_docs/types/GeoPoint.md new file mode 100644 index 0000000000..bd8e527d92 --- /dev/null +++ b/docs/API_docs/types/GeoPoint.md @@ -0,0 +1,23 @@ +--- +title: GeoPoint +description: constructors and methods of type GeoPoint +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GeoPoint +[Back to types index](index.html) + + + +### Possible values (constructors): + +[geoPointEmpty](/API_docs/constructors/geoPointEmpty.html) + +[geoPoint](/API_docs/constructors/geoPoint.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/GlobalPrivacySettings.md b/docs/API_docs/types/GlobalPrivacySettings.md new file mode 100644 index 0000000000..55cebb5683 --- /dev/null +++ b/docs/API_docs/types/GlobalPrivacySettings.md @@ -0,0 +1,25 @@ +--- +title: GlobalPrivacySettings +description: constructors and methods of type GlobalPrivacySettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GlobalPrivacySettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[globalPrivacySettings](/API_docs/constructors/globalPrivacySettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getGlobalPrivacySettings](/API_docs/methods/account.getGlobalPrivacySettings.html) + +[$MadelineProto->account->setGlobalPrivacySettings](/API_docs/methods/account.setGlobalPrivacySettings.html) + + + diff --git a/docs/API_docs/types/GroupCall.md b/docs/API_docs/types/GroupCall.md new file mode 100644 index 0000000000..c8d61fc7ac --- /dev/null +++ b/docs/API_docs/types/GroupCall.md @@ -0,0 +1,23 @@ +--- +title: GroupCall +description: constructors and methods of type GroupCall +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GroupCall +[Back to types index](index.html) + + + +### Possible values (constructors): + +[groupCallDiscarded](/API_docs/constructors/groupCallDiscarded.html) + +[groupCall](/API_docs/constructors/groupCall.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/GroupCallParticipant.md b/docs/API_docs/types/GroupCallParticipant.md new file mode 100644 index 0000000000..889d7f464f --- /dev/null +++ b/docs/API_docs/types/GroupCallParticipant.md @@ -0,0 +1,21 @@ +--- +title: GroupCallParticipant +description: constructors and methods of type GroupCallParticipant +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GroupCallParticipant +[Back to types index](index.html) + + + +### Possible values (constructors): + +[groupCallParticipant](/API_docs/constructors/groupCallParticipant.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/GroupCallParticipantVideo.md b/docs/API_docs/types/GroupCallParticipantVideo.md new file mode 100644 index 0000000000..ae06303280 --- /dev/null +++ b/docs/API_docs/types/GroupCallParticipantVideo.md @@ -0,0 +1,21 @@ +--- +title: GroupCallParticipantVideo +description: constructors and methods of type GroupCallParticipantVideo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GroupCallParticipantVideo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[groupCallParticipantVideo](/API_docs/constructors/groupCallParticipantVideo.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/GroupCallParticipantVideoSourceGroup.md b/docs/API_docs/types/GroupCallParticipantVideoSourceGroup.md new file mode 100644 index 0000000000..3413cae030 --- /dev/null +++ b/docs/API_docs/types/GroupCallParticipantVideoSourceGroup.md @@ -0,0 +1,21 @@ +--- +title: GroupCallParticipantVideoSourceGroup +description: constructors and methods of type GroupCallParticipantVideoSourceGroup +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GroupCallParticipantVideoSourceGroup +[Back to types index](index.html) + + + +### Possible values (constructors): + +[groupCallParticipantVideoSourceGroup](/API_docs/constructors/groupCallParticipantVideoSourceGroup.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/GroupCallStreamChannel.md b/docs/API_docs/types/GroupCallStreamChannel.md new file mode 100644 index 0000000000..726c45fd71 --- /dev/null +++ b/docs/API_docs/types/GroupCallStreamChannel.md @@ -0,0 +1,21 @@ +--- +title: GroupCallStreamChannel +description: constructors and methods of type GroupCallStreamChannel +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: GroupCallStreamChannel +[Back to types index](index.html) + + + +### Possible values (constructors): + +[groupCallStreamChannel](/API_docs/constructors/groupCallStreamChannel.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/HighScore.md b/docs/API_docs/types/HighScore.md new file mode 100644 index 0000000000..e7492bb596 --- /dev/null +++ b/docs/API_docs/types/HighScore.md @@ -0,0 +1,21 @@ +--- +title: HighScore +description: constructors and methods of type HighScore +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: HighScore +[Back to types index](index.html) + + + +### Possible values (constructors): + +[highScore](/API_docs/constructors/highScore.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ImportedContact.md b/docs/API_docs/types/ImportedContact.md new file mode 100644 index 0000000000..901f54b0e1 --- /dev/null +++ b/docs/API_docs/types/ImportedContact.md @@ -0,0 +1,21 @@ +--- +title: ImportedContact +description: constructors and methods of type ImportedContact +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ImportedContact +[Back to types index](index.html) + + + +### Possible values (constructors): + +[importedContact](/API_docs/constructors/importedContact.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InlineBotSwitchPM.md b/docs/API_docs/types/InlineBotSwitchPM.md new file mode 100644 index 0000000000..f734613c5a --- /dev/null +++ b/docs/API_docs/types/InlineBotSwitchPM.md @@ -0,0 +1,21 @@ +--- +title: InlineBotSwitchPM +description: constructors and methods of type InlineBotSwitchPM +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InlineBotSwitchPM +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inlineBotSwitchPM](/API_docs/constructors/inlineBotSwitchPM.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InlineBotWebView.md b/docs/API_docs/types/InlineBotWebView.md new file mode 100644 index 0000000000..13197cd834 --- /dev/null +++ b/docs/API_docs/types/InlineBotWebView.md @@ -0,0 +1,21 @@ +--- +title: InlineBotWebView +description: constructors and methods of type InlineBotWebView +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InlineBotWebView +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inlineBotWebView](/API_docs/constructors/inlineBotWebView.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InlineQueryPeerType.md b/docs/API_docs/types/InlineQueryPeerType.md new file mode 100644 index 0000000000..8285d88022 --- /dev/null +++ b/docs/API_docs/types/InlineQueryPeerType.md @@ -0,0 +1,31 @@ +--- +title: InlineQueryPeerType +description: constructors and methods of type InlineQueryPeerType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InlineQueryPeerType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inlineQueryPeerTypeSameBotPM](/API_docs/constructors/inlineQueryPeerTypeSameBotPM.html) + +[inlineQueryPeerTypePM](/API_docs/constructors/inlineQueryPeerTypePM.html) + +[inlineQueryPeerTypeChat](/API_docs/constructors/inlineQueryPeerTypeChat.html) + +[inlineQueryPeerTypeMegagroup](/API_docs/constructors/inlineQueryPeerTypeMegagroup.html) + +[inlineQueryPeerTypeBroadcast](/API_docs/constructors/inlineQueryPeerTypeBroadcast.html) + +[inlineQueryPeerTypeBotPM](/API_docs/constructors/inlineQueryPeerTypeBotPM.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputAppEvent.md b/docs/API_docs/types/InputAppEvent.md new file mode 100644 index 0000000000..648c14bacd --- /dev/null +++ b/docs/API_docs/types/InputAppEvent.md @@ -0,0 +1,21 @@ +--- +title: InputAppEvent +description: constructors and methods of type InputAppEvent +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputAppEvent +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputAppEvent](/API_docs/constructors/inputAppEvent.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBotApp.md b/docs/API_docs/types/InputBotApp.md new file mode 100644 index 0000000000..530a4070ce --- /dev/null +++ b/docs/API_docs/types/InputBotApp.md @@ -0,0 +1,23 @@ +--- +title: InputBotApp +description: constructors and methods of type InputBotApp +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBotApp +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBotAppID](/API_docs/constructors/inputBotAppID.html) + +[inputBotAppShortName](/API_docs/constructors/inputBotAppShortName.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBotInlineMessage.md b/docs/API_docs/types/InputBotInlineMessage.md new file mode 100644 index 0000000000..f9e430f8aa --- /dev/null +++ b/docs/API_docs/types/InputBotInlineMessage.md @@ -0,0 +1,35 @@ +--- +title: InputBotInlineMessage +description: constructors and methods of type InputBotInlineMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBotInlineMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBotInlineMessageMediaAuto](/API_docs/constructors/inputBotInlineMessageMediaAuto.html) + +[inputBotInlineMessageText](/API_docs/constructors/inputBotInlineMessageText.html) + +[inputBotInlineMessageMediaGeo](/API_docs/constructors/inputBotInlineMessageMediaGeo.html) + +[inputBotInlineMessageMediaVenue](/API_docs/constructors/inputBotInlineMessageMediaVenue.html) + +[inputBotInlineMessageMediaContact](/API_docs/constructors/inputBotInlineMessageMediaContact.html) + +[inputBotInlineMessageGame](/API_docs/constructors/inputBotInlineMessageGame.html) + +[inputBotInlineMessageMediaInvoice](/API_docs/constructors/inputBotInlineMessageMediaInvoice.html) + +[inputBotInlineMessageMediaWebPage](/API_docs/constructors/inputBotInlineMessageMediaWebPage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBotInlineMessageID.md b/docs/API_docs/types/InputBotInlineMessageID.md new file mode 100644 index 0000000000..403200b154 --- /dev/null +++ b/docs/API_docs/types/InputBotInlineMessageID.md @@ -0,0 +1,23 @@ +--- +title: InputBotInlineMessageID +description: constructors and methods of type InputBotInlineMessageID +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBotInlineMessageID +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBotInlineMessageID](/API_docs/constructors/inputBotInlineMessageID.html) + +[inputBotInlineMessageID64](/API_docs/constructors/inputBotInlineMessageID64.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBotInlineResult.md b/docs/API_docs/types/InputBotInlineResult.md new file mode 100644 index 0000000000..3607c97918 --- /dev/null +++ b/docs/API_docs/types/InputBotInlineResult.md @@ -0,0 +1,27 @@ +--- +title: InputBotInlineResult +description: constructors and methods of type InputBotInlineResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBotInlineResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBotInlineResult](/API_docs/constructors/inputBotInlineResult.html) + +[inputBotInlineResultPhoto](/API_docs/constructors/inputBotInlineResultPhoto.html) + +[inputBotInlineResultDocument](/API_docs/constructors/inputBotInlineResultDocument.html) + +[inputBotInlineResultGame](/API_docs/constructors/inputBotInlineResultGame.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBusinessAwayMessage.md b/docs/API_docs/types/InputBusinessAwayMessage.md new file mode 100644 index 0000000000..a934a525f8 --- /dev/null +++ b/docs/API_docs/types/InputBusinessAwayMessage.md @@ -0,0 +1,21 @@ +--- +title: InputBusinessAwayMessage +description: constructors and methods of type InputBusinessAwayMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBusinessAwayMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBusinessAwayMessage](/API_docs/constructors/inputBusinessAwayMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBusinessBotRecipients.md b/docs/API_docs/types/InputBusinessBotRecipients.md new file mode 100644 index 0000000000..73821621d5 --- /dev/null +++ b/docs/API_docs/types/InputBusinessBotRecipients.md @@ -0,0 +1,21 @@ +--- +title: InputBusinessBotRecipients +description: constructors and methods of type InputBusinessBotRecipients +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBusinessBotRecipients +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBusinessBotRecipients](/API_docs/constructors/inputBusinessBotRecipients.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBusinessChatLink.md b/docs/API_docs/types/InputBusinessChatLink.md new file mode 100644 index 0000000000..8834af6481 --- /dev/null +++ b/docs/API_docs/types/InputBusinessChatLink.md @@ -0,0 +1,21 @@ +--- +title: InputBusinessChatLink +description: constructors and methods of type InputBusinessChatLink +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBusinessChatLink +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBusinessChatLink](/API_docs/constructors/inputBusinessChatLink.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBusinessGreetingMessage.md b/docs/API_docs/types/InputBusinessGreetingMessage.md new file mode 100644 index 0000000000..3cfa55ce28 --- /dev/null +++ b/docs/API_docs/types/InputBusinessGreetingMessage.md @@ -0,0 +1,21 @@ +--- +title: InputBusinessGreetingMessage +description: constructors and methods of type InputBusinessGreetingMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBusinessGreetingMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBusinessGreetingMessage](/API_docs/constructors/inputBusinessGreetingMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBusinessIntro.md b/docs/API_docs/types/InputBusinessIntro.md new file mode 100644 index 0000000000..1f3cdd9445 --- /dev/null +++ b/docs/API_docs/types/InputBusinessIntro.md @@ -0,0 +1,21 @@ +--- +title: InputBusinessIntro +description: constructors and methods of type InputBusinessIntro +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBusinessIntro +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBusinessIntro](/API_docs/constructors/inputBusinessIntro.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputBusinessRecipients.md b/docs/API_docs/types/InputBusinessRecipients.md new file mode 100644 index 0000000000..ad7572d4fa --- /dev/null +++ b/docs/API_docs/types/InputBusinessRecipients.md @@ -0,0 +1,21 @@ +--- +title: InputBusinessRecipients +description: constructors and methods of type InputBusinessRecipients +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputBusinessRecipients +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputBusinessRecipients](/API_docs/constructors/inputBusinessRecipients.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputChannel.md b/docs/API_docs/types/InputChannel.md new file mode 100644 index 0000000000..4771388ae1 --- /dev/null +++ b/docs/API_docs/types/InputChannel.md @@ -0,0 +1,60 @@ +--- +title: InputChannel +description: constructors and methods of type InputChannel +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputChannel +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$InputChannel = '@username'; // Username + +$InputChannel = $update; // Update objects received in the event handler + +$InputChannel = 'me'; // The currently logged-in user + +$InputChannel = 44700; // bot API id (users) +$InputChannel = -492772765; // bot API id (chats) +$InputChannel = -10038575794; // bot API id (channels) + +$InputChannel = 'https://t.me/danogentili'; // t.me URLs +$InputChannel = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + + + +### Possible values (constructors): + +[inputChannelEmpty](/API_docs/constructors/inputChannelEmpty.html) + +[inputChannel](/API_docs/constructors/inputChannel.html) + +[inputChannelFromMessage](/API_docs/constructors/inputChannelFromMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputChatPhoto.md b/docs/API_docs/types/InputChatPhoto.md new file mode 100644 index 0000000000..f98a248cfe --- /dev/null +++ b/docs/API_docs/types/InputChatPhoto.md @@ -0,0 +1,25 @@ +--- +title: InputChatPhoto +description: constructors and methods of type InputChatPhoto +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputChatPhoto +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputChatPhotoEmpty](/API_docs/constructors/inputChatPhotoEmpty.html) + +[inputChatUploadedPhoto](/API_docs/constructors/inputChatUploadedPhoto.html) + +[inputChatPhoto](/API_docs/constructors/inputChatPhoto.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputChatlist.md b/docs/API_docs/types/InputChatlist.md new file mode 100644 index 0000000000..631f2fbae1 --- /dev/null +++ b/docs/API_docs/types/InputChatlist.md @@ -0,0 +1,21 @@ +--- +title: InputChatlist +description: constructors and methods of type InputChatlist +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputChatlist +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputChatlistDialogFilter](/API_docs/constructors/inputChatlistDialogFilter.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputCheckPasswordSRP.md b/docs/API_docs/types/InputCheckPasswordSRP.md new file mode 100644 index 0000000000..b1e345951c --- /dev/null +++ b/docs/API_docs/types/InputCheckPasswordSRP.md @@ -0,0 +1,24 @@ +--- +title: InputCheckPasswordSRP +description: constructors and methods of type InputCheckPasswordSRP +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputCheckPasswordSRP +[Back to types index](index.html) + +You can also directly provide a password as a string. + + +### Possible values (constructors): + +[inputCheckPasswordEmpty](/API_docs/constructors/inputCheckPasswordEmpty.html) + +[inputCheckPasswordSRP](/API_docs/constructors/inputCheckPasswordSRP.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputClientProxy.md b/docs/API_docs/types/InputClientProxy.md new file mode 100644 index 0000000000..96efd47f5d --- /dev/null +++ b/docs/API_docs/types/InputClientProxy.md @@ -0,0 +1,21 @@ +--- +title: InputClientProxy +description: constructors and methods of type InputClientProxy +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputClientProxy +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputClientProxy](/API_docs/constructors/inputClientProxy.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputCollectible.md b/docs/API_docs/types/InputCollectible.md new file mode 100644 index 0000000000..fd712dde7b --- /dev/null +++ b/docs/API_docs/types/InputCollectible.md @@ -0,0 +1,23 @@ +--- +title: InputCollectible +description: constructors and methods of type InputCollectible +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputCollectible +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputCollectibleUsername](/API_docs/constructors/inputCollectibleUsername.html) + +[inputCollectiblePhone](/API_docs/constructors/inputCollectiblePhone.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputContact.md b/docs/API_docs/types/InputContact.md new file mode 100644 index 0000000000..47f83d66ce --- /dev/null +++ b/docs/API_docs/types/InputContact.md @@ -0,0 +1,21 @@ +--- +title: InputContact +description: constructors and methods of type InputContact +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputContact +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputPhoneContact](/API_docs/constructors/inputPhoneContact.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputDialogPeer.md b/docs/API_docs/types/InputDialogPeer.md new file mode 100644 index 0000000000..dfdaa31af8 --- /dev/null +++ b/docs/API_docs/types/InputDialogPeer.md @@ -0,0 +1,23 @@ +--- +title: InputDialogPeer +description: constructors and methods of type InputDialogPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputDialogPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputDialogPeer](/API_docs/constructors/inputDialogPeer.html) + +[inputDialogPeerFolder](/API_docs/constructors/inputDialogPeerFolder.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputDocument.md b/docs/API_docs/types/InputDocument.md new file mode 100644 index 0000000000..17216eb0cb --- /dev/null +++ b/docs/API_docs/types/InputDocument.md @@ -0,0 +1,24 @@ +--- +title: InputDocument +description: constructors and methods of type InputDocument +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputDocument +[Back to types index](index.html) + +You can also provide a [MessageMedia](MessageMedia.html), [Message](Message.html), [Update](Update.html), [Document](Document.html) here, MadelineProto will automatically convert it to the right type. + + +### Possible values (constructors): + +[inputDocumentEmpty](/API_docs/constructors/inputDocumentEmpty.html) + +[inputDocument](/API_docs/constructors/inputDocument.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputEncryptedChat.md b/docs/API_docs/types/InputEncryptedChat.md new file mode 100644 index 0000000000..ffb13f7254 --- /dev/null +++ b/docs/API_docs/types/InputEncryptedChat.md @@ -0,0 +1,29 @@ +--- +title: InputEncryptedChat +description: constructors and methods of type InputEncryptedChat +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputEncryptedChat +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [EncryptedMessage](EncryptedMessage.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntax can also be used: + +```php +$InputEncryptedChat = -147286699; // Numeric chat id returned by requestSecretChat, can be positive or negative +``` + + + +### Possible values (constructors): + +[inputEncryptedChat](/API_docs/constructors/inputEncryptedChat.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputEncryptedFile.md b/docs/API_docs/types/InputEncryptedFile.md new file mode 100644 index 0000000000..3d72b43f93 --- /dev/null +++ b/docs/API_docs/types/InputEncryptedFile.md @@ -0,0 +1,35 @@ +--- +title: InputEncryptedFile +description: constructors and methods of type InputEncryptedFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputEncryptedFile +[Back to types index](index.html) + +The following syntax can also be used: + +```php +$InputEncryptedFile = 'filename.mp4'; // The file path can also be used +$InputEncryptedFile = 'https://google.com'; // A URL can also be used +``` + +You can also use async streams, HTTP response objects, and [much more](https://docs.madelineproto.xyz/docs/FILES.html#downloading-files)! + + +### Possible values (constructors): + +[inputEncryptedFileEmpty](/API_docs/constructors/inputEncryptedFileEmpty.html) + +[inputEncryptedFileUploaded](/API_docs/constructors/inputEncryptedFileUploaded.html) + +[inputEncryptedFile](/API_docs/constructors/inputEncryptedFile.html) + +[inputEncryptedFileBigUploaded](/API_docs/constructors/inputEncryptedFileBigUploaded.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputFile.md b/docs/API_docs/types/InputFile.md new file mode 100644 index 0000000000..3b8bd0eaea --- /dev/null +++ b/docs/API_docs/types/InputFile.md @@ -0,0 +1,31 @@ +--- +title: InputFile +description: constructors and methods of type InputFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputFile +[Back to types index](index.html) + +The following syntax can also be used: + +```php +$InputFile = 'filename.mp4'; // The file path can also be used +$InputFile = 'https://google.com'; // A URL can also be used +``` + +You can also use async streams, HTTP response objects, and [much more](https://docs.madelineproto.xyz/docs/FILES.html#downloading-files)! + + +### Possible values (constructors): + +[inputFile](/API_docs/constructors/inputFile.html) + +[inputFileBig](/API_docs/constructors/inputFileBig.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputFileLocation.md b/docs/API_docs/types/InputFileLocation.md new file mode 100644 index 0000000000..899f35071b --- /dev/null +++ b/docs/API_docs/types/InputFileLocation.md @@ -0,0 +1,39 @@ +--- +title: InputFileLocation +description: constructors and methods of type InputFileLocation +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputFileLocation +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputFileLocation](/API_docs/constructors/inputFileLocation.html) + +[inputEncryptedFileLocation](/API_docs/constructors/inputEncryptedFileLocation.html) + +[inputDocumentFileLocation](/API_docs/constructors/inputDocumentFileLocation.html) + +[inputSecureFileLocation](/API_docs/constructors/inputSecureFileLocation.html) + +[inputTakeoutFileLocation](/API_docs/constructors/inputTakeoutFileLocation.html) + +[inputPhotoFileLocation](/API_docs/constructors/inputPhotoFileLocation.html) + +[inputPhotoLegacyFileLocation](/API_docs/constructors/inputPhotoLegacyFileLocation.html) + +[inputPeerPhotoFileLocation](/API_docs/constructors/inputPeerPhotoFileLocation.html) + +[inputStickerSetThumb](/API_docs/constructors/inputStickerSetThumb.html) + +[inputGroupCallStream](/API_docs/constructors/inputGroupCallStream.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputFolderPeer.md b/docs/API_docs/types/InputFolderPeer.md new file mode 100644 index 0000000000..41b3b61167 --- /dev/null +++ b/docs/API_docs/types/InputFolderPeer.md @@ -0,0 +1,21 @@ +--- +title: InputFolderPeer +description: constructors and methods of type InputFolderPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputFolderPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputFolderPeer](/API_docs/constructors/inputFolderPeer.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputGame.md b/docs/API_docs/types/InputGame.md new file mode 100644 index 0000000000..df15386c91 --- /dev/null +++ b/docs/API_docs/types/InputGame.md @@ -0,0 +1,23 @@ +--- +title: InputGame +description: constructors and methods of type InputGame +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputGame +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputGameID](/API_docs/constructors/inputGameID.html) + +[inputGameShortName](/API_docs/constructors/inputGameShortName.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputGeoPoint.md b/docs/API_docs/types/InputGeoPoint.md new file mode 100644 index 0000000000..6945629c5c --- /dev/null +++ b/docs/API_docs/types/InputGeoPoint.md @@ -0,0 +1,23 @@ +--- +title: InputGeoPoint +description: constructors and methods of type InputGeoPoint +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputGeoPoint +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputGeoPointEmpty](/API_docs/constructors/inputGeoPointEmpty.html) + +[inputGeoPoint](/API_docs/constructors/inputGeoPoint.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputGroupCall.md b/docs/API_docs/types/InputGroupCall.md new file mode 100644 index 0000000000..a1a9afe88c --- /dev/null +++ b/docs/API_docs/types/InputGroupCall.md @@ -0,0 +1,21 @@ +--- +title: InputGroupCall +description: constructors and methods of type InputGroupCall +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputGroupCall +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputGroupCall](/API_docs/constructors/inputGroupCall.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputInvoice.md b/docs/API_docs/types/InputInvoice.md new file mode 100644 index 0000000000..f173705383 --- /dev/null +++ b/docs/API_docs/types/InputInvoice.md @@ -0,0 +1,25 @@ +--- +title: InputInvoice +description: constructors and methods of type InputInvoice +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputInvoice +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputInvoiceMessage](/API_docs/constructors/inputInvoiceMessage.html) + +[inputInvoiceSlug](/API_docs/constructors/inputInvoiceSlug.html) + +[inputInvoicePremiumGiftCode](/API_docs/constructors/inputInvoicePremiumGiftCode.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputMedia.md b/docs/API_docs/types/InputMedia.md new file mode 100644 index 0000000000..2c02b7f9ef --- /dev/null +++ b/docs/API_docs/types/InputMedia.md @@ -0,0 +1,54 @@ +--- +title: InputMedia +description: constructors and methods of type InputMedia +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputMedia +[Back to types index](index.html) + +You can also provide a [MessageMedia](MessageMedia.html), [Message](Message.html), [Update](Update.html), [Document](Document.html), [Photo](Photo.html), [InputDocument](InputDocument.html), [InputPhoto](InputPhoto.html) here, MadelineProto will automatically convert it to the right type. + + +### Possible values (constructors): + +[inputMediaEmpty](/API_docs/constructors/inputMediaEmpty.html) + +[inputMediaUploadedPhoto](/API_docs/constructors/inputMediaUploadedPhoto.html) + +[inputMediaPhoto](/API_docs/constructors/inputMediaPhoto.html) + +[inputMediaGeoPoint](/API_docs/constructors/inputMediaGeoPoint.html) + +[inputMediaContact](/API_docs/constructors/inputMediaContact.html) + +[inputMediaUploadedDocument](/API_docs/constructors/inputMediaUploadedDocument.html) + +[inputMediaDocument](/API_docs/constructors/inputMediaDocument.html) + +[inputMediaVenue](/API_docs/constructors/inputMediaVenue.html) + +[inputMediaPhotoExternal](/API_docs/constructors/inputMediaPhotoExternal.html) + +[inputMediaDocumentExternal](/API_docs/constructors/inputMediaDocumentExternal.html) + +[inputMediaGame](/API_docs/constructors/inputMediaGame.html) + +[inputMediaInvoice](/API_docs/constructors/inputMediaInvoice.html) + +[inputMediaGeoLive](/API_docs/constructors/inputMediaGeoLive.html) + +[inputMediaPoll](/API_docs/constructors/inputMediaPoll.html) + +[inputMediaDice](/API_docs/constructors/inputMediaDice.html) + +[inputMediaStory](/API_docs/constructors/inputMediaStory.html) + +[inputMediaWebPage](/API_docs/constructors/inputMediaWebPage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputMessage.md b/docs/API_docs/types/InputMessage.md new file mode 100644 index 0000000000..0f60bbd41e --- /dev/null +++ b/docs/API_docs/types/InputMessage.md @@ -0,0 +1,34 @@ +--- +title: InputMessage +description: constructors and methods of type InputMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputMessage +[Back to types index](index.html) + +The following syntax can also be used: + +```php +$InputMessage = 142; // Numeric message ID +``` + + + + +### Possible values (constructors): + +[inputMessageID](/API_docs/constructors/inputMessageID.html) + +[inputMessageReplyTo](/API_docs/constructors/inputMessageReplyTo.html) + +[inputMessagePinned](/API_docs/constructors/inputMessagePinned.html) + +[inputMessageCallbackQuery](/API_docs/constructors/inputMessageCallbackQuery.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputNotifyPeer.md b/docs/API_docs/types/InputNotifyPeer.md new file mode 100644 index 0000000000..c944410c04 --- /dev/null +++ b/docs/API_docs/types/InputNotifyPeer.md @@ -0,0 +1,29 @@ +--- +title: InputNotifyPeer +description: constructors and methods of type InputNotifyPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputNotifyPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputNotifyPeer](/API_docs/constructors/inputNotifyPeer.html) + +[inputNotifyUsers](/API_docs/constructors/inputNotifyUsers.html) + +[inputNotifyChats](/API_docs/constructors/inputNotifyChats.html) + +[inputNotifyBroadcasts](/API_docs/constructors/inputNotifyBroadcasts.html) + +[inputNotifyForumTopic](/API_docs/constructors/inputNotifyForumTopic.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPaymentCredentials.md b/docs/API_docs/types/InputPaymentCredentials.md new file mode 100644 index 0000000000..69ad28611f --- /dev/null +++ b/docs/API_docs/types/InputPaymentCredentials.md @@ -0,0 +1,27 @@ +--- +title: InputPaymentCredentials +description: constructors and methods of type InputPaymentCredentials +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPaymentCredentials +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputPaymentCredentialsSaved](/API_docs/constructors/inputPaymentCredentialsSaved.html) + +[inputPaymentCredentials](/API_docs/constructors/inputPaymentCredentials.html) + +[inputPaymentCredentialsApplePay](/API_docs/constructors/inputPaymentCredentialsApplePay.html) + +[inputPaymentCredentialsGooglePay](/API_docs/constructors/inputPaymentCredentialsGooglePay.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPeer.md b/docs/API_docs/types/InputPeer.md new file mode 100644 index 0000000000..5019c8e6a1 --- /dev/null +++ b/docs/API_docs/types/InputPeer.md @@ -0,0 +1,68 @@ +--- +title: InputPeer +description: constructors and methods of type InputPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPeer +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$InputPeer = '@username'; // Username + +$InputPeer = $update; // Update objects received in the event handler + +$InputPeer = 'me'; // The currently logged-in user + +$InputPeer = 44700; // bot API id (users) +$InputPeer = -492772765; // bot API id (chats) +$InputPeer = -10038575794; // bot API id (channels) + +$InputPeer = 'https://t.me/danogentili'; // t.me URLs +$InputPeer = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + + + +### Possible values (constructors): + +[inputPeerEmpty](/API_docs/constructors/inputPeerEmpty.html) + +[inputPeerSelf](/API_docs/constructors/inputPeerSelf.html) + +[inputPeerChat](/API_docs/constructors/inputPeerChat.html) + +[inputPeerUser](/API_docs/constructors/inputPeerUser.html) + +[inputPeerChannel](/API_docs/constructors/inputPeerChannel.html) + +[inputPeerUserFromMessage](/API_docs/constructors/inputPeerUserFromMessage.html) + +[inputPeerChannelFromMessage](/API_docs/constructors/inputPeerChannelFromMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPeerNotifySettings.md b/docs/API_docs/types/InputPeerNotifySettings.md new file mode 100644 index 0000000000..62849f88b6 --- /dev/null +++ b/docs/API_docs/types/InputPeerNotifySettings.md @@ -0,0 +1,21 @@ +--- +title: InputPeerNotifySettings +description: constructors and methods of type InputPeerNotifySettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPeerNotifySettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputPeerNotifySettings](/API_docs/constructors/inputPeerNotifySettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPhoneCall.md b/docs/API_docs/types/InputPhoneCall.md new file mode 100644 index 0000000000..c91c22273a --- /dev/null +++ b/docs/API_docs/types/InputPhoneCall.md @@ -0,0 +1,21 @@ +--- +title: InputPhoneCall +description: constructors and methods of type InputPhoneCall +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPhoneCall +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputPhoneCall](/API_docs/constructors/inputPhoneCall.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPhoto.md b/docs/API_docs/types/InputPhoto.md new file mode 100644 index 0000000000..6989516843 --- /dev/null +++ b/docs/API_docs/types/InputPhoto.md @@ -0,0 +1,24 @@ +--- +title: InputPhoto +description: constructors and methods of type InputPhoto +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPhoto +[Back to types index](index.html) + +You can also provide a [MessageMedia](MessageMedia.html), [Message](Message.html), [Update](Update.html), [Photo](Photo.html) here, MadelineProto will automatically convert it to the right type. + + +### Possible values (constructors): + +[inputPhotoEmpty](/API_docs/constructors/inputPhotoEmpty.html) + +[inputPhoto](/API_docs/constructors/inputPhoto.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPrivacyKey.md b/docs/API_docs/types/InputPrivacyKey.md new file mode 100644 index 0000000000..f9b5906673 --- /dev/null +++ b/docs/API_docs/types/InputPrivacyKey.md @@ -0,0 +1,41 @@ +--- +title: InputPrivacyKey +description: constructors and methods of type InputPrivacyKey +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPrivacyKey +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputPrivacyKeyStatusTimestamp](/API_docs/constructors/inputPrivacyKeyStatusTimestamp.html) + +[inputPrivacyKeyChatInvite](/API_docs/constructors/inputPrivacyKeyChatInvite.html) + +[inputPrivacyKeyPhoneCall](/API_docs/constructors/inputPrivacyKeyPhoneCall.html) + +[inputPrivacyKeyPhoneP2P](/API_docs/constructors/inputPrivacyKeyPhoneP2P.html) + +[inputPrivacyKeyForwards](/API_docs/constructors/inputPrivacyKeyForwards.html) + +[inputPrivacyKeyProfilePhoto](/API_docs/constructors/inputPrivacyKeyProfilePhoto.html) + +[inputPrivacyKeyPhoneNumber](/API_docs/constructors/inputPrivacyKeyPhoneNumber.html) + +[inputPrivacyKeyAddedByPhone](/API_docs/constructors/inputPrivacyKeyAddedByPhone.html) + +[inputPrivacyKeyVoiceMessages](/API_docs/constructors/inputPrivacyKeyVoiceMessages.html) + +[inputPrivacyKeyAbout](/API_docs/constructors/inputPrivacyKeyAbout.html) + +[inputPrivacyKeyBirthday](/API_docs/constructors/inputPrivacyKeyBirthday.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputPrivacyRule.md b/docs/API_docs/types/InputPrivacyRule.md new file mode 100644 index 0000000000..11fd86da2a --- /dev/null +++ b/docs/API_docs/types/InputPrivacyRule.md @@ -0,0 +1,39 @@ +--- +title: InputPrivacyRule +description: constructors and methods of type InputPrivacyRule +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputPrivacyRule +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputPrivacyValueAllowContacts](/API_docs/constructors/inputPrivacyValueAllowContacts.html) + +[inputPrivacyValueAllowAll](/API_docs/constructors/inputPrivacyValueAllowAll.html) + +[inputPrivacyValueAllowUsers](/API_docs/constructors/inputPrivacyValueAllowUsers.html) + +[inputPrivacyValueDisallowContacts](/API_docs/constructors/inputPrivacyValueDisallowContacts.html) + +[inputPrivacyValueDisallowAll](/API_docs/constructors/inputPrivacyValueDisallowAll.html) + +[inputPrivacyValueDisallowUsers](/API_docs/constructors/inputPrivacyValueDisallowUsers.html) + +[inputPrivacyValueAllowChatParticipants](/API_docs/constructors/inputPrivacyValueAllowChatParticipants.html) + +[inputPrivacyValueDisallowChatParticipants](/API_docs/constructors/inputPrivacyValueDisallowChatParticipants.html) + +[inputPrivacyValueAllowCloseFriends](/API_docs/constructors/inputPrivacyValueAllowCloseFriends.html) + +[inputPrivacyValueAllowPremium](/API_docs/constructors/inputPrivacyValueAllowPremium.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputQuickReplyShortcut.md b/docs/API_docs/types/InputQuickReplyShortcut.md new file mode 100644 index 0000000000..3b972f13a3 --- /dev/null +++ b/docs/API_docs/types/InputQuickReplyShortcut.md @@ -0,0 +1,23 @@ +--- +title: InputQuickReplyShortcut +description: constructors and methods of type InputQuickReplyShortcut +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputQuickReplyShortcut +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputQuickReplyShortcut](/API_docs/constructors/inputQuickReplyShortcut.html) + +[inputQuickReplyShortcutId](/API_docs/constructors/inputQuickReplyShortcutId.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputReplyTo.md b/docs/API_docs/types/InputReplyTo.md new file mode 100644 index 0000000000..4faa223287 --- /dev/null +++ b/docs/API_docs/types/InputReplyTo.md @@ -0,0 +1,23 @@ +--- +title: InputReplyTo +description: constructors and methods of type InputReplyTo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputReplyTo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputReplyToMessage](/API_docs/constructors/inputReplyToMessage.html) + +[inputReplyToStory](/API_docs/constructors/inputReplyToStory.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputSecureFile.md b/docs/API_docs/types/InputSecureFile.md new file mode 100644 index 0000000000..714ca88d48 --- /dev/null +++ b/docs/API_docs/types/InputSecureFile.md @@ -0,0 +1,23 @@ +--- +title: InputSecureFile +description: constructors and methods of type InputSecureFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputSecureFile +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputSecureFileUploaded](/API_docs/constructors/inputSecureFileUploaded.html) + +[inputSecureFile](/API_docs/constructors/inputSecureFile.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputSecureValue.md b/docs/API_docs/types/InputSecureValue.md new file mode 100644 index 0000000000..538cdffe39 --- /dev/null +++ b/docs/API_docs/types/InputSecureValue.md @@ -0,0 +1,21 @@ +--- +title: InputSecureValue +description: constructors and methods of type InputSecureValue +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputSecureValue +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputSecureValue](/API_docs/constructors/inputSecureValue.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputSingleMedia.md b/docs/API_docs/types/InputSingleMedia.md new file mode 100644 index 0000000000..f07db3dfb1 --- /dev/null +++ b/docs/API_docs/types/InputSingleMedia.md @@ -0,0 +1,21 @@ +--- +title: InputSingleMedia +description: constructors and methods of type InputSingleMedia +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputSingleMedia +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputSingleMedia](/API_docs/constructors/inputSingleMedia.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputStickerSet.md b/docs/API_docs/types/InputStickerSet.md new file mode 100644 index 0000000000..5d571b2479 --- /dev/null +++ b/docs/API_docs/types/InputStickerSet.md @@ -0,0 +1,41 @@ +--- +title: InputStickerSet +description: constructors and methods of type InputStickerSet +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputStickerSet +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputStickerSetEmpty](/API_docs/constructors/inputStickerSetEmpty.html) + +[inputStickerSetID](/API_docs/constructors/inputStickerSetID.html) + +[inputStickerSetShortName](/API_docs/constructors/inputStickerSetShortName.html) + +[inputStickerSetAnimatedEmoji](/API_docs/constructors/inputStickerSetAnimatedEmoji.html) + +[inputStickerSetDice](/API_docs/constructors/inputStickerSetDice.html) + +[inputStickerSetAnimatedEmojiAnimations](/API_docs/constructors/inputStickerSetAnimatedEmojiAnimations.html) + +[inputStickerSetPremiumGifts](/API_docs/constructors/inputStickerSetPremiumGifts.html) + +[inputStickerSetEmojiGenericAnimations](/API_docs/constructors/inputStickerSetEmojiGenericAnimations.html) + +[inputStickerSetEmojiDefaultStatuses](/API_docs/constructors/inputStickerSetEmojiDefaultStatuses.html) + +[inputStickerSetEmojiDefaultTopicIcons](/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.html) + +[inputStickerSetEmojiChannelDefaultStatuses](/API_docs/constructors/inputStickerSetEmojiChannelDefaultStatuses.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputStickerSetItem.md b/docs/API_docs/types/InputStickerSetItem.md new file mode 100644 index 0000000000..d4583d3e7a --- /dev/null +++ b/docs/API_docs/types/InputStickerSetItem.md @@ -0,0 +1,21 @@ +--- +title: InputStickerSetItem +description: constructors and methods of type InputStickerSetItem +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputStickerSetItem +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputStickerSetItem](/API_docs/constructors/inputStickerSetItem.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputStickeredMedia.md b/docs/API_docs/types/InputStickeredMedia.md new file mode 100644 index 0000000000..b4943ae488 --- /dev/null +++ b/docs/API_docs/types/InputStickeredMedia.md @@ -0,0 +1,23 @@ +--- +title: InputStickeredMedia +description: constructors and methods of type InputStickeredMedia +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputStickeredMedia +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputStickeredMediaPhoto](/API_docs/constructors/inputStickeredMediaPhoto.html) + +[inputStickeredMediaDocument](/API_docs/constructors/inputStickeredMediaDocument.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputStorePaymentPurpose.md b/docs/API_docs/types/InputStorePaymentPurpose.md new file mode 100644 index 0000000000..15f80c3bbd --- /dev/null +++ b/docs/API_docs/types/InputStorePaymentPurpose.md @@ -0,0 +1,27 @@ +--- +title: InputStorePaymentPurpose +description: constructors and methods of type InputStorePaymentPurpose +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputStorePaymentPurpose +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputStorePaymentPremiumSubscription](/API_docs/constructors/inputStorePaymentPremiumSubscription.html) + +[inputStorePaymentGiftPremium](/API_docs/constructors/inputStorePaymentGiftPremium.html) + +[inputStorePaymentPremiumGiftCode](/API_docs/constructors/inputStorePaymentPremiumGiftCode.html) + +[inputStorePaymentPremiumGiveaway](/API_docs/constructors/inputStorePaymentPremiumGiveaway.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputTheme.md b/docs/API_docs/types/InputTheme.md new file mode 100644 index 0000000000..dfd01f9430 --- /dev/null +++ b/docs/API_docs/types/InputTheme.md @@ -0,0 +1,23 @@ +--- +title: InputTheme +description: constructors and methods of type InputTheme +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputTheme +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputTheme](/API_docs/constructors/inputTheme.html) + +[inputThemeSlug](/API_docs/constructors/inputThemeSlug.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputThemeSettings.md b/docs/API_docs/types/InputThemeSettings.md new file mode 100644 index 0000000000..daeeb2454b --- /dev/null +++ b/docs/API_docs/types/InputThemeSettings.md @@ -0,0 +1,21 @@ +--- +title: InputThemeSettings +description: constructors and methods of type InputThemeSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputThemeSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputThemeSettings](/API_docs/constructors/inputThemeSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputUser.md b/docs/API_docs/types/InputUser.md new file mode 100644 index 0000000000..734d3e2905 --- /dev/null +++ b/docs/API_docs/types/InputUser.md @@ -0,0 +1,62 @@ +--- +title: InputUser +description: constructors and methods of type InputUser +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputUser +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$InputUser = '@username'; // Username + +$InputUser = $update; // Update objects received in the event handler + +$InputUser = 'me'; // The currently logged-in user + +$InputUser = 44700; // bot API id (users) +$InputUser = -492772765; // bot API id (chats) +$InputUser = -10038575794; // bot API id (channels) + +$InputUser = 'https://t.me/danogentili'; // t.me URLs +$InputUser = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + + + +### Possible values (constructors): + +[inputUserEmpty](/API_docs/constructors/inputUserEmpty.html) + +[inputUserSelf](/API_docs/constructors/inputUserSelf.html) + +[inputUser](/API_docs/constructors/inputUser.html) + +[inputUserFromMessage](/API_docs/constructors/inputUserFromMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputWallPaper.md b/docs/API_docs/types/InputWallPaper.md new file mode 100644 index 0000000000..32bb1a2fe5 --- /dev/null +++ b/docs/API_docs/types/InputWallPaper.md @@ -0,0 +1,25 @@ +--- +title: InputWallPaper +description: constructors and methods of type InputWallPaper +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputWallPaper +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputWallPaper](/API_docs/constructors/inputWallPaper.html) + +[inputWallPaperSlug](/API_docs/constructors/inputWallPaperSlug.html) + +[inputWallPaperNoFile](/API_docs/constructors/inputWallPaperNoFile.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputWebDocument.md b/docs/API_docs/types/InputWebDocument.md new file mode 100644 index 0000000000..4434254980 --- /dev/null +++ b/docs/API_docs/types/InputWebDocument.md @@ -0,0 +1,21 @@ +--- +title: InputWebDocument +description: constructors and methods of type InputWebDocument +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputWebDocument +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputWebDocument](/API_docs/constructors/inputWebDocument.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/InputWebFileLocation.md b/docs/API_docs/types/InputWebFileLocation.md new file mode 100644 index 0000000000..a89011485e --- /dev/null +++ b/docs/API_docs/types/InputWebFileLocation.md @@ -0,0 +1,25 @@ +--- +title: InputWebFileLocation +description: constructors and methods of type InputWebFileLocation +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: InputWebFileLocation +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputWebFileLocation](/API_docs/constructors/inputWebFileLocation.html) + +[inputWebFileGeoPointLocation](/API_docs/constructors/inputWebFileGeoPointLocation.html) + +[inputWebFileAudioAlbumThumbLocation](/API_docs/constructors/inputWebFileAudioAlbumThumbLocation.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Invoice.md b/docs/API_docs/types/Invoice.md new file mode 100644 index 0000000000..6317bd6573 --- /dev/null +++ b/docs/API_docs/types/Invoice.md @@ -0,0 +1,21 @@ +--- +title: Invoice +description: constructors and methods of type Invoice +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Invoice +[Back to types index](index.html) + + + +### Possible values (constructors): + +[invoice](/API_docs/constructors/invoice.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/JSONObjectValue.md b/docs/API_docs/types/JSONObjectValue.md new file mode 100644 index 0000000000..a223c5189b --- /dev/null +++ b/docs/API_docs/types/JSONObjectValue.md @@ -0,0 +1,21 @@ +--- +title: JSONObjectValue +description: constructors and methods of type JSONObjectValue +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: JSONObjectValue +[Back to types index](index.html) + + + +### Possible values (constructors): + +[jsonObjectValue](/API_docs/constructors/jsonObjectValue.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/JSONValue.md b/docs/API_docs/types/JSONValue.md new file mode 100644 index 0000000000..23b4c152d1 --- /dev/null +++ b/docs/API_docs/types/JSONValue.md @@ -0,0 +1,31 @@ +--- +title: JSONValue +description: constructors and methods of type JSONValue +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: JSONValue +[Back to types index](index.html) + + + +### Possible values (constructors): + +[jsonNull](/API_docs/constructors/jsonNull.html) + +[jsonBool](/API_docs/constructors/jsonBool.html) + +[jsonNumber](/API_docs/constructors/jsonNumber.html) + +[jsonString](/API_docs/constructors/jsonString.html) + +[jsonArray](/API_docs/constructors/jsonArray.html) + +[jsonObject](/API_docs/constructors/jsonObject.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/KeyboardButton.md b/docs/API_docs/types/KeyboardButton.md new file mode 100644 index 0000000000..23439a518f --- /dev/null +++ b/docs/API_docs/types/KeyboardButton.md @@ -0,0 +1,74 @@ +--- +title: KeyboardButton +description: constructors and methods of type KeyboardButton +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: KeyboardButton +[Back to types index](index.html) + +Clicking these buttons: + +To click these buttons simply run the `click` method: + +```php +$result = $KeyboardButton->click(); +``` + +`$result` can be one of the following: + + +* A string - If the button is a keyboardButtonUrl + +* [Updates](Updates.html) - If the button is a keyboardButton, the message will be sent to the chat, in reply to the message with the keyboard + +* [messages.BotCallbackAnswer](messages.BotCallbackAnswer.html) - If the button is a keyboardButtonCallback or a keyboardButtonGame the button will be pressed and the result will be returned + +* `false` - If the button is an unsupported button, like keyboardButtonRequestPhone, keyboardButtonRequestGeoLocation, keyboardButtonSwitchInlinekeyboardButtonBuy; you will have to parse data from these buttons manually + + +You can also access the properties of the constructor as a normal array, for example `$button['name']` + + +### Possible values (constructors): + +[keyboardButton](/API_docs/constructors/keyboardButton.html) + +[keyboardButtonUrl](/API_docs/constructors/keyboardButtonUrl.html) + +[keyboardButtonCallback](/API_docs/constructors/keyboardButtonCallback.html) + +[keyboardButtonRequestPhone](/API_docs/constructors/keyboardButtonRequestPhone.html) + +[keyboardButtonRequestGeoLocation](/API_docs/constructors/keyboardButtonRequestGeoLocation.html) + +[keyboardButtonSwitchInline](/API_docs/constructors/keyboardButtonSwitchInline.html) + +[keyboardButtonGame](/API_docs/constructors/keyboardButtonGame.html) + +[keyboardButtonBuy](/API_docs/constructors/keyboardButtonBuy.html) + +[keyboardButtonUrlAuth](/API_docs/constructors/keyboardButtonUrlAuth.html) + +[inputKeyboardButtonUrlAuth](/API_docs/constructors/inputKeyboardButtonUrlAuth.html) + +[keyboardButtonRequestPoll](/API_docs/constructors/keyboardButtonRequestPoll.html) + +[inputKeyboardButtonUserProfile](/API_docs/constructors/inputKeyboardButtonUserProfile.html) + +[keyboardButtonUserProfile](/API_docs/constructors/keyboardButtonUserProfile.html) + +[keyboardButtonWebView](/API_docs/constructors/keyboardButtonWebView.html) + +[keyboardButtonSimpleWebView](/API_docs/constructors/keyboardButtonSimpleWebView.html) + +[keyboardButtonRequestPeer](/API_docs/constructors/keyboardButtonRequestPeer.html) + +[inputKeyboardButtonRequestPeer](/API_docs/constructors/inputKeyboardButtonRequestPeer.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/KeyboardButtonRow.md b/docs/API_docs/types/KeyboardButtonRow.md new file mode 100644 index 0000000000..b5a324af29 --- /dev/null +++ b/docs/API_docs/types/KeyboardButtonRow.md @@ -0,0 +1,21 @@ +--- +title: KeyboardButtonRow +description: constructors and methods of type KeyboardButtonRow +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: KeyboardButtonRow +[Back to types index](index.html) + + + +### Possible values (constructors): + +[keyboardButtonRow](/API_docs/constructors/keyboardButtonRow.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/LabeledPrice.md b/docs/API_docs/types/LabeledPrice.md new file mode 100644 index 0000000000..97a9eb3b8c --- /dev/null +++ b/docs/API_docs/types/LabeledPrice.md @@ -0,0 +1,21 @@ +--- +title: LabeledPrice +description: constructors and methods of type LabeledPrice +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: LabeledPrice +[Back to types index](index.html) + + + +### Possible values (constructors): + +[labeledPrice](/API_docs/constructors/labeledPrice.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/LangPackDifference.md b/docs/API_docs/types/LangPackDifference.md new file mode 100644 index 0000000000..56781f15d7 --- /dev/null +++ b/docs/API_docs/types/LangPackDifference.md @@ -0,0 +1,25 @@ +--- +title: LangPackDifference +description: constructors and methods of type LangPackDifference +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: LangPackDifference +[Back to types index](index.html) + + + +### Possible values (constructors): + +[langPackDifference](/API_docs/constructors/langPackDifference.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->langpack->getLangPack](/API_docs/methods/langpack.getLangPack.html) + +[$MadelineProto->langpack->getDifference](/API_docs/methods/langpack.getDifference.html) + + + diff --git a/docs/API_docs/types/LangPackLanguage.md b/docs/API_docs/types/LangPackLanguage.md new file mode 100644 index 0000000000..087010aa7a --- /dev/null +++ b/docs/API_docs/types/LangPackLanguage.md @@ -0,0 +1,25 @@ +--- +title: LangPackLanguage +description: constructors and methods of type LangPackLanguage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: LangPackLanguage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[langPackLanguage](/API_docs/constructors/langPackLanguage.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->langpack->getLanguages](/API_docs/methods/langpack.getLanguages.html) + +[$MadelineProto->langpack->getLanguage](/API_docs/methods/langpack.getLanguage.html) + + + diff --git a/docs/API_docs/types/LangPackString.md b/docs/API_docs/types/LangPackString.md new file mode 100644 index 0000000000..899d2e639a --- /dev/null +++ b/docs/API_docs/types/LangPackString.md @@ -0,0 +1,27 @@ +--- +title: LangPackString +description: constructors and methods of type LangPackString +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: LangPackString +[Back to types index](index.html) + + + +### Possible values (constructors): + +[langPackString](/API_docs/constructors/langPackString.html) + +[langPackStringPluralized](/API_docs/constructors/langPackStringPluralized.html) + +[langPackStringDeleted](/API_docs/constructors/langPackStringDeleted.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->langpack->getStrings](/API_docs/methods/langpack.getStrings.html) + + + diff --git a/docs/API_docs/types/MaskCoords.md b/docs/API_docs/types/MaskCoords.md new file mode 100644 index 0000000000..de26bcb5bb --- /dev/null +++ b/docs/API_docs/types/MaskCoords.md @@ -0,0 +1,21 @@ +--- +title: MaskCoords +description: constructors and methods of type MaskCoords +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MaskCoords +[Back to types index](index.html) + + + +### Possible values (constructors): + +[maskCoords](/API_docs/constructors/maskCoords.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MediaArea.md b/docs/API_docs/types/MediaArea.md new file mode 100644 index 0000000000..780e7fd725 --- /dev/null +++ b/docs/API_docs/types/MediaArea.md @@ -0,0 +1,31 @@ +--- +title: MediaArea +description: constructors and methods of type MediaArea +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MediaArea +[Back to types index](index.html) + + + +### Possible values (constructors): + +[mediaAreaVenue](/API_docs/constructors/mediaAreaVenue.html) + +[inputMediaAreaVenue](/API_docs/constructors/inputMediaAreaVenue.html) + +[mediaAreaGeoPoint](/API_docs/constructors/mediaAreaGeoPoint.html) + +[mediaAreaSuggestedReaction](/API_docs/constructors/mediaAreaSuggestedReaction.html) + +[mediaAreaChannelPost](/API_docs/constructors/mediaAreaChannelPost.html) + +[inputMediaAreaChannelPost](/API_docs/constructors/inputMediaAreaChannelPost.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MediaAreaCoordinates.md b/docs/API_docs/types/MediaAreaCoordinates.md new file mode 100644 index 0000000000..2480df8369 --- /dev/null +++ b/docs/API_docs/types/MediaAreaCoordinates.md @@ -0,0 +1,21 @@ +--- +title: MediaAreaCoordinates +description: constructors and methods of type MediaAreaCoordinates +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MediaAreaCoordinates +[Back to types index](index.html) + + + +### Possible values (constructors): + +[mediaAreaCoordinates](/API_docs/constructors/mediaAreaCoordinates.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Message.md b/docs/API_docs/types/Message.md new file mode 100644 index 0000000000..3bb7bebe45 --- /dev/null +++ b/docs/API_docs/types/Message.md @@ -0,0 +1,25 @@ +--- +title: Message +description: constructors and methods of type Message +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Message +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageEmpty](/API_docs/constructors/messageEmpty.html) + +[message](/API_docs/constructors/message.html) + +[messageService](/API_docs/constructors/messageService.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageAction.md b/docs/API_docs/types/MessageAction.md new file mode 100644 index 0000000000..efe80b1a27 --- /dev/null +++ b/docs/API_docs/types/MessageAction.md @@ -0,0 +1,105 @@ +--- +title: MessageAction +description: constructors and methods of type MessageAction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageAction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageActionEmpty](/API_docs/constructors/messageActionEmpty.html) + +[messageActionChatCreate](/API_docs/constructors/messageActionChatCreate.html) + +[messageActionChatEditTitle](/API_docs/constructors/messageActionChatEditTitle.html) + +[messageActionChatEditPhoto](/API_docs/constructors/messageActionChatEditPhoto.html) + +[messageActionChatDeletePhoto](/API_docs/constructors/messageActionChatDeletePhoto.html) + +[messageActionChatAddUser](/API_docs/constructors/messageActionChatAddUser.html) + +[messageActionChatDeleteUser](/API_docs/constructors/messageActionChatDeleteUser.html) + +[messageActionChatJoinedByLink](/API_docs/constructors/messageActionChatJoinedByLink.html) + +[messageActionChannelCreate](/API_docs/constructors/messageActionChannelCreate.html) + +[messageActionChatMigrateTo](/API_docs/constructors/messageActionChatMigrateTo.html) + +[messageActionChannelMigrateFrom](/API_docs/constructors/messageActionChannelMigrateFrom.html) + +[messageActionPinMessage](/API_docs/constructors/messageActionPinMessage.html) + +[messageActionHistoryClear](/API_docs/constructors/messageActionHistoryClear.html) + +[messageActionGameScore](/API_docs/constructors/messageActionGameScore.html) + +[messageActionPaymentSentMe](/API_docs/constructors/messageActionPaymentSentMe.html) + +[messageActionPaymentSent](/API_docs/constructors/messageActionPaymentSent.html) + +[messageActionPhoneCall](/API_docs/constructors/messageActionPhoneCall.html) + +[messageActionScreenshotTaken](/API_docs/constructors/messageActionScreenshotTaken.html) + +[messageActionCustomAction](/API_docs/constructors/messageActionCustomAction.html) + +[messageActionBotAllowed](/API_docs/constructors/messageActionBotAllowed.html) + +[messageActionSecureValuesSentMe](/API_docs/constructors/messageActionSecureValuesSentMe.html) + +[messageActionSecureValuesSent](/API_docs/constructors/messageActionSecureValuesSent.html) + +[messageActionContactSignUp](/API_docs/constructors/messageActionContactSignUp.html) + +[messageActionGeoProximityReached](/API_docs/constructors/messageActionGeoProximityReached.html) + +[messageActionGroupCall](/API_docs/constructors/messageActionGroupCall.html) + +[messageActionInviteToGroupCall](/API_docs/constructors/messageActionInviteToGroupCall.html) + +[messageActionSetMessagesTTL](/API_docs/constructors/messageActionSetMessagesTTL.html) + +[messageActionGroupCallScheduled](/API_docs/constructors/messageActionGroupCallScheduled.html) + +[messageActionSetChatTheme](/API_docs/constructors/messageActionSetChatTheme.html) + +[messageActionChatJoinedByRequest](/API_docs/constructors/messageActionChatJoinedByRequest.html) + +[messageActionWebViewDataSentMe](/API_docs/constructors/messageActionWebViewDataSentMe.html) + +[messageActionWebViewDataSent](/API_docs/constructors/messageActionWebViewDataSent.html) + +[messageActionGiftPremium](/API_docs/constructors/messageActionGiftPremium.html) + +[messageActionTopicCreate](/API_docs/constructors/messageActionTopicCreate.html) + +[messageActionTopicEdit](/API_docs/constructors/messageActionTopicEdit.html) + +[messageActionSuggestProfilePhoto](/API_docs/constructors/messageActionSuggestProfilePhoto.html) + +[messageActionRequestedPeer](/API_docs/constructors/messageActionRequestedPeer.html) + +[messageActionSetChatWallPaper](/API_docs/constructors/messageActionSetChatWallPaper.html) + +[messageActionGiftCode](/API_docs/constructors/messageActionGiftCode.html) + +[messageActionGiveawayLaunch](/API_docs/constructors/messageActionGiveawayLaunch.html) + +[messageActionGiveawayResults](/API_docs/constructors/messageActionGiveawayResults.html) + +[messageActionBoostApply](/API_docs/constructors/messageActionBoostApply.html) + +[messageActionRequestedPeerSentMe](/API_docs/constructors/messageActionRequestedPeerSentMe.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageEntity.md b/docs/API_docs/types/MessageEntity.md new file mode 100644 index 0000000000..f3598987a7 --- /dev/null +++ b/docs/API_docs/types/MessageEntity.md @@ -0,0 +1,61 @@ +--- +title: MessageEntity +description: constructors and methods of type MessageEntity +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageEntity +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageEntityUnknown](/API_docs/constructors/messageEntityUnknown.html) + +[messageEntityMention](/API_docs/constructors/messageEntityMention.html) + +[messageEntityHashtag](/API_docs/constructors/messageEntityHashtag.html) + +[messageEntityBotCommand](/API_docs/constructors/messageEntityBotCommand.html) + +[messageEntityUrl](/API_docs/constructors/messageEntityUrl.html) + +[messageEntityEmail](/API_docs/constructors/messageEntityEmail.html) + +[messageEntityBold](/API_docs/constructors/messageEntityBold.html) + +[messageEntityItalic](/API_docs/constructors/messageEntityItalic.html) + +[messageEntityCode](/API_docs/constructors/messageEntityCode.html) + +[messageEntityPre](/API_docs/constructors/messageEntityPre.html) + +[messageEntityTextUrl](/API_docs/constructors/messageEntityTextUrl.html) + +[messageEntityMentionName](/API_docs/constructors/messageEntityMentionName.html) + +[inputMessageEntityMentionName](/API_docs/constructors/inputMessageEntityMentionName.html) + +[messageEntityPhone](/API_docs/constructors/messageEntityPhone.html) + +[messageEntityCashtag](/API_docs/constructors/messageEntityCashtag.html) + +[messageEntityUnderline](/API_docs/constructors/messageEntityUnderline.html) + +[messageEntityStrike](/API_docs/constructors/messageEntityStrike.html) + +[messageEntityBankCard](/API_docs/constructors/messageEntityBankCard.html) + +[messageEntitySpoiler](/API_docs/constructors/messageEntitySpoiler.html) + +[messageEntityCustomEmoji](/API_docs/constructors/messageEntityCustomEmoji.html) + +[messageEntityBlockquote](/API_docs/constructors/messageEntityBlockquote.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageExtendedMedia.md b/docs/API_docs/types/MessageExtendedMedia.md new file mode 100644 index 0000000000..095151d1db --- /dev/null +++ b/docs/API_docs/types/MessageExtendedMedia.md @@ -0,0 +1,23 @@ +--- +title: MessageExtendedMedia +description: constructors and methods of type MessageExtendedMedia +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageExtendedMedia +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageExtendedMediaPreview](/API_docs/constructors/messageExtendedMediaPreview.html) + +[messageExtendedMedia](/API_docs/constructors/messageExtendedMedia.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageFwdHeader.md b/docs/API_docs/types/MessageFwdHeader.md new file mode 100644 index 0000000000..0c8d0c7b97 --- /dev/null +++ b/docs/API_docs/types/MessageFwdHeader.md @@ -0,0 +1,21 @@ +--- +title: MessageFwdHeader +description: constructors and methods of type MessageFwdHeader +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageFwdHeader +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageFwdHeader](/API_docs/constructors/messageFwdHeader.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageMedia.md b/docs/API_docs/types/MessageMedia.md new file mode 100644 index 0000000000..aa2d22d28e --- /dev/null +++ b/docs/API_docs/types/MessageMedia.md @@ -0,0 +1,57 @@ +--- +title: MessageMedia +description: constructors and methods of type MessageMedia +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageMedia +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageMediaEmpty](/API_docs/constructors/messageMediaEmpty.html) + +[messageMediaPhoto](/API_docs/constructors/messageMediaPhoto.html) + +[messageMediaGeo](/API_docs/constructors/messageMediaGeo.html) + +[messageMediaContact](/API_docs/constructors/messageMediaContact.html) + +[messageMediaUnsupported](/API_docs/constructors/messageMediaUnsupported.html) + +[messageMediaDocument](/API_docs/constructors/messageMediaDocument.html) + +[messageMediaWebPage](/API_docs/constructors/messageMediaWebPage.html) + +[messageMediaVenue](/API_docs/constructors/messageMediaVenue.html) + +[messageMediaGame](/API_docs/constructors/messageMediaGame.html) + +[messageMediaInvoice](/API_docs/constructors/messageMediaInvoice.html) + +[messageMediaGeoLive](/API_docs/constructors/messageMediaGeoLive.html) + +[messageMediaPoll](/API_docs/constructors/messageMediaPoll.html) + +[messageMediaDice](/API_docs/constructors/messageMediaDice.html) + +[messageMediaStory](/API_docs/constructors/messageMediaStory.html) + +[messageMediaGiveaway](/API_docs/constructors/messageMediaGiveaway.html) + +[messageMediaGiveawayResults](/API_docs/constructors/messageMediaGiveawayResults.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getWebPagePreview](/API_docs/methods/messages.getWebPagePreview.html) + +[$MadelineProto->messages->uploadMedia](/API_docs/methods/messages.uploadMedia.html) + +[$MadelineProto->messages->uploadImportedMedia](/API_docs/methods/messages.uploadImportedMedia.html) + + + diff --git a/docs/API_docs/types/MessagePeerReaction.md b/docs/API_docs/types/MessagePeerReaction.md new file mode 100644 index 0000000000..cdc03bda64 --- /dev/null +++ b/docs/API_docs/types/MessagePeerReaction.md @@ -0,0 +1,21 @@ +--- +title: MessagePeerReaction +description: constructors and methods of type MessagePeerReaction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessagePeerReaction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messagePeerReaction](/API_docs/constructors/messagePeerReaction.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessagePeerVote.md b/docs/API_docs/types/MessagePeerVote.md new file mode 100644 index 0000000000..cbde075970 --- /dev/null +++ b/docs/API_docs/types/MessagePeerVote.md @@ -0,0 +1,25 @@ +--- +title: MessagePeerVote +description: constructors and methods of type MessagePeerVote +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessagePeerVote +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messagePeerVote](/API_docs/constructors/messagePeerVote.html) + +[messagePeerVoteInputOption](/API_docs/constructors/messagePeerVoteInputOption.html) + +[messagePeerVoteMultiple](/API_docs/constructors/messagePeerVoteMultiple.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageRange.md b/docs/API_docs/types/MessageRange.md new file mode 100644 index 0000000000..b3fac216eb --- /dev/null +++ b/docs/API_docs/types/MessageRange.md @@ -0,0 +1,23 @@ +--- +title: MessageRange +description: constructors and methods of type MessageRange +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageRange +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageRange](/API_docs/constructors/messageRange.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSplitRanges](/API_docs/methods/messages.getSplitRanges.html) + + + diff --git a/docs/API_docs/types/MessageReactions.md b/docs/API_docs/types/MessageReactions.md new file mode 100644 index 0000000000..b6f60beab8 --- /dev/null +++ b/docs/API_docs/types/MessageReactions.md @@ -0,0 +1,21 @@ +--- +title: MessageReactions +description: constructors and methods of type MessageReactions +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageReactions +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageReactions](/API_docs/constructors/messageReactions.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageReplies.md b/docs/API_docs/types/MessageReplies.md new file mode 100644 index 0000000000..b3107c4f52 --- /dev/null +++ b/docs/API_docs/types/MessageReplies.md @@ -0,0 +1,21 @@ +--- +title: MessageReplies +description: constructors and methods of type MessageReplies +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageReplies +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageReplies](/API_docs/constructors/messageReplies.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageReplyHeader.md b/docs/API_docs/types/MessageReplyHeader.md new file mode 100644 index 0000000000..2c49c01d1c --- /dev/null +++ b/docs/API_docs/types/MessageReplyHeader.md @@ -0,0 +1,23 @@ +--- +title: MessageReplyHeader +description: constructors and methods of type MessageReplyHeader +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageReplyHeader +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageReplyHeader](/API_docs/constructors/messageReplyHeader.html) + +[messageReplyStoryHeader](/API_docs/constructors/messageReplyStoryHeader.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessageViews.md b/docs/API_docs/types/MessageViews.md new file mode 100644 index 0000000000..8ec2ede0d0 --- /dev/null +++ b/docs/API_docs/types/MessageViews.md @@ -0,0 +1,21 @@ +--- +title: MessageViews +description: constructors and methods of type MessageViews +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessageViews +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messageViews](/API_docs/constructors/messageViews.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MessagesFilter.md b/docs/API_docs/types/MessagesFilter.md new file mode 100644 index 0000000000..f80ec1ed5a --- /dev/null +++ b/docs/API_docs/types/MessagesFilter.md @@ -0,0 +1,53 @@ +--- +title: MessagesFilter +description: constructors and methods of type MessagesFilter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MessagesFilter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputMessagesFilterEmpty](/API_docs/constructors/inputMessagesFilterEmpty.html) + +[inputMessagesFilterPhotos](/API_docs/constructors/inputMessagesFilterPhotos.html) + +[inputMessagesFilterVideo](/API_docs/constructors/inputMessagesFilterVideo.html) + +[inputMessagesFilterPhotoVideo](/API_docs/constructors/inputMessagesFilterPhotoVideo.html) + +[inputMessagesFilterDocument](/API_docs/constructors/inputMessagesFilterDocument.html) + +[inputMessagesFilterUrl](/API_docs/constructors/inputMessagesFilterUrl.html) + +[inputMessagesFilterGif](/API_docs/constructors/inputMessagesFilterGif.html) + +[inputMessagesFilterVoice](/API_docs/constructors/inputMessagesFilterVoice.html) + +[inputMessagesFilterMusic](/API_docs/constructors/inputMessagesFilterMusic.html) + +[inputMessagesFilterChatPhotos](/API_docs/constructors/inputMessagesFilterChatPhotos.html) + +[inputMessagesFilterPhoneCalls](/API_docs/constructors/inputMessagesFilterPhoneCalls.html) + +[inputMessagesFilterRoundVoice](/API_docs/constructors/inputMessagesFilterRoundVoice.html) + +[inputMessagesFilterRoundVideo](/API_docs/constructors/inputMessagesFilterRoundVideo.html) + +[inputMessagesFilterMyMentions](/API_docs/constructors/inputMessagesFilterMyMentions.html) + +[inputMessagesFilterGeo](/API_docs/constructors/inputMessagesFilterGeo.html) + +[inputMessagesFilterContacts](/API_docs/constructors/inputMessagesFilterContacts.html) + +[inputMessagesFilterPinned](/API_docs/constructors/inputMessagesFilterPinned.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MissingInvitee.md b/docs/API_docs/types/MissingInvitee.md new file mode 100644 index 0000000000..0ae2e2f35d --- /dev/null +++ b/docs/API_docs/types/MissingInvitee.md @@ -0,0 +1,21 @@ +--- +title: MissingInvitee +description: constructors and methods of type MissingInvitee +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MissingInvitee +[Back to types index](index.html) + + + +### Possible values (constructors): + +[missingInvitee](/API_docs/constructors/missingInvitee.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/MyBoost.md b/docs/API_docs/types/MyBoost.md new file mode 100644 index 0000000000..6c34252dbd --- /dev/null +++ b/docs/API_docs/types/MyBoost.md @@ -0,0 +1,21 @@ +--- +title: MyBoost +description: constructors and methods of type MyBoost +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: MyBoost +[Back to types index](index.html) + + + +### Possible values (constructors): + +[myBoost](/API_docs/constructors/myBoost.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/NearestDc.md b/docs/API_docs/types/NearestDc.md new file mode 100644 index 0000000000..24c9b48923 --- /dev/null +++ b/docs/API_docs/types/NearestDc.md @@ -0,0 +1,23 @@ +--- +title: NearestDc +description: constructors and methods of type NearestDc +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: NearestDc +[Back to types index](index.html) + + + +### Possible values (constructors): + +[nearestDc](/API_docs/constructors/nearestDc.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getNearestDc](/API_docs/methods/help.getNearestDc.html) + + + diff --git a/docs/API_docs/types/NotificationSound.md b/docs/API_docs/types/NotificationSound.md new file mode 100644 index 0000000000..5ba047d6f8 --- /dev/null +++ b/docs/API_docs/types/NotificationSound.md @@ -0,0 +1,27 @@ +--- +title: NotificationSound +description: constructors and methods of type NotificationSound +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: NotificationSound +[Back to types index](index.html) + + + +### Possible values (constructors): + +[notificationSoundDefault](/API_docs/constructors/notificationSoundDefault.html) + +[notificationSoundNone](/API_docs/constructors/notificationSoundNone.html) + +[notificationSoundLocal](/API_docs/constructors/notificationSoundLocal.html) + +[notificationSoundRingtone](/API_docs/constructors/notificationSoundRingtone.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/NotifyPeer.md b/docs/API_docs/types/NotifyPeer.md new file mode 100644 index 0000000000..584d1da69f --- /dev/null +++ b/docs/API_docs/types/NotifyPeer.md @@ -0,0 +1,29 @@ +--- +title: NotifyPeer +description: constructors and methods of type NotifyPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: NotifyPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[notifyPeer](/API_docs/constructors/notifyPeer.html) + +[notifyUsers](/API_docs/constructors/notifyUsers.html) + +[notifyChats](/API_docs/constructors/notifyChats.html) + +[notifyBroadcasts](/API_docs/constructors/notifyBroadcasts.html) + +[notifyForumTopic](/API_docs/constructors/notifyForumTopic.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Null.md b/docs/API_docs/types/Null.md new file mode 100644 index 0000000000..36030e677d --- /dev/null +++ b/docs/API_docs/types/Null.md @@ -0,0 +1,21 @@ +--- +title: Null +description: constructors and methods of type Null +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Null +[Back to types index](index.html) + + + +### Possible values (constructors): + +[null](/API_docs/constructors/null.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/OutboxReadDate.md b/docs/API_docs/types/OutboxReadDate.md new file mode 100644 index 0000000000..e7f74b9734 --- /dev/null +++ b/docs/API_docs/types/OutboxReadDate.md @@ -0,0 +1,23 @@ +--- +title: OutboxReadDate +description: constructors and methods of type OutboxReadDate +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: OutboxReadDate +[Back to types index](index.html) + + + +### Possible values (constructors): + +[outboxReadDate](/API_docs/constructors/outboxReadDate.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getOutboxReadDate](/API_docs/methods/messages.getOutboxReadDate.html) + + + diff --git a/docs/API_docs/types/Page.md b/docs/API_docs/types/Page.md new file mode 100644 index 0000000000..edda7f9d37 --- /dev/null +++ b/docs/API_docs/types/Page.md @@ -0,0 +1,21 @@ +--- +title: Page +description: constructors and methods of type Page +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Page +[Back to types index](index.html) + + + +### Possible values (constructors): + +[page](/API_docs/constructors/page.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageBlock.md b/docs/API_docs/types/PageBlock.md new file mode 100644 index 0000000000..a7dfb12904 --- /dev/null +++ b/docs/API_docs/types/PageBlock.md @@ -0,0 +1,77 @@ +--- +title: PageBlock +description: constructors and methods of type PageBlock +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageBlock +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageBlockUnsupported](/API_docs/constructors/pageBlockUnsupported.html) + +[pageBlockTitle](/API_docs/constructors/pageBlockTitle.html) + +[pageBlockSubtitle](/API_docs/constructors/pageBlockSubtitle.html) + +[pageBlockAuthorDate](/API_docs/constructors/pageBlockAuthorDate.html) + +[pageBlockHeader](/API_docs/constructors/pageBlockHeader.html) + +[pageBlockSubheader](/API_docs/constructors/pageBlockSubheader.html) + +[pageBlockParagraph](/API_docs/constructors/pageBlockParagraph.html) + +[pageBlockPreformatted](/API_docs/constructors/pageBlockPreformatted.html) + +[pageBlockFooter](/API_docs/constructors/pageBlockFooter.html) + +[pageBlockDivider](/API_docs/constructors/pageBlockDivider.html) + +[pageBlockAnchor](/API_docs/constructors/pageBlockAnchor.html) + +[pageBlockList](/API_docs/constructors/pageBlockList.html) + +[pageBlockBlockquote](/API_docs/constructors/pageBlockBlockquote.html) + +[pageBlockPullquote](/API_docs/constructors/pageBlockPullquote.html) + +[pageBlockPhoto](/API_docs/constructors/pageBlockPhoto.html) + +[pageBlockVideo](/API_docs/constructors/pageBlockVideo.html) + +[pageBlockCover](/API_docs/constructors/pageBlockCover.html) + +[pageBlockEmbed](/API_docs/constructors/pageBlockEmbed.html) + +[pageBlockEmbedPost](/API_docs/constructors/pageBlockEmbedPost.html) + +[pageBlockCollage](/API_docs/constructors/pageBlockCollage.html) + +[pageBlockSlideshow](/API_docs/constructors/pageBlockSlideshow.html) + +[pageBlockChannel](/API_docs/constructors/pageBlockChannel.html) + +[pageBlockAudio](/API_docs/constructors/pageBlockAudio.html) + +[pageBlockKicker](/API_docs/constructors/pageBlockKicker.html) + +[pageBlockTable](/API_docs/constructors/pageBlockTable.html) + +[pageBlockOrderedList](/API_docs/constructors/pageBlockOrderedList.html) + +[pageBlockDetails](/API_docs/constructors/pageBlockDetails.html) + +[pageBlockRelatedArticles](/API_docs/constructors/pageBlockRelatedArticles.html) + +[pageBlockMap](/API_docs/constructors/pageBlockMap.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageCaption.md b/docs/API_docs/types/PageCaption.md new file mode 100644 index 0000000000..d3092e6239 --- /dev/null +++ b/docs/API_docs/types/PageCaption.md @@ -0,0 +1,21 @@ +--- +title: PageCaption +description: constructors and methods of type PageCaption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageCaption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageCaption](/API_docs/constructors/pageCaption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageListItem.md b/docs/API_docs/types/PageListItem.md new file mode 100644 index 0000000000..f7570903fa --- /dev/null +++ b/docs/API_docs/types/PageListItem.md @@ -0,0 +1,23 @@ +--- +title: PageListItem +description: constructors and methods of type PageListItem +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageListItem +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageListItemText](/API_docs/constructors/pageListItemText.html) + +[pageListItemBlocks](/API_docs/constructors/pageListItemBlocks.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageListOrderedItem.md b/docs/API_docs/types/PageListOrderedItem.md new file mode 100644 index 0000000000..a8c7e01a1d --- /dev/null +++ b/docs/API_docs/types/PageListOrderedItem.md @@ -0,0 +1,23 @@ +--- +title: PageListOrderedItem +description: constructors and methods of type PageListOrderedItem +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageListOrderedItem +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageListOrderedItemText](/API_docs/constructors/pageListOrderedItemText.html) + +[pageListOrderedItemBlocks](/API_docs/constructors/pageListOrderedItemBlocks.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageRelatedArticle.md b/docs/API_docs/types/PageRelatedArticle.md new file mode 100644 index 0000000000..f5d470a791 --- /dev/null +++ b/docs/API_docs/types/PageRelatedArticle.md @@ -0,0 +1,21 @@ +--- +title: PageRelatedArticle +description: constructors and methods of type PageRelatedArticle +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageRelatedArticle +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageRelatedArticle](/API_docs/constructors/pageRelatedArticle.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageTableCell.md b/docs/API_docs/types/PageTableCell.md new file mode 100644 index 0000000000..b6b9bc64dc --- /dev/null +++ b/docs/API_docs/types/PageTableCell.md @@ -0,0 +1,21 @@ +--- +title: PageTableCell +description: constructors and methods of type PageTableCell +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageTableCell +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageTableCell](/API_docs/constructors/pageTableCell.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PageTableRow.md b/docs/API_docs/types/PageTableRow.md new file mode 100644 index 0000000000..a0c31fc6d7 --- /dev/null +++ b/docs/API_docs/types/PageTableRow.md @@ -0,0 +1,21 @@ +--- +title: PageTableRow +description: constructors and methods of type PageTableRow +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PageTableRow +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pageTableRow](/API_docs/constructors/pageTableRow.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PasswordKdfAlgo.md b/docs/API_docs/types/PasswordKdfAlgo.md new file mode 100644 index 0000000000..6642551ac3 --- /dev/null +++ b/docs/API_docs/types/PasswordKdfAlgo.md @@ -0,0 +1,23 @@ +--- +title: PasswordKdfAlgo +description: constructors and methods of type PasswordKdfAlgo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PasswordKdfAlgo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[passwordKdfAlgoUnknown](/API_docs/constructors/passwordKdfAlgoUnknown.html) + +[passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow](/API_docs/constructors/passwordKdfAlgoSHA256SHA256PBKDF2HMACSHA512iter100000SHA256ModPow.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PaymentCharge.md b/docs/API_docs/types/PaymentCharge.md new file mode 100644 index 0000000000..5e566e22b7 --- /dev/null +++ b/docs/API_docs/types/PaymentCharge.md @@ -0,0 +1,21 @@ +--- +title: PaymentCharge +description: constructors and methods of type PaymentCharge +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PaymentCharge +[Back to types index](index.html) + + + +### Possible values (constructors): + +[paymentCharge](/API_docs/constructors/paymentCharge.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PaymentFormMethod.md b/docs/API_docs/types/PaymentFormMethod.md new file mode 100644 index 0000000000..c9b93455b9 --- /dev/null +++ b/docs/API_docs/types/PaymentFormMethod.md @@ -0,0 +1,21 @@ +--- +title: PaymentFormMethod +description: constructors and methods of type PaymentFormMethod +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PaymentFormMethod +[Back to types index](index.html) + + + +### Possible values (constructors): + +[paymentFormMethod](/API_docs/constructors/paymentFormMethod.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PaymentRequestedInfo.md b/docs/API_docs/types/PaymentRequestedInfo.md new file mode 100644 index 0000000000..5ee9add3cc --- /dev/null +++ b/docs/API_docs/types/PaymentRequestedInfo.md @@ -0,0 +1,21 @@ +--- +title: PaymentRequestedInfo +description: constructors and methods of type PaymentRequestedInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PaymentRequestedInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[paymentRequestedInfo](/API_docs/constructors/paymentRequestedInfo.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PaymentSavedCredentials.md b/docs/API_docs/types/PaymentSavedCredentials.md new file mode 100644 index 0000000000..355e9cfdd8 --- /dev/null +++ b/docs/API_docs/types/PaymentSavedCredentials.md @@ -0,0 +1,21 @@ +--- +title: PaymentSavedCredentials +description: constructors and methods of type PaymentSavedCredentials +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PaymentSavedCredentials +[Back to types index](index.html) + + + +### Possible values (constructors): + +[paymentSavedCredentialsCard](/API_docs/constructors/paymentSavedCredentialsCard.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Peer.md b/docs/API_docs/types/Peer.md new file mode 100644 index 0000000000..cc2b97ed93 --- /dev/null +++ b/docs/API_docs/types/Peer.md @@ -0,0 +1,62 @@ +--- +title: Peer +description: constructors and methods of type Peer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Peer +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$Peer = '@username'; // Username + +$Peer = $update; // Update objects received in the event handler + +$Peer = 'me'; // The currently logged-in user + +$Peer = 44700; // bot API id (users) +$Peer = -492772765; // bot API id (chats) +$Peer = -10038575794; // bot API id (channels) + +$Peer = 'https://t.me/danogentili'; // t.me URLs +$Peer = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + + + +### Possible values (constructors): + +[peerUser](/API_docs/constructors/peerUser.html) + +[peerChat](/API_docs/constructors/peerChat.html) + +[peerChannel](/API_docs/constructors/peerChannel.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->chatlists->getLeaveChatlistSuggestions](/API_docs/methods/chatlists.getLeaveChatlistSuggestions.html) + + + diff --git a/docs/API_docs/types/PeerBlocked.md b/docs/API_docs/types/PeerBlocked.md new file mode 100644 index 0000000000..ac2b7948a3 --- /dev/null +++ b/docs/API_docs/types/PeerBlocked.md @@ -0,0 +1,21 @@ +--- +title: PeerBlocked +description: constructors and methods of type PeerBlocked +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PeerBlocked +[Back to types index](index.html) + + + +### Possible values (constructors): + +[peerBlocked](/API_docs/constructors/peerBlocked.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PeerColor.md b/docs/API_docs/types/PeerColor.md new file mode 100644 index 0000000000..aaec69f6f2 --- /dev/null +++ b/docs/API_docs/types/PeerColor.md @@ -0,0 +1,21 @@ +--- +title: PeerColor +description: constructors and methods of type PeerColor +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PeerColor +[Back to types index](index.html) + + + +### Possible values (constructors): + +[peerColor](/API_docs/constructors/peerColor.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PeerLocated.md b/docs/API_docs/types/PeerLocated.md new file mode 100644 index 0000000000..8aaf69aa2b --- /dev/null +++ b/docs/API_docs/types/PeerLocated.md @@ -0,0 +1,23 @@ +--- +title: PeerLocated +description: constructors and methods of type PeerLocated +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PeerLocated +[Back to types index](index.html) + + + +### Possible values (constructors): + +[peerLocated](/API_docs/constructors/peerLocated.html) + +[peerSelfLocated](/API_docs/constructors/peerSelfLocated.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PeerNotifySettings.md b/docs/API_docs/types/PeerNotifySettings.md new file mode 100644 index 0000000000..a7fcf4a932 --- /dev/null +++ b/docs/API_docs/types/PeerNotifySettings.md @@ -0,0 +1,23 @@ +--- +title: PeerNotifySettings +description: constructors and methods of type PeerNotifySettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PeerNotifySettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[peerNotifySettings](/API_docs/constructors/peerNotifySettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getNotifySettings](/API_docs/methods/account.getNotifySettings.html) + + + diff --git a/docs/API_docs/types/PeerSettings.md b/docs/API_docs/types/PeerSettings.md new file mode 100644 index 0000000000..6d4bc645b7 --- /dev/null +++ b/docs/API_docs/types/PeerSettings.md @@ -0,0 +1,21 @@ +--- +title: PeerSettings +description: constructors and methods of type PeerSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PeerSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[peerSettings](/API_docs/constructors/peerSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PeerStories.md b/docs/API_docs/types/PeerStories.md new file mode 100644 index 0000000000..2e84b6d0f5 --- /dev/null +++ b/docs/API_docs/types/PeerStories.md @@ -0,0 +1,21 @@ +--- +title: PeerStories +description: constructors and methods of type PeerStories +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PeerStories +[Back to types index](index.html) + + + +### Possible values (constructors): + +[peerStories](/API_docs/constructors/peerStories.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PhoneCall.md b/docs/API_docs/types/PhoneCall.md new file mode 100644 index 0000000000..019942b6f9 --- /dev/null +++ b/docs/API_docs/types/PhoneCall.md @@ -0,0 +1,31 @@ +--- +title: PhoneCall +description: constructors and methods of type PhoneCall +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PhoneCall +[Back to types index](index.html) + +See [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) for the full documentation! + +### Possible values (constructors): + +[phoneCallEmpty](/API_docs/constructors/phoneCallEmpty.html) + +[phoneCallWaiting](/API_docs/constructors/phoneCallWaiting.html) + +[phoneCallRequested](/API_docs/constructors/phoneCallRequested.html) + +[phoneCallAccepted](/API_docs/constructors/phoneCallAccepted.html) + +[phoneCall](/API_docs/constructors/phoneCall.html) + +[phoneCallDiscarded](/API_docs/constructors/phoneCallDiscarded.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PhoneCallDiscardReason.md b/docs/API_docs/types/PhoneCallDiscardReason.md new file mode 100644 index 0000000000..af0dc47626 --- /dev/null +++ b/docs/API_docs/types/PhoneCallDiscardReason.md @@ -0,0 +1,27 @@ +--- +title: PhoneCallDiscardReason +description: constructors and methods of type PhoneCallDiscardReason +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PhoneCallDiscardReason +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phoneCallDiscardReasonMissed](/API_docs/constructors/phoneCallDiscardReasonMissed.html) + +[phoneCallDiscardReasonDisconnect](/API_docs/constructors/phoneCallDiscardReasonDisconnect.html) + +[phoneCallDiscardReasonHangup](/API_docs/constructors/phoneCallDiscardReasonHangup.html) + +[phoneCallDiscardReasonBusy](/API_docs/constructors/phoneCallDiscardReasonBusy.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PhoneCallProtocol.md b/docs/API_docs/types/PhoneCallProtocol.md new file mode 100644 index 0000000000..24fb705a4d --- /dev/null +++ b/docs/API_docs/types/PhoneCallProtocol.md @@ -0,0 +1,21 @@ +--- +title: PhoneCallProtocol +description: constructors and methods of type PhoneCallProtocol +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PhoneCallProtocol +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phoneCallProtocol](/API_docs/constructors/phoneCallProtocol.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PhoneConnection.md b/docs/API_docs/types/PhoneConnection.md new file mode 100644 index 0000000000..bb6d0dd7d5 --- /dev/null +++ b/docs/API_docs/types/PhoneConnection.md @@ -0,0 +1,23 @@ +--- +title: PhoneConnection +description: constructors and methods of type PhoneConnection +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PhoneConnection +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phoneConnection](/API_docs/constructors/phoneConnection.html) + +[phoneConnectionWebrtc](/API_docs/constructors/phoneConnectionWebrtc.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Photo.md b/docs/API_docs/types/Photo.md new file mode 100644 index 0000000000..871d1dc6c9 --- /dev/null +++ b/docs/API_docs/types/Photo.md @@ -0,0 +1,23 @@ +--- +title: Photo +description: constructors and methods of type Photo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Photo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[photoEmpty](/API_docs/constructors/photoEmpty.html) + +[photo](/API_docs/constructors/photo.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PhotoSize.md b/docs/API_docs/types/PhotoSize.md new file mode 100644 index 0000000000..93a7509a78 --- /dev/null +++ b/docs/API_docs/types/PhotoSize.md @@ -0,0 +1,35 @@ +--- +title: PhotoSize +description: constructors and methods of type PhotoSize +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PhotoSize +[Back to types index](index.html) + + + +### Possible values (constructors): + +[photoSizeEmpty](/API_docs/constructors/photoSizeEmpty.html) + +[photoSize](/API_docs/constructors/photoSize.html) + +[photoCachedSize](/API_docs/constructors/photoCachedSize.html) + +[photoStrippedSize](/API_docs/constructors/photoStrippedSize.html) + +[photoSizeProgressive](/API_docs/constructors/photoSizeProgressive.html) + +[photoPathSize](/API_docs/constructors/photoPathSize.html) + +[photoSize\_23](/API_docs/constructors/photoSize_23.html) + +[photoCachedSize\_23](/API_docs/constructors/photoCachedSize_23.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Poll.md b/docs/API_docs/types/Poll.md new file mode 100644 index 0000000000..affb2c65d1 --- /dev/null +++ b/docs/API_docs/types/Poll.md @@ -0,0 +1,21 @@ +--- +title: Poll +description: constructors and methods of type Poll +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Poll +[Back to types index](index.html) + + + +### Possible values (constructors): + +[poll](/API_docs/constructors/poll.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PollAnswer.md b/docs/API_docs/types/PollAnswer.md new file mode 100644 index 0000000000..4c4cc57fcf --- /dev/null +++ b/docs/API_docs/types/PollAnswer.md @@ -0,0 +1,21 @@ +--- +title: PollAnswer +description: constructors and methods of type PollAnswer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PollAnswer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pollAnswer](/API_docs/constructors/pollAnswer.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PollAnswerVoters.md b/docs/API_docs/types/PollAnswerVoters.md new file mode 100644 index 0000000000..a2f79bc16b --- /dev/null +++ b/docs/API_docs/types/PollAnswerVoters.md @@ -0,0 +1,21 @@ +--- +title: PollAnswerVoters +description: constructors and methods of type PollAnswerVoters +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PollAnswerVoters +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pollAnswerVoters](/API_docs/constructors/pollAnswerVoters.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PollResults.md b/docs/API_docs/types/PollResults.md new file mode 100644 index 0000000000..5314170a6d --- /dev/null +++ b/docs/API_docs/types/PollResults.md @@ -0,0 +1,21 @@ +--- +title: PollResults +description: constructors and methods of type PollResults +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PollResults +[Back to types index](index.html) + + + +### Possible values (constructors): + +[pollResults](/API_docs/constructors/pollResults.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PopularContact.md b/docs/API_docs/types/PopularContact.md new file mode 100644 index 0000000000..ded9a8812c --- /dev/null +++ b/docs/API_docs/types/PopularContact.md @@ -0,0 +1,21 @@ +--- +title: PopularContact +description: constructors and methods of type PopularContact +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PopularContact +[Back to types index](index.html) + + + +### Possible values (constructors): + +[popularContact](/API_docs/constructors/popularContact.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PostAddress.md b/docs/API_docs/types/PostAddress.md new file mode 100644 index 0000000000..f97111fd8a --- /dev/null +++ b/docs/API_docs/types/PostAddress.md @@ -0,0 +1,21 @@ +--- +title: PostAddress +description: constructors and methods of type PostAddress +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PostAddress +[Back to types index](index.html) + + + +### Possible values (constructors): + +[postAddress](/API_docs/constructors/postAddress.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PostInteractionCounters.md b/docs/API_docs/types/PostInteractionCounters.md new file mode 100644 index 0000000000..26371336d0 --- /dev/null +++ b/docs/API_docs/types/PostInteractionCounters.md @@ -0,0 +1,23 @@ +--- +title: PostInteractionCounters +description: constructors and methods of type PostInteractionCounters +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PostInteractionCounters +[Back to types index](index.html) + + + +### Possible values (constructors): + +[postInteractionCountersMessage](/API_docs/constructors/postInteractionCountersMessage.html) + +[postInteractionCountersStory](/API_docs/constructors/postInteractionCountersStory.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PremiumGiftCodeOption.md b/docs/API_docs/types/PremiumGiftCodeOption.md new file mode 100644 index 0000000000..796d3ecd32 --- /dev/null +++ b/docs/API_docs/types/PremiumGiftCodeOption.md @@ -0,0 +1,23 @@ +--- +title: PremiumGiftCodeOption +description: constructors and methods of type PremiumGiftCodeOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PremiumGiftCodeOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[premiumGiftCodeOption](/API_docs/constructors/premiumGiftCodeOption.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->getPremiumGiftCodeOptions](/API_docs/methods/payments.getPremiumGiftCodeOptions.html) + + + diff --git a/docs/API_docs/types/PremiumGiftOption.md b/docs/API_docs/types/PremiumGiftOption.md new file mode 100644 index 0000000000..6408bc827e --- /dev/null +++ b/docs/API_docs/types/PremiumGiftOption.md @@ -0,0 +1,21 @@ +--- +title: PremiumGiftOption +description: constructors and methods of type PremiumGiftOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PremiumGiftOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[premiumGiftOption](/API_docs/constructors/premiumGiftOption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PremiumSubscriptionOption.md b/docs/API_docs/types/PremiumSubscriptionOption.md new file mode 100644 index 0000000000..8acb06ff46 --- /dev/null +++ b/docs/API_docs/types/PremiumSubscriptionOption.md @@ -0,0 +1,21 @@ +--- +title: PremiumSubscriptionOption +description: constructors and methods of type PremiumSubscriptionOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PremiumSubscriptionOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[premiumSubscriptionOption](/API_docs/constructors/premiumSubscriptionOption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PrepaidGiveaway.md b/docs/API_docs/types/PrepaidGiveaway.md new file mode 100644 index 0000000000..2fd641ae7d --- /dev/null +++ b/docs/API_docs/types/PrepaidGiveaway.md @@ -0,0 +1,21 @@ +--- +title: PrepaidGiveaway +description: constructors and methods of type PrepaidGiveaway +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PrepaidGiveaway +[Back to types index](index.html) + + + +### Possible values (constructors): + +[prepaidGiveaway](/API_docs/constructors/prepaidGiveaway.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PrivacyKey.md b/docs/API_docs/types/PrivacyKey.md new file mode 100644 index 0000000000..9f0a2167be --- /dev/null +++ b/docs/API_docs/types/PrivacyKey.md @@ -0,0 +1,41 @@ +--- +title: PrivacyKey +description: constructors and methods of type PrivacyKey +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PrivacyKey +[Back to types index](index.html) + + + +### Possible values (constructors): + +[privacyKeyStatusTimestamp](/API_docs/constructors/privacyKeyStatusTimestamp.html) + +[privacyKeyChatInvite](/API_docs/constructors/privacyKeyChatInvite.html) + +[privacyKeyPhoneCall](/API_docs/constructors/privacyKeyPhoneCall.html) + +[privacyKeyPhoneP2P](/API_docs/constructors/privacyKeyPhoneP2P.html) + +[privacyKeyForwards](/API_docs/constructors/privacyKeyForwards.html) + +[privacyKeyProfilePhoto](/API_docs/constructors/privacyKeyProfilePhoto.html) + +[privacyKeyPhoneNumber](/API_docs/constructors/privacyKeyPhoneNumber.html) + +[privacyKeyAddedByPhone](/API_docs/constructors/privacyKeyAddedByPhone.html) + +[privacyKeyVoiceMessages](/API_docs/constructors/privacyKeyVoiceMessages.html) + +[privacyKeyAbout](/API_docs/constructors/privacyKeyAbout.html) + +[privacyKeyBirthday](/API_docs/constructors/privacyKeyBirthday.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PrivacyRule.md b/docs/API_docs/types/PrivacyRule.md new file mode 100644 index 0000000000..968e66a551 --- /dev/null +++ b/docs/API_docs/types/PrivacyRule.md @@ -0,0 +1,39 @@ +--- +title: PrivacyRule +description: constructors and methods of type PrivacyRule +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PrivacyRule +[Back to types index](index.html) + + + +### Possible values (constructors): + +[privacyValueAllowContacts](/API_docs/constructors/privacyValueAllowContacts.html) + +[privacyValueAllowAll](/API_docs/constructors/privacyValueAllowAll.html) + +[privacyValueAllowUsers](/API_docs/constructors/privacyValueAllowUsers.html) + +[privacyValueDisallowContacts](/API_docs/constructors/privacyValueDisallowContacts.html) + +[privacyValueDisallowAll](/API_docs/constructors/privacyValueDisallowAll.html) + +[privacyValueDisallowUsers](/API_docs/constructors/privacyValueDisallowUsers.html) + +[privacyValueAllowChatParticipants](/API_docs/constructors/privacyValueAllowChatParticipants.html) + +[privacyValueDisallowChatParticipants](/API_docs/constructors/privacyValueDisallowChatParticipants.html) + +[privacyValueAllowCloseFriends](/API_docs/constructors/privacyValueAllowCloseFriends.html) + +[privacyValueAllowPremium](/API_docs/constructors/privacyValueAllowPremium.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/PublicForward.md b/docs/API_docs/types/PublicForward.md new file mode 100644 index 0000000000..17aeb75941 --- /dev/null +++ b/docs/API_docs/types/PublicForward.md @@ -0,0 +1,23 @@ +--- +title: PublicForward +description: constructors and methods of type PublicForward +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: PublicForward +[Back to types index](index.html) + + + +### Possible values (constructors): + +[publicForwardMessage](/API_docs/constructors/publicForwardMessage.html) + +[publicForwardStory](/API_docs/constructors/publicForwardStory.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/QuickReply.md b/docs/API_docs/types/QuickReply.md new file mode 100644 index 0000000000..ccb6a5d394 --- /dev/null +++ b/docs/API_docs/types/QuickReply.md @@ -0,0 +1,21 @@ +--- +title: QuickReply +description: constructors and methods of type QuickReply +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: QuickReply +[Back to types index](index.html) + + + +### Possible values (constructors): + +[quickReply](/API_docs/constructors/quickReply.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Reaction.md b/docs/API_docs/types/Reaction.md new file mode 100644 index 0000000000..0bfa61cabf --- /dev/null +++ b/docs/API_docs/types/Reaction.md @@ -0,0 +1,25 @@ +--- +title: Reaction +description: constructors and methods of type Reaction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Reaction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[reactionEmpty](/API_docs/constructors/reactionEmpty.html) + +[reactionEmoji](/API_docs/constructors/reactionEmoji.html) + +[reactionCustomEmoji](/API_docs/constructors/reactionCustomEmoji.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ReactionCount.md b/docs/API_docs/types/ReactionCount.md new file mode 100644 index 0000000000..c450bd5f63 --- /dev/null +++ b/docs/API_docs/types/ReactionCount.md @@ -0,0 +1,21 @@ +--- +title: ReactionCount +description: constructors and methods of type ReactionCount +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReactionCount +[Back to types index](index.html) + + + +### Possible values (constructors): + +[reactionCount](/API_docs/constructors/reactionCount.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ReactionNotificationsFrom.md b/docs/API_docs/types/ReactionNotificationsFrom.md new file mode 100644 index 0000000000..0c3b01de92 --- /dev/null +++ b/docs/API_docs/types/ReactionNotificationsFrom.md @@ -0,0 +1,23 @@ +--- +title: ReactionNotificationsFrom +description: constructors and methods of type ReactionNotificationsFrom +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReactionNotificationsFrom +[Back to types index](index.html) + + + +### Possible values (constructors): + +[reactionNotificationsFromContacts](/API_docs/constructors/reactionNotificationsFromContacts.html) + +[reactionNotificationsFromAll](/API_docs/constructors/reactionNotificationsFromAll.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ReactionsNotifySettings.md b/docs/API_docs/types/ReactionsNotifySettings.md new file mode 100644 index 0000000000..dd805f0357 --- /dev/null +++ b/docs/API_docs/types/ReactionsNotifySettings.md @@ -0,0 +1,25 @@ +--- +title: ReactionsNotifySettings +description: constructors and methods of type ReactionsNotifySettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReactionsNotifySettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[reactionsNotifySettings](/API_docs/constructors/reactionsNotifySettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getReactionsNotifySettings](/API_docs/methods/account.getReactionsNotifySettings.html) + +[$MadelineProto->account->setReactionsNotifySettings](/API_docs/methods/account.setReactionsNotifySettings.html) + + + diff --git a/docs/API_docs/types/ReadParticipantDate.md b/docs/API_docs/types/ReadParticipantDate.md new file mode 100644 index 0000000000..15485e9d7a --- /dev/null +++ b/docs/API_docs/types/ReadParticipantDate.md @@ -0,0 +1,23 @@ +--- +title: ReadParticipantDate +description: constructors and methods of type ReadParticipantDate +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReadParticipantDate +[Back to types index](index.html) + + + +### Possible values (constructors): + +[readParticipantDate](/API_docs/constructors/readParticipantDate.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getMessageReadParticipants](/API_docs/methods/messages.getMessageReadParticipants.html) + + + diff --git a/docs/API_docs/types/ReceivedNotifyMessage.md b/docs/API_docs/types/ReceivedNotifyMessage.md new file mode 100644 index 0000000000..ee4878d46c --- /dev/null +++ b/docs/API_docs/types/ReceivedNotifyMessage.md @@ -0,0 +1,23 @@ +--- +title: ReceivedNotifyMessage +description: constructors and methods of type ReceivedNotifyMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReceivedNotifyMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[receivedNotifyMessage](/API_docs/constructors/receivedNotifyMessage.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->receivedMessages](/API_docs/methods/messages.receivedMessages.html) + + + diff --git a/docs/API_docs/types/RecentMeUrl.md b/docs/API_docs/types/RecentMeUrl.md new file mode 100644 index 0000000000..354e5beab3 --- /dev/null +++ b/docs/API_docs/types/RecentMeUrl.md @@ -0,0 +1,29 @@ +--- +title: RecentMeUrl +description: constructors and methods of type RecentMeUrl +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: RecentMeUrl +[Back to types index](index.html) + + + +### Possible values (constructors): + +[recentMeUrlUnknown](/API_docs/constructors/recentMeUrlUnknown.html) + +[recentMeUrlUser](/API_docs/constructors/recentMeUrlUser.html) + +[recentMeUrlChat](/API_docs/constructors/recentMeUrlChat.html) + +[recentMeUrlChatInvite](/API_docs/constructors/recentMeUrlChatInvite.html) + +[recentMeUrlStickerSet](/API_docs/constructors/recentMeUrlStickerSet.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ReplyMarkup.md b/docs/API_docs/types/ReplyMarkup.md new file mode 100644 index 0000000000..43d55a6079 --- /dev/null +++ b/docs/API_docs/types/ReplyMarkup.md @@ -0,0 +1,33 @@ +--- +title: ReplyMarkup +description: constructors and methods of type ReplyMarkup +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReplyMarkup +[Back to types index](index.html) + +For simplicity, you can also provide a bot API markup object, one of: +- [bot API InlineKeyboardMarkup](https://core.telegram.org/bots/api#inlinekeyboardmarkup) +- [bot API ReplyKeyboardMarkup](https://core.telegram.org/bots/api#replykeyboardmarkup) +- [bot API ReplyKeyboardRemove](https://core.telegram.org/bots/api#replykeyboardremove) +- [bot API ForceReply](https://core.telegram.org/bots/api#forcereply) + + + +### Possible values (constructors): + +[replyKeyboardHide](/API_docs/constructors/replyKeyboardHide.html) + +[replyKeyboardForceReply](/API_docs/constructors/replyKeyboardForceReply.html) + +[replyKeyboardMarkup](/API_docs/constructors/replyKeyboardMarkup.html) + +[replyInlineMarkup](/API_docs/constructors/replyInlineMarkup.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ReportReason.md b/docs/API_docs/types/ReportReason.md new file mode 100644 index 0000000000..39a0b51a45 --- /dev/null +++ b/docs/API_docs/types/ReportReason.md @@ -0,0 +1,39 @@ +--- +title: ReportReason +description: constructors and methods of type ReportReason +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ReportReason +[Back to types index](index.html) + + + +### Possible values (constructors): + +[inputReportReasonSpam](/API_docs/constructors/inputReportReasonSpam.html) + +[inputReportReasonViolence](/API_docs/constructors/inputReportReasonViolence.html) + +[inputReportReasonPornography](/API_docs/constructors/inputReportReasonPornography.html) + +[inputReportReasonChildAbuse](/API_docs/constructors/inputReportReasonChildAbuse.html) + +[inputReportReasonOther](/API_docs/constructors/inputReportReasonOther.html) + +[inputReportReasonCopyright](/API_docs/constructors/inputReportReasonCopyright.html) + +[inputReportReasonGeoIrrelevant](/API_docs/constructors/inputReportReasonGeoIrrelevant.html) + +[inputReportReasonFake](/API_docs/constructors/inputReportReasonFake.html) + +[inputReportReasonIllegalDrugs](/API_docs/constructors/inputReportReasonIllegalDrugs.html) + +[inputReportReasonPersonalDetails](/API_docs/constructors/inputReportReasonPersonalDetails.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/RequestPeerType.md b/docs/API_docs/types/RequestPeerType.md new file mode 100644 index 0000000000..6dcd2a3b7f --- /dev/null +++ b/docs/API_docs/types/RequestPeerType.md @@ -0,0 +1,25 @@ +--- +title: RequestPeerType +description: constructors and methods of type RequestPeerType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: RequestPeerType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[requestPeerTypeUser](/API_docs/constructors/requestPeerTypeUser.html) + +[requestPeerTypeChat](/API_docs/constructors/requestPeerTypeChat.html) + +[requestPeerTypeBroadcast](/API_docs/constructors/requestPeerTypeBroadcast.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/RequestedPeer.md b/docs/API_docs/types/RequestedPeer.md new file mode 100644 index 0000000000..f8e749ee19 --- /dev/null +++ b/docs/API_docs/types/RequestedPeer.md @@ -0,0 +1,25 @@ +--- +title: RequestedPeer +description: constructors and methods of type RequestedPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: RequestedPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[requestedPeerUser](/API_docs/constructors/requestedPeerUser.html) + +[requestedPeerChat](/API_docs/constructors/requestedPeerChat.html) + +[requestedPeerChannel](/API_docs/constructors/requestedPeerChannel.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/RestrictionReason.md b/docs/API_docs/types/RestrictionReason.md new file mode 100644 index 0000000000..3716f86da7 --- /dev/null +++ b/docs/API_docs/types/RestrictionReason.md @@ -0,0 +1,21 @@ +--- +title: RestrictionReason +description: constructors and methods of type RestrictionReason +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: RestrictionReason +[Back to types index](index.html) + + + +### Possible values (constructors): + +[restrictionReason](/API_docs/constructors/restrictionReason.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/RichText.md b/docs/API_docs/types/RichText.md new file mode 100644 index 0000000000..b62a2d975f --- /dev/null +++ b/docs/API_docs/types/RichText.md @@ -0,0 +1,51 @@ +--- +title: RichText +description: constructors and methods of type RichText +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: RichText +[Back to types index](index.html) + + + +### Possible values (constructors): + +[textEmpty](/API_docs/constructors/textEmpty.html) + +[textPlain](/API_docs/constructors/textPlain.html) + +[textBold](/API_docs/constructors/textBold.html) + +[textItalic](/API_docs/constructors/textItalic.html) + +[textUnderline](/API_docs/constructors/textUnderline.html) + +[textStrike](/API_docs/constructors/textStrike.html) + +[textFixed](/API_docs/constructors/textFixed.html) + +[textUrl](/API_docs/constructors/textUrl.html) + +[textEmail](/API_docs/constructors/textEmail.html) + +[textConcat](/API_docs/constructors/textConcat.html) + +[textSubscript](/API_docs/constructors/textSubscript.html) + +[textSuperscript](/API_docs/constructors/textSuperscript.html) + +[textMarked](/API_docs/constructors/textMarked.html) + +[textPhone](/API_docs/constructors/textPhone.html) + +[textImage](/API_docs/constructors/textImage.html) + +[textAnchor](/API_docs/constructors/textAnchor.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SavedContact.md b/docs/API_docs/types/SavedContact.md new file mode 100644 index 0000000000..7a5c32ae8b --- /dev/null +++ b/docs/API_docs/types/SavedContact.md @@ -0,0 +1,23 @@ +--- +title: SavedContact +description: constructors and methods of type SavedContact +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SavedContact +[Back to types index](index.html) + + + +### Possible values (constructors): + +[savedPhoneContact](/API_docs/constructors/savedPhoneContact.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->getSaved](/API_docs/methods/contacts.getSaved.html) + + + diff --git a/docs/API_docs/types/SavedDialog.md b/docs/API_docs/types/SavedDialog.md new file mode 100644 index 0000000000..927a7ae6fa --- /dev/null +++ b/docs/API_docs/types/SavedDialog.md @@ -0,0 +1,21 @@ +--- +title: SavedDialog +description: constructors and methods of type SavedDialog +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SavedDialog +[Back to types index](index.html) + + + +### Possible values (constructors): + +[savedDialog](/API_docs/constructors/savedDialog.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SavedReactionTag.md b/docs/API_docs/types/SavedReactionTag.md new file mode 100644 index 0000000000..2971f87100 --- /dev/null +++ b/docs/API_docs/types/SavedReactionTag.md @@ -0,0 +1,21 @@ +--- +title: SavedReactionTag +description: constructors and methods of type SavedReactionTag +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SavedReactionTag +[Back to types index](index.html) + + + +### Possible values (constructors): + +[savedReactionTag](/API_docs/constructors/savedReactionTag.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SearchResultsCalendarPeriod.md b/docs/API_docs/types/SearchResultsCalendarPeriod.md new file mode 100644 index 0000000000..b0716aef00 --- /dev/null +++ b/docs/API_docs/types/SearchResultsCalendarPeriod.md @@ -0,0 +1,21 @@ +--- +title: SearchResultsCalendarPeriod +description: constructors and methods of type SearchResultsCalendarPeriod +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SearchResultsCalendarPeriod +[Back to types index](index.html) + + + +### Possible values (constructors): + +[searchResultsCalendarPeriod](/API_docs/constructors/searchResultsCalendarPeriod.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SearchResultsPosition.md b/docs/API_docs/types/SearchResultsPosition.md new file mode 100644 index 0000000000..e05806ceab --- /dev/null +++ b/docs/API_docs/types/SearchResultsPosition.md @@ -0,0 +1,21 @@ +--- +title: SearchResultsPosition +description: constructors and methods of type SearchResultsPosition +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SearchResultsPosition +[Back to types index](index.html) + + + +### Possible values (constructors): + +[searchResultPosition](/API_docs/constructors/searchResultPosition.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureCredentialsEncrypted.md b/docs/API_docs/types/SecureCredentialsEncrypted.md new file mode 100644 index 0000000000..5d0120102c --- /dev/null +++ b/docs/API_docs/types/SecureCredentialsEncrypted.md @@ -0,0 +1,21 @@ +--- +title: SecureCredentialsEncrypted +description: constructors and methods of type SecureCredentialsEncrypted +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureCredentialsEncrypted +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureCredentialsEncrypted](/API_docs/constructors/secureCredentialsEncrypted.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureData.md b/docs/API_docs/types/SecureData.md new file mode 100644 index 0000000000..4daf0facdc --- /dev/null +++ b/docs/API_docs/types/SecureData.md @@ -0,0 +1,21 @@ +--- +title: SecureData +description: constructors and methods of type SecureData +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureData +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureData](/API_docs/constructors/secureData.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureFile.md b/docs/API_docs/types/SecureFile.md new file mode 100644 index 0000000000..836f1ca6b2 --- /dev/null +++ b/docs/API_docs/types/SecureFile.md @@ -0,0 +1,23 @@ +--- +title: SecureFile +description: constructors and methods of type SecureFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureFile +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureFileEmpty](/API_docs/constructors/secureFileEmpty.html) + +[secureFile](/API_docs/constructors/secureFile.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecurePasswordKdfAlgo.md b/docs/API_docs/types/SecurePasswordKdfAlgo.md new file mode 100644 index 0000000000..507e9b0349 --- /dev/null +++ b/docs/API_docs/types/SecurePasswordKdfAlgo.md @@ -0,0 +1,25 @@ +--- +title: SecurePasswordKdfAlgo +description: constructors and methods of type SecurePasswordKdfAlgo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecurePasswordKdfAlgo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[securePasswordKdfAlgoUnknown](/API_docs/constructors/securePasswordKdfAlgoUnknown.html) + +[securePasswordKdfAlgoPBKDF2HMACSHA512iter100000](/API_docs/constructors/securePasswordKdfAlgoPBKDF2HMACSHA512iter100000.html) + +[securePasswordKdfAlgoSHA512](/API_docs/constructors/securePasswordKdfAlgoSHA512.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecurePlainData.md b/docs/API_docs/types/SecurePlainData.md new file mode 100644 index 0000000000..27bf7ed907 --- /dev/null +++ b/docs/API_docs/types/SecurePlainData.md @@ -0,0 +1,23 @@ +--- +title: SecurePlainData +description: constructors and methods of type SecurePlainData +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecurePlainData +[Back to types index](index.html) + + + +### Possible values (constructors): + +[securePlainPhone](/API_docs/constructors/securePlainPhone.html) + +[securePlainEmail](/API_docs/constructors/securePlainEmail.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureRequiredType.md b/docs/API_docs/types/SecureRequiredType.md new file mode 100644 index 0000000000..9d6a0ca18f --- /dev/null +++ b/docs/API_docs/types/SecureRequiredType.md @@ -0,0 +1,23 @@ +--- +title: SecureRequiredType +description: constructors and methods of type SecureRequiredType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureRequiredType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureRequiredType](/API_docs/constructors/secureRequiredType.html) + +[secureRequiredTypeOneOf](/API_docs/constructors/secureRequiredTypeOneOf.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureSecretSettings.md b/docs/API_docs/types/SecureSecretSettings.md new file mode 100644 index 0000000000..b1becd8bb3 --- /dev/null +++ b/docs/API_docs/types/SecureSecretSettings.md @@ -0,0 +1,21 @@ +--- +title: SecureSecretSettings +description: constructors and methods of type SecureSecretSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureSecretSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureSecretSettings](/API_docs/constructors/secureSecretSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureValue.md b/docs/API_docs/types/SecureValue.md new file mode 100644 index 0000000000..b4520b91e9 --- /dev/null +++ b/docs/API_docs/types/SecureValue.md @@ -0,0 +1,27 @@ +--- +title: SecureValue +description: constructors and methods of type SecureValue +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureValue +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureValue](/API_docs/constructors/secureValue.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getAllSecureValues](/API_docs/methods/account.getAllSecureValues.html) + +[$MadelineProto->account->getSecureValue](/API_docs/methods/account.getSecureValue.html) + +[$MadelineProto->account->saveSecureValue](/API_docs/methods/account.saveSecureValue.html) + + + diff --git a/docs/API_docs/types/SecureValueError.md b/docs/API_docs/types/SecureValueError.md new file mode 100644 index 0000000000..4500f40328 --- /dev/null +++ b/docs/API_docs/types/SecureValueError.md @@ -0,0 +1,37 @@ +--- +title: SecureValueError +description: constructors and methods of type SecureValueError +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureValueError +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureValueErrorData](/API_docs/constructors/secureValueErrorData.html) + +[secureValueErrorFrontSide](/API_docs/constructors/secureValueErrorFrontSide.html) + +[secureValueErrorReverseSide](/API_docs/constructors/secureValueErrorReverseSide.html) + +[secureValueErrorSelfie](/API_docs/constructors/secureValueErrorSelfie.html) + +[secureValueErrorFile](/API_docs/constructors/secureValueErrorFile.html) + +[secureValueErrorFiles](/API_docs/constructors/secureValueErrorFiles.html) + +[secureValueError](/API_docs/constructors/secureValueError.html) + +[secureValueErrorTranslationFile](/API_docs/constructors/secureValueErrorTranslationFile.html) + +[secureValueErrorTranslationFiles](/API_docs/constructors/secureValueErrorTranslationFiles.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureValueHash.md b/docs/API_docs/types/SecureValueHash.md new file mode 100644 index 0000000000..224f1f1243 --- /dev/null +++ b/docs/API_docs/types/SecureValueHash.md @@ -0,0 +1,21 @@ +--- +title: SecureValueHash +description: constructors and methods of type SecureValueHash +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureValueHash +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureValueHash](/API_docs/constructors/secureValueHash.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SecureValueType.md b/docs/API_docs/types/SecureValueType.md new file mode 100644 index 0000000000..5f2e7a7037 --- /dev/null +++ b/docs/API_docs/types/SecureValueType.md @@ -0,0 +1,45 @@ +--- +title: SecureValueType +description: constructors and methods of type SecureValueType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SecureValueType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[secureValueTypePersonalDetails](/API_docs/constructors/secureValueTypePersonalDetails.html) + +[secureValueTypePassport](/API_docs/constructors/secureValueTypePassport.html) + +[secureValueTypeDriverLicense](/API_docs/constructors/secureValueTypeDriverLicense.html) + +[secureValueTypeIdentityCard](/API_docs/constructors/secureValueTypeIdentityCard.html) + +[secureValueTypeInternalPassport](/API_docs/constructors/secureValueTypeInternalPassport.html) + +[secureValueTypeAddress](/API_docs/constructors/secureValueTypeAddress.html) + +[secureValueTypeUtilityBill](/API_docs/constructors/secureValueTypeUtilityBill.html) + +[secureValueTypeBankStatement](/API_docs/constructors/secureValueTypeBankStatement.html) + +[secureValueTypeRentalAgreement](/API_docs/constructors/secureValueTypeRentalAgreement.html) + +[secureValueTypePassportRegistration](/API_docs/constructors/secureValueTypePassportRegistration.html) + +[secureValueTypeTemporaryRegistration](/API_docs/constructors/secureValueTypeTemporaryRegistration.html) + +[secureValueTypePhone](/API_docs/constructors/secureValueTypePhone.html) + +[secureValueTypeEmail](/API_docs/constructors/secureValueTypeEmail.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SendAsPeer.md b/docs/API_docs/types/SendAsPeer.md new file mode 100644 index 0000000000..de77b859b3 --- /dev/null +++ b/docs/API_docs/types/SendAsPeer.md @@ -0,0 +1,21 @@ +--- +title: SendAsPeer +description: constructors and methods of type SendAsPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SendAsPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[sendAsPeer](/API_docs/constructors/sendAsPeer.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SendMessageAction.md b/docs/API_docs/types/SendMessageAction.md new file mode 100644 index 0000000000..e9e7a39c82 --- /dev/null +++ b/docs/API_docs/types/SendMessageAction.md @@ -0,0 +1,65 @@ +--- +title: SendMessageAction +description: constructors and methods of type SendMessageAction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SendMessageAction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[sendMessageTypingAction](/API_docs/constructors/sendMessageTypingAction.html) + +[sendMessageCancelAction](/API_docs/constructors/sendMessageCancelAction.html) + +[sendMessageRecordVideoAction](/API_docs/constructors/sendMessageRecordVideoAction.html) + +[sendMessageUploadVideoAction](/API_docs/constructors/sendMessageUploadVideoAction.html) + +[sendMessageRecordAudioAction](/API_docs/constructors/sendMessageRecordAudioAction.html) + +[sendMessageUploadAudioAction](/API_docs/constructors/sendMessageUploadAudioAction.html) + +[sendMessageUploadPhotoAction](/API_docs/constructors/sendMessageUploadPhotoAction.html) + +[sendMessageUploadDocumentAction](/API_docs/constructors/sendMessageUploadDocumentAction.html) + +[sendMessageGeoLocationAction](/API_docs/constructors/sendMessageGeoLocationAction.html) + +[sendMessageChooseContactAction](/API_docs/constructors/sendMessageChooseContactAction.html) + +[sendMessageGamePlayAction](/API_docs/constructors/sendMessageGamePlayAction.html) + +[sendMessageRecordRoundAction](/API_docs/constructors/sendMessageRecordRoundAction.html) + +[sendMessageUploadRoundAction](/API_docs/constructors/sendMessageUploadRoundAction.html) + +[speakingInGroupCallAction](/API_docs/constructors/speakingInGroupCallAction.html) + +[sendMessageHistoryImportAction](/API_docs/constructors/sendMessageHistoryImportAction.html) + +[sendMessageChooseStickerAction](/API_docs/constructors/sendMessageChooseStickerAction.html) + +[sendMessageEmojiInteraction](/API_docs/constructors/sendMessageEmojiInteraction.html) + +[sendMessageEmojiInteractionSeen](/API_docs/constructors/sendMessageEmojiInteractionSeen.html) + +[sendMessageUploadVideoAction\_17](/API_docs/constructors/sendMessageUploadVideoAction_17.html) + +[sendMessageUploadAudioAction\_17](/API_docs/constructors/sendMessageUploadAudioAction_17.html) + +[sendMessageUploadPhotoAction\_17](/API_docs/constructors/sendMessageUploadPhotoAction_17.html) + +[sendMessageUploadDocumentAction\_17](/API_docs/constructors/sendMessageUploadDocumentAction_17.html) + +[sendMessageUploadRoundAction\_66](/API_docs/constructors/sendMessageUploadRoundAction_66.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/ShippingOption.md b/docs/API_docs/types/ShippingOption.md new file mode 100644 index 0000000000..899f65cf9c --- /dev/null +++ b/docs/API_docs/types/ShippingOption.md @@ -0,0 +1,21 @@ +--- +title: ShippingOption +description: constructors and methods of type ShippingOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ShippingOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[shippingOption](/API_docs/constructors/shippingOption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SimpleWebViewResult.md b/docs/API_docs/types/SimpleWebViewResult.md new file mode 100644 index 0000000000..7cd54a3fdc --- /dev/null +++ b/docs/API_docs/types/SimpleWebViewResult.md @@ -0,0 +1,23 @@ +--- +title: SimpleWebViewResult +description: constructors and methods of type SimpleWebViewResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SimpleWebViewResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[simpleWebViewResultUrl](/API_docs/constructors/simpleWebViewResultUrl.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->requestSimpleWebView](/API_docs/methods/messages.requestSimpleWebView.html) + + + diff --git a/docs/API_docs/types/SmsJob.md b/docs/API_docs/types/SmsJob.md new file mode 100644 index 0000000000..9dbb61815e --- /dev/null +++ b/docs/API_docs/types/SmsJob.md @@ -0,0 +1,23 @@ +--- +title: SmsJob +description: constructors and methods of type SmsJob +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SmsJob +[Back to types index](index.html) + + + +### Possible values (constructors): + +[smsJob](/API_docs/constructors/smsJob.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->smsjobs->getSmsJob](/API_docs/methods/smsjobs.getSmsJob.html) + + + diff --git a/docs/API_docs/types/SponsoredMessage.md b/docs/API_docs/types/SponsoredMessage.md new file mode 100644 index 0000000000..2f90cf62a8 --- /dev/null +++ b/docs/API_docs/types/SponsoredMessage.md @@ -0,0 +1,21 @@ +--- +title: SponsoredMessage +description: constructors and methods of type SponsoredMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SponsoredMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[sponsoredMessage](/API_docs/constructors/sponsoredMessage.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/SponsoredMessageReportOption.md b/docs/API_docs/types/SponsoredMessageReportOption.md new file mode 100644 index 0000000000..8109d7d53b --- /dev/null +++ b/docs/API_docs/types/SponsoredMessageReportOption.md @@ -0,0 +1,21 @@ +--- +title: SponsoredMessageReportOption +description: constructors and methods of type SponsoredMessageReportOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: SponsoredMessageReportOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[sponsoredMessageReportOption](/API_docs/constructors/sponsoredMessageReportOption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsAbsValueAndPrev.md b/docs/API_docs/types/StatsAbsValueAndPrev.md new file mode 100644 index 0000000000..4a1b3d3b85 --- /dev/null +++ b/docs/API_docs/types/StatsAbsValueAndPrev.md @@ -0,0 +1,21 @@ +--- +title: StatsAbsValueAndPrev +description: constructors and methods of type StatsAbsValueAndPrev +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsAbsValueAndPrev +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsAbsValueAndPrev](/API_docs/constructors/statsAbsValueAndPrev.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsDateRangeDays.md b/docs/API_docs/types/StatsDateRangeDays.md new file mode 100644 index 0000000000..0fe45ce563 --- /dev/null +++ b/docs/API_docs/types/StatsDateRangeDays.md @@ -0,0 +1,21 @@ +--- +title: StatsDateRangeDays +description: constructors and methods of type StatsDateRangeDays +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsDateRangeDays +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsDateRangeDays](/API_docs/constructors/statsDateRangeDays.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsGraph.md b/docs/API_docs/types/StatsGraph.md new file mode 100644 index 0000000000..05dd606527 --- /dev/null +++ b/docs/API_docs/types/StatsGraph.md @@ -0,0 +1,27 @@ +--- +title: StatsGraph +description: constructors and methods of type StatsGraph +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsGraph +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsGraphAsync](/API_docs/constructors/statsGraphAsync.html) + +[statsGraphError](/API_docs/constructors/statsGraphError.html) + +[statsGraph](/API_docs/constructors/statsGraph.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->loadAsyncGraph](/API_docs/methods/stats.loadAsyncGraph.html) + + + diff --git a/docs/API_docs/types/StatsGroupTopAdmin.md b/docs/API_docs/types/StatsGroupTopAdmin.md new file mode 100644 index 0000000000..ee81be1be0 --- /dev/null +++ b/docs/API_docs/types/StatsGroupTopAdmin.md @@ -0,0 +1,21 @@ +--- +title: StatsGroupTopAdmin +description: constructors and methods of type StatsGroupTopAdmin +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsGroupTopAdmin +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsGroupTopAdmin](/API_docs/constructors/statsGroupTopAdmin.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsGroupTopInviter.md b/docs/API_docs/types/StatsGroupTopInviter.md new file mode 100644 index 0000000000..d52b8d3ca5 --- /dev/null +++ b/docs/API_docs/types/StatsGroupTopInviter.md @@ -0,0 +1,21 @@ +--- +title: StatsGroupTopInviter +description: constructors and methods of type StatsGroupTopInviter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsGroupTopInviter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsGroupTopInviter](/API_docs/constructors/statsGroupTopInviter.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsGroupTopPoster.md b/docs/API_docs/types/StatsGroupTopPoster.md new file mode 100644 index 0000000000..4f765aff9b --- /dev/null +++ b/docs/API_docs/types/StatsGroupTopPoster.md @@ -0,0 +1,21 @@ +--- +title: StatsGroupTopPoster +description: constructors and methods of type StatsGroupTopPoster +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsGroupTopPoster +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsGroupTopPoster](/API_docs/constructors/statsGroupTopPoster.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsPercentValue.md b/docs/API_docs/types/StatsPercentValue.md new file mode 100644 index 0000000000..79cfd9dd84 --- /dev/null +++ b/docs/API_docs/types/StatsPercentValue.md @@ -0,0 +1,21 @@ +--- +title: StatsPercentValue +description: constructors and methods of type StatsPercentValue +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsPercentValue +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsPercentValue](/API_docs/constructors/statsPercentValue.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StatsURL.md b/docs/API_docs/types/StatsURL.md new file mode 100644 index 0000000000..e3863b3acf --- /dev/null +++ b/docs/API_docs/types/StatsURL.md @@ -0,0 +1,21 @@ +--- +title: StatsURL +description: constructors and methods of type StatsURL +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StatsURL +[Back to types index](index.html) + + + +### Possible values (constructors): + +[statsURL](/API_docs/constructors/statsURL.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StickerKeyword.md b/docs/API_docs/types/StickerKeyword.md new file mode 100644 index 0000000000..a34f6ea09c --- /dev/null +++ b/docs/API_docs/types/StickerKeyword.md @@ -0,0 +1,21 @@ +--- +title: StickerKeyword +description: constructors and methods of type StickerKeyword +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StickerKeyword +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stickerKeyword](/API_docs/constructors/stickerKeyword.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StickerPack.md b/docs/API_docs/types/StickerPack.md new file mode 100644 index 0000000000..a42fb66a7f --- /dev/null +++ b/docs/API_docs/types/StickerPack.md @@ -0,0 +1,21 @@ +--- +title: StickerPack +description: constructors and methods of type StickerPack +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StickerPack +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stickerPack](/API_docs/constructors/stickerPack.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StickerSet.md b/docs/API_docs/types/StickerSet.md new file mode 100644 index 0000000000..99b9dc93cc --- /dev/null +++ b/docs/API_docs/types/StickerSet.md @@ -0,0 +1,21 @@ +--- +title: StickerSet +description: constructors and methods of type StickerSet +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StickerSet +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stickerSet](/API_docs/constructors/stickerSet.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StickerSetCovered.md b/docs/API_docs/types/StickerSetCovered.md new file mode 100644 index 0000000000..7e3a8eb97c --- /dev/null +++ b/docs/API_docs/types/StickerSetCovered.md @@ -0,0 +1,29 @@ +--- +title: StickerSetCovered +description: constructors and methods of type StickerSetCovered +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StickerSetCovered +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stickerSetCovered](/API_docs/constructors/stickerSetCovered.html) + +[stickerSetMultiCovered](/API_docs/constructors/stickerSetMultiCovered.html) + +[stickerSetFullCovered](/API_docs/constructors/stickerSetFullCovered.html) + +[stickerSetNoCovered](/API_docs/constructors/stickerSetNoCovered.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getAttachedStickers](/API_docs/methods/messages.getAttachedStickers.html) + + + diff --git a/docs/API_docs/types/StoriesStealthMode.md b/docs/API_docs/types/StoriesStealthMode.md new file mode 100644 index 0000000000..7540be6418 --- /dev/null +++ b/docs/API_docs/types/StoriesStealthMode.md @@ -0,0 +1,21 @@ +--- +title: StoriesStealthMode +description: constructors and methods of type StoriesStealthMode +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StoriesStealthMode +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storiesStealthMode](/API_docs/constructors/storiesStealthMode.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StoryFwdHeader.md b/docs/API_docs/types/StoryFwdHeader.md new file mode 100644 index 0000000000..39e3af5437 --- /dev/null +++ b/docs/API_docs/types/StoryFwdHeader.md @@ -0,0 +1,21 @@ +--- +title: StoryFwdHeader +description: constructors and methods of type StoryFwdHeader +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StoryFwdHeader +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storyFwdHeader](/API_docs/constructors/storyFwdHeader.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StoryItem.md b/docs/API_docs/types/StoryItem.md new file mode 100644 index 0000000000..8dc835a6c9 --- /dev/null +++ b/docs/API_docs/types/StoryItem.md @@ -0,0 +1,25 @@ +--- +title: StoryItem +description: constructors and methods of type StoryItem +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StoryItem +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storyItemDeleted](/API_docs/constructors/storyItemDeleted.html) + +[storyItemSkipped](/API_docs/constructors/storyItemSkipped.html) + +[storyItem](/API_docs/constructors/storyItem.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StoryReaction.md b/docs/API_docs/types/StoryReaction.md new file mode 100644 index 0000000000..3bc0265fce --- /dev/null +++ b/docs/API_docs/types/StoryReaction.md @@ -0,0 +1,25 @@ +--- +title: StoryReaction +description: constructors and methods of type StoryReaction +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StoryReaction +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storyReaction](/API_docs/constructors/storyReaction.html) + +[storyReactionPublicForward](/API_docs/constructors/storyReactionPublicForward.html) + +[storyReactionPublicRepost](/API_docs/constructors/storyReactionPublicRepost.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StoryView.md b/docs/API_docs/types/StoryView.md new file mode 100644 index 0000000000..f6e131624c --- /dev/null +++ b/docs/API_docs/types/StoryView.md @@ -0,0 +1,25 @@ +--- +title: StoryView +description: constructors and methods of type StoryView +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StoryView +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storyView](/API_docs/constructors/storyView.html) + +[storyViewPublicForward](/API_docs/constructors/storyViewPublicForward.html) + +[storyViewPublicRepost](/API_docs/constructors/storyViewPublicRepost.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/StoryViews.md b/docs/API_docs/types/StoryViews.md new file mode 100644 index 0000000000..80d4c7196f --- /dev/null +++ b/docs/API_docs/types/StoryViews.md @@ -0,0 +1,21 @@ +--- +title: StoryViews +description: constructors and methods of type StoryViews +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: StoryViews +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storyViews](/API_docs/constructors/storyViews.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/TextWithEntities.md b/docs/API_docs/types/TextWithEntities.md new file mode 100644 index 0000000000..5efa20e2bc --- /dev/null +++ b/docs/API_docs/types/TextWithEntities.md @@ -0,0 +1,21 @@ +--- +title: TextWithEntities +description: constructors and methods of type TextWithEntities +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: TextWithEntities +[Back to types index](index.html) + + + +### Possible values (constructors): + +[textWithEntities](/API_docs/constructors/textWithEntities.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Theme.md b/docs/API_docs/types/Theme.md new file mode 100644 index 0000000000..d50a06775a --- /dev/null +++ b/docs/API_docs/types/Theme.md @@ -0,0 +1,27 @@ +--- +title: Theme +description: constructors and methods of type Theme +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Theme +[Back to types index](index.html) + + + +### Possible values (constructors): + +[theme](/API_docs/constructors/theme.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->createTheme](/API_docs/methods/account.createTheme.html) + +[$MadelineProto->account->updateTheme](/API_docs/methods/account.updateTheme.html) + +[$MadelineProto->account->getTheme](/API_docs/methods/account.getTheme.html) + + + diff --git a/docs/API_docs/types/ThemeSettings.md b/docs/API_docs/types/ThemeSettings.md new file mode 100644 index 0000000000..9346846a4d --- /dev/null +++ b/docs/API_docs/types/ThemeSettings.md @@ -0,0 +1,21 @@ +--- +title: ThemeSettings +description: constructors and methods of type ThemeSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: ThemeSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[themeSettings](/API_docs/constructors/themeSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Timezone.md b/docs/API_docs/types/Timezone.md new file mode 100644 index 0000000000..4d38381e9a --- /dev/null +++ b/docs/API_docs/types/Timezone.md @@ -0,0 +1,21 @@ +--- +title: Timezone +description: constructors and methods of type Timezone +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Timezone +[Back to types index](index.html) + + + +### Possible values (constructors): + +[timezone](/API_docs/constructors/timezone.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/TopPeer.md b/docs/API_docs/types/TopPeer.md new file mode 100644 index 0000000000..4c855dad14 --- /dev/null +++ b/docs/API_docs/types/TopPeer.md @@ -0,0 +1,21 @@ +--- +title: TopPeer +description: constructors and methods of type TopPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: TopPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[topPeer](/API_docs/constructors/topPeer.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/TopPeerCategory.md b/docs/API_docs/types/TopPeerCategory.md new file mode 100644 index 0000000000..f9b7b14f34 --- /dev/null +++ b/docs/API_docs/types/TopPeerCategory.md @@ -0,0 +1,35 @@ +--- +title: TopPeerCategory +description: constructors and methods of type TopPeerCategory +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: TopPeerCategory +[Back to types index](index.html) + + + +### Possible values (constructors): + +[topPeerCategoryBotsPM](/API_docs/constructors/topPeerCategoryBotsPM.html) + +[topPeerCategoryBotsInline](/API_docs/constructors/topPeerCategoryBotsInline.html) + +[topPeerCategoryCorrespondents](/API_docs/constructors/topPeerCategoryCorrespondents.html) + +[topPeerCategoryGroups](/API_docs/constructors/topPeerCategoryGroups.html) + +[topPeerCategoryChannels](/API_docs/constructors/topPeerCategoryChannels.html) + +[topPeerCategoryPhoneCalls](/API_docs/constructors/topPeerCategoryPhoneCalls.html) + +[topPeerCategoryForwardUsers](/API_docs/constructors/topPeerCategoryForwardUsers.html) + +[topPeerCategoryForwardChats](/API_docs/constructors/topPeerCategoryForwardChats.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/TopPeerCategoryPeers.md b/docs/API_docs/types/TopPeerCategoryPeers.md new file mode 100644 index 0000000000..01e8f34e1c --- /dev/null +++ b/docs/API_docs/types/TopPeerCategoryPeers.md @@ -0,0 +1,21 @@ +--- +title: TopPeerCategoryPeers +description: constructors and methods of type TopPeerCategoryPeers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: TopPeerCategoryPeers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[topPeerCategoryPeers](/API_docs/constructors/topPeerCategoryPeers.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/True.md b/docs/API_docs/types/True.md new file mode 100644 index 0000000000..5776f59229 --- /dev/null +++ b/docs/API_docs/types/True.md @@ -0,0 +1,21 @@ +--- +title: True +description: constructors and methods of type True +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: True +[Back to types index](index.html) + + + +### Possible values (constructors): + +[true](/API_docs/constructors/true.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Update.md b/docs/API_docs/types/Update.md new file mode 100644 index 0000000000..6ae6470835 --- /dev/null +++ b/docs/API_docs/types/Update.md @@ -0,0 +1,289 @@ +--- +title: Update +description: constructors and methods of type Update +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Update +[Back to types index](index.html) + + + +### Possible values (constructors): + +[updateNewMessage](/API_docs/constructors/updateNewMessage.html) + +[updateMessageID](/API_docs/constructors/updateMessageID.html) + +[updateDeleteMessages](/API_docs/constructors/updateDeleteMessages.html) + +[updateUserTyping](/API_docs/constructors/updateUserTyping.html) + +[updateChatUserTyping](/API_docs/constructors/updateChatUserTyping.html) + +[updateChatParticipants](/API_docs/constructors/updateChatParticipants.html) + +[updateUserStatus](/API_docs/constructors/updateUserStatus.html) + +[updateUserName](/API_docs/constructors/updateUserName.html) + +[updateNewAuthorization](/API_docs/constructors/updateNewAuthorization.html) + +[updateNewEncryptedMessage](/API_docs/constructors/updateNewEncryptedMessage.html) + +[updateEncryptedChatTyping](/API_docs/constructors/updateEncryptedChatTyping.html) + +[updateEncryption](/API_docs/constructors/updateEncryption.html) + +[updateEncryptedMessagesRead](/API_docs/constructors/updateEncryptedMessagesRead.html) + +[updateChatParticipantAdd](/API_docs/constructors/updateChatParticipantAdd.html) + +[updateChatParticipantDelete](/API_docs/constructors/updateChatParticipantDelete.html) + +[updateDcOptions](/API_docs/constructors/updateDcOptions.html) + +[updateNotifySettings](/API_docs/constructors/updateNotifySettings.html) + +[updateServiceNotification](/API_docs/constructors/updateServiceNotification.html) + +[updatePrivacy](/API_docs/constructors/updatePrivacy.html) + +[updateUserPhone](/API_docs/constructors/updateUserPhone.html) + +[updateReadHistoryInbox](/API_docs/constructors/updateReadHistoryInbox.html) + +[updateReadHistoryOutbox](/API_docs/constructors/updateReadHistoryOutbox.html) + +[updateWebPage](/API_docs/constructors/updateWebPage.html) + +[updateReadMessagesContents](/API_docs/constructors/updateReadMessagesContents.html) + +[updateChannelTooLong](/API_docs/constructors/updateChannelTooLong.html) + +[updateChannel](/API_docs/constructors/updateChannel.html) + +[updateNewChannelMessage](/API_docs/constructors/updateNewChannelMessage.html) + +[updateReadChannelInbox](/API_docs/constructors/updateReadChannelInbox.html) + +[updateDeleteChannelMessages](/API_docs/constructors/updateDeleteChannelMessages.html) + +[updateChannelMessageViews](/API_docs/constructors/updateChannelMessageViews.html) + +[updateChatParticipantAdmin](/API_docs/constructors/updateChatParticipantAdmin.html) + +[updateNewStickerSet](/API_docs/constructors/updateNewStickerSet.html) + +[updateStickerSetsOrder](/API_docs/constructors/updateStickerSetsOrder.html) + +[updateStickerSets](/API_docs/constructors/updateStickerSets.html) + +[updateSavedGifs](/API_docs/constructors/updateSavedGifs.html) + +[updateBotInlineQuery](/API_docs/constructors/updateBotInlineQuery.html) + +[updateBotInlineSend](/API_docs/constructors/updateBotInlineSend.html) + +[updateEditChannelMessage](/API_docs/constructors/updateEditChannelMessage.html) + +[updateBotCallbackQuery](/API_docs/constructors/updateBotCallbackQuery.html) + +[updateEditMessage](/API_docs/constructors/updateEditMessage.html) + +[updateInlineBotCallbackQuery](/API_docs/constructors/updateInlineBotCallbackQuery.html) + +[updateReadChannelOutbox](/API_docs/constructors/updateReadChannelOutbox.html) + +[updateDraftMessage](/API_docs/constructors/updateDraftMessage.html) + +[updateReadFeaturedStickers](/API_docs/constructors/updateReadFeaturedStickers.html) + +[updateRecentStickers](/API_docs/constructors/updateRecentStickers.html) + +[updateConfig](/API_docs/constructors/updateConfig.html) + +[updatePtsChanged](/API_docs/constructors/updatePtsChanged.html) + +[updateChannelWebPage](/API_docs/constructors/updateChannelWebPage.html) + +[updateDialogPinned](/API_docs/constructors/updateDialogPinned.html) + +[updatePinnedDialogs](/API_docs/constructors/updatePinnedDialogs.html) + +[updateBotWebhookJSON](/API_docs/constructors/updateBotWebhookJSON.html) + +[updateBotWebhookJSONQuery](/API_docs/constructors/updateBotWebhookJSONQuery.html) + +[updateBotShippingQuery](/API_docs/constructors/updateBotShippingQuery.html) + +[updateBotPrecheckoutQuery](/API_docs/constructors/updateBotPrecheckoutQuery.html) + +[updatePhoneCall](/API_docs/constructors/updatePhoneCall.html) + +[updateLangPackTooLong](/API_docs/constructors/updateLangPackTooLong.html) + +[updateLangPack](/API_docs/constructors/updateLangPack.html) + +[updateFavedStickers](/API_docs/constructors/updateFavedStickers.html) + +[updateChannelReadMessagesContents](/API_docs/constructors/updateChannelReadMessagesContents.html) + +[updateContactsReset](/API_docs/constructors/updateContactsReset.html) + +[updateChannelAvailableMessages](/API_docs/constructors/updateChannelAvailableMessages.html) + +[updateDialogUnreadMark](/API_docs/constructors/updateDialogUnreadMark.html) + +[updateMessagePoll](/API_docs/constructors/updateMessagePoll.html) + +[updateChatDefaultBannedRights](/API_docs/constructors/updateChatDefaultBannedRights.html) + +[updateFolderPeers](/API_docs/constructors/updateFolderPeers.html) + +[updatePeerSettings](/API_docs/constructors/updatePeerSettings.html) + +[updatePeerLocated](/API_docs/constructors/updatePeerLocated.html) + +[updateNewScheduledMessage](/API_docs/constructors/updateNewScheduledMessage.html) + +[updateDeleteScheduledMessages](/API_docs/constructors/updateDeleteScheduledMessages.html) + +[updateTheme](/API_docs/constructors/updateTheme.html) + +[updateGeoLiveViewed](/API_docs/constructors/updateGeoLiveViewed.html) + +[updateLoginToken](/API_docs/constructors/updateLoginToken.html) + +[updateMessagePollVote](/API_docs/constructors/updateMessagePollVote.html) + +[updateDialogFilter](/API_docs/constructors/updateDialogFilter.html) + +[updateDialogFilterOrder](/API_docs/constructors/updateDialogFilterOrder.html) + +[updateDialogFilters](/API_docs/constructors/updateDialogFilters.html) + +[updatePhoneCallSignalingData](/API_docs/constructors/updatePhoneCallSignalingData.html) + +[updateChannelMessageForwards](/API_docs/constructors/updateChannelMessageForwards.html) + +[updateReadChannelDiscussionInbox](/API_docs/constructors/updateReadChannelDiscussionInbox.html) + +[updateReadChannelDiscussionOutbox](/API_docs/constructors/updateReadChannelDiscussionOutbox.html) + +[updatePeerBlocked](/API_docs/constructors/updatePeerBlocked.html) + +[updateChannelUserTyping](/API_docs/constructors/updateChannelUserTyping.html) + +[updatePinnedMessages](/API_docs/constructors/updatePinnedMessages.html) + +[updatePinnedChannelMessages](/API_docs/constructors/updatePinnedChannelMessages.html) + +[updateChat](/API_docs/constructors/updateChat.html) + +[updateGroupCallParticipants](/API_docs/constructors/updateGroupCallParticipants.html) + +[updateGroupCall](/API_docs/constructors/updateGroupCall.html) + +[updatePeerHistoryTTL](/API_docs/constructors/updatePeerHistoryTTL.html) + +[updateChatParticipant](/API_docs/constructors/updateChatParticipant.html) + +[updateChannelParticipant](/API_docs/constructors/updateChannelParticipant.html) + +[updateBotStopped](/API_docs/constructors/updateBotStopped.html) + +[updateGroupCallConnection](/API_docs/constructors/updateGroupCallConnection.html) + +[updateBotCommands](/API_docs/constructors/updateBotCommands.html) + +[updatePendingJoinRequests](/API_docs/constructors/updatePendingJoinRequests.html) + +[updateBotChatInviteRequester](/API_docs/constructors/updateBotChatInviteRequester.html) + +[updateMessageReactions](/API_docs/constructors/updateMessageReactions.html) + +[updateAttachMenuBots](/API_docs/constructors/updateAttachMenuBots.html) + +[updateWebViewResultSent](/API_docs/constructors/updateWebViewResultSent.html) + +[updateBotMenuButton](/API_docs/constructors/updateBotMenuButton.html) + +[updateSavedRingtones](/API_docs/constructors/updateSavedRingtones.html) + +[updateTranscribedAudio](/API_docs/constructors/updateTranscribedAudio.html) + +[updateReadFeaturedEmojiStickers](/API_docs/constructors/updateReadFeaturedEmojiStickers.html) + +[updateUserEmojiStatus](/API_docs/constructors/updateUserEmojiStatus.html) + +[updateRecentEmojiStatuses](/API_docs/constructors/updateRecentEmojiStatuses.html) + +[updateRecentReactions](/API_docs/constructors/updateRecentReactions.html) + +[updateMoveStickerSetToTop](/API_docs/constructors/updateMoveStickerSetToTop.html) + +[updateMessageExtendedMedia](/API_docs/constructors/updateMessageExtendedMedia.html) + +[updateChannelPinnedTopic](/API_docs/constructors/updateChannelPinnedTopic.html) + +[updateChannelPinnedTopics](/API_docs/constructors/updateChannelPinnedTopics.html) + +[updateUser](/API_docs/constructors/updateUser.html) + +[updateAutoSaveSettings](/API_docs/constructors/updateAutoSaveSettings.html) + +[updateStory](/API_docs/constructors/updateStory.html) + +[updateReadStories](/API_docs/constructors/updateReadStories.html) + +[updateStoryID](/API_docs/constructors/updateStoryID.html) + +[updateStoriesStealthMode](/API_docs/constructors/updateStoriesStealthMode.html) + +[updateSentStoryReaction](/API_docs/constructors/updateSentStoryReaction.html) + +[updateBotChatBoost](/API_docs/constructors/updateBotChatBoost.html) + +[updateChannelViewForumAsMessages](/API_docs/constructors/updateChannelViewForumAsMessages.html) + +[updatePeerWallpaper](/API_docs/constructors/updatePeerWallpaper.html) + +[updateBotMessageReaction](/API_docs/constructors/updateBotMessageReaction.html) + +[updateBotMessageReactions](/API_docs/constructors/updateBotMessageReactions.html) + +[updateSavedDialogPinned](/API_docs/constructors/updateSavedDialogPinned.html) + +[updatePinnedSavedDialogs](/API_docs/constructors/updatePinnedSavedDialogs.html) + +[updateSavedReactionTags](/API_docs/constructors/updateSavedReactionTags.html) + +[updateSmsJob](/API_docs/constructors/updateSmsJob.html) + +[updateQuickReplies](/API_docs/constructors/updateQuickReplies.html) + +[updateNewQuickReply](/API_docs/constructors/updateNewQuickReply.html) + +[updateDeleteQuickReply](/API_docs/constructors/updateDeleteQuickReply.html) + +[updateQuickReplyMessage](/API_docs/constructors/updateQuickReplyMessage.html) + +[updateDeleteQuickReplyMessages](/API_docs/constructors/updateDeleteQuickReplyMessages.html) + +[updateBotBusinessConnect](/API_docs/constructors/updateBotBusinessConnect.html) + +[updateBotNewBusinessMessage](/API_docs/constructors/updateBotNewBusinessMessage.html) + +[updateBotEditBusinessMessage](/API_docs/constructors/updateBotEditBusinessMessage.html) + +[updateBotDeleteBusinessMessage](/API_docs/constructors/updateBotDeleteBusinessMessage.html) + +[updateNewStoryReaction](/API_docs/constructors/updateNewStoryReaction.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Updates.md b/docs/API_docs/types/Updates.md new file mode 100644 index 0000000000..52f7b63251 --- /dev/null +++ b/docs/API_docs/types/Updates.md @@ -0,0 +1,248 @@ +--- +title: Updates +description: constructors and methods of type Updates +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Updates +[Back to types index](index.html) + +You can use the following methods to extract information from this constructor: + +```php +// Extract an array of Update constructors +$vector_of_update = $MadelineProto->extractUpdates($Updates); + +// Extract an updateNewMessage, updateNewChannelMessage, updateEditMessage, updateEditChannelMessage constructor +$message_update = $MadelineProto->extractMessageUpdate($Updates); + +// Extract a message constructor +$message = $MadelineProto->extractMessage($Updates); + +// Extract a message ID +$message = $MadelineProto->extractMessageId($Updates); +``` + + +### Possible values (constructors): + +[updatesTooLong](/API_docs/constructors/updatesTooLong.html) + +[updateShortMessage](/API_docs/constructors/updateShortMessage.html) + +[updateShortChatMessage](/API_docs/constructors/updateShortChatMessage.html) + +[updateShort](/API_docs/constructors/updateShort.html) + +[updatesCombined](/API_docs/constructors/updatesCombined.html) + +[updates](/API_docs/constructors/updates.html) + +[updateShortSentMessage](/API_docs/constructors/updateShortSentMessage.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getNotifyExceptions](/API_docs/methods/account.getNotifyExceptions.html) + +[$MadelineProto->account->updateConnectedBot](/API_docs/methods/account.updateConnectedBot.html) + +[$MadelineProto->account->getBotBusinessConnection](/API_docs/methods/account.getBotBusinessConnection.html) + +[$MadelineProto->contacts->deleteContacts](/API_docs/methods/contacts.deleteContacts.html) + +[$MadelineProto->contacts->addContact](/API_docs/methods/contacts.addContact.html) + +[$MadelineProto->contacts->acceptContact](/API_docs/methods/contacts.acceptContact.html) + +[$MadelineProto->contacts->getLocated](/API_docs/methods/contacts.getLocated.html) + +[$MadelineProto->contacts->blockFromReplies](/API_docs/methods/contacts.blockFromReplies.html) + +[$MadelineProto->messages->sendMessage](/API_docs/methods/messages.sendMessage.html) + +[$MadelineProto->messages->sendMedia](/API_docs/methods/messages.sendMedia.html) + +[$MadelineProto->messages->forwardMessages](/API_docs/methods/messages.forwardMessages.html) + +[$MadelineProto->messages->editChatTitle](/API_docs/methods/messages.editChatTitle.html) + +[$MadelineProto->messages->editChatPhoto](/API_docs/methods/messages.editChatPhoto.html) + +[$MadelineProto->messages->deleteChatUser](/API_docs/methods/messages.deleteChatUser.html) + +[$MadelineProto->messages->importChatInvite](/API_docs/methods/messages.importChatInvite.html) + +[$MadelineProto->messages->startBot](/API_docs/methods/messages.startBot.html) + +[$MadelineProto->messages->migrateChat](/API_docs/methods/messages.migrateChat.html) + +[$MadelineProto->messages->sendInlineBotResult](/API_docs/methods/messages.sendInlineBotResult.html) + +[$MadelineProto->messages->editMessage](/API_docs/methods/messages.editMessage.html) + +[$MadelineProto->messages->getAllDrafts](/API_docs/methods/messages.getAllDrafts.html) + +[$MadelineProto->messages->setGameScore](/API_docs/methods/messages.setGameScore.html) + +[$MadelineProto->messages->sendScreenshotNotification](/API_docs/methods/messages.sendScreenshotNotification.html) + +[$MadelineProto->messages->sendMultiMedia](/API_docs/methods/messages.sendMultiMedia.html) + +[$MadelineProto->messages->updatePinnedMessage](/API_docs/methods/messages.updatePinnedMessage.html) + +[$MadelineProto->messages->sendVote](/API_docs/methods/messages.sendVote.html) + +[$MadelineProto->messages->getPollResults](/API_docs/methods/messages.getPollResults.html) + +[$MadelineProto->messages->editChatDefaultBannedRights](/API_docs/methods/messages.editChatDefaultBannedRights.html) + +[$MadelineProto->messages->sendScheduledMessages](/API_docs/methods/messages.sendScheduledMessages.html) + +[$MadelineProto->messages->deleteScheduledMessages](/API_docs/methods/messages.deleteScheduledMessages.html) + +[$MadelineProto->messages->setHistoryTTL](/API_docs/methods/messages.setHistoryTTL.html) + +[$MadelineProto->messages->setChatTheme](/API_docs/methods/messages.setChatTheme.html) + +[$MadelineProto->messages->hideChatJoinRequest](/API_docs/methods/messages.hideChatJoinRequest.html) + +[$MadelineProto->messages->hideAllChatJoinRequests](/API_docs/methods/messages.hideAllChatJoinRequests.html) + +[$MadelineProto->messages->toggleNoForwards](/API_docs/methods/messages.toggleNoForwards.html) + +[$MadelineProto->messages->sendReaction](/API_docs/methods/messages.sendReaction.html) + +[$MadelineProto->messages->getMessagesReactions](/API_docs/methods/messages.getMessagesReactions.html) + +[$MadelineProto->messages->setChatAvailableReactions](/API_docs/methods/messages.setChatAvailableReactions.html) + +[$MadelineProto->messages->sendWebViewData](/API_docs/methods/messages.sendWebViewData.html) + +[$MadelineProto->messages->getExtendedMedia](/API_docs/methods/messages.getExtendedMedia.html) + +[$MadelineProto->messages->sendBotRequestedPeer](/API_docs/methods/messages.sendBotRequestedPeer.html) + +[$MadelineProto->messages->setChatWallPaper](/API_docs/methods/messages.setChatWallPaper.html) + +[$MadelineProto->messages->sendQuickReplyMessages](/API_docs/methods/messages.sendQuickReplyMessages.html) + +[$MadelineProto->messages->deleteQuickReplyMessages](/API_docs/methods/messages.deleteQuickReplyMessages.html) + +[$MadelineProto->channels->createChannel](/API_docs/methods/channels.createChannel.html) + +[$MadelineProto->channels->editAdmin](/API_docs/methods/channels.editAdmin.html) + +[$MadelineProto->channels->editTitle](/API_docs/methods/channels.editTitle.html) + +[$MadelineProto->channels->editPhoto](/API_docs/methods/channels.editPhoto.html) + +[$MadelineProto->channels->joinChannel](/API_docs/methods/channels.joinChannel.html) + +[$MadelineProto->channels->leaveChannel](/API_docs/methods/channels.leaveChannel.html) + +[$MadelineProto->channels->deleteChannel](/API_docs/methods/channels.deleteChannel.html) + +[$MadelineProto->channels->toggleSignatures](/API_docs/methods/channels.toggleSignatures.html) + +[$MadelineProto->channels->editBanned](/API_docs/methods/channels.editBanned.html) + +[$MadelineProto->channels->deleteHistory](/API_docs/methods/channels.deleteHistory.html) + +[$MadelineProto->channels->togglePreHistoryHidden](/API_docs/methods/channels.togglePreHistoryHidden.html) + +[$MadelineProto->channels->editCreator](/API_docs/methods/channels.editCreator.html) + +[$MadelineProto->channels->toggleSlowMode](/API_docs/methods/channels.toggleSlowMode.html) + +[$MadelineProto->channels->convertToGigagroup](/API_docs/methods/channels.convertToGigagroup.html) + +[$MadelineProto->channels->toggleJoinToSend](/API_docs/methods/channels.toggleJoinToSend.html) + +[$MadelineProto->channels->toggleJoinRequest](/API_docs/methods/channels.toggleJoinRequest.html) + +[$MadelineProto->channels->toggleForum](/API_docs/methods/channels.toggleForum.html) + +[$MadelineProto->channels->createForumTopic](/API_docs/methods/channels.createForumTopic.html) + +[$MadelineProto->channels->editForumTopic](/API_docs/methods/channels.editForumTopic.html) + +[$MadelineProto->channels->updatePinnedForumTopic](/API_docs/methods/channels.updatePinnedForumTopic.html) + +[$MadelineProto->channels->reorderPinnedForumTopics](/API_docs/methods/channels.reorderPinnedForumTopics.html) + +[$MadelineProto->channels->toggleAntiSpam](/API_docs/methods/channels.toggleAntiSpam.html) + +[$MadelineProto->channels->toggleParticipantsHidden](/API_docs/methods/channels.toggleParticipantsHidden.html) + +[$MadelineProto->channels->updateColor](/API_docs/methods/channels.updateColor.html) + +[$MadelineProto->channels->toggleViewForumAsMessages](/API_docs/methods/channels.toggleViewForumAsMessages.html) + +[$MadelineProto->channels->updateEmojiStatus](/API_docs/methods/channels.updateEmojiStatus.html) + +[$MadelineProto->channels->setBoostsToUnblockRestrictions](/API_docs/methods/channels.setBoostsToUnblockRestrictions.html) + +[$MadelineProto->channels->restrictSponsoredMessages](/API_docs/methods/channels.restrictSponsoredMessages.html) + +[$MadelineProto->bots->allowSendMessage](/API_docs/methods/bots.allowSendMessage.html) + +[$MadelineProto->payments->assignAppStoreTransaction](/API_docs/methods/payments.assignAppStoreTransaction.html) + +[$MadelineProto->payments->assignPlayMarketTransaction](/API_docs/methods/payments.assignPlayMarketTransaction.html) + +[$MadelineProto->payments->applyGiftCode](/API_docs/methods/payments.applyGiftCode.html) + +[$MadelineProto->payments->launchPrepaidGiveaway](/API_docs/methods/payments.launchPrepaidGiveaway.html) + +[$MadelineProto->phone->discardCall](/API_docs/methods/phone.discardCall.html) + +[$MadelineProto->phone->setCallRating](/API_docs/methods/phone.setCallRating.html) + +[$MadelineProto->phone->createGroupCall](/API_docs/methods/phone.createGroupCall.html) + +[$MadelineProto->phone->joinGroupCall](/API_docs/methods/phone.joinGroupCall.html) + +[$MadelineProto->phone->leaveGroupCall](/API_docs/methods/phone.leaveGroupCall.html) + +[$MadelineProto->phone->inviteToGroupCall](/API_docs/methods/phone.inviteToGroupCall.html) + +[$MadelineProto->phone->discardGroupCall](/API_docs/methods/phone.discardGroupCall.html) + +[$MadelineProto->phone->toggleGroupCallSettings](/API_docs/methods/phone.toggleGroupCallSettings.html) + +[$MadelineProto->phone->toggleGroupCallRecord](/API_docs/methods/phone.toggleGroupCallRecord.html) + +[$MadelineProto->phone->editGroupCallParticipant](/API_docs/methods/phone.editGroupCallParticipant.html) + +[$MadelineProto->phone->editGroupCallTitle](/API_docs/methods/phone.editGroupCallTitle.html) + +[$MadelineProto->phone->toggleGroupCallStartSubscription](/API_docs/methods/phone.toggleGroupCallStartSubscription.html) + +[$MadelineProto->phone->startScheduledGroupCall](/API_docs/methods/phone.startScheduledGroupCall.html) + +[$MadelineProto->phone->joinGroupCallPresentation](/API_docs/methods/phone.joinGroupCallPresentation.html) + +[$MadelineProto->phone->leaveGroupCallPresentation](/API_docs/methods/phone.leaveGroupCallPresentation.html) + +[$MadelineProto->folders->editPeerFolders](/API_docs/methods/folders.editPeerFolders.html) + +[$MadelineProto->chatlists->joinChatlistInvite](/API_docs/methods/chatlists.joinChatlistInvite.html) + +[$MadelineProto->chatlists->joinChatlistUpdates](/API_docs/methods/chatlists.joinChatlistUpdates.html) + +[$MadelineProto->chatlists->leaveChatlist](/API_docs/methods/chatlists.leaveChatlist.html) + +[$MadelineProto->stories->sendStory](/API_docs/methods/stories.sendStory.html) + +[$MadelineProto->stories->editStory](/API_docs/methods/stories.editStory.html) + +[$MadelineProto->stories->activateStealthMode](/API_docs/methods/stories.activateStealthMode.html) + +[$MadelineProto->stories->sendReaction](/API_docs/methods/stories.sendReaction.html) + +[$MadelineProto->stories->getAllReadPeerStories](/API_docs/methods/stories.getAllReadPeerStories.html) + + + diff --git a/docs/API_docs/types/UrlAuthResult.md b/docs/API_docs/types/UrlAuthResult.md new file mode 100644 index 0000000000..5ef271fc6f --- /dev/null +++ b/docs/API_docs/types/UrlAuthResult.md @@ -0,0 +1,29 @@ +--- +title: UrlAuthResult +description: constructors and methods of type UrlAuthResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: UrlAuthResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[urlAuthResultRequest](/API_docs/constructors/urlAuthResultRequest.html) + +[urlAuthResultAccepted](/API_docs/constructors/urlAuthResultAccepted.html) + +[urlAuthResultDefault](/API_docs/constructors/urlAuthResultDefault.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->requestUrlAuth](/API_docs/methods/messages.requestUrlAuth.html) + +[$MadelineProto->messages->acceptUrlAuth](/API_docs/methods/messages.acceptUrlAuth.html) + + + diff --git a/docs/API_docs/types/User.md b/docs/API_docs/types/User.md new file mode 100644 index 0000000000..5ea52ace19 --- /dev/null +++ b/docs/API_docs/types/User.md @@ -0,0 +1,68 @@ +--- +title: User +description: constructors and methods of type User +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: User +[Back to types index](index.html) + +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$User = '@username'; // Username + +$User = $update; // Update objects received in the event handler + +$User = 'me'; // The currently logged-in user + +$User = 44700; // bot API id (users) +$User = -492772765; // bot API id (chats) +$User = -10038575794; // bot API id (channels) + +$User = 'https://t.me/danogentili'; // t.me URLs +$User = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + + + +### Possible values (constructors): + +[userEmpty](/API_docs/constructors/userEmpty.html) + +[user](/API_docs/constructors/user.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->updateProfile](/API_docs/methods/account.updateProfile.html) + +[$MadelineProto->account->updateUsername](/API_docs/methods/account.updateUsername.html) + +[$MadelineProto->account->changePhone](/API_docs/methods/account.changePhone.html) + +[$MadelineProto->users->getUsers](/API_docs/methods/users.getUsers.html) + +[$MadelineProto->contacts->importContactToken](/API_docs/methods/contacts.importContactToken.html) + + + diff --git a/docs/API_docs/types/UserFull.md b/docs/API_docs/types/UserFull.md new file mode 100644 index 0000000000..94126af727 --- /dev/null +++ b/docs/API_docs/types/UserFull.md @@ -0,0 +1,21 @@ +--- +title: UserFull +description: constructors and methods of type UserFull +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: UserFull +[Back to types index](index.html) + + + +### Possible values (constructors): + +[userFull](/API_docs/constructors/userFull.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/UserProfilePhoto.md b/docs/API_docs/types/UserProfilePhoto.md new file mode 100644 index 0000000000..d40125225d --- /dev/null +++ b/docs/API_docs/types/UserProfilePhoto.md @@ -0,0 +1,23 @@ +--- +title: UserProfilePhoto +description: constructors and methods of type UserProfilePhoto +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: UserProfilePhoto +[Back to types index](index.html) + + + +### Possible values (constructors): + +[userProfilePhotoEmpty](/API_docs/constructors/userProfilePhotoEmpty.html) + +[userProfilePhoto](/API_docs/constructors/userProfilePhoto.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/UserStatus.md b/docs/API_docs/types/UserStatus.md new file mode 100644 index 0000000000..4e60c1cb3d --- /dev/null +++ b/docs/API_docs/types/UserStatus.md @@ -0,0 +1,31 @@ +--- +title: UserStatus +description: constructors and methods of type UserStatus +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: UserStatus +[Back to types index](index.html) + + + +### Possible values (constructors): + +[userStatusEmpty](/API_docs/constructors/userStatusEmpty.html) + +[userStatusOnline](/API_docs/constructors/userStatusOnline.html) + +[userStatusOffline](/API_docs/constructors/userStatusOffline.html) + +[userStatusRecently](/API_docs/constructors/userStatusRecently.html) + +[userStatusLastWeek](/API_docs/constructors/userStatusLastWeek.html) + +[userStatusLastMonth](/API_docs/constructors/userStatusLastMonth.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/Username.md b/docs/API_docs/types/Username.md new file mode 100644 index 0000000000..888312c12e --- /dev/null +++ b/docs/API_docs/types/Username.md @@ -0,0 +1,21 @@ +--- +title: Username +description: constructors and methods of type Username +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: Username +[Back to types index](index.html) + + + +### Possible values (constructors): + +[username](/API_docs/constructors/username.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/VideoSize.md b/docs/API_docs/types/VideoSize.md new file mode 100644 index 0000000000..7fa106ae9f --- /dev/null +++ b/docs/API_docs/types/VideoSize.md @@ -0,0 +1,25 @@ +--- +title: VideoSize +description: constructors and methods of type VideoSize +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: VideoSize +[Back to types index](index.html) + + + +### Possible values (constructors): + +[videoSize](/API_docs/constructors/videoSize.html) + +[videoSizeEmojiMarkup](/API_docs/constructors/videoSizeEmojiMarkup.html) + +[videoSizeStickerMarkup](/API_docs/constructors/videoSizeStickerMarkup.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/WallPaper.md b/docs/API_docs/types/WallPaper.md new file mode 100644 index 0000000000..3608089c5f --- /dev/null +++ b/docs/API_docs/types/WallPaper.md @@ -0,0 +1,29 @@ +--- +title: WallPaper +description: constructors and methods of type WallPaper +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WallPaper +[Back to types index](index.html) + + + +### Possible values (constructors): + +[wallPaper](/API_docs/constructors/wallPaper.html) + +[wallPaperNoFile](/API_docs/constructors/wallPaperNoFile.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getWallPaper](/API_docs/methods/account.getWallPaper.html) + +[$MadelineProto->account->uploadWallPaper](/API_docs/methods/account.uploadWallPaper.html) + +[$MadelineProto->account->getMultiWallPapers](/API_docs/methods/account.getMultiWallPapers.html) + + + diff --git a/docs/API_docs/types/WallPaperSettings.md b/docs/API_docs/types/WallPaperSettings.md new file mode 100644 index 0000000000..3e08eb00cd --- /dev/null +++ b/docs/API_docs/types/WallPaperSettings.md @@ -0,0 +1,21 @@ +--- +title: WallPaperSettings +description: constructors and methods of type WallPaperSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WallPaperSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[wallPaperSettings](/API_docs/constructors/wallPaperSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/WebAuthorization.md b/docs/API_docs/types/WebAuthorization.md new file mode 100644 index 0000000000..83add1c76f --- /dev/null +++ b/docs/API_docs/types/WebAuthorization.md @@ -0,0 +1,21 @@ +--- +title: WebAuthorization +description: constructors and methods of type WebAuthorization +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WebAuthorization +[Back to types index](index.html) + + + +### Possible values (constructors): + +[webAuthorization](/API_docs/constructors/webAuthorization.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/WebDocument.md b/docs/API_docs/types/WebDocument.md new file mode 100644 index 0000000000..44fc533899 --- /dev/null +++ b/docs/API_docs/types/WebDocument.md @@ -0,0 +1,23 @@ +--- +title: WebDocument +description: constructors and methods of type WebDocument +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WebDocument +[Back to types index](index.html) + + + +### Possible values (constructors): + +[webDocument](/API_docs/constructors/webDocument.html) + +[webDocumentNoProxy](/API_docs/constructors/webDocumentNoProxy.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/WebPage.md b/docs/API_docs/types/WebPage.md new file mode 100644 index 0000000000..d16f78caae --- /dev/null +++ b/docs/API_docs/types/WebPage.md @@ -0,0 +1,27 @@ +--- +title: WebPage +description: constructors and methods of type WebPage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WebPage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[webPageEmpty](/API_docs/constructors/webPageEmpty.html) + +[webPagePending](/API_docs/constructors/webPagePending.html) + +[webPage](/API_docs/constructors/webPage.html) + +[webPageNotModified](/API_docs/constructors/webPageNotModified.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/WebPageAttribute.md b/docs/API_docs/types/WebPageAttribute.md new file mode 100644 index 0000000000..739aff13bb --- /dev/null +++ b/docs/API_docs/types/WebPageAttribute.md @@ -0,0 +1,25 @@ +--- +title: WebPageAttribute +description: constructors and methods of type WebPageAttribute +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WebPageAttribute +[Back to types index](index.html) + + + +### Possible values (constructors): + +[webPageAttributeTheme](/API_docs/constructors/webPageAttributeTheme.html) + +[webPageAttributeStory](/API_docs/constructors/webPageAttributeStory.html) + +[webPageAttributeStickerSet](/API_docs/constructors/webPageAttributeStickerSet.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/WebViewMessageSent.md b/docs/API_docs/types/WebViewMessageSent.md new file mode 100644 index 0000000000..497c20d1a8 --- /dev/null +++ b/docs/API_docs/types/WebViewMessageSent.md @@ -0,0 +1,23 @@ +--- +title: WebViewMessageSent +description: constructors and methods of type WebViewMessageSent +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WebViewMessageSent +[Back to types index](index.html) + + + +### Possible values (constructors): + +[webViewMessageSent](/API_docs/constructors/webViewMessageSent.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->sendWebViewResultMessage](/API_docs/methods/messages.sendWebViewResultMessage.html) + + + diff --git a/docs/API_docs/types/WebViewResult.md b/docs/API_docs/types/WebViewResult.md new file mode 100644 index 0000000000..595c3e2b96 --- /dev/null +++ b/docs/API_docs/types/WebViewResult.md @@ -0,0 +1,23 @@ +--- +title: WebViewResult +description: constructors and methods of type WebViewResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: WebViewResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[webViewResultUrl](/API_docs/constructors/webViewResultUrl.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->requestWebView](/API_docs/methods/messages.requestWebView.html) + + + diff --git a/docs/API_docs/types/X.md b/docs/API_docs/types/X.md new file mode 100644 index 0000000000..2f8bed5f2d --- /dev/null +++ b/docs/API_docs/types/X.md @@ -0,0 +1,35 @@ +--- +title: X +description: constructors and methods of type X +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Type: X +[Back to types index](index.html) + + + +### Possible values (constructors): + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->invokeAfterMsg](/API_docs/methods/invokeAfterMsg.html) + +[$MadelineProto->invokeAfterMsgs](/API_docs/methods/invokeAfterMsgs.html) + +[$MadelineProto->initConnection](/API_docs/methods/initConnection.html) + +[$MadelineProto->invokeWithLayer](/API_docs/methods/invokeWithLayer.html) + +[$MadelineProto->invokeWithoutUpdates](/API_docs/methods/invokeWithoutUpdates.html) + +[$MadelineProto->invokeWithMessagesRange](/API_docs/methods/invokeWithMessagesRange.html) + +[$MadelineProto->invokeWithTakeout](/API_docs/methods/invokeWithTakeout.html) + +[$MadelineProto->invokeWithBusinessConnection](/API_docs/methods/invokeWithBusinessConnection.html) + + + diff --git a/docs/API_docs/types/account.AuthorizationForm.md b/docs/API_docs/types/account.AuthorizationForm.md new file mode 100644 index 0000000000..14dffa3dd4 --- /dev/null +++ b/docs/API_docs/types/account.AuthorizationForm.md @@ -0,0 +1,24 @@ +--- +title: account.AuthorizationForm +description: constructors and methods of type account.AuthorizationForm +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_AuthorizationForm.html +--- +# Type: account.AuthorizationForm +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.authorizationForm](/API_docs/constructors/account.authorizationForm.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getAuthorizationForm](/API_docs/methods/account.getAuthorizationForm.html) + + + diff --git a/docs/API_docs/types/account.Authorizations.md b/docs/API_docs/types/account.Authorizations.md new file mode 100644 index 0000000000..b803e7c5f9 --- /dev/null +++ b/docs/API_docs/types/account.Authorizations.md @@ -0,0 +1,24 @@ +--- +title: account.Authorizations +description: constructors and methods of type account.Authorizations +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_Authorizations.html +--- +# Type: account.Authorizations +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.authorizations](/API_docs/constructors/account.authorizations.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getAuthorizations](/API_docs/methods/account.getAuthorizations.html) + + + diff --git a/docs/API_docs/types/account.AutoDownloadSettings.md b/docs/API_docs/types/account.AutoDownloadSettings.md new file mode 100644 index 0000000000..1ffadead2c --- /dev/null +++ b/docs/API_docs/types/account.AutoDownloadSettings.md @@ -0,0 +1,24 @@ +--- +title: account.AutoDownloadSettings +description: constructors and methods of type account.AutoDownloadSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_AutoDownloadSettings.html +--- +# Type: account.AutoDownloadSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.autoDownloadSettings](/API_docs/constructors/account.autoDownloadSettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getAutoDownloadSettings](/API_docs/methods/account.getAutoDownloadSettings.html) + + + diff --git a/docs/API_docs/types/account.AutoSaveSettings.md b/docs/API_docs/types/account.AutoSaveSettings.md new file mode 100644 index 0000000000..ef048ae82c --- /dev/null +++ b/docs/API_docs/types/account.AutoSaveSettings.md @@ -0,0 +1,24 @@ +--- +title: account.AutoSaveSettings +description: constructors and methods of type account.AutoSaveSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_AutoSaveSettings.html +--- +# Type: account.AutoSaveSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.autoSaveSettings](/API_docs/constructors/account.autoSaveSettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getAutoSaveSettings](/API_docs/methods/account.getAutoSaveSettings.html) + + + diff --git a/docs/API_docs/types/account.BusinessChatLinks.md b/docs/API_docs/types/account.BusinessChatLinks.md new file mode 100644 index 0000000000..653c8fb8e0 --- /dev/null +++ b/docs/API_docs/types/account.BusinessChatLinks.md @@ -0,0 +1,24 @@ +--- +title: account.BusinessChatLinks +description: constructors and methods of type account.BusinessChatLinks +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_BusinessChatLinks.html +--- +# Type: account.BusinessChatLinks +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.businessChatLinks](/API_docs/constructors/account.businessChatLinks.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getBusinessChatLinks](/API_docs/methods/account.getBusinessChatLinks.html) + + + diff --git a/docs/API_docs/types/account.ConnectedBots.md b/docs/API_docs/types/account.ConnectedBots.md new file mode 100644 index 0000000000..b05f763e47 --- /dev/null +++ b/docs/API_docs/types/account.ConnectedBots.md @@ -0,0 +1,24 @@ +--- +title: account.ConnectedBots +description: constructors and methods of type account.ConnectedBots +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_ConnectedBots.html +--- +# Type: account.ConnectedBots +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.connectedBots](/API_docs/constructors/account.connectedBots.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getConnectedBots](/API_docs/methods/account.getConnectedBots.html) + + + diff --git a/docs/API_docs/types/account.ContentSettings.md b/docs/API_docs/types/account.ContentSettings.md new file mode 100644 index 0000000000..c8c11f3080 --- /dev/null +++ b/docs/API_docs/types/account.ContentSettings.md @@ -0,0 +1,24 @@ +--- +title: account.ContentSettings +description: constructors and methods of type account.ContentSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_ContentSettings.html +--- +# Type: account.ContentSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.contentSettings](/API_docs/constructors/account.contentSettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getContentSettings](/API_docs/methods/account.getContentSettings.html) + + + diff --git a/docs/API_docs/types/account.EmailVerified.md b/docs/API_docs/types/account.EmailVerified.md new file mode 100644 index 0000000000..f1704d1f06 --- /dev/null +++ b/docs/API_docs/types/account.EmailVerified.md @@ -0,0 +1,26 @@ +--- +title: account.EmailVerified +description: constructors and methods of type account.EmailVerified +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_EmailVerified.html +--- +# Type: account.EmailVerified +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.emailVerified](/API_docs/constructors/account.emailVerified.html) + +[account.emailVerifiedLogin](/API_docs/constructors/account.emailVerifiedLogin.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->verifyEmail](/API_docs/methods/account.verifyEmail.html) + + + diff --git a/docs/API_docs/types/account.EmojiStatuses.md b/docs/API_docs/types/account.EmojiStatuses.md new file mode 100644 index 0000000000..166738cee8 --- /dev/null +++ b/docs/API_docs/types/account.EmojiStatuses.md @@ -0,0 +1,30 @@ +--- +title: account.EmojiStatuses +description: constructors and methods of type account.EmojiStatuses +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_EmojiStatuses.html +--- +# Type: account.EmojiStatuses +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.emojiStatusesNotModified](/API_docs/constructors/account.emojiStatusesNotModified.html) + +[account.emojiStatuses](/API_docs/constructors/account.emojiStatuses.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getDefaultEmojiStatuses](/API_docs/methods/account.getDefaultEmojiStatuses.html) + +[$MadelineProto->account->getRecentEmojiStatuses](/API_docs/methods/account.getRecentEmojiStatuses.html) + +[$MadelineProto->account->getChannelDefaultEmojiStatuses](/API_docs/methods/account.getChannelDefaultEmojiStatuses.html) + + + diff --git a/docs/API_docs/types/account.Password.md b/docs/API_docs/types/account.Password.md new file mode 100644 index 0000000000..ef50f5c78f --- /dev/null +++ b/docs/API_docs/types/account.Password.md @@ -0,0 +1,24 @@ +--- +title: account.Password +description: constructors and methods of type account.Password +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_Password.html +--- +# Type: account.Password +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.password](/API_docs/constructors/account.password.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getPassword](/API_docs/methods/account.getPassword.html) + + + diff --git a/docs/API_docs/types/account.PasswordInputSettings.md b/docs/API_docs/types/account.PasswordInputSettings.md new file mode 100644 index 0000000000..412545af59 --- /dev/null +++ b/docs/API_docs/types/account.PasswordInputSettings.md @@ -0,0 +1,22 @@ +--- +title: account.PasswordInputSettings +description: constructors and methods of type account.PasswordInputSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_PasswordInputSettings.html +--- +# Type: account.PasswordInputSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.passwordInputSettings](/API_docs/constructors/account.passwordInputSettings.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/account.PasswordSettings.md b/docs/API_docs/types/account.PasswordSettings.md new file mode 100644 index 0000000000..f1585ed61c --- /dev/null +++ b/docs/API_docs/types/account.PasswordSettings.md @@ -0,0 +1,24 @@ +--- +title: account.PasswordSettings +description: constructors and methods of type account.PasswordSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_PasswordSettings.html +--- +# Type: account.PasswordSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.passwordSettings](/API_docs/constructors/account.passwordSettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getPasswordSettings](/API_docs/methods/account.getPasswordSettings.html) + + + diff --git a/docs/API_docs/types/account.PrivacyRules.md b/docs/API_docs/types/account.PrivacyRules.md new file mode 100644 index 0000000000..88d5381810 --- /dev/null +++ b/docs/API_docs/types/account.PrivacyRules.md @@ -0,0 +1,26 @@ +--- +title: account.PrivacyRules +description: constructors and methods of type account.PrivacyRules +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_PrivacyRules.html +--- +# Type: account.PrivacyRules +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.privacyRules](/API_docs/constructors/account.privacyRules.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getPrivacy](/API_docs/methods/account.getPrivacy.html) + +[$MadelineProto->account->setPrivacy](/API_docs/methods/account.setPrivacy.html) + + + diff --git a/docs/API_docs/types/account.ResetPasswordResult.md b/docs/API_docs/types/account.ResetPasswordResult.md new file mode 100644 index 0000000000..1f2c2474a5 --- /dev/null +++ b/docs/API_docs/types/account.ResetPasswordResult.md @@ -0,0 +1,28 @@ +--- +title: account.ResetPasswordResult +description: constructors and methods of type account.ResetPasswordResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_ResetPasswordResult.html +--- +# Type: account.ResetPasswordResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.resetPasswordFailedWait](/API_docs/constructors/account.resetPasswordFailedWait.html) + +[account.resetPasswordRequestedWait](/API_docs/constructors/account.resetPasswordRequestedWait.html) + +[account.resetPasswordOk](/API_docs/constructors/account.resetPasswordOk.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->resetPassword](/API_docs/methods/account.resetPassword.html) + + + diff --git a/docs/API_docs/types/account.ResolvedBusinessChatLinks.md b/docs/API_docs/types/account.ResolvedBusinessChatLinks.md new file mode 100644 index 0000000000..4aad95fe1d --- /dev/null +++ b/docs/API_docs/types/account.ResolvedBusinessChatLinks.md @@ -0,0 +1,24 @@ +--- +title: account.ResolvedBusinessChatLinks +description: constructors and methods of type account.ResolvedBusinessChatLinks +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_ResolvedBusinessChatLinks.html +--- +# Type: account.ResolvedBusinessChatLinks +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.resolvedBusinessChatLinks](/API_docs/constructors/account.resolvedBusinessChatLinks.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->resolveBusinessChatLink](/API_docs/methods/account.resolveBusinessChatLink.html) + + + diff --git a/docs/API_docs/types/account.SavedRingtone.md b/docs/API_docs/types/account.SavedRingtone.md new file mode 100644 index 0000000000..6ebfa419be --- /dev/null +++ b/docs/API_docs/types/account.SavedRingtone.md @@ -0,0 +1,26 @@ +--- +title: account.SavedRingtone +description: constructors and methods of type account.SavedRingtone +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_SavedRingtone.html +--- +# Type: account.SavedRingtone +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.savedRingtone](/API_docs/constructors/account.savedRingtone.html) + +[account.savedRingtoneConverted](/API_docs/constructors/account.savedRingtoneConverted.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->saveRingtone](/API_docs/methods/account.saveRingtone.html) + + + diff --git a/docs/API_docs/types/account.SavedRingtones.md b/docs/API_docs/types/account.SavedRingtones.md new file mode 100644 index 0000000000..c76a13cdce --- /dev/null +++ b/docs/API_docs/types/account.SavedRingtones.md @@ -0,0 +1,26 @@ +--- +title: account.SavedRingtones +description: constructors and methods of type account.SavedRingtones +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_SavedRingtones.html +--- +# Type: account.SavedRingtones +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.savedRingtonesNotModified](/API_docs/constructors/account.savedRingtonesNotModified.html) + +[account.savedRingtones](/API_docs/constructors/account.savedRingtones.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getSavedRingtones](/API_docs/methods/account.getSavedRingtones.html) + + + diff --git a/docs/API_docs/types/account.SentEmailCode.md b/docs/API_docs/types/account.SentEmailCode.md new file mode 100644 index 0000000000..e590ad5e6b --- /dev/null +++ b/docs/API_docs/types/account.SentEmailCode.md @@ -0,0 +1,24 @@ +--- +title: account.SentEmailCode +description: constructors and methods of type account.SentEmailCode +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_SentEmailCode.html +--- +# Type: account.SentEmailCode +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.sentEmailCode](/API_docs/constructors/account.sentEmailCode.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->sendVerifyEmailCode](/API_docs/methods/account.sendVerifyEmailCode.html) + + + diff --git a/docs/API_docs/types/account.Takeout.md b/docs/API_docs/types/account.Takeout.md new file mode 100644 index 0000000000..b538050ec0 --- /dev/null +++ b/docs/API_docs/types/account.Takeout.md @@ -0,0 +1,24 @@ +--- +title: account.Takeout +description: constructors and methods of type account.Takeout +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_Takeout.html +--- +# Type: account.Takeout +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.takeout](/API_docs/constructors/account.takeout.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->initTakeoutSession](/API_docs/methods/account.initTakeoutSession.html) + + + diff --git a/docs/API_docs/types/account.Themes.md b/docs/API_docs/types/account.Themes.md new file mode 100644 index 0000000000..a3ebfc1c1f --- /dev/null +++ b/docs/API_docs/types/account.Themes.md @@ -0,0 +1,28 @@ +--- +title: account.Themes +description: constructors and methods of type account.Themes +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_Themes.html +--- +# Type: account.Themes +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.themesNotModified](/API_docs/constructors/account.themesNotModified.html) + +[account.themes](/API_docs/constructors/account.themes.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getThemes](/API_docs/methods/account.getThemes.html) + +[$MadelineProto->account->getChatThemes](/API_docs/methods/account.getChatThemes.html) + + + diff --git a/docs/API_docs/types/account.TmpPassword.md b/docs/API_docs/types/account.TmpPassword.md new file mode 100644 index 0000000000..0c17c97c0f --- /dev/null +++ b/docs/API_docs/types/account.TmpPassword.md @@ -0,0 +1,24 @@ +--- +title: account.TmpPassword +description: constructors and methods of type account.TmpPassword +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_TmpPassword.html +--- +# Type: account.TmpPassword +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.tmpPassword](/API_docs/constructors/account.tmpPassword.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getTmpPassword](/API_docs/methods/account.getTmpPassword.html) + + + diff --git a/docs/API_docs/types/account.WallPapers.md b/docs/API_docs/types/account.WallPapers.md new file mode 100644 index 0000000000..120222e108 --- /dev/null +++ b/docs/API_docs/types/account.WallPapers.md @@ -0,0 +1,26 @@ +--- +title: account.WallPapers +description: constructors and methods of type account.WallPapers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_WallPapers.html +--- +# Type: account.WallPapers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.wallPapersNotModified](/API_docs/constructors/account.wallPapersNotModified.html) + +[account.wallPapers](/API_docs/constructors/account.wallPapers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getWallPapers](/API_docs/methods/account.getWallPapers.html) + + + diff --git a/docs/API_docs/types/account.WebAuthorizations.md b/docs/API_docs/types/account.WebAuthorizations.md new file mode 100644 index 0000000000..dfb4a1d708 --- /dev/null +++ b/docs/API_docs/types/account.WebAuthorizations.md @@ -0,0 +1,24 @@ +--- +title: account.WebAuthorizations +description: constructors and methods of type account.WebAuthorizations +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/account_WebAuthorizations.html +--- +# Type: account.WebAuthorizations +[Back to types index](index.html) + + + +### Possible values (constructors): + +[account.webAuthorizations](/API_docs/constructors/account.webAuthorizations.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->account->getWebAuthorizations](/API_docs/methods/account.getWebAuthorizations.html) + + + diff --git a/docs/API_docs/types/auth.Authorization.md b/docs/API_docs/types/auth.Authorization.md new file mode 100644 index 0000000000..464cf4692c --- /dev/null +++ b/docs/API_docs/types/auth.Authorization.md @@ -0,0 +1,38 @@ +--- +title: auth.Authorization +description: constructors and methods of type auth.Authorization +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_Authorization.html +--- +# Type: auth.Authorization +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.authorization](/API_docs/constructors/auth.authorization.html) + +[auth.authorizationSignUpRequired](/API_docs/constructors/auth.authorizationSignUpRequired.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->signUp](/API_docs/methods/auth.signUp.html) + +[$MadelineProto->auth->signIn](/API_docs/methods/auth.signIn.html) + +[$MadelineProto->auth->importAuthorization](/API_docs/methods/auth.importAuthorization.html) + +[$MadelineProto->auth->importBotAuthorization](/API_docs/methods/auth.importBotAuthorization.html) + +[$MadelineProto->auth->checkPassword](/API_docs/methods/auth.checkPassword.html) + +[$MadelineProto->auth->recoverPassword](/API_docs/methods/auth.recoverPassword.html) + +[$MadelineProto->auth->importWebTokenAuthorization](/API_docs/methods/auth.importWebTokenAuthorization.html) + + + diff --git a/docs/API_docs/types/auth.CodeType.md b/docs/API_docs/types/auth.CodeType.md new file mode 100644 index 0000000000..2fc47b6a21 --- /dev/null +++ b/docs/API_docs/types/auth.CodeType.md @@ -0,0 +1,30 @@ +--- +title: auth.CodeType +description: constructors and methods of type auth.CodeType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_CodeType.html +--- +# Type: auth.CodeType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.codeTypeSms](/API_docs/constructors/auth.codeTypeSms.html) + +[auth.codeTypeCall](/API_docs/constructors/auth.codeTypeCall.html) + +[auth.codeTypeFlashCall](/API_docs/constructors/auth.codeTypeFlashCall.html) + +[auth.codeTypeMissedCall](/API_docs/constructors/auth.codeTypeMissedCall.html) + +[auth.codeTypeFragmentSms](/API_docs/constructors/auth.codeTypeFragmentSms.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/auth.ExportedAuthorization.md b/docs/API_docs/types/auth.ExportedAuthorization.md new file mode 100644 index 0000000000..3cba26b6ad --- /dev/null +++ b/docs/API_docs/types/auth.ExportedAuthorization.md @@ -0,0 +1,24 @@ +--- +title: auth.ExportedAuthorization +description: constructors and methods of type auth.ExportedAuthorization +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_ExportedAuthorization.html +--- +# Type: auth.ExportedAuthorization +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.exportedAuthorization](/API_docs/constructors/auth.exportedAuthorization.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->exportAuthorization](/API_docs/methods/auth.exportAuthorization.html) + + + diff --git a/docs/API_docs/types/auth.LoggedOut.md b/docs/API_docs/types/auth.LoggedOut.md new file mode 100644 index 0000000000..2b43f77508 --- /dev/null +++ b/docs/API_docs/types/auth.LoggedOut.md @@ -0,0 +1,24 @@ +--- +title: auth.LoggedOut +description: constructors and methods of type auth.LoggedOut +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_LoggedOut.html +--- +# Type: auth.LoggedOut +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.loggedOut](/API_docs/constructors/auth.loggedOut.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->logOut](/API_docs/methods/auth.logOut.html) + + + diff --git a/docs/API_docs/types/auth.LoginToken.md b/docs/API_docs/types/auth.LoginToken.md new file mode 100644 index 0000000000..04a7de626f --- /dev/null +++ b/docs/API_docs/types/auth.LoginToken.md @@ -0,0 +1,30 @@ +--- +title: auth.LoginToken +description: constructors and methods of type auth.LoginToken +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_LoginToken.html +--- +# Type: auth.LoginToken +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.loginToken](/API_docs/constructors/auth.loginToken.html) + +[auth.loginTokenMigrateTo](/API_docs/constructors/auth.loginTokenMigrateTo.html) + +[auth.loginTokenSuccess](/API_docs/constructors/auth.loginTokenSuccess.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->exportLoginToken](/API_docs/methods/auth.exportLoginToken.html) + +[$MadelineProto->auth->importLoginToken](/API_docs/methods/auth.importLoginToken.html) + + + diff --git a/docs/API_docs/types/auth.PasswordRecovery.md b/docs/API_docs/types/auth.PasswordRecovery.md new file mode 100644 index 0000000000..824a93ed7f --- /dev/null +++ b/docs/API_docs/types/auth.PasswordRecovery.md @@ -0,0 +1,24 @@ +--- +title: auth.PasswordRecovery +description: constructors and methods of type auth.PasswordRecovery +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_PasswordRecovery.html +--- +# Type: auth.PasswordRecovery +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.passwordRecovery](/API_docs/constructors/auth.passwordRecovery.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->requestPasswordRecovery](/API_docs/methods/auth.requestPasswordRecovery.html) + + + diff --git a/docs/API_docs/types/auth.SentCode.md b/docs/API_docs/types/auth.SentCode.md new file mode 100644 index 0000000000..b5fcff84f3 --- /dev/null +++ b/docs/API_docs/types/auth.SentCode.md @@ -0,0 +1,36 @@ +--- +title: auth.SentCode +description: constructors and methods of type auth.SentCode +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_SentCode.html +--- +# Type: auth.SentCode +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.sentCode](/API_docs/constructors/auth.sentCode.html) + +[auth.sentCodeSuccess](/API_docs/constructors/auth.sentCodeSuccess.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->auth->sendCode](/API_docs/methods/auth.sendCode.html) + +[$MadelineProto->auth->resendCode](/API_docs/methods/auth.resendCode.html) + +[$MadelineProto->auth->resetLoginEmail](/API_docs/methods/auth.resetLoginEmail.html) + +[$MadelineProto->account->sendChangePhoneCode](/API_docs/methods/account.sendChangePhoneCode.html) + +[$MadelineProto->account->sendConfirmPhoneCode](/API_docs/methods/account.sendConfirmPhoneCode.html) + +[$MadelineProto->account->sendVerifyPhoneCode](/API_docs/methods/account.sendVerifyPhoneCode.html) + + + diff --git a/docs/API_docs/types/auth.SentCodeType.md b/docs/API_docs/types/auth.SentCodeType.md new file mode 100644 index 0000000000..e421173221 --- /dev/null +++ b/docs/API_docs/types/auth.SentCodeType.md @@ -0,0 +1,42 @@ +--- +title: auth.SentCodeType +description: constructors and methods of type auth.SentCodeType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/auth_SentCodeType.html +--- +# Type: auth.SentCodeType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[auth.sentCodeTypeApp](/API_docs/constructors/auth.sentCodeTypeApp.html) + +[auth.sentCodeTypeSms](/API_docs/constructors/auth.sentCodeTypeSms.html) + +[auth.sentCodeTypeCall](/API_docs/constructors/auth.sentCodeTypeCall.html) + +[auth.sentCodeTypeFlashCall](/API_docs/constructors/auth.sentCodeTypeFlashCall.html) + +[auth.sentCodeTypeMissedCall](/API_docs/constructors/auth.sentCodeTypeMissedCall.html) + +[auth.sentCodeTypeEmailCode](/API_docs/constructors/auth.sentCodeTypeEmailCode.html) + +[auth.sentCodeTypeSetUpEmailRequired](/API_docs/constructors/auth.sentCodeTypeSetUpEmailRequired.html) + +[auth.sentCodeTypeFragmentSms](/API_docs/constructors/auth.sentCodeTypeFragmentSms.html) + +[auth.sentCodeTypeFirebaseSms](/API_docs/constructors/auth.sentCodeTypeFirebaseSms.html) + +[auth.sentCodeTypeSmsWord](/API_docs/constructors/auth.sentCodeTypeSmsWord.html) + +[auth.sentCodeTypeSmsPhrase](/API_docs/constructors/auth.sentCodeTypeSmsPhrase.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/bots.BotInfo.md b/docs/API_docs/types/bots.BotInfo.md new file mode 100644 index 0000000000..b60e554ed4 --- /dev/null +++ b/docs/API_docs/types/bots.BotInfo.md @@ -0,0 +1,24 @@ +--- +title: bots.BotInfo +description: constructors and methods of type bots.BotInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/bots_BotInfo.html +--- +# Type: bots.BotInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[bots.botInfo](/API_docs/constructors/bots.botInfo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->bots->getBotInfo](/API_docs/methods/bots.getBotInfo.html) + + + diff --git a/docs/API_docs/types/bytes.md b/docs/API_docs/types/bytes.md new file mode 100644 index 0000000000..ff1d00fbe5 --- /dev/null +++ b/docs/API_docs/types/bytes.md @@ -0,0 +1,13 @@ +--- +title: bytes +description: A string of variable length +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: bytes +[Back to constructor index](index.html) + +```php +$bytes = "simple string of bytes"; +``` + diff --git a/docs/API_docs/types/channels.AdminLogResults.md b/docs/API_docs/types/channels.AdminLogResults.md new file mode 100644 index 0000000000..19cd1d71ae --- /dev/null +++ b/docs/API_docs/types/channels.AdminLogResults.md @@ -0,0 +1,24 @@ +--- +title: channels.AdminLogResults +description: constructors and methods of type channels.AdminLogResults +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/channels_AdminLogResults.html +--- +# Type: channels.AdminLogResults +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channels.adminLogResults](/API_docs/constructors/channels.adminLogResults.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getAdminLog](/API_docs/methods/channels.getAdminLog.html) + + + diff --git a/docs/API_docs/types/channels.ChannelParticipant.md b/docs/API_docs/types/channels.ChannelParticipant.md new file mode 100644 index 0000000000..86a384419d --- /dev/null +++ b/docs/API_docs/types/channels.ChannelParticipant.md @@ -0,0 +1,24 @@ +--- +title: channels.ChannelParticipant +description: constructors and methods of type channels.ChannelParticipant +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/channels_ChannelParticipant.html +--- +# Type: channels.ChannelParticipant +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channels.channelParticipant](/API_docs/constructors/channels.channelParticipant.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getParticipant](/API_docs/methods/channels.getParticipant.html) + + + diff --git a/docs/API_docs/types/channels.ChannelParticipants.md b/docs/API_docs/types/channels.ChannelParticipants.md new file mode 100644 index 0000000000..ebd77652e4 --- /dev/null +++ b/docs/API_docs/types/channels.ChannelParticipants.md @@ -0,0 +1,26 @@ +--- +title: channels.ChannelParticipants +description: constructors and methods of type channels.ChannelParticipants +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/channels_ChannelParticipants.html +--- +# Type: channels.ChannelParticipants +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channels.channelParticipants](/API_docs/constructors/channels.channelParticipants.html) + +[channels.channelParticipantsNotModified](/API_docs/constructors/channels.channelParticipantsNotModified.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getParticipants](/API_docs/methods/channels.getParticipants.html) + + + diff --git a/docs/API_docs/types/channels.SendAsPeers.md b/docs/API_docs/types/channels.SendAsPeers.md new file mode 100644 index 0000000000..47585d0b34 --- /dev/null +++ b/docs/API_docs/types/channels.SendAsPeers.md @@ -0,0 +1,24 @@ +--- +title: channels.SendAsPeers +description: constructors and methods of type channels.SendAsPeers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/channels_SendAsPeers.html +--- +# Type: channels.SendAsPeers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channels.sendAsPeers](/API_docs/constructors/channels.sendAsPeers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getSendAs](/API_docs/methods/channels.getSendAs.html) + + + diff --git a/docs/API_docs/types/channels.SponsoredMessageReportResult.md b/docs/API_docs/types/channels.SponsoredMessageReportResult.md new file mode 100644 index 0000000000..e9169be7af --- /dev/null +++ b/docs/API_docs/types/channels.SponsoredMessageReportResult.md @@ -0,0 +1,28 @@ +--- +title: channels.SponsoredMessageReportResult +description: constructors and methods of type channels.SponsoredMessageReportResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/channels_SponsoredMessageReportResult.html +--- +# Type: channels.SponsoredMessageReportResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[channels.sponsoredMessageReportResultChooseOption](/API_docs/constructors/channels.sponsoredMessageReportResultChooseOption.html) + +[channels.sponsoredMessageReportResultAdsHidden](/API_docs/constructors/channels.sponsoredMessageReportResultAdsHidden.html) + +[channels.sponsoredMessageReportResultReported](/API_docs/constructors/channels.sponsoredMessageReportResultReported.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->reportSponsoredMessage](/API_docs/methods/channels.reportSponsoredMessage.html) + + + diff --git a/docs/API_docs/types/chatlists.ChatlistInvite.md b/docs/API_docs/types/chatlists.ChatlistInvite.md new file mode 100644 index 0000000000..b829c96b38 --- /dev/null +++ b/docs/API_docs/types/chatlists.ChatlistInvite.md @@ -0,0 +1,26 @@ +--- +title: chatlists.ChatlistInvite +description: constructors and methods of type chatlists.ChatlistInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/chatlists_ChatlistInvite.html +--- +# Type: chatlists.ChatlistInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatlists.chatlistInviteAlready](/API_docs/constructors/chatlists.chatlistInviteAlready.html) + +[chatlists.chatlistInvite](/API_docs/constructors/chatlists.chatlistInvite.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->chatlists->checkChatlistInvite](/API_docs/methods/chatlists.checkChatlistInvite.html) + + + diff --git a/docs/API_docs/types/chatlists.ChatlistUpdates.md b/docs/API_docs/types/chatlists.ChatlistUpdates.md new file mode 100644 index 0000000000..677fab0d92 --- /dev/null +++ b/docs/API_docs/types/chatlists.ChatlistUpdates.md @@ -0,0 +1,24 @@ +--- +title: chatlists.ChatlistUpdates +description: constructors and methods of type chatlists.ChatlistUpdates +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/chatlists_ChatlistUpdates.html +--- +# Type: chatlists.ChatlistUpdates +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatlists.chatlistUpdates](/API_docs/constructors/chatlists.chatlistUpdates.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->chatlists->getChatlistUpdates](/API_docs/methods/chatlists.getChatlistUpdates.html) + + + diff --git a/docs/API_docs/types/chatlists.ExportedChatlistInvite.md b/docs/API_docs/types/chatlists.ExportedChatlistInvite.md new file mode 100644 index 0000000000..2936c7f33c --- /dev/null +++ b/docs/API_docs/types/chatlists.ExportedChatlistInvite.md @@ -0,0 +1,24 @@ +--- +title: chatlists.ExportedChatlistInvite +description: constructors and methods of type chatlists.ExportedChatlistInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/chatlists_ExportedChatlistInvite.html +--- +# Type: chatlists.ExportedChatlistInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatlists.exportedChatlistInvite](/API_docs/constructors/chatlists.exportedChatlistInvite.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->chatlists->exportChatlistInvite](/API_docs/methods/chatlists.exportChatlistInvite.html) + + + diff --git a/docs/API_docs/types/chatlists.ExportedInvites.md b/docs/API_docs/types/chatlists.ExportedInvites.md new file mode 100644 index 0000000000..612c401619 --- /dev/null +++ b/docs/API_docs/types/chatlists.ExportedInvites.md @@ -0,0 +1,24 @@ +--- +title: chatlists.ExportedInvites +description: constructors and methods of type chatlists.ExportedInvites +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/chatlists_ExportedInvites.html +--- +# Type: chatlists.ExportedInvites +[Back to types index](index.html) + + + +### Possible values (constructors): + +[chatlists.exportedInvites](/API_docs/constructors/chatlists.exportedInvites.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->chatlists->getExportedInvites](/API_docs/methods/chatlists.getExportedInvites.html) + + + diff --git a/docs/API_docs/types/contacts.Blocked.md b/docs/API_docs/types/contacts.Blocked.md new file mode 100644 index 0000000000..7483b714e3 --- /dev/null +++ b/docs/API_docs/types/contacts.Blocked.md @@ -0,0 +1,26 @@ +--- +title: contacts.Blocked +description: constructors and methods of type contacts.Blocked +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_Blocked.html +--- +# Type: contacts.Blocked +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.blocked](/API_docs/constructors/contacts.blocked.html) + +[contacts.blockedSlice](/API_docs/constructors/contacts.blockedSlice.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->getBlocked](/API_docs/methods/contacts.getBlocked.html) + + + diff --git a/docs/API_docs/types/contacts.ContactBirthdays.md b/docs/API_docs/types/contacts.ContactBirthdays.md new file mode 100644 index 0000000000..f345effb7f --- /dev/null +++ b/docs/API_docs/types/contacts.ContactBirthdays.md @@ -0,0 +1,24 @@ +--- +title: contacts.ContactBirthdays +description: constructors and methods of type contacts.ContactBirthdays +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_ContactBirthdays.html +--- +# Type: contacts.ContactBirthdays +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.contactBirthdays](/API_docs/constructors/contacts.contactBirthdays.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->getBirthdays](/API_docs/methods/contacts.getBirthdays.html) + + + diff --git a/docs/API_docs/types/contacts.Contacts.md b/docs/API_docs/types/contacts.Contacts.md new file mode 100644 index 0000000000..afef840053 --- /dev/null +++ b/docs/API_docs/types/contacts.Contacts.md @@ -0,0 +1,26 @@ +--- +title: contacts.Contacts +description: constructors and methods of type contacts.Contacts +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_Contacts.html +--- +# Type: contacts.Contacts +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.contactsNotModified](/API_docs/constructors/contacts.contactsNotModified.html) + +[contacts.contacts](/API_docs/constructors/contacts.contacts.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->getContacts](/API_docs/methods/contacts.getContacts.html) + + + diff --git a/docs/API_docs/types/contacts.Found.md b/docs/API_docs/types/contacts.Found.md new file mode 100644 index 0000000000..a78e235064 --- /dev/null +++ b/docs/API_docs/types/contacts.Found.md @@ -0,0 +1,24 @@ +--- +title: contacts.Found +description: constructors and methods of type contacts.Found +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_Found.html +--- +# Type: contacts.Found +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.found](/API_docs/constructors/contacts.found.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->search](/API_docs/methods/contacts.search.html) + + + diff --git a/docs/API_docs/types/contacts.ImportedContacts.md b/docs/API_docs/types/contacts.ImportedContacts.md new file mode 100644 index 0000000000..a9710a5ffc --- /dev/null +++ b/docs/API_docs/types/contacts.ImportedContacts.md @@ -0,0 +1,24 @@ +--- +title: contacts.ImportedContacts +description: constructors and methods of type contacts.ImportedContacts +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_ImportedContacts.html +--- +# Type: contacts.ImportedContacts +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.importedContacts](/API_docs/constructors/contacts.importedContacts.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->importContacts](/API_docs/methods/contacts.importContacts.html) + + + diff --git a/docs/API_docs/types/contacts.ResolvedPeer.md b/docs/API_docs/types/contacts.ResolvedPeer.md new file mode 100644 index 0000000000..f6dc482b26 --- /dev/null +++ b/docs/API_docs/types/contacts.ResolvedPeer.md @@ -0,0 +1,26 @@ +--- +title: contacts.ResolvedPeer +description: constructors and methods of type contacts.ResolvedPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_ResolvedPeer.html +--- +# Type: contacts.ResolvedPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.resolvedPeer](/API_docs/constructors/contacts.resolvedPeer.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->resolveUsername](/API_docs/methods/contacts.resolveUsername.html) + +[$MadelineProto->contacts->resolvePhone](/API_docs/methods/contacts.resolvePhone.html) + + + diff --git a/docs/API_docs/types/contacts.TopPeers.md b/docs/API_docs/types/contacts.TopPeers.md new file mode 100644 index 0000000000..6776aa84d6 --- /dev/null +++ b/docs/API_docs/types/contacts.TopPeers.md @@ -0,0 +1,28 @@ +--- +title: contacts.TopPeers +description: constructors and methods of type contacts.TopPeers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/contacts_TopPeers.html +--- +# Type: contacts.TopPeers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[contacts.topPeersNotModified](/API_docs/constructors/contacts.topPeersNotModified.html) + +[contacts.topPeers](/API_docs/constructors/contacts.topPeers.html) + +[contacts.topPeersDisabled](/API_docs/constructors/contacts.topPeersDisabled.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->contacts->getTopPeers](/API_docs/methods/contacts.getTopPeers.html) + + + diff --git a/docs/API_docs/types/double.md b/docs/API_docs/types/double.md new file mode 100644 index 0000000000..6a0545ce05 --- /dev/null +++ b/docs/API_docs/types/double.md @@ -0,0 +1,10 @@ +--- +title: double +description: A double precision floating point number +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: double +[Back to constructor index](index.html) + +A double precision floating point number, single precision can also be used (float). diff --git a/docs/API_docs/types/fragment.CollectibleInfo.md b/docs/API_docs/types/fragment.CollectibleInfo.md new file mode 100644 index 0000000000..30da4fc66e --- /dev/null +++ b/docs/API_docs/types/fragment.CollectibleInfo.md @@ -0,0 +1,24 @@ +--- +title: fragment.CollectibleInfo +description: constructors and methods of type fragment.CollectibleInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/fragment_CollectibleInfo.html +--- +# Type: fragment.CollectibleInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[fragment.collectibleInfo](/API_docs/constructors/fragment.collectibleInfo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->fragment->getCollectibleInfo](/API_docs/methods/fragment.getCollectibleInfo.html) + + + diff --git a/docs/API_docs/types/help.AppConfig.md b/docs/API_docs/types/help.AppConfig.md new file mode 100644 index 0000000000..c5d45fc04b --- /dev/null +++ b/docs/API_docs/types/help.AppConfig.md @@ -0,0 +1,26 @@ +--- +title: help.AppConfig +description: constructors and methods of type help.AppConfig +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_AppConfig.html +--- +# Type: help.AppConfig +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.appConfigNotModified](/API_docs/constructors/help.appConfigNotModified.html) + +[help.appConfig](/API_docs/constructors/help.appConfig.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getAppConfig](/API_docs/methods/help.getAppConfig.html) + + + diff --git a/docs/API_docs/types/help.AppUpdate.md b/docs/API_docs/types/help.AppUpdate.md new file mode 100644 index 0000000000..6af587eeaf --- /dev/null +++ b/docs/API_docs/types/help.AppUpdate.md @@ -0,0 +1,26 @@ +--- +title: help.AppUpdate +description: constructors and methods of type help.AppUpdate +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_AppUpdate.html +--- +# Type: help.AppUpdate +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.appUpdate](/API_docs/constructors/help.appUpdate.html) + +[help.noAppUpdate](/API_docs/constructors/help.noAppUpdate.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getAppUpdate](/API_docs/methods/help.getAppUpdate.html) + + + diff --git a/docs/API_docs/types/help.CountriesList.md b/docs/API_docs/types/help.CountriesList.md new file mode 100644 index 0000000000..deb4967cfd --- /dev/null +++ b/docs/API_docs/types/help.CountriesList.md @@ -0,0 +1,26 @@ +--- +title: help.CountriesList +description: constructors and methods of type help.CountriesList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_CountriesList.html +--- +# Type: help.CountriesList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.countriesListNotModified](/API_docs/constructors/help.countriesListNotModified.html) + +[help.countriesList](/API_docs/constructors/help.countriesList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getCountriesList](/API_docs/methods/help.getCountriesList.html) + + + diff --git a/docs/API_docs/types/help.Country.md b/docs/API_docs/types/help.Country.md new file mode 100644 index 0000000000..e3f061f499 --- /dev/null +++ b/docs/API_docs/types/help.Country.md @@ -0,0 +1,22 @@ +--- +title: help.Country +description: constructors and methods of type help.Country +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_Country.html +--- +# Type: help.Country +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.country](/API_docs/constructors/help.country.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/help.CountryCode.md b/docs/API_docs/types/help.CountryCode.md new file mode 100644 index 0000000000..7aa91b8a13 --- /dev/null +++ b/docs/API_docs/types/help.CountryCode.md @@ -0,0 +1,22 @@ +--- +title: help.CountryCode +description: constructors and methods of type help.CountryCode +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_CountryCode.html +--- +# Type: help.CountryCode +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.countryCode](/API_docs/constructors/help.countryCode.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/help.DeepLinkInfo.md b/docs/API_docs/types/help.DeepLinkInfo.md new file mode 100644 index 0000000000..ec3dccae6c --- /dev/null +++ b/docs/API_docs/types/help.DeepLinkInfo.md @@ -0,0 +1,26 @@ +--- +title: help.DeepLinkInfo +description: constructors and methods of type help.DeepLinkInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_DeepLinkInfo.html +--- +# Type: help.DeepLinkInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.deepLinkInfoEmpty](/API_docs/constructors/help.deepLinkInfoEmpty.html) + +[help.deepLinkInfo](/API_docs/constructors/help.deepLinkInfo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getDeepLinkInfo](/API_docs/methods/help.getDeepLinkInfo.html) + + + diff --git a/docs/API_docs/types/help.InviteText.md b/docs/API_docs/types/help.InviteText.md new file mode 100644 index 0000000000..51b57bf89b --- /dev/null +++ b/docs/API_docs/types/help.InviteText.md @@ -0,0 +1,24 @@ +--- +title: help.InviteText +description: constructors and methods of type help.InviteText +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_InviteText.html +--- +# Type: help.InviteText +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.inviteText](/API_docs/constructors/help.inviteText.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getInviteText](/API_docs/methods/help.getInviteText.html) + + + diff --git a/docs/API_docs/types/help.PassportConfig.md b/docs/API_docs/types/help.PassportConfig.md new file mode 100644 index 0000000000..09bcefb5fe --- /dev/null +++ b/docs/API_docs/types/help.PassportConfig.md @@ -0,0 +1,26 @@ +--- +title: help.PassportConfig +description: constructors and methods of type help.PassportConfig +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_PassportConfig.html +--- +# Type: help.PassportConfig +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.passportConfigNotModified](/API_docs/constructors/help.passportConfigNotModified.html) + +[help.passportConfig](/API_docs/constructors/help.passportConfig.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getPassportConfig](/API_docs/methods/help.getPassportConfig.html) + + + diff --git a/docs/API_docs/types/help.PeerColorOption.md b/docs/API_docs/types/help.PeerColorOption.md new file mode 100644 index 0000000000..8b2425e41a --- /dev/null +++ b/docs/API_docs/types/help.PeerColorOption.md @@ -0,0 +1,22 @@ +--- +title: help.PeerColorOption +description: constructors and methods of type help.PeerColorOption +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_PeerColorOption.html +--- +# Type: help.PeerColorOption +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.peerColorOption](/API_docs/constructors/help.peerColorOption.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/help.PeerColorSet.md b/docs/API_docs/types/help.PeerColorSet.md new file mode 100644 index 0000000000..7aeca87dbd --- /dev/null +++ b/docs/API_docs/types/help.PeerColorSet.md @@ -0,0 +1,24 @@ +--- +title: help.PeerColorSet +description: constructors and methods of type help.PeerColorSet +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_PeerColorSet.html +--- +# Type: help.PeerColorSet +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.peerColorSet](/API_docs/constructors/help.peerColorSet.html) + +[help.peerColorProfileSet](/API_docs/constructors/help.peerColorProfileSet.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/help.PeerColors.md b/docs/API_docs/types/help.PeerColors.md new file mode 100644 index 0000000000..d7c20f58c5 --- /dev/null +++ b/docs/API_docs/types/help.PeerColors.md @@ -0,0 +1,28 @@ +--- +title: help.PeerColors +description: constructors and methods of type help.PeerColors +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_PeerColors.html +--- +# Type: help.PeerColors +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.peerColorsNotModified](/API_docs/constructors/help.peerColorsNotModified.html) + +[help.peerColors](/API_docs/constructors/help.peerColors.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getPeerColors](/API_docs/methods/help.getPeerColors.html) + +[$MadelineProto->help->getPeerProfileColors](/API_docs/methods/help.getPeerProfileColors.html) + + + diff --git a/docs/API_docs/types/help.PremiumPromo.md b/docs/API_docs/types/help.PremiumPromo.md new file mode 100644 index 0000000000..bffcb48e2d --- /dev/null +++ b/docs/API_docs/types/help.PremiumPromo.md @@ -0,0 +1,24 @@ +--- +title: help.PremiumPromo +description: constructors and methods of type help.PremiumPromo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_PremiumPromo.html +--- +# Type: help.PremiumPromo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.premiumPromo](/API_docs/constructors/help.premiumPromo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getPremiumPromo](/API_docs/methods/help.getPremiumPromo.html) + + + diff --git a/docs/API_docs/types/help.PromoData.md b/docs/API_docs/types/help.PromoData.md new file mode 100644 index 0000000000..ada56a3cda --- /dev/null +++ b/docs/API_docs/types/help.PromoData.md @@ -0,0 +1,26 @@ +--- +title: help.PromoData +description: constructors and methods of type help.PromoData +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_PromoData.html +--- +# Type: help.PromoData +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.promoDataEmpty](/API_docs/constructors/help.promoDataEmpty.html) + +[help.promoData](/API_docs/constructors/help.promoData.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getPromoData](/API_docs/methods/help.getPromoData.html) + + + diff --git a/docs/API_docs/types/help.RecentMeUrls.md b/docs/API_docs/types/help.RecentMeUrls.md new file mode 100644 index 0000000000..43b41a544f --- /dev/null +++ b/docs/API_docs/types/help.RecentMeUrls.md @@ -0,0 +1,24 @@ +--- +title: help.RecentMeUrls +description: constructors and methods of type help.RecentMeUrls +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_RecentMeUrls.html +--- +# Type: help.RecentMeUrls +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.recentMeUrls](/API_docs/constructors/help.recentMeUrls.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getRecentMeUrls](/API_docs/methods/help.getRecentMeUrls.html) + + + diff --git a/docs/API_docs/types/help.Support.md b/docs/API_docs/types/help.Support.md new file mode 100644 index 0000000000..571541bd4b --- /dev/null +++ b/docs/API_docs/types/help.Support.md @@ -0,0 +1,24 @@ +--- +title: help.Support +description: constructors and methods of type help.Support +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_Support.html +--- +# Type: help.Support +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.support](/API_docs/constructors/help.support.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getSupport](/API_docs/methods/help.getSupport.html) + + + diff --git a/docs/API_docs/types/help.SupportName.md b/docs/API_docs/types/help.SupportName.md new file mode 100644 index 0000000000..6f01f6624d --- /dev/null +++ b/docs/API_docs/types/help.SupportName.md @@ -0,0 +1,24 @@ +--- +title: help.SupportName +description: constructors and methods of type help.SupportName +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_SupportName.html +--- +# Type: help.SupportName +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.supportName](/API_docs/constructors/help.supportName.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getSupportName](/API_docs/methods/help.getSupportName.html) + + + diff --git a/docs/API_docs/types/help.TermsOfService.md b/docs/API_docs/types/help.TermsOfService.md new file mode 100644 index 0000000000..e405069823 --- /dev/null +++ b/docs/API_docs/types/help.TermsOfService.md @@ -0,0 +1,22 @@ +--- +title: help.TermsOfService +description: constructors and methods of type help.TermsOfService +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_TermsOfService.html +--- +# Type: help.TermsOfService +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.termsOfService](/API_docs/constructors/help.termsOfService.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/help.TermsOfServiceUpdate.md b/docs/API_docs/types/help.TermsOfServiceUpdate.md new file mode 100644 index 0000000000..4bff0dfa06 --- /dev/null +++ b/docs/API_docs/types/help.TermsOfServiceUpdate.md @@ -0,0 +1,26 @@ +--- +title: help.TermsOfServiceUpdate +description: constructors and methods of type help.TermsOfServiceUpdate +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_TermsOfServiceUpdate.html +--- +# Type: help.TermsOfServiceUpdate +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.termsOfServiceUpdateEmpty](/API_docs/constructors/help.termsOfServiceUpdateEmpty.html) + +[help.termsOfServiceUpdate](/API_docs/constructors/help.termsOfServiceUpdate.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getTermsOfServiceUpdate](/API_docs/methods/help.getTermsOfServiceUpdate.html) + + + diff --git a/docs/API_docs/types/help.TimezonesList.md b/docs/API_docs/types/help.TimezonesList.md new file mode 100644 index 0000000000..c5e2ed418f --- /dev/null +++ b/docs/API_docs/types/help.TimezonesList.md @@ -0,0 +1,26 @@ +--- +title: help.TimezonesList +description: constructors and methods of type help.TimezonesList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_TimezonesList.html +--- +# Type: help.TimezonesList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.timezonesListNotModified](/API_docs/constructors/help.timezonesListNotModified.html) + +[help.timezonesList](/API_docs/constructors/help.timezonesList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getTimezonesList](/API_docs/methods/help.getTimezonesList.html) + + + diff --git a/docs/API_docs/types/help.UserInfo.md b/docs/API_docs/types/help.UserInfo.md new file mode 100644 index 0000000000..51906a5714 --- /dev/null +++ b/docs/API_docs/types/help.UserInfo.md @@ -0,0 +1,28 @@ +--- +title: help.UserInfo +description: constructors and methods of type help.UserInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/help_UserInfo.html +--- +# Type: help.UserInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[help.userInfoEmpty](/API_docs/constructors/help.userInfoEmpty.html) + +[help.userInfo](/API_docs/constructors/help.userInfo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->help->getUserInfo](/API_docs/methods/help.getUserInfo.html) + +[$MadelineProto->help->editUserInfo](/API_docs/methods/help.editUserInfo.html) + + + diff --git a/docs/API_docs/types/index.md b/docs/API_docs/types/index.md new file mode 100644 index 0000000000..1ddf8cb271 --- /dev/null +++ b/docs/API_docs/types/index.md @@ -0,0 +1,999 @@ +--- +title: Types +description: List of types +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Types +[Back to API documentation index](..) + +[AccountDaysTTL](/API_docs/types/AccountDaysTTL.html) + +[AppWebViewResult](/API_docs/types/AppWebViewResult.html) + +[AttachMenuBot](/API_docs/types/AttachMenuBot.html) + +[AttachMenuBotIcon](/API_docs/types/AttachMenuBotIcon.html) + +[AttachMenuBotIconColor](/API_docs/types/AttachMenuBotIconColor.html) + +[AttachMenuBots](/API_docs/types/AttachMenuBots.html) + +[AttachMenuBotsBot](/API_docs/types/AttachMenuBotsBot.html) + +[AttachMenuPeerType](/API_docs/types/AttachMenuPeerType.html) + +[Authorization](/API_docs/types/Authorization.html) + +[AutoDownloadSettings](/API_docs/types/AutoDownloadSettings.html) + +[AutoSaveException](/API_docs/types/AutoSaveException.html) + +[AutoSaveSettings](/API_docs/types/AutoSaveSettings.html) + +[AvailableReaction](/API_docs/types/AvailableReaction.html) + +[BankCardOpenUrl](/API_docs/types/BankCardOpenUrl.html) + +[BaseTheme](/API_docs/types/BaseTheme.html) + +[Birthday](/API_docs/types/Birthday.html) + +[Bool](/API_docs/types/Bool.html) + +[Boost](/API_docs/types/Boost.html) + +[BotApp](/API_docs/types/BotApp.html) + +[BotBusinessConnection](/API_docs/types/BotBusinessConnection.html) + +[BotCommand](/API_docs/types/BotCommand.html) + +[BotCommandScope](/API_docs/types/BotCommandScope.html) + +[BotInfo](/API_docs/types/BotInfo.html) + +[BotInlineMessage](/API_docs/types/BotInlineMessage.html) + +[BotInlineResult](/API_docs/types/BotInlineResult.html) + +[BotMenuButton](/API_docs/types/BotMenuButton.html) + +[BroadcastRevenueBalances](/API_docs/types/BroadcastRevenueBalances.html) + +[BroadcastRevenueTransaction](/API_docs/types/BroadcastRevenueTransaction.html) + +[BusinessAwayMessage](/API_docs/types/BusinessAwayMessage.html) + +[BusinessAwayMessageSchedule](/API_docs/types/BusinessAwayMessageSchedule.html) + +[BusinessBotRecipients](/API_docs/types/BusinessBotRecipients.html) + +[BusinessChatLink](/API_docs/types/BusinessChatLink.html) + +[BusinessGreetingMessage](/API_docs/types/BusinessGreetingMessage.html) + +[BusinessIntro](/API_docs/types/BusinessIntro.html) + +[BusinessLocation](/API_docs/types/BusinessLocation.html) + +[BusinessRecipients](/API_docs/types/BusinessRecipients.html) + +[BusinessWeeklyOpen](/API_docs/types/BusinessWeeklyOpen.html) + +[BusinessWorkHours](/API_docs/types/BusinessWorkHours.html) + +[CdnConfig](/API_docs/types/CdnConfig.html) + +[CdnPublicKey](/API_docs/types/CdnPublicKey.html) + +[ChannelAdminLogEvent](/API_docs/types/ChannelAdminLogEvent.html) + +[ChannelAdminLogEventAction](/API_docs/types/ChannelAdminLogEventAction.html) + +[ChannelAdminLogEventsFilter](/API_docs/types/ChannelAdminLogEventsFilter.html) + +[ChannelLocation](/API_docs/types/ChannelLocation.html) + +[ChannelMessagesFilter](/API_docs/types/ChannelMessagesFilter.html) + +[ChannelParticipant](/API_docs/types/ChannelParticipant.html) + +[ChannelParticipantsFilter](/API_docs/types/ChannelParticipantsFilter.html) + +[Chat](/API_docs/types/Chat.html) + +[ChatAdminRights](/API_docs/types/ChatAdminRights.html) + +[ChatAdminWithInvites](/API_docs/types/ChatAdminWithInvites.html) + +[ChatBannedRights](/API_docs/types/ChatBannedRights.html) + +[ChatFull](/API_docs/types/ChatFull.html) + +[ChatInvite](/API_docs/types/ChatInvite.html) + +[ChatInviteImporter](/API_docs/types/ChatInviteImporter.html) + +[ChatOnlines](/API_docs/types/ChatOnlines.html) + +[ChatParticipant](/API_docs/types/ChatParticipant.html) + +[ChatParticipants](/API_docs/types/ChatParticipants.html) + +[ChatPhoto](/API_docs/types/ChatPhoto.html) + +[ChatReactions](/API_docs/types/ChatReactions.html) + +[CodeSettings](/API_docs/types/CodeSettings.html) + +[Config](/API_docs/types/Config.html) + +[ConnectedBot](/API_docs/types/ConnectedBot.html) + +[Contact](/API_docs/types/Contact.html) + +[ContactBirthday](/API_docs/types/ContactBirthday.html) + +[ContactStatus](/API_docs/types/ContactStatus.html) + +[DataJSON](/API_docs/types/DataJSON.html) + +[DcOption](/API_docs/types/DcOption.html) + +[DecryptedMessage](/API_docs/types/DecryptedMessage.html) + +[DecryptedMessageAction](/API_docs/types/DecryptedMessageAction.html) + +[DecryptedMessageLayer](/API_docs/types/DecryptedMessageLayer.html) + +[DecryptedMessageMedia](/API_docs/types/DecryptedMessageMedia.html) + +[DefaultHistoryTTL](/API_docs/types/DefaultHistoryTTL.html) + +[Dialog](/API_docs/types/Dialog.html) + +[DialogFilter](/API_docs/types/DialogFilter.html) + +[DialogFilterSuggested](/API_docs/types/DialogFilterSuggested.html) + +[DialogPeer](/API_docs/types/DialogPeer.html) + +[Document](/API_docs/types/Document.html) + +[DocumentAttribute](/API_docs/types/DocumentAttribute.html) + +[DraftMessage](/API_docs/types/DraftMessage.html) + +[EmailVerification](/API_docs/types/EmailVerification.html) + +[EmailVerifyPurpose](/API_docs/types/EmailVerifyPurpose.html) + +[EmojiGroup](/API_docs/types/EmojiGroup.html) + +[EmojiKeyword](/API_docs/types/EmojiKeyword.html) + +[EmojiKeywordsDifference](/API_docs/types/EmojiKeywordsDifference.html) + +[EmojiLanguage](/API_docs/types/EmojiLanguage.html) + +[EmojiList](/API_docs/types/EmojiList.html) + +[EmojiStatus](/API_docs/types/EmojiStatus.html) + +[EmojiURL](/API_docs/types/EmojiURL.html) + +[EncryptedChat](/API_docs/types/EncryptedChat.html) + +[EncryptedFile](/API_docs/types/EncryptedFile.html) + +[EncryptedMessage](/API_docs/types/EncryptedMessage.html) + +[Error](/API_docs/types/Error.html) + +[ExportedChatInvite](/API_docs/types/ExportedChatInvite.html) + +[ExportedChatlistInvite](/API_docs/types/ExportedChatlistInvite.html) + +[ExportedContactToken](/API_docs/types/ExportedContactToken.html) + +[ExportedMessageLink](/API_docs/types/ExportedMessageLink.html) + +[ExportedStoryLink](/API_docs/types/ExportedStoryLink.html) + +[FileHash](/API_docs/types/FileHash.html) + +[FileLocation](/API_docs/types/FileLocation.html) + +[Folder](/API_docs/types/Folder.html) + +[FolderPeer](/API_docs/types/FolderPeer.html) + +[ForumTopic](/API_docs/types/ForumTopic.html) + +[Game](/API_docs/types/Game.html) + +[GeoPoint](/API_docs/types/GeoPoint.html) + +[GlobalPrivacySettings](/API_docs/types/GlobalPrivacySettings.html) + +[GroupCall](/API_docs/types/GroupCall.html) + +[GroupCallParticipant](/API_docs/types/GroupCallParticipant.html) + +[GroupCallParticipantVideo](/API_docs/types/GroupCallParticipantVideo.html) + +[GroupCallParticipantVideoSourceGroup](/API_docs/types/GroupCallParticipantVideoSourceGroup.html) + +[GroupCallStreamChannel](/API_docs/types/GroupCallStreamChannel.html) + +[HighScore](/API_docs/types/HighScore.html) + +[ImportedContact](/API_docs/types/ImportedContact.html) + +[InlineBotSwitchPM](/API_docs/types/InlineBotSwitchPM.html) + +[InlineBotWebView](/API_docs/types/InlineBotWebView.html) + +[InlineQueryPeerType](/API_docs/types/InlineQueryPeerType.html) + +[InputAppEvent](/API_docs/types/InputAppEvent.html) + +[InputBotApp](/API_docs/types/InputBotApp.html) + +[InputBotInlineMessage](/API_docs/types/InputBotInlineMessage.html) + +[InputBotInlineMessageID](/API_docs/types/InputBotInlineMessageID.html) + +[InputBotInlineResult](/API_docs/types/InputBotInlineResult.html) + +[InputBusinessAwayMessage](/API_docs/types/InputBusinessAwayMessage.html) + +[InputBusinessBotRecipients](/API_docs/types/InputBusinessBotRecipients.html) + +[InputBusinessChatLink](/API_docs/types/InputBusinessChatLink.html) + +[InputBusinessGreetingMessage](/API_docs/types/InputBusinessGreetingMessage.html) + +[InputBusinessIntro](/API_docs/types/InputBusinessIntro.html) + +[InputBusinessRecipients](/API_docs/types/InputBusinessRecipients.html) + +[InputChannel](/API_docs/types/InputChannel.html) + +[InputChatPhoto](/API_docs/types/InputChatPhoto.html) + +[InputChatlist](/API_docs/types/InputChatlist.html) + +[InputCheckPasswordSRP](/API_docs/types/InputCheckPasswordSRP.html) + +[InputClientProxy](/API_docs/types/InputClientProxy.html) + +[InputCollectible](/API_docs/types/InputCollectible.html) + +[InputContact](/API_docs/types/InputContact.html) + +[InputDialogPeer](/API_docs/types/InputDialogPeer.html) + +[InputDocument](/API_docs/types/InputDocument.html) + +[InputEncryptedChat](/API_docs/types/InputEncryptedChat.html) + +[InputEncryptedFile](/API_docs/types/InputEncryptedFile.html) + +[InputFile](/API_docs/types/InputFile.html) + +[InputFileLocation](/API_docs/types/InputFileLocation.html) + +[InputFolderPeer](/API_docs/types/InputFolderPeer.html) + +[InputGame](/API_docs/types/InputGame.html) + +[InputGeoPoint](/API_docs/types/InputGeoPoint.html) + +[InputGroupCall](/API_docs/types/InputGroupCall.html) + +[InputInvoice](/API_docs/types/InputInvoice.html) + +[InputMedia](/API_docs/types/InputMedia.html) + +[InputMessage](/API_docs/types/InputMessage.html) + +[InputNotifyPeer](/API_docs/types/InputNotifyPeer.html) + +[InputPaymentCredentials](/API_docs/types/InputPaymentCredentials.html) + +[InputPeer](/API_docs/types/InputPeer.html) + +[InputPeerNotifySettings](/API_docs/types/InputPeerNotifySettings.html) + +[InputPhoneCall](/API_docs/types/InputPhoneCall.html) + +[InputPhoto](/API_docs/types/InputPhoto.html) + +[InputPrivacyKey](/API_docs/types/InputPrivacyKey.html) + +[InputPrivacyRule](/API_docs/types/InputPrivacyRule.html) + +[InputQuickReplyShortcut](/API_docs/types/InputQuickReplyShortcut.html) + +[InputReplyTo](/API_docs/types/InputReplyTo.html) + +[InputSecureFile](/API_docs/types/InputSecureFile.html) + +[InputSecureValue](/API_docs/types/InputSecureValue.html) + +[InputSingleMedia](/API_docs/types/InputSingleMedia.html) + +[InputStickerSet](/API_docs/types/InputStickerSet.html) + +[InputStickerSetItem](/API_docs/types/InputStickerSetItem.html) + +[InputStickeredMedia](/API_docs/types/InputStickeredMedia.html) + +[InputStorePaymentPurpose](/API_docs/types/InputStorePaymentPurpose.html) + +[InputTheme](/API_docs/types/InputTheme.html) + +[InputThemeSettings](/API_docs/types/InputThemeSettings.html) + +[InputUser](/API_docs/types/InputUser.html) + +[InputWallPaper](/API_docs/types/InputWallPaper.html) + +[InputWebDocument](/API_docs/types/InputWebDocument.html) + +[InputWebFileLocation](/API_docs/types/InputWebFileLocation.html) + +[Invoice](/API_docs/types/Invoice.html) + +[JSONObjectValue](/API_docs/types/JSONObjectValue.html) + +[JSONValue](/API_docs/types/JSONValue.html) + +[KeyboardButton](/API_docs/types/KeyboardButton.html) + +[KeyboardButtonRow](/API_docs/types/KeyboardButtonRow.html) + +[LabeledPrice](/API_docs/types/LabeledPrice.html) + +[LangPackDifference](/API_docs/types/LangPackDifference.html) + +[LangPackLanguage](/API_docs/types/LangPackLanguage.html) + +[LangPackString](/API_docs/types/LangPackString.html) + +[MaskCoords](/API_docs/types/MaskCoords.html) + +[MediaArea](/API_docs/types/MediaArea.html) + +[MediaAreaCoordinates](/API_docs/types/MediaAreaCoordinates.html) + +[Message](/API_docs/types/Message.html) + +[MessageAction](/API_docs/types/MessageAction.html) + +[MessageEntity](/API_docs/types/MessageEntity.html) + +[MessageExtendedMedia](/API_docs/types/MessageExtendedMedia.html) + +[MessageFwdHeader](/API_docs/types/MessageFwdHeader.html) + +[MessageMedia](/API_docs/types/MessageMedia.html) + +[MessagePeerReaction](/API_docs/types/MessagePeerReaction.html) + +[MessagePeerVote](/API_docs/types/MessagePeerVote.html) + +[MessageRange](/API_docs/types/MessageRange.html) + +[MessageReactions](/API_docs/types/MessageReactions.html) + +[MessageReplies](/API_docs/types/MessageReplies.html) + +[MessageReplyHeader](/API_docs/types/MessageReplyHeader.html) + +[MessageViews](/API_docs/types/MessageViews.html) + +[MessagesFilter](/API_docs/types/MessagesFilter.html) + +[MissingInvitee](/API_docs/types/MissingInvitee.html) + +[MyBoost](/API_docs/types/MyBoost.html) + +[NearestDc](/API_docs/types/NearestDc.html) + +[NotificationSound](/API_docs/types/NotificationSound.html) + +[NotifyPeer](/API_docs/types/NotifyPeer.html) + +[Null](/API_docs/types/Null.html) + +[OutboxReadDate](/API_docs/types/OutboxReadDate.html) + +[Page](/API_docs/types/Page.html) + +[PageBlock](/API_docs/types/PageBlock.html) + +[PageCaption](/API_docs/types/PageCaption.html) + +[PageListItem](/API_docs/types/PageListItem.html) + +[PageListOrderedItem](/API_docs/types/PageListOrderedItem.html) + +[PageRelatedArticle](/API_docs/types/PageRelatedArticle.html) + +[PageTableCell](/API_docs/types/PageTableCell.html) + +[PageTableRow](/API_docs/types/PageTableRow.html) + +[PasswordKdfAlgo](/API_docs/types/PasswordKdfAlgo.html) + +[PaymentCharge](/API_docs/types/PaymentCharge.html) + +[PaymentFormMethod](/API_docs/types/PaymentFormMethod.html) + +[PaymentRequestedInfo](/API_docs/types/PaymentRequestedInfo.html) + +[PaymentSavedCredentials](/API_docs/types/PaymentSavedCredentials.html) + +[Peer](/API_docs/types/Peer.html) + +[PeerBlocked](/API_docs/types/PeerBlocked.html) + +[PeerColor](/API_docs/types/PeerColor.html) + +[PeerLocated](/API_docs/types/PeerLocated.html) + +[PeerNotifySettings](/API_docs/types/PeerNotifySettings.html) + +[PeerSettings](/API_docs/types/PeerSettings.html) + +[PeerStories](/API_docs/types/PeerStories.html) + +[PhoneCall](/API_docs/types/PhoneCall.html) + +[PhoneCallDiscardReason](/API_docs/types/PhoneCallDiscardReason.html) + +[PhoneCallProtocol](/API_docs/types/PhoneCallProtocol.html) + +[PhoneConnection](/API_docs/types/PhoneConnection.html) + +[Photo](/API_docs/types/Photo.html) + +[PhotoSize](/API_docs/types/PhotoSize.html) + +[Poll](/API_docs/types/Poll.html) + +[PollAnswer](/API_docs/types/PollAnswer.html) + +[PollAnswerVoters](/API_docs/types/PollAnswerVoters.html) + +[PollResults](/API_docs/types/PollResults.html) + +[PopularContact](/API_docs/types/PopularContact.html) + +[PostAddress](/API_docs/types/PostAddress.html) + +[PostInteractionCounters](/API_docs/types/PostInteractionCounters.html) + +[PremiumGiftCodeOption](/API_docs/types/PremiumGiftCodeOption.html) + +[PremiumGiftOption](/API_docs/types/PremiumGiftOption.html) + +[PremiumSubscriptionOption](/API_docs/types/PremiumSubscriptionOption.html) + +[PrepaidGiveaway](/API_docs/types/PrepaidGiveaway.html) + +[PrivacyKey](/API_docs/types/PrivacyKey.html) + +[PrivacyRule](/API_docs/types/PrivacyRule.html) + +[PublicForward](/API_docs/types/PublicForward.html) + +[QuickReply](/API_docs/types/QuickReply.html) + +[Reaction](/API_docs/types/Reaction.html) + +[ReactionCount](/API_docs/types/ReactionCount.html) + +[ReactionNotificationsFrom](/API_docs/types/ReactionNotificationsFrom.html) + +[ReactionsNotifySettings](/API_docs/types/ReactionsNotifySettings.html) + +[ReadParticipantDate](/API_docs/types/ReadParticipantDate.html) + +[ReceivedNotifyMessage](/API_docs/types/ReceivedNotifyMessage.html) + +[RecentMeUrl](/API_docs/types/RecentMeUrl.html) + +[ReplyMarkup](/API_docs/types/ReplyMarkup.html) + +[ReportReason](/API_docs/types/ReportReason.html) + +[RequestPeerType](/API_docs/types/RequestPeerType.html) + +[RequestedPeer](/API_docs/types/RequestedPeer.html) + +[RestrictionReason](/API_docs/types/RestrictionReason.html) + +[RichText](/API_docs/types/RichText.html) + +[SavedContact](/API_docs/types/SavedContact.html) + +[SavedDialog](/API_docs/types/SavedDialog.html) + +[SavedReactionTag](/API_docs/types/SavedReactionTag.html) + +[SearchResultsCalendarPeriod](/API_docs/types/SearchResultsCalendarPeriod.html) + +[SearchResultsPosition](/API_docs/types/SearchResultsPosition.html) + +[SecureCredentialsEncrypted](/API_docs/types/SecureCredentialsEncrypted.html) + +[SecureData](/API_docs/types/SecureData.html) + +[SecureFile](/API_docs/types/SecureFile.html) + +[SecurePasswordKdfAlgo](/API_docs/types/SecurePasswordKdfAlgo.html) + +[SecurePlainData](/API_docs/types/SecurePlainData.html) + +[SecureRequiredType](/API_docs/types/SecureRequiredType.html) + +[SecureSecretSettings](/API_docs/types/SecureSecretSettings.html) + +[SecureValue](/API_docs/types/SecureValue.html) + +[SecureValueError](/API_docs/types/SecureValueError.html) + +[SecureValueHash](/API_docs/types/SecureValueHash.html) + +[SecureValueType](/API_docs/types/SecureValueType.html) + +[SendAsPeer](/API_docs/types/SendAsPeer.html) + +[SendMessageAction](/API_docs/types/SendMessageAction.html) + +[ShippingOption](/API_docs/types/ShippingOption.html) + +[SimpleWebViewResult](/API_docs/types/SimpleWebViewResult.html) + +[SmsJob](/API_docs/types/SmsJob.html) + +[SponsoredMessage](/API_docs/types/SponsoredMessage.html) + +[SponsoredMessageReportOption](/API_docs/types/SponsoredMessageReportOption.html) + +[StatsAbsValueAndPrev](/API_docs/types/StatsAbsValueAndPrev.html) + +[StatsDateRangeDays](/API_docs/types/StatsDateRangeDays.html) + +[StatsGraph](/API_docs/types/StatsGraph.html) + +[StatsGroupTopAdmin](/API_docs/types/StatsGroupTopAdmin.html) + +[StatsGroupTopInviter](/API_docs/types/StatsGroupTopInviter.html) + +[StatsGroupTopPoster](/API_docs/types/StatsGroupTopPoster.html) + +[StatsPercentValue](/API_docs/types/StatsPercentValue.html) + +[StatsURL](/API_docs/types/StatsURL.html) + +[StickerKeyword](/API_docs/types/StickerKeyword.html) + +[StickerPack](/API_docs/types/StickerPack.html) + +[StickerSet](/API_docs/types/StickerSet.html) + +[StickerSetCovered](/API_docs/types/StickerSetCovered.html) + +[StoriesStealthMode](/API_docs/types/StoriesStealthMode.html) + +[StoryFwdHeader](/API_docs/types/StoryFwdHeader.html) + +[StoryItem](/API_docs/types/StoryItem.html) + +[StoryReaction](/API_docs/types/StoryReaction.html) + +[StoryView](/API_docs/types/StoryView.html) + +[StoryViews](/API_docs/types/StoryViews.html) + +[TextWithEntities](/API_docs/types/TextWithEntities.html) + +[Theme](/API_docs/types/Theme.html) + +[ThemeSettings](/API_docs/types/ThemeSettings.html) + +[Timezone](/API_docs/types/Timezone.html) + +[TopPeer](/API_docs/types/TopPeer.html) + +[TopPeerCategory](/API_docs/types/TopPeerCategory.html) + +[TopPeerCategoryPeers](/API_docs/types/TopPeerCategoryPeers.html) + +[True](/API_docs/types/True.html) + +[Update](/API_docs/types/Update.html) + +[Updates](/API_docs/types/Updates.html) + +[UrlAuthResult](/API_docs/types/UrlAuthResult.html) + +[User](/API_docs/types/User.html) + +[UserFull](/API_docs/types/UserFull.html) + +[UserProfilePhoto](/API_docs/types/UserProfilePhoto.html) + +[UserStatus](/API_docs/types/UserStatus.html) + +[Username](/API_docs/types/Username.html) + +[VideoSize](/API_docs/types/VideoSize.html) + +[WallPaper](/API_docs/types/WallPaper.html) + +[WallPaperSettings](/API_docs/types/WallPaperSettings.html) + +[WebAuthorization](/API_docs/types/WebAuthorization.html) + +[WebDocument](/API_docs/types/WebDocument.html) + +[WebPage](/API_docs/types/WebPage.html) + +[WebPageAttribute](/API_docs/types/WebPageAttribute.html) + +[WebViewMessageSent](/API_docs/types/WebViewMessageSent.html) + +[WebViewResult](/API_docs/types/WebViewResult.html) + +[X](/API_docs/types/X.html) + +[account.AuthorizationForm](/API_docs/types/account.AuthorizationForm.html) + +[account.Authorizations](/API_docs/types/account.Authorizations.html) + +[account.AutoDownloadSettings](/API_docs/types/account.AutoDownloadSettings.html) + +[account.AutoSaveSettings](/API_docs/types/account.AutoSaveSettings.html) + +[account.BusinessChatLinks](/API_docs/types/account.BusinessChatLinks.html) + +[account.ConnectedBots](/API_docs/types/account.ConnectedBots.html) + +[account.ContentSettings](/API_docs/types/account.ContentSettings.html) + +[account.EmailVerified](/API_docs/types/account.EmailVerified.html) + +[account.EmojiStatuses](/API_docs/types/account.EmojiStatuses.html) + +[account.Password](/API_docs/types/account.Password.html) + +[account.PasswordInputSettings](/API_docs/types/account.PasswordInputSettings.html) + +[account.PasswordSettings](/API_docs/types/account.PasswordSettings.html) + +[account.PrivacyRules](/API_docs/types/account.PrivacyRules.html) + +[account.ResetPasswordResult](/API_docs/types/account.ResetPasswordResult.html) + +[account.ResolvedBusinessChatLinks](/API_docs/types/account.ResolvedBusinessChatLinks.html) + +[account.SavedRingtone](/API_docs/types/account.SavedRingtone.html) + +[account.SavedRingtones](/API_docs/types/account.SavedRingtones.html) + +[account.SentEmailCode](/API_docs/types/account.SentEmailCode.html) + +[account.Takeout](/API_docs/types/account.Takeout.html) + +[account.Themes](/API_docs/types/account.Themes.html) + +[account.TmpPassword](/API_docs/types/account.TmpPassword.html) + +[account.WallPapers](/API_docs/types/account.WallPapers.html) + +[account.WebAuthorizations](/API_docs/types/account.WebAuthorizations.html) + +[auth.Authorization](/API_docs/types/auth.Authorization.html) + +[auth.CodeType](/API_docs/types/auth.CodeType.html) + +[auth.ExportedAuthorization](/API_docs/types/auth.ExportedAuthorization.html) + +[auth.LoggedOut](/API_docs/types/auth.LoggedOut.html) + +[auth.LoginToken](/API_docs/types/auth.LoginToken.html) + +[auth.PasswordRecovery](/API_docs/types/auth.PasswordRecovery.html) + +[auth.SentCode](/API_docs/types/auth.SentCode.html) + +[auth.SentCodeType](/API_docs/types/auth.SentCodeType.html) + +[bots.BotInfo](/API_docs/types/bots.BotInfo.html) + +[channels.AdminLogResults](/API_docs/types/channels.AdminLogResults.html) + +[channels.ChannelParticipant](/API_docs/types/channels.ChannelParticipant.html) + +[channels.ChannelParticipants](/API_docs/types/channels.ChannelParticipants.html) + +[channels.SendAsPeers](/API_docs/types/channels.SendAsPeers.html) + +[channels.SponsoredMessageReportResult](/API_docs/types/channels.SponsoredMessageReportResult.html) + +[chatlists.ChatlistInvite](/API_docs/types/chatlists.ChatlistInvite.html) + +[chatlists.ChatlistUpdates](/API_docs/types/chatlists.ChatlistUpdates.html) + +[chatlists.ExportedChatlistInvite](/API_docs/types/chatlists.ExportedChatlistInvite.html) + +[chatlists.ExportedInvites](/API_docs/types/chatlists.ExportedInvites.html) + +[contacts.Blocked](/API_docs/types/contacts.Blocked.html) + +[contacts.ContactBirthdays](/API_docs/types/contacts.ContactBirthdays.html) + +[contacts.Contacts](/API_docs/types/contacts.Contacts.html) + +[contacts.Found](/API_docs/types/contacts.Found.html) + +[contacts.ImportedContacts](/API_docs/types/contacts.ImportedContacts.html) + +[contacts.ResolvedPeer](/API_docs/types/contacts.ResolvedPeer.html) + +[contacts.TopPeers](/API_docs/types/contacts.TopPeers.html) + +[fragment.CollectibleInfo](/API_docs/types/fragment.CollectibleInfo.html) + +[help.AppConfig](/API_docs/types/help.AppConfig.html) + +[help.AppUpdate](/API_docs/types/help.AppUpdate.html) + +[help.CountriesList](/API_docs/types/help.CountriesList.html) + +[help.Country](/API_docs/types/help.Country.html) + +[help.CountryCode](/API_docs/types/help.CountryCode.html) + +[help.DeepLinkInfo](/API_docs/types/help.DeepLinkInfo.html) + +[help.InviteText](/API_docs/types/help.InviteText.html) + +[help.PassportConfig](/API_docs/types/help.PassportConfig.html) + +[help.PeerColorOption](/API_docs/types/help.PeerColorOption.html) + +[help.PeerColorSet](/API_docs/types/help.PeerColorSet.html) + +[help.PeerColors](/API_docs/types/help.PeerColors.html) + +[help.PremiumPromo](/API_docs/types/help.PremiumPromo.html) + +[help.PromoData](/API_docs/types/help.PromoData.html) + +[help.RecentMeUrls](/API_docs/types/help.RecentMeUrls.html) + +[help.Support](/API_docs/types/help.Support.html) + +[help.SupportName](/API_docs/types/help.SupportName.html) + +[help.TermsOfService](/API_docs/types/help.TermsOfService.html) + +[help.TermsOfServiceUpdate](/API_docs/types/help.TermsOfServiceUpdate.html) + +[help.TimezonesList](/API_docs/types/help.TimezonesList.html) + +[help.UserInfo](/API_docs/types/help.UserInfo.html) + +[int](/API_docs/types/int.html) + +[long](/API_docs/types/long.html) + +[messages.AffectedFoundMessages](/API_docs/types/messages.AffectedFoundMessages.html) + +[messages.AffectedHistory](/API_docs/types/messages.AffectedHistory.html) + +[messages.AffectedMessages](/API_docs/types/messages.AffectedMessages.html) + +[messages.AllStickers](/API_docs/types/messages.AllStickers.html) + +[messages.ArchivedStickers](/API_docs/types/messages.ArchivedStickers.html) + +[messages.AvailableReactions](/API_docs/types/messages.AvailableReactions.html) + +[messages.BotApp](/API_docs/types/messages.BotApp.html) + +[messages.BotCallbackAnswer](/API_docs/types/messages.BotCallbackAnswer.html) + +[messages.BotResults](/API_docs/types/messages.BotResults.html) + +[messages.ChatAdminsWithInvites](/API_docs/types/messages.ChatAdminsWithInvites.html) + +[messages.ChatFull](/API_docs/types/messages.ChatFull.html) + +[messages.ChatInviteImporters](/API_docs/types/messages.ChatInviteImporters.html) + +[messages.Chats](/API_docs/types/messages.Chats.html) + +[messages.CheckedHistoryImportPeer](/API_docs/types/messages.CheckedHistoryImportPeer.html) + +[messages.DhConfig](/API_docs/types/messages.DhConfig.html) + +[messages.DialogFilters](/API_docs/types/messages.DialogFilters.html) + +[messages.Dialogs](/API_docs/types/messages.Dialogs.html) + +[messages.DiscussionMessage](/API_docs/types/messages.DiscussionMessage.html) + +[messages.EmojiGroups](/API_docs/types/messages.EmojiGroups.html) + +[messages.ExportedChatInvite](/API_docs/types/messages.ExportedChatInvite.html) + +[messages.ExportedChatInvites](/API_docs/types/messages.ExportedChatInvites.html) + +[messages.FavedStickers](/API_docs/types/messages.FavedStickers.html) + +[messages.FeaturedStickers](/API_docs/types/messages.FeaturedStickers.html) + +[messages.ForumTopics](/API_docs/types/messages.ForumTopics.html) + +[messages.FoundStickerSets](/API_docs/types/messages.FoundStickerSets.html) + +[messages.HighScores](/API_docs/types/messages.HighScores.html) + +[messages.HistoryImport](/API_docs/types/messages.HistoryImport.html) + +[messages.HistoryImportParsed](/API_docs/types/messages.HistoryImportParsed.html) + +[messages.InactiveChats](/API_docs/types/messages.InactiveChats.html) + +[messages.InvitedUsers](/API_docs/types/messages.InvitedUsers.html) + +[messages.MessageEditData](/API_docs/types/messages.MessageEditData.html) + +[messages.MessageReactionsList](/API_docs/types/messages.MessageReactionsList.html) + +[messages.MessageViews](/API_docs/types/messages.MessageViews.html) + +[messages.Messages](/API_docs/types/messages.Messages.html) + +[messages.MyStickers](/API_docs/types/messages.MyStickers.html) + +[messages.PeerDialogs](/API_docs/types/messages.PeerDialogs.html) + +[messages.PeerSettings](/API_docs/types/messages.PeerSettings.html) + +[messages.QuickReplies](/API_docs/types/messages.QuickReplies.html) + +[messages.Reactions](/API_docs/types/messages.Reactions.html) + +[messages.RecentStickers](/API_docs/types/messages.RecentStickers.html) + +[messages.SavedDialogs](/API_docs/types/messages.SavedDialogs.html) + +[messages.SavedGifs](/API_docs/types/messages.SavedGifs.html) + +[messages.SavedReactionTags](/API_docs/types/messages.SavedReactionTags.html) + +[messages.SearchCounter](/API_docs/types/messages.SearchCounter.html) + +[messages.SearchResultsCalendar](/API_docs/types/messages.SearchResultsCalendar.html) + +[messages.SearchResultsPositions](/API_docs/types/messages.SearchResultsPositions.html) + +[messages.SentEncryptedMessage](/API_docs/types/messages.SentEncryptedMessage.html) + +[messages.SponsoredMessages](/API_docs/types/messages.SponsoredMessages.html) + +[messages.StickerSet](/API_docs/types/messages.StickerSet.html) + +[messages.StickerSetInstallResult](/API_docs/types/messages.StickerSetInstallResult.html) + +[messages.Stickers](/API_docs/types/messages.Stickers.html) + +[messages.TranscribedAudio](/API_docs/types/messages.TranscribedAudio.html) + +[messages.TranslatedText](/API_docs/types/messages.TranslatedText.html) + +[messages.VotesList](/API_docs/types/messages.VotesList.html) + +[messages.WebPage](/API_docs/types/messages.WebPage.html) + +[payments.BankCardData](/API_docs/types/payments.BankCardData.html) + +[payments.CheckedGiftCode](/API_docs/types/payments.CheckedGiftCode.html) + +[payments.ExportedInvoice](/API_docs/types/payments.ExportedInvoice.html) + +[payments.GiveawayInfo](/API_docs/types/payments.GiveawayInfo.html) + +[payments.PaymentForm](/API_docs/types/payments.PaymentForm.html) + +[payments.PaymentReceipt](/API_docs/types/payments.PaymentReceipt.html) + +[payments.PaymentResult](/API_docs/types/payments.PaymentResult.html) + +[payments.SavedInfo](/API_docs/types/payments.SavedInfo.html) + +[payments.ValidatedRequestedInfo](/API_docs/types/payments.ValidatedRequestedInfo.html) + +[phone.ExportedGroupCallInvite](/API_docs/types/phone.ExportedGroupCallInvite.html) + +[phone.GroupCall](/API_docs/types/phone.GroupCall.html) + +[phone.GroupCallStreamChannels](/API_docs/types/phone.GroupCallStreamChannels.html) + +[phone.GroupCallStreamRtmpUrl](/API_docs/types/phone.GroupCallStreamRtmpUrl.html) + +[phone.GroupParticipants](/API_docs/types/phone.GroupParticipants.html) + +[phone.JoinAsPeers](/API_docs/types/phone.JoinAsPeers.html) + +[phone.PhoneCall](/API_docs/types/phone.PhoneCall.html) + +[photos.Photo](/API_docs/types/photos.Photo.html) + +[photos.Photos](/API_docs/types/photos.Photos.html) + +[premium.BoostsList](/API_docs/types/premium.BoostsList.html) + +[premium.BoostsStatus](/API_docs/types/premium.BoostsStatus.html) + +[premium.MyBoosts](/API_docs/types/premium.MyBoosts.html) + +[smsjobs.EligibilityToJoin](/API_docs/types/smsjobs.EligibilityToJoin.html) + +[smsjobs.Status](/API_docs/types/smsjobs.Status.html) + +[stats.BroadcastRevenueStats](/API_docs/types/stats.BroadcastRevenueStats.html) + +[stats.BroadcastRevenueTransactions](/API_docs/types/stats.BroadcastRevenueTransactions.html) + +[stats.BroadcastRevenueWithdrawalUrl](/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.html) + +[stats.BroadcastStats](/API_docs/types/stats.BroadcastStats.html) + +[stats.MegagroupStats](/API_docs/types/stats.MegagroupStats.html) + +[stats.MessageStats](/API_docs/types/stats.MessageStats.html) + +[stats.PublicForwards](/API_docs/types/stats.PublicForwards.html) + +[stats.StoryStats](/API_docs/types/stats.StoryStats.html) + +[stickers.SuggestedShortName](/API_docs/types/stickers.SuggestedShortName.html) + +[storage.FileType](/API_docs/types/storage.FileType.html) + +[stories.AllStories](/API_docs/types/stories.AllStories.html) + +[stories.PeerStories](/API_docs/types/stories.PeerStories.html) + +[stories.Stories](/API_docs/types/stories.Stories.html) + +[stories.StoryReactionsList](/API_docs/types/stories.StoryReactionsList.html) + +[stories.StoryViews](/API_docs/types/stories.StoryViews.html) + +[stories.StoryViewsList](/API_docs/types/stories.StoryViewsList.html) + +[updates.ChannelDifference](/API_docs/types/updates.ChannelDifference.html) + +[updates.Difference](/API_docs/types/updates.Difference.html) + +[updates.State](/API_docs/types/updates.State.html) + +[upload.CdnFile](/API_docs/types/upload.CdnFile.html) + +[upload.File](/API_docs/types/upload.File.html) + +[upload.WebFile](/API_docs/types/upload.WebFile.html) + +[users.UserFull](/API_docs/types/users.UserFull.html) + diff --git a/docs/API_docs/types/int.md b/docs/API_docs/types/int.md new file mode 100644 index 0000000000..59ad4e6570 --- /dev/null +++ b/docs/API_docs/types/int.md @@ -0,0 +1,10 @@ +--- +title: integer +description: A 32 bit signed integer ranging from -2147483648 to 2147483647 +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int +[Back to constructor index](index.html) + +A 32 bit signed integer ranging from `-2147483648` to `2147483647`. diff --git a/docs/API_docs/types/int128.md b/docs/API_docs/types/int128.md new file mode 100644 index 0000000000..2f28592d0c --- /dev/null +++ b/docs/API_docs/types/int128.md @@ -0,0 +1,10 @@ +--- +title: int128 +description: A 128 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int128 +[Back to constructor index](index.html) + +A 128 bit signed integer represented in little-endian base256 (`string`) format. diff --git a/docs/API_docs/types/int256.md b/docs/API_docs/types/int256.md new file mode 100644 index 0000000000..6a67124c18 --- /dev/null +++ b/docs/API_docs/types/int256.md @@ -0,0 +1,10 @@ +--- +title: int256 +description: A 256 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int256 +[Back to constructor index](index.html) + +A 256 bit signed integer represented in little-endian base256 (`string`) format. diff --git a/docs/API_docs/types/int512.md b/docs/API_docs/types/int512.md new file mode 100644 index 0000000000..756bedce57 --- /dev/null +++ b/docs/API_docs/types/int512.md @@ -0,0 +1,10 @@ +--- +title: int512 +description: A 512 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int512 +[Back to constructor index](index.html) + +A 512 bit signed integer represented in little-endian base256 (`string`) format. diff --git a/docs/API_docs/types/int53.md b/docs/API_docs/types/int53.md new file mode 100644 index 0000000000..90a1e5ef7c --- /dev/null +++ b/docs/API_docs/types/int53.md @@ -0,0 +1,10 @@ +--- +title: integer +description: A 53 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int53 +[Back to constructor index](index.html) + +A 53 bit signed integer. diff --git a/docs/API_docs/types/long.md b/docs/API_docs/types/long.md new file mode 100644 index 0000000000..4465a550d2 --- /dev/null +++ b/docs/API_docs/types/long.md @@ -0,0 +1,10 @@ +--- +title: long +description: A 32 bit signed integer ranging from -9223372036854775808 to 9223372036854775807 +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: long +[Back to constructor index](index.html) + +A 64 bit signed integer ranging from `-9223372036854775808` to `9223372036854775807`. diff --git a/docs/API_docs/types/messages.AffectedFoundMessages.md b/docs/API_docs/types/messages.AffectedFoundMessages.md new file mode 100644 index 0000000000..1b723a3314 --- /dev/null +++ b/docs/API_docs/types/messages.AffectedFoundMessages.md @@ -0,0 +1,24 @@ +--- +title: messages.AffectedFoundMessages +description: constructors and methods of type messages.AffectedFoundMessages +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_AffectedFoundMessages.html +--- +# Type: messages.AffectedFoundMessages +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.affectedFoundMessages](/API_docs/constructors/messages.affectedFoundMessages.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->deletePhoneCallHistory](/API_docs/methods/messages.deletePhoneCallHistory.html) + + + diff --git a/docs/API_docs/types/messages.AffectedHistory.md b/docs/API_docs/types/messages.AffectedHistory.md new file mode 100644 index 0000000000..94f0745297 --- /dev/null +++ b/docs/API_docs/types/messages.AffectedHistory.md @@ -0,0 +1,36 @@ +--- +title: messages.AffectedHistory +description: constructors and methods of type messages.AffectedHistory +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_AffectedHistory.html +--- +# Type: messages.AffectedHistory +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.affectedHistory](/API_docs/constructors/messages.affectedHistory.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->deleteHistory](/API_docs/methods/messages.deleteHistory.html) + +[$MadelineProto->messages->readMentions](/API_docs/methods/messages.readMentions.html) + +[$MadelineProto->messages->unpinAllMessages](/API_docs/methods/messages.unpinAllMessages.html) + +[$MadelineProto->messages->readReactions](/API_docs/methods/messages.readReactions.html) + +[$MadelineProto->messages->deleteSavedHistory](/API_docs/methods/messages.deleteSavedHistory.html) + +[$MadelineProto->channels->deleteParticipantHistory](/API_docs/methods/channels.deleteParticipantHistory.html) + +[$MadelineProto->channels->deleteTopicHistory](/API_docs/methods/channels.deleteTopicHistory.html) + + + diff --git a/docs/API_docs/types/messages.AffectedMessages.md b/docs/API_docs/types/messages.AffectedMessages.md new file mode 100644 index 0000000000..daa430c8c3 --- /dev/null +++ b/docs/API_docs/types/messages.AffectedMessages.md @@ -0,0 +1,30 @@ +--- +title: messages.AffectedMessages +description: constructors and methods of type messages.AffectedMessages +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_AffectedMessages.html +--- +# Type: messages.AffectedMessages +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.affectedMessages](/API_docs/constructors/messages.affectedMessages.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->readHistory](/API_docs/methods/messages.readHistory.html) + +[$MadelineProto->messages->deleteMessages](/API_docs/methods/messages.deleteMessages.html) + +[$MadelineProto->messages->readMessageContents](/API_docs/methods/messages.readMessageContents.html) + +[$MadelineProto->channels->deleteMessages](/API_docs/methods/channels.deleteMessages.html) + + + diff --git a/docs/API_docs/types/messages.AllStickers.md b/docs/API_docs/types/messages.AllStickers.md new file mode 100644 index 0000000000..4a3aa3f055 --- /dev/null +++ b/docs/API_docs/types/messages.AllStickers.md @@ -0,0 +1,30 @@ +--- +title: messages.AllStickers +description: constructors and methods of type messages.AllStickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_AllStickers.html +--- +# Type: messages.AllStickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.allStickersNotModified](/API_docs/constructors/messages.allStickersNotModified.html) + +[messages.allStickers](/API_docs/constructors/messages.allStickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getAllStickers](/API_docs/methods/messages.getAllStickers.html) + +[$MadelineProto->messages->getMaskStickers](/API_docs/methods/messages.getMaskStickers.html) + +[$MadelineProto->messages->getEmojiStickers](/API_docs/methods/messages.getEmojiStickers.html) + + + diff --git a/docs/API_docs/types/messages.ArchivedStickers.md b/docs/API_docs/types/messages.ArchivedStickers.md new file mode 100644 index 0000000000..8c4c3e80f2 --- /dev/null +++ b/docs/API_docs/types/messages.ArchivedStickers.md @@ -0,0 +1,24 @@ +--- +title: messages.ArchivedStickers +description: constructors and methods of type messages.ArchivedStickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ArchivedStickers.html +--- +# Type: messages.ArchivedStickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.archivedStickers](/API_docs/constructors/messages.archivedStickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getArchivedStickers](/API_docs/methods/messages.getArchivedStickers.html) + + + diff --git a/docs/API_docs/types/messages.AvailableReactions.md b/docs/API_docs/types/messages.AvailableReactions.md new file mode 100644 index 0000000000..4336ad5219 --- /dev/null +++ b/docs/API_docs/types/messages.AvailableReactions.md @@ -0,0 +1,26 @@ +--- +title: messages.AvailableReactions +description: constructors and methods of type messages.AvailableReactions +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_AvailableReactions.html +--- +# Type: messages.AvailableReactions +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.availableReactionsNotModified](/API_docs/constructors/messages.availableReactionsNotModified.html) + +[messages.availableReactions](/API_docs/constructors/messages.availableReactions.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getAvailableReactions](/API_docs/methods/messages.getAvailableReactions.html) + + + diff --git a/docs/API_docs/types/messages.BotApp.md b/docs/API_docs/types/messages.BotApp.md new file mode 100644 index 0000000000..1253129584 --- /dev/null +++ b/docs/API_docs/types/messages.BotApp.md @@ -0,0 +1,24 @@ +--- +title: messages.BotApp +description: constructors and methods of type messages.BotApp +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_BotApp.html +--- +# Type: messages.BotApp +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.botApp](/API_docs/constructors/messages.botApp.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getBotApp](/API_docs/methods/messages.getBotApp.html) + + + diff --git a/docs/API_docs/types/messages.BotCallbackAnswer.md b/docs/API_docs/types/messages.BotCallbackAnswer.md new file mode 100644 index 0000000000..5820d3ec53 --- /dev/null +++ b/docs/API_docs/types/messages.BotCallbackAnswer.md @@ -0,0 +1,24 @@ +--- +title: messages.BotCallbackAnswer +description: constructors and methods of type messages.BotCallbackAnswer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_BotCallbackAnswer.html +--- +# Type: messages.BotCallbackAnswer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.botCallbackAnswer](/API_docs/constructors/messages.botCallbackAnswer.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getBotCallbackAnswer](/API_docs/methods/messages.getBotCallbackAnswer.html) + + + diff --git a/docs/API_docs/types/messages.BotResults.md b/docs/API_docs/types/messages.BotResults.md new file mode 100644 index 0000000000..7b02083072 --- /dev/null +++ b/docs/API_docs/types/messages.BotResults.md @@ -0,0 +1,24 @@ +--- +title: messages.BotResults +description: constructors and methods of type messages.BotResults +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_BotResults.html +--- +# Type: messages.BotResults +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.botResults](/API_docs/constructors/messages.botResults.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getInlineBotResults](/API_docs/methods/messages.getInlineBotResults.html) + + + diff --git a/docs/API_docs/types/messages.ChatAdminsWithInvites.md b/docs/API_docs/types/messages.ChatAdminsWithInvites.md new file mode 100644 index 0000000000..58fe669a6e --- /dev/null +++ b/docs/API_docs/types/messages.ChatAdminsWithInvites.md @@ -0,0 +1,24 @@ +--- +title: messages.ChatAdminsWithInvites +description: constructors and methods of type messages.ChatAdminsWithInvites +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ChatAdminsWithInvites.html +--- +# Type: messages.ChatAdminsWithInvites +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.chatAdminsWithInvites](/API_docs/constructors/messages.chatAdminsWithInvites.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getAdminsWithInvites](/API_docs/methods/messages.getAdminsWithInvites.html) + + + diff --git a/docs/API_docs/types/messages.ChatFull.md b/docs/API_docs/types/messages.ChatFull.md new file mode 100644 index 0000000000..5bcc26719b --- /dev/null +++ b/docs/API_docs/types/messages.ChatFull.md @@ -0,0 +1,26 @@ +--- +title: messages.ChatFull +description: constructors and methods of type messages.ChatFull +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ChatFull.html +--- +# Type: messages.ChatFull +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.chatFull](/API_docs/constructors/messages.chatFull.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getFullChat](/API_docs/methods/messages.getFullChat.html) + +[$MadelineProto->channels->getFullChannel](/API_docs/methods/channels.getFullChannel.html) + + + diff --git a/docs/API_docs/types/messages.ChatInviteImporters.md b/docs/API_docs/types/messages.ChatInviteImporters.md new file mode 100644 index 0000000000..cf3243e1a7 --- /dev/null +++ b/docs/API_docs/types/messages.ChatInviteImporters.md @@ -0,0 +1,24 @@ +--- +title: messages.ChatInviteImporters +description: constructors and methods of type messages.ChatInviteImporters +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ChatInviteImporters.html +--- +# Type: messages.ChatInviteImporters +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.chatInviteImporters](/API_docs/constructors/messages.chatInviteImporters.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getChatInviteImporters](/API_docs/methods/messages.getChatInviteImporters.html) + + + diff --git a/docs/API_docs/types/messages.Chats.md b/docs/API_docs/types/messages.Chats.md new file mode 100644 index 0000000000..4e6ec919cf --- /dev/null +++ b/docs/API_docs/types/messages.Chats.md @@ -0,0 +1,40 @@ +--- +title: messages.Chats +description: constructors and methods of type messages.Chats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_Chats.html +--- +# Type: messages.Chats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.chats](/API_docs/constructors/messages.chats.html) + +[messages.chatsSlice](/API_docs/constructors/messages.chatsSlice.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getChats](/API_docs/methods/messages.getChats.html) + +[$MadelineProto->messages->getCommonChats](/API_docs/methods/messages.getCommonChats.html) + +[$MadelineProto->channels->getChannels](/API_docs/methods/channels.getChannels.html) + +[$MadelineProto->channels->getAdminedPublicChannels](/API_docs/methods/channels.getAdminedPublicChannels.html) + +[$MadelineProto->channels->getLeftChannels](/API_docs/methods/channels.getLeftChannels.html) + +[$MadelineProto->channels->getGroupsForDiscussion](/API_docs/methods/channels.getGroupsForDiscussion.html) + +[$MadelineProto->channels->getChannelRecommendations](/API_docs/methods/channels.getChannelRecommendations.html) + +[$MadelineProto->stories->getChatsToSend](/API_docs/methods/stories.getChatsToSend.html) + + + diff --git a/docs/API_docs/types/messages.CheckedHistoryImportPeer.md b/docs/API_docs/types/messages.CheckedHistoryImportPeer.md new file mode 100644 index 0000000000..35554e0389 --- /dev/null +++ b/docs/API_docs/types/messages.CheckedHistoryImportPeer.md @@ -0,0 +1,24 @@ +--- +title: messages.CheckedHistoryImportPeer +description: constructors and methods of type messages.CheckedHistoryImportPeer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_CheckedHistoryImportPeer.html +--- +# Type: messages.CheckedHistoryImportPeer +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.checkedHistoryImportPeer](/API_docs/constructors/messages.checkedHistoryImportPeer.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->checkHistoryImportPeer](/API_docs/methods/messages.checkHistoryImportPeer.html) + + + diff --git a/docs/API_docs/types/messages.DhConfig.md b/docs/API_docs/types/messages.DhConfig.md new file mode 100644 index 0000000000..cec37b6d05 --- /dev/null +++ b/docs/API_docs/types/messages.DhConfig.md @@ -0,0 +1,26 @@ +--- +title: messages.DhConfig +description: constructors and methods of type messages.DhConfig +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_DhConfig.html +--- +# Type: messages.DhConfig +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.dhConfigNotModified](/API_docs/constructors/messages.dhConfigNotModified.html) + +[messages.dhConfig](/API_docs/constructors/messages.dhConfig.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getDhConfig](/API_docs/methods/messages.getDhConfig.html) + + + diff --git a/docs/API_docs/types/messages.DialogFilters.md b/docs/API_docs/types/messages.DialogFilters.md new file mode 100644 index 0000000000..cef9d7c275 --- /dev/null +++ b/docs/API_docs/types/messages.DialogFilters.md @@ -0,0 +1,24 @@ +--- +title: messages.DialogFilters +description: constructors and methods of type messages.DialogFilters +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_DialogFilters.html +--- +# Type: messages.DialogFilters +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.dialogFilters](/API_docs/constructors/messages.dialogFilters.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getDialogFilters](/API_docs/methods/messages.getDialogFilters.html) + + + diff --git a/docs/API_docs/types/messages.Dialogs.md b/docs/API_docs/types/messages.Dialogs.md new file mode 100644 index 0000000000..4fd9ade112 --- /dev/null +++ b/docs/API_docs/types/messages.Dialogs.md @@ -0,0 +1,28 @@ +--- +title: messages.Dialogs +description: constructors and methods of type messages.Dialogs +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_Dialogs.html +--- +# Type: messages.Dialogs +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.dialogs](/API_docs/constructors/messages.dialogs.html) + +[messages.dialogsSlice](/API_docs/constructors/messages.dialogsSlice.html) + +[messages.dialogsNotModified](/API_docs/constructors/messages.dialogsNotModified.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getDialogs](/API_docs/methods/messages.getDialogs.html) + + + diff --git a/docs/API_docs/types/messages.DiscussionMessage.md b/docs/API_docs/types/messages.DiscussionMessage.md new file mode 100644 index 0000000000..d4dbf1b9a1 --- /dev/null +++ b/docs/API_docs/types/messages.DiscussionMessage.md @@ -0,0 +1,24 @@ +--- +title: messages.DiscussionMessage +description: constructors and methods of type messages.DiscussionMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_DiscussionMessage.html +--- +# Type: messages.DiscussionMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.discussionMessage](/API_docs/constructors/messages.discussionMessage.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getDiscussionMessage](/API_docs/methods/messages.getDiscussionMessage.html) + + + diff --git a/docs/API_docs/types/messages.EmojiGroups.md b/docs/API_docs/types/messages.EmojiGroups.md new file mode 100644 index 0000000000..503a3c35b1 --- /dev/null +++ b/docs/API_docs/types/messages.EmojiGroups.md @@ -0,0 +1,32 @@ +--- +title: messages.EmojiGroups +description: constructors and methods of type messages.EmojiGroups +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_EmojiGroups.html +--- +# Type: messages.EmojiGroups +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.emojiGroupsNotModified](/API_docs/constructors/messages.emojiGroupsNotModified.html) + +[messages.emojiGroups](/API_docs/constructors/messages.emojiGroups.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getEmojiGroups](/API_docs/methods/messages.getEmojiGroups.html) + +[$MadelineProto->messages->getEmojiStatusGroups](/API_docs/methods/messages.getEmojiStatusGroups.html) + +[$MadelineProto->messages->getEmojiProfilePhotoGroups](/API_docs/methods/messages.getEmojiProfilePhotoGroups.html) + +[$MadelineProto->messages->getEmojiStickerGroups](/API_docs/methods/messages.getEmojiStickerGroups.html) + + + diff --git a/docs/API_docs/types/messages.ExportedChatInvite.md b/docs/API_docs/types/messages.ExportedChatInvite.md new file mode 100644 index 0000000000..7326ab6c42 --- /dev/null +++ b/docs/API_docs/types/messages.ExportedChatInvite.md @@ -0,0 +1,28 @@ +--- +title: messages.ExportedChatInvite +description: constructors and methods of type messages.ExportedChatInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ExportedChatInvite.html +--- +# Type: messages.ExportedChatInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.exportedChatInvite](/API_docs/constructors/messages.exportedChatInvite.html) + +[messages.exportedChatInviteReplaced](/API_docs/constructors/messages.exportedChatInviteReplaced.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getExportedChatInvite](/API_docs/methods/messages.getExportedChatInvite.html) + +[$MadelineProto->messages->editExportedChatInvite](/API_docs/methods/messages.editExportedChatInvite.html) + + + diff --git a/docs/API_docs/types/messages.ExportedChatInvites.md b/docs/API_docs/types/messages.ExportedChatInvites.md new file mode 100644 index 0000000000..6b18d45de4 --- /dev/null +++ b/docs/API_docs/types/messages.ExportedChatInvites.md @@ -0,0 +1,24 @@ +--- +title: messages.ExportedChatInvites +description: constructors and methods of type messages.ExportedChatInvites +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ExportedChatInvites.html +--- +# Type: messages.ExportedChatInvites +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.exportedChatInvites](/API_docs/constructors/messages.exportedChatInvites.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getExportedChatInvites](/API_docs/methods/messages.getExportedChatInvites.html) + + + diff --git a/docs/API_docs/types/messages.FavedStickers.md b/docs/API_docs/types/messages.FavedStickers.md new file mode 100644 index 0000000000..b518b9a3b2 --- /dev/null +++ b/docs/API_docs/types/messages.FavedStickers.md @@ -0,0 +1,26 @@ +--- +title: messages.FavedStickers +description: constructors and methods of type messages.FavedStickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_FavedStickers.html +--- +# Type: messages.FavedStickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.favedStickersNotModified](/API_docs/constructors/messages.favedStickersNotModified.html) + +[messages.favedStickers](/API_docs/constructors/messages.favedStickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getFavedStickers](/API_docs/methods/messages.getFavedStickers.html) + + + diff --git a/docs/API_docs/types/messages.FeaturedStickers.md b/docs/API_docs/types/messages.FeaturedStickers.md new file mode 100644 index 0000000000..97b043bf6c --- /dev/null +++ b/docs/API_docs/types/messages.FeaturedStickers.md @@ -0,0 +1,30 @@ +--- +title: messages.FeaturedStickers +description: constructors and methods of type messages.FeaturedStickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_FeaturedStickers.html +--- +# Type: messages.FeaturedStickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.featuredStickersNotModified](/API_docs/constructors/messages.featuredStickersNotModified.html) + +[messages.featuredStickers](/API_docs/constructors/messages.featuredStickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getFeaturedStickers](/API_docs/methods/messages.getFeaturedStickers.html) + +[$MadelineProto->messages->getOldFeaturedStickers](/API_docs/methods/messages.getOldFeaturedStickers.html) + +[$MadelineProto->messages->getFeaturedEmojiStickers](/API_docs/methods/messages.getFeaturedEmojiStickers.html) + + + diff --git a/docs/API_docs/types/messages.ForumTopics.md b/docs/API_docs/types/messages.ForumTopics.md new file mode 100644 index 0000000000..b443e25021 --- /dev/null +++ b/docs/API_docs/types/messages.ForumTopics.md @@ -0,0 +1,26 @@ +--- +title: messages.ForumTopics +description: constructors and methods of type messages.ForumTopics +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_ForumTopics.html +--- +# Type: messages.ForumTopics +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.forumTopics](/API_docs/constructors/messages.forumTopics.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getForumTopics](/API_docs/methods/channels.getForumTopics.html) + +[$MadelineProto->channels->getForumTopicsByID](/API_docs/methods/channels.getForumTopicsByID.html) + + + diff --git a/docs/API_docs/types/messages.FoundStickerSets.md b/docs/API_docs/types/messages.FoundStickerSets.md new file mode 100644 index 0000000000..93974149a1 --- /dev/null +++ b/docs/API_docs/types/messages.FoundStickerSets.md @@ -0,0 +1,28 @@ +--- +title: messages.FoundStickerSets +description: constructors and methods of type messages.FoundStickerSets +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_FoundStickerSets.html +--- +# Type: messages.FoundStickerSets +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.foundStickerSetsNotModified](/API_docs/constructors/messages.foundStickerSetsNotModified.html) + +[messages.foundStickerSets](/API_docs/constructors/messages.foundStickerSets.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->searchStickerSets](/API_docs/methods/messages.searchStickerSets.html) + +[$MadelineProto->messages->searchEmojiStickerSets](/API_docs/methods/messages.searchEmojiStickerSets.html) + + + diff --git a/docs/API_docs/types/messages.HighScores.md b/docs/API_docs/types/messages.HighScores.md new file mode 100644 index 0000000000..432ca59ea7 --- /dev/null +++ b/docs/API_docs/types/messages.HighScores.md @@ -0,0 +1,26 @@ +--- +title: messages.HighScores +description: constructors and methods of type messages.HighScores +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_HighScores.html +--- +# Type: messages.HighScores +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.highScores](/API_docs/constructors/messages.highScores.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getGameHighScores](/API_docs/methods/messages.getGameHighScores.html) + +[$MadelineProto->messages->getInlineGameHighScores](/API_docs/methods/messages.getInlineGameHighScores.html) + + + diff --git a/docs/API_docs/types/messages.HistoryImport.md b/docs/API_docs/types/messages.HistoryImport.md new file mode 100644 index 0000000000..d2572f6456 --- /dev/null +++ b/docs/API_docs/types/messages.HistoryImport.md @@ -0,0 +1,24 @@ +--- +title: messages.HistoryImport +description: constructors and methods of type messages.HistoryImport +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_HistoryImport.html +--- +# Type: messages.HistoryImport +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.historyImport](/API_docs/constructors/messages.historyImport.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->initHistoryImport](/API_docs/methods/messages.initHistoryImport.html) + + + diff --git a/docs/API_docs/types/messages.HistoryImportParsed.md b/docs/API_docs/types/messages.HistoryImportParsed.md new file mode 100644 index 0000000000..f2540d08d8 --- /dev/null +++ b/docs/API_docs/types/messages.HistoryImportParsed.md @@ -0,0 +1,24 @@ +--- +title: messages.HistoryImportParsed +description: constructors and methods of type messages.HistoryImportParsed +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_HistoryImportParsed.html +--- +# Type: messages.HistoryImportParsed +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.historyImportParsed](/API_docs/constructors/messages.historyImportParsed.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->checkHistoryImport](/API_docs/methods/messages.checkHistoryImport.html) + + + diff --git a/docs/API_docs/types/messages.InactiveChats.md b/docs/API_docs/types/messages.InactiveChats.md new file mode 100644 index 0000000000..0548818c79 --- /dev/null +++ b/docs/API_docs/types/messages.InactiveChats.md @@ -0,0 +1,24 @@ +--- +title: messages.InactiveChats +description: constructors and methods of type messages.InactiveChats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_InactiveChats.html +--- +# Type: messages.InactiveChats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.inactiveChats](/API_docs/constructors/messages.inactiveChats.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getInactiveChannels](/API_docs/methods/channels.getInactiveChannels.html) + + + diff --git a/docs/API_docs/types/messages.InvitedUsers.md b/docs/API_docs/types/messages.InvitedUsers.md new file mode 100644 index 0000000000..b3e0d6b406 --- /dev/null +++ b/docs/API_docs/types/messages.InvitedUsers.md @@ -0,0 +1,28 @@ +--- +title: messages.InvitedUsers +description: constructors and methods of type messages.InvitedUsers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_InvitedUsers.html +--- +# Type: messages.InvitedUsers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.invitedUsers](/API_docs/constructors/messages.invitedUsers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->addChatUser](/API_docs/methods/messages.addChatUser.html) + +[$MadelineProto->messages->createChat](/API_docs/methods/messages.createChat.html) + +[$MadelineProto->channels->inviteToChannel](/API_docs/methods/channels.inviteToChannel.html) + + + diff --git a/docs/API_docs/types/messages.MessageEditData.md b/docs/API_docs/types/messages.MessageEditData.md new file mode 100644 index 0000000000..969ab40b38 --- /dev/null +++ b/docs/API_docs/types/messages.MessageEditData.md @@ -0,0 +1,24 @@ +--- +title: messages.MessageEditData +description: constructors and methods of type messages.MessageEditData +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_MessageEditData.html +--- +# Type: messages.MessageEditData +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.messageEditData](/API_docs/constructors/messages.messageEditData.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getMessageEditData](/API_docs/methods/messages.getMessageEditData.html) + + + diff --git a/docs/API_docs/types/messages.MessageReactionsList.md b/docs/API_docs/types/messages.MessageReactionsList.md new file mode 100644 index 0000000000..4732a3465a --- /dev/null +++ b/docs/API_docs/types/messages.MessageReactionsList.md @@ -0,0 +1,24 @@ +--- +title: messages.MessageReactionsList +description: constructors and methods of type messages.MessageReactionsList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_MessageReactionsList.html +--- +# Type: messages.MessageReactionsList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.messageReactionsList](/API_docs/constructors/messages.messageReactionsList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getMessageReactionsList](/API_docs/methods/messages.getMessageReactionsList.html) + + + diff --git a/docs/API_docs/types/messages.MessageViews.md b/docs/API_docs/types/messages.MessageViews.md new file mode 100644 index 0000000000..bf0ecb7002 --- /dev/null +++ b/docs/API_docs/types/messages.MessageViews.md @@ -0,0 +1,24 @@ +--- +title: messages.MessageViews +description: constructors and methods of type messages.MessageViews +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_MessageViews.html +--- +# Type: messages.MessageViews +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.messageViews](/API_docs/constructors/messages.messageViews.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getMessagesViews](/API_docs/methods/messages.getMessagesViews.html) + + + diff --git a/docs/API_docs/types/messages.Messages.md b/docs/API_docs/types/messages.Messages.md new file mode 100644 index 0000000000..94bde13ac0 --- /dev/null +++ b/docs/API_docs/types/messages.Messages.md @@ -0,0 +1,56 @@ +--- +title: messages.Messages +description: constructors and methods of type messages.Messages +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_Messages.html +--- +# Type: messages.Messages +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.messages](/API_docs/constructors/messages.messages.html) + +[messages.messagesSlice](/API_docs/constructors/messages.messagesSlice.html) + +[messages.channelMessages](/API_docs/constructors/messages.channelMessages.html) + +[messages.messagesNotModified](/API_docs/constructors/messages.messagesNotModified.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getMessages](/API_docs/methods/messages.getMessages.html) + +[$MadelineProto->messages->getHistory](/API_docs/methods/messages.getHistory.html) + +[$MadelineProto->messages->search](/API_docs/methods/messages.search.html) + +[$MadelineProto->messages->searchGlobal](/API_docs/methods/messages.searchGlobal.html) + +[$MadelineProto->messages->getUnreadMentions](/API_docs/methods/messages.getUnreadMentions.html) + +[$MadelineProto->messages->getRecentLocations](/API_docs/methods/messages.getRecentLocations.html) + +[$MadelineProto->messages->getScheduledHistory](/API_docs/methods/messages.getScheduledHistory.html) + +[$MadelineProto->messages->getScheduledMessages](/API_docs/methods/messages.getScheduledMessages.html) + +[$MadelineProto->messages->getReplies](/API_docs/methods/messages.getReplies.html) + +[$MadelineProto->messages->getUnreadReactions](/API_docs/methods/messages.getUnreadReactions.html) + +[$MadelineProto->messages->searchSentMedia](/API_docs/methods/messages.searchSentMedia.html) + +[$MadelineProto->messages->getSavedHistory](/API_docs/methods/messages.getSavedHistory.html) + +[$MadelineProto->messages->getQuickReplyMessages](/API_docs/methods/messages.getQuickReplyMessages.html) + +[$MadelineProto->channels->getMessages](/API_docs/methods/channels.getMessages.html) + + + diff --git a/docs/API_docs/types/messages.MyStickers.md b/docs/API_docs/types/messages.MyStickers.md new file mode 100644 index 0000000000..737520871f --- /dev/null +++ b/docs/API_docs/types/messages.MyStickers.md @@ -0,0 +1,24 @@ +--- +title: messages.MyStickers +description: constructors and methods of type messages.MyStickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_MyStickers.html +--- +# Type: messages.MyStickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.myStickers](/API_docs/constructors/messages.myStickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getMyStickers](/API_docs/methods/messages.getMyStickers.html) + + + diff --git a/docs/API_docs/types/messages.PeerDialogs.md b/docs/API_docs/types/messages.PeerDialogs.md new file mode 100644 index 0000000000..82df541b46 --- /dev/null +++ b/docs/API_docs/types/messages.PeerDialogs.md @@ -0,0 +1,26 @@ +--- +title: messages.PeerDialogs +description: constructors and methods of type messages.PeerDialogs +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_PeerDialogs.html +--- +# Type: messages.PeerDialogs +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.peerDialogs](/API_docs/constructors/messages.peerDialogs.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getPeerDialogs](/API_docs/methods/messages.getPeerDialogs.html) + +[$MadelineProto->messages->getPinnedDialogs](/API_docs/methods/messages.getPinnedDialogs.html) + + + diff --git a/docs/API_docs/types/messages.PeerSettings.md b/docs/API_docs/types/messages.PeerSettings.md new file mode 100644 index 0000000000..5655fda595 --- /dev/null +++ b/docs/API_docs/types/messages.PeerSettings.md @@ -0,0 +1,24 @@ +--- +title: messages.PeerSettings +description: constructors and methods of type messages.PeerSettings +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_PeerSettings.html +--- +# Type: messages.PeerSettings +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.peerSettings](/API_docs/constructors/messages.peerSettings.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getPeerSettings](/API_docs/methods/messages.getPeerSettings.html) + + + diff --git a/docs/API_docs/types/messages.QuickReplies.md b/docs/API_docs/types/messages.QuickReplies.md new file mode 100644 index 0000000000..251e5354e6 --- /dev/null +++ b/docs/API_docs/types/messages.QuickReplies.md @@ -0,0 +1,26 @@ +--- +title: messages.QuickReplies +description: constructors and methods of type messages.QuickReplies +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_QuickReplies.html +--- +# Type: messages.QuickReplies +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.quickReplies](/API_docs/constructors/messages.quickReplies.html) + +[messages.quickRepliesNotModified](/API_docs/constructors/messages.quickRepliesNotModified.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getQuickReplies](/API_docs/methods/messages.getQuickReplies.html) + + + diff --git a/docs/API_docs/types/messages.Reactions.md b/docs/API_docs/types/messages.Reactions.md new file mode 100644 index 0000000000..4acf487e62 --- /dev/null +++ b/docs/API_docs/types/messages.Reactions.md @@ -0,0 +1,30 @@ +--- +title: messages.Reactions +description: constructors and methods of type messages.Reactions +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_Reactions.html +--- +# Type: messages.Reactions +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.reactionsNotModified](/API_docs/constructors/messages.reactionsNotModified.html) + +[messages.reactions](/API_docs/constructors/messages.reactions.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getTopReactions](/API_docs/methods/messages.getTopReactions.html) + +[$MadelineProto->messages->getRecentReactions](/API_docs/methods/messages.getRecentReactions.html) + +[$MadelineProto->messages->getDefaultTagReactions](/API_docs/methods/messages.getDefaultTagReactions.html) + + + diff --git a/docs/API_docs/types/messages.RecentStickers.md b/docs/API_docs/types/messages.RecentStickers.md new file mode 100644 index 0000000000..fe4f758215 --- /dev/null +++ b/docs/API_docs/types/messages.RecentStickers.md @@ -0,0 +1,26 @@ +--- +title: messages.RecentStickers +description: constructors and methods of type messages.RecentStickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_RecentStickers.html +--- +# Type: messages.RecentStickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.recentStickersNotModified](/API_docs/constructors/messages.recentStickersNotModified.html) + +[messages.recentStickers](/API_docs/constructors/messages.recentStickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getRecentStickers](/API_docs/methods/messages.getRecentStickers.html) + + + diff --git a/docs/API_docs/types/messages.SavedDialogs.md b/docs/API_docs/types/messages.SavedDialogs.md new file mode 100644 index 0000000000..1482bdfcc7 --- /dev/null +++ b/docs/API_docs/types/messages.SavedDialogs.md @@ -0,0 +1,30 @@ +--- +title: messages.SavedDialogs +description: constructors and methods of type messages.SavedDialogs +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SavedDialogs.html +--- +# Type: messages.SavedDialogs +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.savedDialogs](/API_docs/constructors/messages.savedDialogs.html) + +[messages.savedDialogsSlice](/API_docs/constructors/messages.savedDialogsSlice.html) + +[messages.savedDialogsNotModified](/API_docs/constructors/messages.savedDialogsNotModified.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSavedDialogs](/API_docs/methods/messages.getSavedDialogs.html) + +[$MadelineProto->messages->getPinnedSavedDialogs](/API_docs/methods/messages.getPinnedSavedDialogs.html) + + + diff --git a/docs/API_docs/types/messages.SavedGifs.md b/docs/API_docs/types/messages.SavedGifs.md new file mode 100644 index 0000000000..463e740d68 --- /dev/null +++ b/docs/API_docs/types/messages.SavedGifs.md @@ -0,0 +1,26 @@ +--- +title: messages.SavedGifs +description: constructors and methods of type messages.SavedGifs +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SavedGifs.html +--- +# Type: messages.SavedGifs +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.savedGifsNotModified](/API_docs/constructors/messages.savedGifsNotModified.html) + +[messages.savedGifs](/API_docs/constructors/messages.savedGifs.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSavedGifs](/API_docs/methods/messages.getSavedGifs.html) + + + diff --git a/docs/API_docs/types/messages.SavedReactionTags.md b/docs/API_docs/types/messages.SavedReactionTags.md new file mode 100644 index 0000000000..16b5583502 --- /dev/null +++ b/docs/API_docs/types/messages.SavedReactionTags.md @@ -0,0 +1,26 @@ +--- +title: messages.SavedReactionTags +description: constructors and methods of type messages.SavedReactionTags +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SavedReactionTags.html +--- +# Type: messages.SavedReactionTags +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.savedReactionTagsNotModified](/API_docs/constructors/messages.savedReactionTagsNotModified.html) + +[messages.savedReactionTags](/API_docs/constructors/messages.savedReactionTags.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSavedReactionTags](/API_docs/methods/messages.getSavedReactionTags.html) + + + diff --git a/docs/API_docs/types/messages.SearchCounter.md b/docs/API_docs/types/messages.SearchCounter.md new file mode 100644 index 0000000000..a28198d29f --- /dev/null +++ b/docs/API_docs/types/messages.SearchCounter.md @@ -0,0 +1,24 @@ +--- +title: messages.SearchCounter +description: constructors and methods of type messages.SearchCounter +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SearchCounter.html +--- +# Type: messages.SearchCounter +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.searchCounter](/API_docs/constructors/messages.searchCounter.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSearchCounters](/API_docs/methods/messages.getSearchCounters.html) + + + diff --git a/docs/API_docs/types/messages.SearchResultsCalendar.md b/docs/API_docs/types/messages.SearchResultsCalendar.md new file mode 100644 index 0000000000..80e18a1b37 --- /dev/null +++ b/docs/API_docs/types/messages.SearchResultsCalendar.md @@ -0,0 +1,24 @@ +--- +title: messages.SearchResultsCalendar +description: constructors and methods of type messages.SearchResultsCalendar +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SearchResultsCalendar.html +--- +# Type: messages.SearchResultsCalendar +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.searchResultsCalendar](/API_docs/constructors/messages.searchResultsCalendar.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSearchResultsCalendar](/API_docs/methods/messages.getSearchResultsCalendar.html) + + + diff --git a/docs/API_docs/types/messages.SearchResultsPositions.md b/docs/API_docs/types/messages.SearchResultsPositions.md new file mode 100644 index 0000000000..8f01e467bd --- /dev/null +++ b/docs/API_docs/types/messages.SearchResultsPositions.md @@ -0,0 +1,24 @@ +--- +title: messages.SearchResultsPositions +description: constructors and methods of type messages.SearchResultsPositions +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SearchResultsPositions.html +--- +# Type: messages.SearchResultsPositions +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.searchResultsPositions](/API_docs/constructors/messages.searchResultsPositions.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getSearchResultsPositions](/API_docs/methods/messages.getSearchResultsPositions.html) + + + diff --git a/docs/API_docs/types/messages.SentEncryptedMessage.md b/docs/API_docs/types/messages.SentEncryptedMessage.md new file mode 100644 index 0000000000..529f53d2a9 --- /dev/null +++ b/docs/API_docs/types/messages.SentEncryptedMessage.md @@ -0,0 +1,30 @@ +--- +title: messages.SentEncryptedMessage +description: constructors and methods of type messages.SentEncryptedMessage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SentEncryptedMessage.html +--- +# Type: messages.SentEncryptedMessage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.sentEncryptedMessage](/API_docs/constructors/messages.sentEncryptedMessage.html) + +[messages.sentEncryptedFile](/API_docs/constructors/messages.sentEncryptedFile.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->sendEncrypted](/API_docs/methods/messages.sendEncrypted.html) + +[$MadelineProto->messages->sendEncryptedFile](/API_docs/methods/messages.sendEncryptedFile.html) + +[$MadelineProto->messages->sendEncryptedService](/API_docs/methods/messages.sendEncryptedService.html) + + + diff --git a/docs/API_docs/types/messages.SponsoredMessages.md b/docs/API_docs/types/messages.SponsoredMessages.md new file mode 100644 index 0000000000..95005efed0 --- /dev/null +++ b/docs/API_docs/types/messages.SponsoredMessages.md @@ -0,0 +1,26 @@ +--- +title: messages.SponsoredMessages +description: constructors and methods of type messages.SponsoredMessages +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_SponsoredMessages.html +--- +# Type: messages.SponsoredMessages +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.sponsoredMessages](/API_docs/constructors/messages.sponsoredMessages.html) + +[messages.sponsoredMessagesEmpty](/API_docs/constructors/messages.sponsoredMessagesEmpty.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->channels->getSponsoredMessages](/API_docs/methods/channels.getSponsoredMessages.html) + + + diff --git a/docs/API_docs/types/messages.StickerSet.md b/docs/API_docs/types/messages.StickerSet.md new file mode 100644 index 0000000000..0dd22bc285 --- /dev/null +++ b/docs/API_docs/types/messages.StickerSet.md @@ -0,0 +1,42 @@ +--- +title: messages.StickerSet +description: constructors and methods of type messages.StickerSet +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_StickerSet.html +--- +# Type: messages.StickerSet +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.stickerSet](/API_docs/constructors/messages.stickerSet.html) + +[messages.stickerSetNotModified](/API_docs/constructors/messages.stickerSetNotModified.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getStickerSet](/API_docs/methods/messages.getStickerSet.html) + +[$MadelineProto->stickers->createStickerSet](/API_docs/methods/stickers.createStickerSet.html) + +[$MadelineProto->stickers->removeStickerFromSet](/API_docs/methods/stickers.removeStickerFromSet.html) + +[$MadelineProto->stickers->changeStickerPosition](/API_docs/methods/stickers.changeStickerPosition.html) + +[$MadelineProto->stickers->addStickerToSet](/API_docs/methods/stickers.addStickerToSet.html) + +[$MadelineProto->stickers->setStickerSetThumb](/API_docs/methods/stickers.setStickerSetThumb.html) + +[$MadelineProto->stickers->changeSticker](/API_docs/methods/stickers.changeSticker.html) + +[$MadelineProto->stickers->renameStickerSet](/API_docs/methods/stickers.renameStickerSet.html) + +[$MadelineProto->stickers->replaceSticker](/API_docs/methods/stickers.replaceSticker.html) + + + diff --git a/docs/API_docs/types/messages.StickerSetInstallResult.md b/docs/API_docs/types/messages.StickerSetInstallResult.md new file mode 100644 index 0000000000..e78f96ac8a --- /dev/null +++ b/docs/API_docs/types/messages.StickerSetInstallResult.md @@ -0,0 +1,26 @@ +--- +title: messages.StickerSetInstallResult +description: constructors and methods of type messages.StickerSetInstallResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_StickerSetInstallResult.html +--- +# Type: messages.StickerSetInstallResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.stickerSetInstallResultSuccess](/API_docs/constructors/messages.stickerSetInstallResultSuccess.html) + +[messages.stickerSetInstallResultArchive](/API_docs/constructors/messages.stickerSetInstallResultArchive.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->installStickerSet](/API_docs/methods/messages.installStickerSet.html) + + + diff --git a/docs/API_docs/types/messages.Stickers.md b/docs/API_docs/types/messages.Stickers.md new file mode 100644 index 0000000000..811ebbb26e --- /dev/null +++ b/docs/API_docs/types/messages.Stickers.md @@ -0,0 +1,26 @@ +--- +title: messages.Stickers +description: constructors and methods of type messages.Stickers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_Stickers.html +--- +# Type: messages.Stickers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.stickersNotModified](/API_docs/constructors/messages.stickersNotModified.html) + +[messages.stickers](/API_docs/constructors/messages.stickers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getStickers](/API_docs/methods/messages.getStickers.html) + + + diff --git a/docs/API_docs/types/messages.TranscribedAudio.md b/docs/API_docs/types/messages.TranscribedAudio.md new file mode 100644 index 0000000000..fad47dedb0 --- /dev/null +++ b/docs/API_docs/types/messages.TranscribedAudio.md @@ -0,0 +1,24 @@ +--- +title: messages.TranscribedAudio +description: constructors and methods of type messages.TranscribedAudio +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_TranscribedAudio.html +--- +# Type: messages.TranscribedAudio +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.transcribedAudio](/API_docs/constructors/messages.transcribedAudio.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->transcribeAudio](/API_docs/methods/messages.transcribeAudio.html) + + + diff --git a/docs/API_docs/types/messages.TranslatedText.md b/docs/API_docs/types/messages.TranslatedText.md new file mode 100644 index 0000000000..7a95672bb7 --- /dev/null +++ b/docs/API_docs/types/messages.TranslatedText.md @@ -0,0 +1,24 @@ +--- +title: messages.TranslatedText +description: constructors and methods of type messages.TranslatedText +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_TranslatedText.html +--- +# Type: messages.TranslatedText +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.translateResult](/API_docs/constructors/messages.translateResult.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->translateText](/API_docs/methods/messages.translateText.html) + + + diff --git a/docs/API_docs/types/messages.VotesList.md b/docs/API_docs/types/messages.VotesList.md new file mode 100644 index 0000000000..2d62f4ab49 --- /dev/null +++ b/docs/API_docs/types/messages.VotesList.md @@ -0,0 +1,24 @@ +--- +title: messages.VotesList +description: constructors and methods of type messages.VotesList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_VotesList.html +--- +# Type: messages.VotesList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.votesList](/API_docs/constructors/messages.votesList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getPollVotes](/API_docs/methods/messages.getPollVotes.html) + + + diff --git a/docs/API_docs/types/messages.WebPage.md b/docs/API_docs/types/messages.WebPage.md new file mode 100644 index 0000000000..a1e654eeee --- /dev/null +++ b/docs/API_docs/types/messages.WebPage.md @@ -0,0 +1,24 @@ +--- +title: messages.WebPage +description: constructors and methods of type messages.WebPage +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/messages_WebPage.html +--- +# Type: messages.WebPage +[Back to types index](index.html) + + + +### Possible values (constructors): + +[messages.webPage](/API_docs/constructors/messages.webPage.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->messages->getWebPage](/API_docs/methods/messages.getWebPage.html) + + + diff --git a/docs/API_docs/types/payments.BankCardData.md b/docs/API_docs/types/payments.BankCardData.md new file mode 100644 index 0000000000..aa54f4a654 --- /dev/null +++ b/docs/API_docs/types/payments.BankCardData.md @@ -0,0 +1,24 @@ +--- +title: payments.BankCardData +description: constructors and methods of type payments.BankCardData +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_BankCardData.html +--- +# Type: payments.BankCardData +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.bankCardData](/API_docs/constructors/payments.bankCardData.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->getBankCardData](/API_docs/methods/payments.getBankCardData.html) + + + diff --git a/docs/API_docs/types/payments.CheckedGiftCode.md b/docs/API_docs/types/payments.CheckedGiftCode.md new file mode 100644 index 0000000000..cf8fe08c4d --- /dev/null +++ b/docs/API_docs/types/payments.CheckedGiftCode.md @@ -0,0 +1,24 @@ +--- +title: payments.CheckedGiftCode +description: constructors and methods of type payments.CheckedGiftCode +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_CheckedGiftCode.html +--- +# Type: payments.CheckedGiftCode +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.checkedGiftCode](/API_docs/constructors/payments.checkedGiftCode.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->checkGiftCode](/API_docs/methods/payments.checkGiftCode.html) + + + diff --git a/docs/API_docs/types/payments.ExportedInvoice.md b/docs/API_docs/types/payments.ExportedInvoice.md new file mode 100644 index 0000000000..6ac9278702 --- /dev/null +++ b/docs/API_docs/types/payments.ExportedInvoice.md @@ -0,0 +1,24 @@ +--- +title: payments.ExportedInvoice +description: constructors and methods of type payments.ExportedInvoice +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_ExportedInvoice.html +--- +# Type: payments.ExportedInvoice +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.exportedInvoice](/API_docs/constructors/payments.exportedInvoice.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->exportInvoice](/API_docs/methods/payments.exportInvoice.html) + + + diff --git a/docs/API_docs/types/payments.GiveawayInfo.md b/docs/API_docs/types/payments.GiveawayInfo.md new file mode 100644 index 0000000000..a2073e9862 --- /dev/null +++ b/docs/API_docs/types/payments.GiveawayInfo.md @@ -0,0 +1,26 @@ +--- +title: payments.GiveawayInfo +description: constructors and methods of type payments.GiveawayInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_GiveawayInfo.html +--- +# Type: payments.GiveawayInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.giveawayInfo](/API_docs/constructors/payments.giveawayInfo.html) + +[payments.giveawayInfoResults](/API_docs/constructors/payments.giveawayInfoResults.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->getGiveawayInfo](/API_docs/methods/payments.getGiveawayInfo.html) + + + diff --git a/docs/API_docs/types/payments.PaymentForm.md b/docs/API_docs/types/payments.PaymentForm.md new file mode 100644 index 0000000000..eed6c724d6 --- /dev/null +++ b/docs/API_docs/types/payments.PaymentForm.md @@ -0,0 +1,24 @@ +--- +title: payments.PaymentForm +description: constructors and methods of type payments.PaymentForm +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_PaymentForm.html +--- +# Type: payments.PaymentForm +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.paymentForm](/API_docs/constructors/payments.paymentForm.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->getPaymentForm](/API_docs/methods/payments.getPaymentForm.html) + + + diff --git a/docs/API_docs/types/payments.PaymentReceipt.md b/docs/API_docs/types/payments.PaymentReceipt.md new file mode 100644 index 0000000000..d2566ac284 --- /dev/null +++ b/docs/API_docs/types/payments.PaymentReceipt.md @@ -0,0 +1,24 @@ +--- +title: payments.PaymentReceipt +description: constructors and methods of type payments.PaymentReceipt +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_PaymentReceipt.html +--- +# Type: payments.PaymentReceipt +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.paymentReceipt](/API_docs/constructors/payments.paymentReceipt.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->getPaymentReceipt](/API_docs/methods/payments.getPaymentReceipt.html) + + + diff --git a/docs/API_docs/types/payments.PaymentResult.md b/docs/API_docs/types/payments.PaymentResult.md new file mode 100644 index 0000000000..5cf083a8f2 --- /dev/null +++ b/docs/API_docs/types/payments.PaymentResult.md @@ -0,0 +1,26 @@ +--- +title: payments.PaymentResult +description: constructors and methods of type payments.PaymentResult +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_PaymentResult.html +--- +# Type: payments.PaymentResult +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.paymentResult](/API_docs/constructors/payments.paymentResult.html) + +[payments.paymentVerificationNeeded](/API_docs/constructors/payments.paymentVerificationNeeded.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->sendPaymentForm](/API_docs/methods/payments.sendPaymentForm.html) + + + diff --git a/docs/API_docs/types/payments.SavedInfo.md b/docs/API_docs/types/payments.SavedInfo.md new file mode 100644 index 0000000000..5aeb7f346b --- /dev/null +++ b/docs/API_docs/types/payments.SavedInfo.md @@ -0,0 +1,24 @@ +--- +title: payments.SavedInfo +description: constructors and methods of type payments.SavedInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_SavedInfo.html +--- +# Type: payments.SavedInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.savedInfo](/API_docs/constructors/payments.savedInfo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->getSavedInfo](/API_docs/methods/payments.getSavedInfo.html) + + + diff --git a/docs/API_docs/types/payments.ValidatedRequestedInfo.md b/docs/API_docs/types/payments.ValidatedRequestedInfo.md new file mode 100644 index 0000000000..cfb08c79eb --- /dev/null +++ b/docs/API_docs/types/payments.ValidatedRequestedInfo.md @@ -0,0 +1,24 @@ +--- +title: payments.ValidatedRequestedInfo +description: constructors and methods of type payments.ValidatedRequestedInfo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/payments_ValidatedRequestedInfo.html +--- +# Type: payments.ValidatedRequestedInfo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[payments.validatedRequestedInfo](/API_docs/constructors/payments.validatedRequestedInfo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->payments->validateRequestedInfo](/API_docs/methods/payments.validateRequestedInfo.html) + + + diff --git a/docs/API_docs/types/phone.ExportedGroupCallInvite.md b/docs/API_docs/types/phone.ExportedGroupCallInvite.md new file mode 100644 index 0000000000..041c9f3239 --- /dev/null +++ b/docs/API_docs/types/phone.ExportedGroupCallInvite.md @@ -0,0 +1,24 @@ +--- +title: phone.ExportedGroupCallInvite +description: constructors and methods of type phone.ExportedGroupCallInvite +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_ExportedGroupCallInvite.html +--- +# Type: phone.ExportedGroupCallInvite +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.exportedGroupCallInvite](/API_docs/constructors/phone.exportedGroupCallInvite.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->exportGroupCallInvite](/API_docs/methods/phone.exportGroupCallInvite.html) + + + diff --git a/docs/API_docs/types/phone.GroupCall.md b/docs/API_docs/types/phone.GroupCall.md new file mode 100644 index 0000000000..b3888e41e5 --- /dev/null +++ b/docs/API_docs/types/phone.GroupCall.md @@ -0,0 +1,24 @@ +--- +title: phone.GroupCall +description: constructors and methods of type phone.GroupCall +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_GroupCall.html +--- +# Type: phone.GroupCall +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.groupCall](/API_docs/constructors/phone.groupCall.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->getGroupCall](/API_docs/methods/phone.getGroupCall.html) + + + diff --git a/docs/API_docs/types/phone.GroupCallStreamChannels.md b/docs/API_docs/types/phone.GroupCallStreamChannels.md new file mode 100644 index 0000000000..c8b858b68d --- /dev/null +++ b/docs/API_docs/types/phone.GroupCallStreamChannels.md @@ -0,0 +1,24 @@ +--- +title: phone.GroupCallStreamChannels +description: constructors and methods of type phone.GroupCallStreamChannels +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_GroupCallStreamChannels.html +--- +# Type: phone.GroupCallStreamChannels +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.groupCallStreamChannels](/API_docs/constructors/phone.groupCallStreamChannels.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->getGroupCallStreamChannels](/API_docs/methods/phone.getGroupCallStreamChannels.html) + + + diff --git a/docs/API_docs/types/phone.GroupCallStreamRtmpUrl.md b/docs/API_docs/types/phone.GroupCallStreamRtmpUrl.md new file mode 100644 index 0000000000..fbb1b10223 --- /dev/null +++ b/docs/API_docs/types/phone.GroupCallStreamRtmpUrl.md @@ -0,0 +1,24 @@ +--- +title: phone.GroupCallStreamRtmpUrl +description: constructors and methods of type phone.GroupCallStreamRtmpUrl +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_GroupCallStreamRtmpUrl.html +--- +# Type: phone.GroupCallStreamRtmpUrl +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.groupCallStreamRtmpUrl](/API_docs/constructors/phone.groupCallStreamRtmpUrl.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->getGroupCallStreamRtmpUrl](/API_docs/methods/phone.getGroupCallStreamRtmpUrl.html) + + + diff --git a/docs/API_docs/types/phone.GroupParticipants.md b/docs/API_docs/types/phone.GroupParticipants.md new file mode 100644 index 0000000000..a60afbf6f2 --- /dev/null +++ b/docs/API_docs/types/phone.GroupParticipants.md @@ -0,0 +1,24 @@ +--- +title: phone.GroupParticipants +description: constructors and methods of type phone.GroupParticipants +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_GroupParticipants.html +--- +# Type: phone.GroupParticipants +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.groupParticipants](/API_docs/constructors/phone.groupParticipants.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->getGroupParticipants](/API_docs/methods/phone.getGroupParticipants.html) + + + diff --git a/docs/API_docs/types/phone.JoinAsPeers.md b/docs/API_docs/types/phone.JoinAsPeers.md new file mode 100644 index 0000000000..0382a8f3bb --- /dev/null +++ b/docs/API_docs/types/phone.JoinAsPeers.md @@ -0,0 +1,24 @@ +--- +title: phone.JoinAsPeers +description: constructors and methods of type phone.JoinAsPeers +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_JoinAsPeers.html +--- +# Type: phone.JoinAsPeers +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.joinAsPeers](/API_docs/constructors/phone.joinAsPeers.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->getGroupCallJoinAs](/API_docs/methods/phone.getGroupCallJoinAs.html) + + + diff --git a/docs/API_docs/types/phone.PhoneCall.md b/docs/API_docs/types/phone.PhoneCall.md new file mode 100644 index 0000000000..5596f0aed1 --- /dev/null +++ b/docs/API_docs/types/phone.PhoneCall.md @@ -0,0 +1,28 @@ +--- +title: phone.PhoneCall +description: constructors and methods of type phone.PhoneCall +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/phone_PhoneCall.html +--- +# Type: phone.PhoneCall +[Back to types index](index.html) + + + +### Possible values (constructors): + +[phone.phoneCall](/API_docs/constructors/phone.phoneCall.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->phone->requestCall](/API_docs/methods/phone.requestCall.html) + +[$MadelineProto->phone->acceptCall](/API_docs/methods/phone.acceptCall.html) + +[$MadelineProto->phone->confirmCall](/API_docs/methods/phone.confirmCall.html) + + + diff --git a/docs/API_docs/types/photos.Photo.md b/docs/API_docs/types/photos.Photo.md new file mode 100644 index 0000000000..1590717f79 --- /dev/null +++ b/docs/API_docs/types/photos.Photo.md @@ -0,0 +1,28 @@ +--- +title: photos.Photo +description: constructors and methods of type photos.Photo +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/photos_Photo.html +--- +# Type: photos.Photo +[Back to types index](index.html) + + + +### Possible values (constructors): + +[photos.photo](/API_docs/constructors/photos.photo.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->photos->updateProfilePhoto](/API_docs/methods/photos.updateProfilePhoto.html) + +[$MadelineProto->photos->uploadProfilePhoto](/API_docs/methods/photos.uploadProfilePhoto.html) + +[$MadelineProto->photos->uploadContactProfilePhoto](/API_docs/methods/photos.uploadContactProfilePhoto.html) + + + diff --git a/docs/API_docs/types/photos.Photos.md b/docs/API_docs/types/photos.Photos.md new file mode 100644 index 0000000000..99dd82a8dd --- /dev/null +++ b/docs/API_docs/types/photos.Photos.md @@ -0,0 +1,26 @@ +--- +title: photos.Photos +description: constructors and methods of type photos.Photos +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/photos_Photos.html +--- +# Type: photos.Photos +[Back to types index](index.html) + + + +### Possible values (constructors): + +[photos.photos](/API_docs/constructors/photos.photos.html) + +[photos.photosSlice](/API_docs/constructors/photos.photosSlice.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->photos->getUserPhotos](/API_docs/methods/photos.getUserPhotos.html) + + + diff --git a/docs/API_docs/types/premium.BoostsList.md b/docs/API_docs/types/premium.BoostsList.md new file mode 100644 index 0000000000..54d88e0a7c --- /dev/null +++ b/docs/API_docs/types/premium.BoostsList.md @@ -0,0 +1,26 @@ +--- +title: premium.BoostsList +description: constructors and methods of type premium.BoostsList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/premium_BoostsList.html +--- +# Type: premium.BoostsList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[premium.boostsList](/API_docs/constructors/premium.boostsList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->premium->getBoostsList](/API_docs/methods/premium.getBoostsList.html) + +[$MadelineProto->premium->getUserBoosts](/API_docs/methods/premium.getUserBoosts.html) + + + diff --git a/docs/API_docs/types/premium.BoostsStatus.md b/docs/API_docs/types/premium.BoostsStatus.md new file mode 100644 index 0000000000..592b12b3b0 --- /dev/null +++ b/docs/API_docs/types/premium.BoostsStatus.md @@ -0,0 +1,24 @@ +--- +title: premium.BoostsStatus +description: constructors and methods of type premium.BoostsStatus +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/premium_BoostsStatus.html +--- +# Type: premium.BoostsStatus +[Back to types index](index.html) + + + +### Possible values (constructors): + +[premium.boostsStatus](/API_docs/constructors/premium.boostsStatus.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->premium->getBoostsStatus](/API_docs/methods/premium.getBoostsStatus.html) + + + diff --git a/docs/API_docs/types/premium.MyBoosts.md b/docs/API_docs/types/premium.MyBoosts.md new file mode 100644 index 0000000000..1721ae05ed --- /dev/null +++ b/docs/API_docs/types/premium.MyBoosts.md @@ -0,0 +1,26 @@ +--- +title: premium.MyBoosts +description: constructors and methods of type premium.MyBoosts +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/premium_MyBoosts.html +--- +# Type: premium.MyBoosts +[Back to types index](index.html) + + + +### Possible values (constructors): + +[premium.myBoosts](/API_docs/constructors/premium.myBoosts.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->premium->getMyBoosts](/API_docs/methods/premium.getMyBoosts.html) + +[$MadelineProto->premium->applyBoost](/API_docs/methods/premium.applyBoost.html) + + + diff --git a/docs/API_docs/types/smsjobs.EligibilityToJoin.md b/docs/API_docs/types/smsjobs.EligibilityToJoin.md new file mode 100644 index 0000000000..9348d3289a --- /dev/null +++ b/docs/API_docs/types/smsjobs.EligibilityToJoin.md @@ -0,0 +1,24 @@ +--- +title: smsjobs.EligibilityToJoin +description: constructors and methods of type smsjobs.EligibilityToJoin +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/smsjobs_EligibilityToJoin.html +--- +# Type: smsjobs.EligibilityToJoin +[Back to types index](index.html) + + + +### Possible values (constructors): + +[smsjobs.eligibleToJoin](/API_docs/constructors/smsjobs.eligibleToJoin.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->smsjobs->isEligibleToJoin](/API_docs/methods/smsjobs.isEligibleToJoin.html) + + + diff --git a/docs/API_docs/types/smsjobs.Status.md b/docs/API_docs/types/smsjobs.Status.md new file mode 100644 index 0000000000..de5da82273 --- /dev/null +++ b/docs/API_docs/types/smsjobs.Status.md @@ -0,0 +1,24 @@ +--- +title: smsjobs.Status +description: constructors and methods of type smsjobs.Status +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/smsjobs_Status.html +--- +# Type: smsjobs.Status +[Back to types index](index.html) + + + +### Possible values (constructors): + +[smsjobs.status](/API_docs/constructors/smsjobs.status.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->smsjobs->getStatus](/API_docs/methods/smsjobs.getStatus.html) + + + diff --git a/docs/API_docs/types/stats.BroadcastRevenueStats.md b/docs/API_docs/types/stats.BroadcastRevenueStats.md new file mode 100644 index 0000000000..f2691ed626 --- /dev/null +++ b/docs/API_docs/types/stats.BroadcastRevenueStats.md @@ -0,0 +1,24 @@ +--- +title: stats.BroadcastRevenueStats +description: constructors and methods of type stats.BroadcastRevenueStats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_BroadcastRevenueStats.html +--- +# Type: stats.BroadcastRevenueStats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.broadcastRevenueStats](/API_docs/constructors/stats.broadcastRevenueStats.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getBroadcastRevenueStats](/API_docs/methods/stats.getBroadcastRevenueStats.html) + + + diff --git a/docs/API_docs/types/stats.BroadcastRevenueTransactions.md b/docs/API_docs/types/stats.BroadcastRevenueTransactions.md new file mode 100644 index 0000000000..797a17e75b --- /dev/null +++ b/docs/API_docs/types/stats.BroadcastRevenueTransactions.md @@ -0,0 +1,24 @@ +--- +title: stats.BroadcastRevenueTransactions +description: constructors and methods of type stats.BroadcastRevenueTransactions +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_BroadcastRevenueTransactions.html +--- +# Type: stats.BroadcastRevenueTransactions +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.broadcastRevenueTransactions](/API_docs/constructors/stats.broadcastRevenueTransactions.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getBroadcastRevenueTransactions](/API_docs/methods/stats.getBroadcastRevenueTransactions.html) + + + diff --git a/docs/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.md b/docs/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.md new file mode 100644 index 0000000000..6973bc4d28 --- /dev/null +++ b/docs/API_docs/types/stats.BroadcastRevenueWithdrawalUrl.md @@ -0,0 +1,24 @@ +--- +title: stats.BroadcastRevenueWithdrawalUrl +description: constructors and methods of type stats.BroadcastRevenueWithdrawalUrl +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_BroadcastRevenueWithdrawalUrl.html +--- +# Type: stats.BroadcastRevenueWithdrawalUrl +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.broadcastRevenueWithdrawalUrl](/API_docs/constructors/stats.broadcastRevenueWithdrawalUrl.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getBroadcastRevenueWithdrawalUrl](/API_docs/methods/stats.getBroadcastRevenueWithdrawalUrl.html) + + + diff --git a/docs/API_docs/types/stats.BroadcastStats.md b/docs/API_docs/types/stats.BroadcastStats.md new file mode 100644 index 0000000000..c66f090f10 --- /dev/null +++ b/docs/API_docs/types/stats.BroadcastStats.md @@ -0,0 +1,24 @@ +--- +title: stats.BroadcastStats +description: constructors and methods of type stats.BroadcastStats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_BroadcastStats.html +--- +# Type: stats.BroadcastStats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.broadcastStats](/API_docs/constructors/stats.broadcastStats.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getBroadcastStats](/API_docs/methods/stats.getBroadcastStats.html) + + + diff --git a/docs/API_docs/types/stats.MegagroupStats.md b/docs/API_docs/types/stats.MegagroupStats.md new file mode 100644 index 0000000000..7edaf483a9 --- /dev/null +++ b/docs/API_docs/types/stats.MegagroupStats.md @@ -0,0 +1,24 @@ +--- +title: stats.MegagroupStats +description: constructors and methods of type stats.MegagroupStats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_MegagroupStats.html +--- +# Type: stats.MegagroupStats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.megagroupStats](/API_docs/constructors/stats.megagroupStats.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getMegagroupStats](/API_docs/methods/stats.getMegagroupStats.html) + + + diff --git a/docs/API_docs/types/stats.MessageStats.md b/docs/API_docs/types/stats.MessageStats.md new file mode 100644 index 0000000000..dce18d5310 --- /dev/null +++ b/docs/API_docs/types/stats.MessageStats.md @@ -0,0 +1,24 @@ +--- +title: stats.MessageStats +description: constructors and methods of type stats.MessageStats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_MessageStats.html +--- +# Type: stats.MessageStats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.messageStats](/API_docs/constructors/stats.messageStats.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getMessageStats](/API_docs/methods/stats.getMessageStats.html) + + + diff --git a/docs/API_docs/types/stats.PublicForwards.md b/docs/API_docs/types/stats.PublicForwards.md new file mode 100644 index 0000000000..e40f7bceae --- /dev/null +++ b/docs/API_docs/types/stats.PublicForwards.md @@ -0,0 +1,26 @@ +--- +title: stats.PublicForwards +description: constructors and methods of type stats.PublicForwards +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_PublicForwards.html +--- +# Type: stats.PublicForwards +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.publicForwards](/API_docs/constructors/stats.publicForwards.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getMessagePublicForwards](/API_docs/methods/stats.getMessagePublicForwards.html) + +[$MadelineProto->stats->getStoryPublicForwards](/API_docs/methods/stats.getStoryPublicForwards.html) + + + diff --git a/docs/API_docs/types/stats.StoryStats.md b/docs/API_docs/types/stats.StoryStats.md new file mode 100644 index 0000000000..bee52c7707 --- /dev/null +++ b/docs/API_docs/types/stats.StoryStats.md @@ -0,0 +1,24 @@ +--- +title: stats.StoryStats +description: constructors and methods of type stats.StoryStats +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stats_StoryStats.html +--- +# Type: stats.StoryStats +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stats.storyStats](/API_docs/constructors/stats.storyStats.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stats->getStoryStats](/API_docs/methods/stats.getStoryStats.html) + + + diff --git a/docs/API_docs/types/stickers.SuggestedShortName.md b/docs/API_docs/types/stickers.SuggestedShortName.md new file mode 100644 index 0000000000..fd9598d47c --- /dev/null +++ b/docs/API_docs/types/stickers.SuggestedShortName.md @@ -0,0 +1,24 @@ +--- +title: stickers.SuggestedShortName +description: constructors and methods of type stickers.SuggestedShortName +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stickers_SuggestedShortName.html +--- +# Type: stickers.SuggestedShortName +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stickers.suggestedShortName](/API_docs/constructors/stickers.suggestedShortName.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stickers->suggestShortName](/API_docs/methods/stickers.suggestShortName.html) + + + diff --git a/docs/API_docs/types/storage.FileType.md b/docs/API_docs/types/storage.FileType.md new file mode 100644 index 0000000000..ed3a23e5bd --- /dev/null +++ b/docs/API_docs/types/storage.FileType.md @@ -0,0 +1,40 @@ +--- +title: storage.FileType +description: constructors and methods of type storage.FileType +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/storage_FileType.html +--- +# Type: storage.FileType +[Back to types index](index.html) + + + +### Possible values (constructors): + +[storage.fileUnknown](/API_docs/constructors/storage.fileUnknown.html) + +[storage.filePartial](/API_docs/constructors/storage.filePartial.html) + +[storage.fileJpeg](/API_docs/constructors/storage.fileJpeg.html) + +[storage.fileGif](/API_docs/constructors/storage.fileGif.html) + +[storage.filePng](/API_docs/constructors/storage.filePng.html) + +[storage.filePdf](/API_docs/constructors/storage.filePdf.html) + +[storage.fileMp3](/API_docs/constructors/storage.fileMp3.html) + +[storage.fileMov](/API_docs/constructors/storage.fileMov.html) + +[storage.fileMp4](/API_docs/constructors/storage.fileMp4.html) + +[storage.fileWebp](/API_docs/constructors/storage.fileWebp.html) + + + +### Methods that return an object of this type (methods): + + + diff --git a/docs/API_docs/types/stories.AllStories.md b/docs/API_docs/types/stories.AllStories.md new file mode 100644 index 0000000000..f861eebd59 --- /dev/null +++ b/docs/API_docs/types/stories.AllStories.md @@ -0,0 +1,26 @@ +--- +title: stories.AllStories +description: constructors and methods of type stories.AllStories +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stories_AllStories.html +--- +# Type: stories.AllStories +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stories.allStoriesNotModified](/API_docs/constructors/stories.allStoriesNotModified.html) + +[stories.allStories](/API_docs/constructors/stories.allStories.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->getAllStories](/API_docs/methods/stories.getAllStories.html) + + + diff --git a/docs/API_docs/types/stories.PeerStories.md b/docs/API_docs/types/stories.PeerStories.md new file mode 100644 index 0000000000..6e435c804f --- /dev/null +++ b/docs/API_docs/types/stories.PeerStories.md @@ -0,0 +1,24 @@ +--- +title: stories.PeerStories +description: constructors and methods of type stories.PeerStories +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stories_PeerStories.html +--- +# Type: stories.PeerStories +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stories.peerStories](/API_docs/constructors/stories.peerStories.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->getPeerStories](/API_docs/methods/stories.getPeerStories.html) + + + diff --git a/docs/API_docs/types/stories.Stories.md b/docs/API_docs/types/stories.Stories.md new file mode 100644 index 0000000000..3b3b0a5a44 --- /dev/null +++ b/docs/API_docs/types/stories.Stories.md @@ -0,0 +1,28 @@ +--- +title: stories.Stories +description: constructors and methods of type stories.Stories +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stories_Stories.html +--- +# Type: stories.Stories +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stories.stories](/API_docs/constructors/stories.stories.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->getPinnedStories](/API_docs/methods/stories.getPinnedStories.html) + +[$MadelineProto->stories->getStoriesArchive](/API_docs/methods/stories.getStoriesArchive.html) + +[$MadelineProto->stories->getStoriesByID](/API_docs/methods/stories.getStoriesByID.html) + + + diff --git a/docs/API_docs/types/stories.StoryReactionsList.md b/docs/API_docs/types/stories.StoryReactionsList.md new file mode 100644 index 0000000000..c61f627ac2 --- /dev/null +++ b/docs/API_docs/types/stories.StoryReactionsList.md @@ -0,0 +1,24 @@ +--- +title: stories.StoryReactionsList +description: constructors and methods of type stories.StoryReactionsList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stories_StoryReactionsList.html +--- +# Type: stories.StoryReactionsList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stories.storyReactionsList](/API_docs/constructors/stories.storyReactionsList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->getStoryReactionsList](/API_docs/methods/stories.getStoryReactionsList.html) + + + diff --git a/docs/API_docs/types/stories.StoryViews.md b/docs/API_docs/types/stories.StoryViews.md new file mode 100644 index 0000000000..9eb7643a1b --- /dev/null +++ b/docs/API_docs/types/stories.StoryViews.md @@ -0,0 +1,24 @@ +--- +title: stories.StoryViews +description: constructors and methods of type stories.StoryViews +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stories_StoryViews.html +--- +# Type: stories.StoryViews +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stories.storyViews](/API_docs/constructors/stories.storyViews.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->getStoriesViews](/API_docs/methods/stories.getStoriesViews.html) + + + diff --git a/docs/API_docs/types/stories.StoryViewsList.md b/docs/API_docs/types/stories.StoryViewsList.md new file mode 100644 index 0000000000..ed0e530813 --- /dev/null +++ b/docs/API_docs/types/stories.StoryViewsList.md @@ -0,0 +1,24 @@ +--- +title: stories.StoryViewsList +description: constructors and methods of type stories.StoryViewsList +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/stories_StoryViewsList.html +--- +# Type: stories.StoryViewsList +[Back to types index](index.html) + + + +### Possible values (constructors): + +[stories.storyViewsList](/API_docs/constructors/stories.storyViewsList.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->stories->getStoryViewsList](/API_docs/methods/stories.getStoryViewsList.html) + + + diff --git a/docs/API_docs/types/string.md b/docs/API_docs/types/string.md new file mode 100644 index 0000000000..95353ffd00 --- /dev/null +++ b/docs/API_docs/types/string.md @@ -0,0 +1,10 @@ +--- +title: string +description: A UTF8 string of variable length +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: string +[Back to constructor index](index.html) + +A UTF8 string of variable length. The total length in bytes of the string must not be bigger than 16777215. diff --git a/docs/API_docs/types/updates.ChannelDifference.md b/docs/API_docs/types/updates.ChannelDifference.md new file mode 100644 index 0000000000..dc3e40a0d9 --- /dev/null +++ b/docs/API_docs/types/updates.ChannelDifference.md @@ -0,0 +1,28 @@ +--- +title: updates.ChannelDifference +description: constructors and methods of type updates.ChannelDifference +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/updates_ChannelDifference.html +--- +# Type: updates.ChannelDifference +[Back to types index](index.html) + + + +### Possible values (constructors): + +[updates.channelDifferenceEmpty](/API_docs/constructors/updates.channelDifferenceEmpty.html) + +[updates.channelDifferenceTooLong](/API_docs/constructors/updates.channelDifferenceTooLong.html) + +[updates.channelDifference](/API_docs/constructors/updates.channelDifference.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->updates->getChannelDifference](/API_docs/methods/updates.getChannelDifference.html) + + + diff --git a/docs/API_docs/types/updates.Difference.md b/docs/API_docs/types/updates.Difference.md new file mode 100644 index 0000000000..de0cad895d --- /dev/null +++ b/docs/API_docs/types/updates.Difference.md @@ -0,0 +1,30 @@ +--- +title: updates.Difference +description: constructors and methods of type updates.Difference +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/updates_Difference.html +--- +# Type: updates.Difference +[Back to types index](index.html) + + + +### Possible values (constructors): + +[updates.differenceEmpty](/API_docs/constructors/updates.differenceEmpty.html) + +[updates.difference](/API_docs/constructors/updates.difference.html) + +[updates.differenceSlice](/API_docs/constructors/updates.differenceSlice.html) + +[updates.differenceTooLong](/API_docs/constructors/updates.differenceTooLong.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->updates->getDifference](/API_docs/methods/updates.getDifference.html) + + + diff --git a/docs/API_docs/types/updates.State.md b/docs/API_docs/types/updates.State.md new file mode 100644 index 0000000000..96e30384f8 --- /dev/null +++ b/docs/API_docs/types/updates.State.md @@ -0,0 +1,24 @@ +--- +title: updates.State +description: constructors and methods of type updates.State +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/updates_State.html +--- +# Type: updates.State +[Back to types index](index.html) + + + +### Possible values (constructors): + +[updates.state](/API_docs/constructors/updates.state.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->updates->getState](/API_docs/methods/updates.getState.html) + + + diff --git a/docs/API_docs/types/upload.CdnFile.md b/docs/API_docs/types/upload.CdnFile.md new file mode 100644 index 0000000000..a14410c05a --- /dev/null +++ b/docs/API_docs/types/upload.CdnFile.md @@ -0,0 +1,26 @@ +--- +title: upload.CdnFile +description: constructors and methods of type upload.CdnFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/upload_CdnFile.html +--- +# Type: upload.CdnFile +[Back to types index](index.html) + + + +### Possible values (constructors): + +[upload.cdnFileReuploadNeeded](/API_docs/constructors/upload.cdnFileReuploadNeeded.html) + +[upload.cdnFile](/API_docs/constructors/upload.cdnFile.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->upload->getCdnFile](/API_docs/methods/upload.getCdnFile.html) + + + diff --git a/docs/API_docs/types/upload.File.md b/docs/API_docs/types/upload.File.md new file mode 100644 index 0000000000..4fcc041f42 --- /dev/null +++ b/docs/API_docs/types/upload.File.md @@ -0,0 +1,26 @@ +--- +title: upload.File +description: constructors and methods of type upload.File +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/upload_File.html +--- +# Type: upload.File +[Back to types index](index.html) + + + +### Possible values (constructors): + +[upload.file](/API_docs/constructors/upload.file.html) + +[upload.fileCdnRedirect](/API_docs/constructors/upload.fileCdnRedirect.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->upload->getFile](/API_docs/methods/upload.getFile.html) + + + diff --git a/docs/API_docs/types/upload.WebFile.md b/docs/API_docs/types/upload.WebFile.md new file mode 100644 index 0000000000..33b3118179 --- /dev/null +++ b/docs/API_docs/types/upload.WebFile.md @@ -0,0 +1,24 @@ +--- +title: upload.WebFile +description: constructors and methods of type upload.WebFile +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/upload_WebFile.html +--- +# Type: upload.WebFile +[Back to types index](index.html) + + + +### Possible values (constructors): + +[upload.webFile](/API_docs/constructors/upload.webFile.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->upload->getWebFile](/API_docs/methods/upload.getWebFile.html) + + + diff --git a/docs/API_docs/types/users.UserFull.md b/docs/API_docs/types/users.UserFull.md new file mode 100644 index 0000000000..f467312060 --- /dev/null +++ b/docs/API_docs/types/users.UserFull.md @@ -0,0 +1,24 @@ +--- +title: users.UserFull +description: constructors and methods of type users.UserFull +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +redirect_from: /API_docs/types/users_UserFull.html +--- +# Type: users.UserFull +[Back to types index](index.html) + + + +### Possible values (constructors): + +[users.userFull](/API_docs/constructors/users.userFull.html) + + + +### Methods that return an object of this type (methods): + +[$MadelineProto->users->getFullUser](/API_docs/methods/users.getFullUser.html) + + + diff --git a/docs/API_docs/types/waveform.md b/docs/API_docs/types/waveform.md new file mode 100644 index 0000000000..8867f420ca --- /dev/null +++ b/docs/API_docs/types/waveform.md @@ -0,0 +1,16 @@ +--- +title: waveform +description: An array representing the waveform of a voice message +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: waveform +[Back to constructor index](index.html) + +The waveform of a voice message is represented by an array of 100 elements, containing integers ranging from 0 to 31. + +```php +$waveform = array_fill(0, 100, 0); +$waveform = array_fill(0, 100, 31); +``` + diff --git a/docs/CNAME b/docs/CNAME new file mode 100644 index 0000000000..f4ccbf5357 --- /dev/null +++ b/docs/CNAME @@ -0,0 +1 @@ +docs.madelineproto.xyz \ No newline at end of file diff --git a/docs/Chat.md b/docs/Chat.md new file mode 100644 index 0000000000..004d4ae36c --- /dev/null +++ b/docs/Chat.md @@ -0,0 +1,51 @@ +--- +title: PWRTelegram chat +description: chat attributes, type and example +nav_exclude: true +--- +## Constructor: PWRTelegram chat + + + +### Attributes: + +| Name | Type | Required |Description| +|----------|---------------|----------|-----------| +|type|[string](API_docs/types/string.html) | Yes|bot, user, channel, supergroup or chat| +|id|[long](API_docs/types/long.html) | Yes|bot API chat id| +|access\_hash|[long](API_docs/types/long.html) | Optional|access hash of peer| +|first\_name|[string](API_docs/types/string.html) | Optional|First name of the user| +|last\_name|[string](API_docs/types/string.html) | Optional|Last name of the user| +|lang\_code|[string](API_docs/types/string.html) | Optional|Language of the user| +|username|[string](API_docs/types/string.html) | Optional|Username| +|verified|[Bool](API_docs/types/Bool.html) | Optional|Is the peer official?| +|restricted|[Bool](API_docs/types/Bool.html) | Optional|Is the peer restricted to the current user?| +|restriction\_reason|[string](API_docs/types/string.html) | Optional|Restriction reason| +|status|[UserStatus](API_docs/types/UserStatus.html) | Optional|Describes last time user was online| +|bot\_inline\_placeholder|[string](API_docs/types/string.html) | Optional|Inline placeholder of inline bot| +|bot\_nochats|[Bool](API_docs/types/Bool.html) | Optional|Can the bot be added to a group| +|about|[string](API_docs/types/string.html) | Optional|Description of supergroups/channels or bios of users| +|bot\_info|[BotInfo](API_docs/types/BotInfo.html) | Optional|Bot info of bots| +|phone\_calls\_available|[Bool](API_docs/types/Bool.html) | Optional|Are phone calls available for that user?| +|phone\_calls\_private|[Bool](API_docs/types/Bool.html) | Optional|| +|common\_chats\_count|[int](API_docs/types/int.html) | Optional|Number of chats in common with that user| +|photo|[string](API_docs/types/string.html) | Optional|bot API file object the profile picture| +|title|[string](API_docs/types/string.html) | Optional|Chat title| +|participants\_count|[int](API_docs/types/int.html) | Optional|Number of participants in the chat.| +|kicked\_count|[int](API_docs/types/int.html) | Optional|Number of users kicked from the chat.| +|admin\_count|[int](API_docs/types/int.html) | Optional|Number of admins in the chat.| +|admin|[Bool](API_docs/types/Bool.html) | Optional|Are you an admin in this chat?| +|all\_members\_are\_administrators|[Bool](API_docs/types/Bool.html) | Optional|True if a group has ‘All Members Are Admins’ enabled.| +|invite|[string](API_docs/types/string.html) | Optional|Invite link of the chat| +|participants|Array of [Participant](Participant.html) | Yes|Chat participants| +|democracy|[Bool](API_docs/types/Bool.html) | Optional|Can everyone add users to this chat?| +|signatures|[Bool](API_docs/types/Bool.html) | Optional|Are channel signatures enabled?| +|can\_view\_participants|[Bool](API_docs/types/Bool.html) | Optional|Can you view participants (you can still view the bots in channels even if this is false)| +|can\_set\_username|[Bool](API_docs/types/Bool.html) | Optional|Can you set the username of this channel/supergroup?| +|can\_set\_stickers|[Bool](API_docs/types/Bool.html) | Optional|Can you set the associated stickerpack of this channel/supergroup?| +|stickerset|[StickerSet](API_docs/types/StickerSet.html) | Optional|StickerSet associtaed to this channel/supergroup| +|migrated\_from\_chat\_id|[int](API_docs/types/int.html) | Optional|MTProto chat id of the original chat (render it negative to make it a bot API chat id)| +|migrated\_from\_max\_id|[int](API_docs/types/int.html) | Optional|Last message id before migration| +|pinned\_msg\_id|[int](API_docs/types/int.html) | Optional|Message id of pinned message| + + diff --git a/docs/FOSS.html b/docs/FOSS.html new file mode 100644 index 0000000000..6413691a34 --- /dev/null +++ b/docs/FOSS.html @@ -0,0 +1,10 @@ + + + Redirecting... + + + + +

Redirecting to https://github.com/danog/MadelineProto/edit/v8/README.md...

+ + diff --git a/docs/FullInfo.md b/docs/FullInfo.md new file mode 100644 index 0000000000..eb03bdae8e --- /dev/null +++ b/docs/FullInfo.md @@ -0,0 +1,26 @@ +--- +title: full chat info +description: chat attributes, type and example +nav_exclude: true +--- +## Constructor: FullInfo + + + +### Attributes: + +| Name | Type | Required |Description| +|----------|---------------|----------|-----------| +|type|[string](API_docs/types/string.html) | Yes|bot, user, channel, supergroup or chat| +|Chat|[Chat](API_docs/types/Chat.html) | Optional|Info about the current chat| +|User|[User](API_docs/types/User.html) | Optional|Info about the current user| +|bot\_api\_id|[long](API_docs/types/long.html) | Yes|bot API chat id| +|InputPeer|[InputPeer](API_docs/types/InputPeer.html) | Yes|InputPeer object| +|Peer|[Peer](API_docs/types/Peer.html) | Optional|Peer object| +|user\_id|[int](API_docs/types/int.html) | Optional|MTProto user id| +|chat\_id|[int](API_docs/types/int.html) | Optional|MTProto chat id| +|channel\_id|[int](API_docs/types/int.html) | Optional|MTProto channel id| +|InputUser|[InputUser](API_docs/types/InputUser.html) | Optional|InputUser object| +|InputChannel|[InputChannel](API_docs/types/InputChannel.html) | Optional|InputChannel object| +|last_update|[int](API_docs/types/int.html) | Yes|When was info about this peer cached| +|full|[ChatFull](API_docs/types/ChatFull.html) or [UserFull](API_docs/types/UserFull.html) | Yes|full info| diff --git a/docs/Info.md b/docs/Info.md new file mode 100644 index 0000000000..daf74b73bc --- /dev/null +++ b/docs/Info.md @@ -0,0 +1,26 @@ +--- +title: chat info +description: chat attributes, type and example +nav_exclude: true +--- +## Constructor: Info + + + +### Attributes: + +| Name | Type | Required |Description| +|----------|---------------|----------|-----------| +|type|[string](API_docs/types/string.html) | Yes|bot, user, channel, supergroup or chat| +|Chat|[Chat](API_docs/types/Chat.html) | Optional|Info about the current chat| +|User|[User](API_docs/types/User.html) | Optional|Info about the current user| +|bot\_api\_id|[long](API_docs/types/long.html) | Yes|bot API chat id| +|InputPeer|[InputPeer](API_docs/types/InputPeer.html) | Yes|InputPeer object| +|Peer|[Peer](API_docs/types/Peer.html) | Optional|Peer object| +|user\_id|[int](API_docs/types/int.html) | Optional|MTProto user id| +|chat\_id|[int](API_docs/types/int.html) | Optional|MTProto chat id| +|channel\_id|[int](API_docs/types/int.html) | Optional|MTProto channel id| +|InputUser|[InputUser](API_docs/types/InputUser.html) | Optional|InputUser object| +|InputChannel|[InputChannel](API_docs/types/InputChannel.html) | Optional|InputChannel object| + + diff --git a/docs/LICENSE-theme.txt b/docs/LICENSE-theme.txt new file mode 100644 index 0000000000..9e81a6cf5f --- /dev/null +++ b/docs/LICENSE-theme.txt @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2016 Patrick Marsceill + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/docs/PHP/danog/MadelineProto/API.md b/docs/PHP/danog/MadelineProto/API.md new file mode 100644 index 0000000000..32688a0d9c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/API.md @@ -0,0 +1,3287 @@ +--- +title: "danog\\MadelineProto\\API: Main API wrapper for MadelineProto." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\API` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Main API wrapper for MadelineProto. + + + + +## Constants +* `danog\MadelineProto\API::RELEASE`: Release version. + +* `danog\MadelineProto\API::NOT_LOGGED_IN`: We're not logged in. + +* `danog\MadelineProto\API::WAITING_CODE`: We're waiting for the login code. + +* `danog\MadelineProto\API::WAITING_SIGNUP`: We're waiting for parameters to sign up. + +* `danog\MadelineProto\API::WAITING_PASSWORD`: We're waiting for the 2FA password. + +* `danog\MadelineProto\API::LOGGED_IN`: We're logged in. + +* `danog\MadelineProto\API::LOGGED_OUT`: We're logged out, the session will be deleted ASAP. + +* `danog\MadelineProto\API::PEER_TYPE_USER`: This peer is a user. + +* `danog\MadelineProto\API::PEER_TYPE_BOT`: This peer is a bot. + +* `danog\MadelineProto\API::PEER_TYPE_GROUP`: This peer is a normal group. + +* `danog\MadelineProto\API::PEER_TYPE_SUPERGROUP`: This peer is a supergroup. + +* `danog\MadelineProto\API::PEER_TYPE_CHANNEL`: This peer is a channel. + +* `danog\MadelineProto\API::INFO_TYPE_PEER`: Whether to generate only peer information. + +* `danog\MadelineProto\API::INFO_TYPE_CONSTRUCTOR`: Whether to generate only constructor information. + +* `danog\MadelineProto\API::INFO_TYPE_ID`: Whether to generate only ID information. + +* `danog\MadelineProto\API::INFO_TYPE_ALL`: Whether to generate all information. + +* `danog\MadelineProto\API::INFO_TYPE_USERNAMES`: Whether to generate all usernames. + +* `danog\MadelineProto\API::INFO_TYPE_TYPE`: Whether to generate just type info. + +## Properties +* `$auth`: `\danog\MadelineProto\Namespace\Auth` +* `$account`: `\danog\MadelineProto\Namespace\Account` +* `$users`: `\danog\MadelineProto\Namespace\Users` +* `$contacts`: `\danog\MadelineProto\Namespace\Contacts` +* `$messages`: `\danog\MadelineProto\Namespace\Messages` +* `$updates`: `\danog\MadelineProto\Namespace\Updates` +* `$photos`: `\danog\MadelineProto\Namespace\Photos` +* `$upload`: `\danog\MadelineProto\Namespace\Upload` +* `$help`: `\danog\MadelineProto\Namespace\Help` +* `$channels`: `\danog\MadelineProto\Namespace\Channels` +* `$bots`: `\danog\MadelineProto\Namespace\Bots` +* `$payments`: `\danog\MadelineProto\Namespace\Payments` +* `$stickers`: `\danog\MadelineProto\Namespace\Stickers` +* `$phone`: `\danog\MadelineProto\Namespace\Phone` +* `$langpack`: `\danog\MadelineProto\Namespace\Langpack` +* `$folders`: `\danog\MadelineProto\Namespace\Folders` +* `$stats`: `\danog\MadelineProto\Namespace\Stats` +* `$chatlists`: `\danog\MadelineProto\Namespace\Chatlists` +* `$stories`: `\danog\MadelineProto\Namespace\Stories` +* `$premium`: `\danog\MadelineProto\Namespace\Premium` +* `$smsjobs`: `\danog\MadelineProto\Namespace\Smsjobs` +* `$fragment`: `\danog\MadelineProto\Namespace\Fragment` + +## Method list: +* [`getWebAPITemplate(): string`](#getWebAPITemplate) +* [`setWebApiTemplate(string $template): void`](#setWebApiTemplate) +* [`__construct(string $session, \danog\MadelineProto\SettingsAbstract $settings = NULL)`](#__construct) +* [`startAndLoopMulti(array<\danog\MadelineProto\API> $instances, (array>|class-string<\danog\MadelineProto\EventHandler>) $eventHandler): void`](#startAndLoopMulti) +* [`MTProtoToBotAPI(array $data): array`](#MTProtoToBotAPI) +* [`MTProtoToTd(mixed $params): array`](#MTProtoToTd) +* [`MTProtoToTdcli(mixed $params): array`](#MTProtoToTdcli) +* [`acceptCall(int $id): void`](#acceptCall) +* [`acceptSecretChat(array $params): void`](#acceptSecretChat) +* [`arr(mixed ...$params): array`](#arr) +* [`base64urlDecode(string $data): string`](#base64urlDecode) +* [`base64urlEncode(string $data): string`](#base64urlEncode) +* [`botAPIToMTProto(array $arguments): array`](#botAPIToMTProto) +* [`botLogin(string $token): ?array`](#botLogin) +* [`broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int`](#broadcastCustom) +* [`broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastForwardMessages) +* [`broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastMessages) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null`](#callGetCurrent) +* [`callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void`](#callPlay) +* [`callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void`](#callPlayOnHold) +* [`callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void`](#callSetOutput) +* [`canConvertOgg(): bool`](#canConvertOgg) +* [`canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool`](#canUseFFmpeg) +* [`cancelBroadcast(integer $id): void`](#cancelBroadcast) +* [`closeConnection(string $message): void`](#closeConnection) +* [`complete2faLogin(string $password): array`](#complete2faLogin) +* [`completePhoneLogin(string $code): array`](#completePhoneLogin) +* [`completeSignup(string $first_name, string $last_name = ''): array`](#completeSignup) +* [`discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void`](#discardCall) +* [`discardSecretChat(int $chat): void`](#discardSecretChat) +* [`downloadServer(string $session): void`](#downloadServer) +* [`downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToBrowser) +* [`downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToCallable) +* [`downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToDir) +* [`downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToFile) +* [`downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response`](#downloadToResponse) +* [`downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#downloadToReturnedStream) +* [`downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToStream) +* [`echo(string $string): void`](#echo) +* [`end(array $what): T`](#end) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`exportAuthorization(): array{0: (int|string), 1: string}`](#exportAuthorization) +* [`extractBotAPIFile(array $info): ?array`](#extractBotAPIFile) +* [`extractMessage(array $updates): array`](#extractMessage) +* [`extractMessageId(array $updates): int`](#extractMessageId) +* [`extractMessageUpdate(array $updates): array`](#extractMessageUpdate) +* [`extractUpdates(array $updates): array`](#extractUpdates) +* [`fileGetContents(string $url): string`](#fileGetContents) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`fullChatLastUpdated(mixed $id): int`](#fullChatLastUpdated) +* [`fullGetSelf(): array|false`](#fullGetSelf) +* [`genVectorHash(array $longs): string`](#genVectorHash) +* [`getAdminIds(): array`](#getAdminIds) +* [`getAllCalls(): array`](#getAllCalls) +* [`getAllMethods(): array`](#getAllMethods) +* [`getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)`](#getAuthorization) +* [`getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress`](#getBroadcastProgress) +* [`getCachedConfig(): array`](#getCachedConfig) +* [`getCall(int $id): ?\danog\MadelineProto\VoIP`](#getCall) +* [`getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP`](#getCallByPeer) +* [`getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState`](#getCallState) +* [`getCdnConfig(): void`](#getCdnConfig) +* [`getConfig(array $config = []): array`](#getConfig) +* [`getDNSClient(): \Amp\Dns\DnsResolver`](#getDNSClient) +* [`getDhConfig(): array`](#getDhConfig) +* [`getDialogIds(): list`](#getDialogIds) +* [`getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}`](#getDownloadInfo) +* [`getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string`](#getDownloadLink) +* [`getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)`](#getEventHandler) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getFileInfo(mixed $constructor): array`](#getFileInfo) +* [`getFullDialogs(): array`](#getFullDialogs) +* [`getFullInfo(mixed $id): array`](#getFullInfo) +* [`getHTTPClient(): \Amp\Http\Client\HttpClient`](#getHTTPClient) +* [`getHint(): string`](#getHint) +* [`getId(mixed $id): int`](#getId) +* [`getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))`](#getInfo) +* [`getLogger(): \danog\MadelineProto\Logger`](#getLogger) +* [`getMaps(): ?int`](#getMaps) +* [`getMaxMaps(): ?int`](#getMaxMaps) +* [`getMethodNamespaces(): array`](#getMethodNamespaces) +* [`getMethodsNamespaced(): array`](#getMethodsNamespaced) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null`](#getPlugin) +* [`getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo`](#getPropicInfo) +* [`getPsrLogger(): \Psr\Log\LoggerInterface`](#getPsrLogger) +* [`getPwrChat(mixed $id, bool $fullfetch = true): array`](#getPwrChat) +* [`getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat`](#getSecretChat) +* [`getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage`](#getSecretMessage) +* [`getSelf(): array|false`](#getSelf) +* [`getSessionName(): string`](#getSessionName) +* [`getSettings(): \danog\MadelineProto\Settings`](#getSettings) +* [`getSponsoredMessages((int|string|array) $peer): ?array`](#getSponsoredMessages) +* [`getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`getStreamPipe(): \Amp\ByteStream\Pipe`](#getStreamPipe) +* [`getTL(): \danog\MadelineProto\TL\TLInterface`](#getTL) +* [`getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*`](#getType) +* [`getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list`](#getUpdates) +* [`getWebMessage(string $message): string`](#getWebMessage) +* [`getWebWarnings(): string`](#getWebWarnings) +* [`hasAdmins(): bool`](#hasAdmins) +* [`hasEventHandler(): bool`](#hasEventHandler) +* [`hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool`](#hasPlugin) +* [`hasReportPeers(): bool`](#hasReportPeers) +* [`hasSecretChat((array|int) $chat): bool`](#hasSecretChat) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`importAuthorization(array $authorization, int $mainDcID): array`](#importAuthorization) +* [`inflateStripped(string $stripped): string`](#inflateStripped) +* [`initSelfRestart(): void`](#initSelfRestart) +* [`isAltervista(): bool`](#isAltervista) +* [`isArrayOrAlike(mixed $var): bool`](#isArrayOrAlike) +* [`isBot(mixed $peer): bool`](#isBot) +* [`isForum(mixed $peer): bool`](#isForum) +* [`isIpc(): bool`](#isIpc) +* [`isIpcWorker(): bool`](#isIpcWorker) +* [`isPlayPaused(int $id): bool`](#isPlayPaused) +* [`isPremium(): bool`](#isPremium) +* [`isSelfBot(): bool`](#isSelfBot) +* [`isSelfUser(): bool`](#isSelfUser) +* [`isTestMode(): boolean`](#isTestMode) +* [`logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void`](#logger) +* [`logout(): void`](#logout) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string`](#openBuffered) +* [`openFileAppendOnly(string $path): \Amp\File\File`](#openFileAppendOnly) +* [`packDouble(float $value): string`](#packDouble) +* [`packSignedInt(integer $value): string`](#packSignedInt) +* [`packSignedLong(int $value): string`](#packSignedLong) +* [`packUnsignedInt(int $value): string`](#packUnsignedInt) +* [`pausePlay(int $id): void`](#pausePlay) +* [`peerIsset(mixed $id): bool`](#peerIsset) +* [`phoneLogin(string $number, integer $sms_type = 5): array`](#phoneLogin) +* [`posmod(int $a, int $b): int`](#posmod) +* [`processDownloadServerPing(string $path, string $payload): void`](#processDownloadServerPing) +* [`qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode`](#qrLogin) +* [`random(integer $length): string`](#random) +* [`randomInt(integer $modulus = 0): int`](#randomInt) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`refreshFullPeerCache(mixed $id): void`](#refreshFullPeerCache) +* [`refreshPeerCache(mixed ...$ids): void`](#refreshPeerCache) +* [`report(string $message, string $parseMode = ''): void`](#report) +* [`reportMemoryProfile(): void`](#reportMemoryProfile) +* [`requestCall(mixed $user): \danog\MadelineProto\VoIP`](#requestCall) +* [`requestSecretChat(mixed $user): int`](#requestSecretChat) +* [`resetUpdateState(): void`](#resetUpdateState) +* [`restart(): void`](#restart) +* [`resumePlay(int $id): void`](#resumePlay) +* [`rethrow(Throwable $e): void`](#rethrow) +* [`rleDecode(string $string): string`](#rleDecode) +* [`rleEncode(string $string): string`](#rleEncode) +* [`sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendAudio) +* [`sendCustomEvent(mixed $payload): void`](#sendCustomEvent) +* [`sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocument) +* [`sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocumentPhoto) +* [`sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendGif) +* [`sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendMessage) +* [`sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>`](#sendMessageToAdmins) +* [`sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendPhoto) +* [`sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendSticker) +* [`sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVideo) +* [`sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVoice) +* [`setNoop(): void`](#setNoop) +* [`setReportPeers((int|string|array<(int|string)>) $userOrId): void`](#setReportPeers) +* [`setWebhook(string $webhookUrl): void`](#setWebhook) +* [`skipPlay(int $id): void`](#skipPlay) +* [`sleep(float $time): void`](#sleep) +* [`start(): array`](#start) +* [`stop(): void`](#stop) +* [`stopPlay(int $id): void`](#stopPlay) +* [`stringToStream(string $str): \Amp\ByteStream\ReadableBuffer`](#stringToStream) +* [`subscribeToUpdates(mixed $channel): bool`](#subscribeToUpdates) +* [`tdToMTProto(array $params): array`](#tdToMTProto) +* [`tdToTdcli(mixed $params): array`](#tdToTdcli) +* [`tdcliToTd(mixed $params, array $key = NULL): array`](#tdcliToTd) +* [`testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}`](#testFibers) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`unpackDouble(string $value): float`](#unpackDouble) +* [`unpackFileId(string $fileId): array`](#unpackFileId) +* [`unpackSignedInt(string $value): int`](#unpackSignedInt) +* [`unpackSignedLong(string $value): int`](#unpackSignedLong) +* [`unpackSignedLongString((string|int|array) $value): string`](#unpackSignedLongString) +* [`unsetEventHandler(): void`](#unsetEventHandler) +* [`update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void`](#update2fa) +* [`updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void`](#updateSettings) +* [`upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#upload) +* [`uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadEncrypted) +* [`uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromCallable) +* [`uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromStream) +* [`uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromTgfile) +* [`uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromUrl) +* [`validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>`](#validateEventHandlerClass) +* [`viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool`](#viewSponsoredMessage) +* [`wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media`](#wrapMedia) +* [`wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage`](#wrapMessage) +* [`wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned`](#wrapPin) +* [`wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update`](#wrapUpdate) + +## Methods: +### `getWebAPITemplate(): string` + +Obtain the API ID UI template. + + + +### `setWebApiTemplate(string $template): void` + +Set the API ID UI template. + + +Parameters: + +* `$template`: `string` + + + +### `__construct(string $session, \danog\MadelineProto\SettingsAbstract $settings = NULL)` + +Constructor function. + + +Parameters: + +* `$session`: `string` Session name +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `startAndLoopMulti(array<\danog\MadelineProto\API> $instances, (array>|class-string<\danog\MadelineProto\EventHandler>) $eventHandler): void` + +Start multiple instances of MadelineProto and the event handlers (enables async). + + +Parameters: + +* `$instances`: `array<\danog\MadelineProto\API>` Instances of madeline +* `$eventHandler`: `(array>|class-string<\danog\MadelineProto\EventHandler>)` Event handler(s) + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) + + + + +### `MTProtoToBotAPI(array $data): array` + +Convert MTProto parameters to bot API parameters. + + +Parameters: + +* `$data`: `array` Data + + + +### `MTProtoToTd(mixed $params): array` + +MTProto to TD params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `MTProtoToTdcli(mixed $params): array` + +MTProto to TDCLI params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `acceptCall(int $id): void` + +Accept call. + + +Parameters: + +* `$id`: `int` + + + +### `acceptSecretChat(array $params): void` + +Accept secret chat. + + +Parameters: + +* `$params`: `array` Secret chat ID + + + +### `arr(mixed ...$params): array` + +Create array. + + +Parameters: + +* `...$params`: `mixed` Params + + + +### `base64urlDecode(string $data): string` + +base64URL decode. + + +Parameters: + +* `$data`: `string` Data to decode + + + +### `base64urlEncode(string $data): string` + +Base64URL encode. + + +Parameters: + +* `$data`: `string` Data to encode + + + +### `botAPIToMTProto(array $arguments): array` + +Convert bot API parameters to MTProto parameters. + + +Parameters: + +* `$arguments`: `array` Arguments + + + +### `botLogin(string $token): ?array` + +Login as bot. + + +Parameters: + +* `$token`: `string` Bot token + + + +### `broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int` + +Executes a custom broadcast action with all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$action`: `\danog\MadelineProto\Broadcast\Action` A custom, serializable Action class that will be called once for every peer. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Action`: Interface that represents a broadcast action.](../../danog/MadelineProto/Broadcast/Action.html) +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Forwards a list of messages to all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$from_peer`: `mixed` Bot API ID or Update, from where to forward the messages. +* `$message_ids`: `list` IDs of the messages to forward. +* `$drop_author`: `bool` If true, will forward messages without quoting the original author. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Sends a list of messages to all peers (users, chats, channels) of the bot. + +A simplified version of this method is also available: broadcastForwardMessages can work with pre-prepared messages. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$messages`: `array` The messages to send: an array of arrays, containing parameters to pass to messages.sendMessage. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null` + +Get the file that is currently being played. + +Will return a string with the object ID of the stream if we're currently playing a stream, otherwise returns the related LocalFile or RemoteUrl. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) + + + + +### `callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void` + +Play file in call. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void` + +Play files on hold in call. + + +Parameters: + +* `$id`: `int` +* `...$files`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void` + +Set output file or stream for incoming OPUS audio packets in a call. + +Will write an OGG OPUS stream to the specified file or stream. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* `\Amp\ByteStream\WritableStream` + + + + +### `canConvertOgg(): bool` + +Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot. + + + +### `canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool` + +Whether we can convert any audio/video file using ffmpeg. + + +Parameters: + +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `cancelBroadcast(integer $id): void` + +Cancel a running broadcast. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + + +### `closeConnection(string $message): void` + +Close connection with client, connected via web. + + +Parameters: + +* `$message`: `string` Message + + + +### `complete2faLogin(string $password): array` + +Complete 2FA login. + + +Parameters: + +* `$password`: `string` Password + + + +### `completePhoneLogin(string $code): array` + +Complet user login using login code. + + +Parameters: + +* `$code`: `string` Login code + + + +### `completeSignup(string $first_name, string $last_name = ''): array` + +Complete signup to Telegram. + + +Parameters: + +* `$first_name`: `string` First name +* `$last_name`: `string` Last name + + + +### `discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void` + +Discard call. + + +Parameters: + +* `$id`: `int` +* `$reason`: `\danog\MadelineProto\VoIP\DiscardReason` +* `$rating`: `int<1, 5>` Call rating in stars +* `$comment`: `string` Additional comment on call quality. + + +#### See also: +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `discardSecretChat(int $chat): void` + +Discard secret chat. + + +Parameters: + +* `$chat`: `int` Secret chat ID + + + +### `downloadServer(string $session): void` + +Downloads a file to the browser using the specified session file. + + +Parameters: + +* `$session`: `string` + + + +### `downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to browser. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$cb`: `(null|callable)` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Cancellation` + + + + +### `downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to callable. +The callable must accept two parameters: string $payload, int $offset +The callable will be called (possibly out of order, depending on the value of $seekable). + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$callable`: `(callable|\danog\MadelineProto\FileCallbackInterface)` Chunk callback +* `$cb`: `callable` Status callback +* `$seekable`: `bool` Whether the callable can be called out of order +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to stop downloading (inclusive) +* `$part_size`: `int` Size of each chunk +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file to directory. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$dir`: `(string|\danog\MadelineProto\FileCallbackInterface)` Directory where to download the file +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$file`: `(string|\danog\MadelineProto\FileCallbackInterface)` Downloaded file path +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response` + +Download file to amphp/http-server response. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$request`: `\Amp\Http\Server\Request` Request +* `$cb`: `callable` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Http\Server\Request` +* `\Amp\Cancellation` +* `\Amp\Http\Server\Response` + + + + +### `downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Download file to an amphp stream, returning it. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to stream. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$stream`: `(mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream)` Stream where to download file +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `resource` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `end(array $what): T` + +Get final element of array. + + +Parameters: + +* `$what`: `array` Array + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `exportAuthorization(): array{0: (int|string), 1: string}` + +Export authorization. + + + +### `extractBotAPIFile(array $info): ?array` + +Extract file info from bot API message. + + +Parameters: + +* `$info`: `array` Bot API message object + + + +### `extractMessage(array $updates): array` + +Extract a message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageId(array $updates): int` + +Extract a message ID from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageUpdate(array $updates): array` + +Extract an update message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractUpdates(array $updates): array` + +Extract Update constructors from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `fileGetContents(string $url): string` + +Get contents of remote file asynchronously. + + +Parameters: + +* `$url`: `string` URL + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `fullChatLastUpdated(mixed $id): int` + +When was full info for this chat last cached. + + +Parameters: + +* `$id`: `mixed` Chat ID + + + +### `fullGetSelf(): array|false` + +Get info about the logged-in user, not cached. + + + +### `genVectorHash(array $longs): string` + +Generate MTProto vector hash. + +Returns a vector hash. + + +Parameters: + +* `$longs`: `array` IDs + + + +### `getAdminIds(): array` + +Get admin IDs (equal to all user report peers). + + + +### `getAllCalls(): array` + +Get all pending and running calls, indexed by user ID. + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getAllMethods(): array` + +Get full list of MTProto and API methods. + + + +### `getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)` + +Get authorization info. + + +#### See also: +* `\danog\MadelineProto\API::NOT_LOGGED_IN` +* `\danog\MadelineProto\API::WAITING_CODE` +* `\danog\MadelineProto\API::WAITING_SIGNUP` +* `\danog\MadelineProto\API::WAITING_PASSWORD` +* `\danog\MadelineProto\API::LOGGED_IN` +* `API::LOGGED_OUT` + + + + +### `getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress` + +Get the progress of a currently running broadcast. + +Will return null if the broadcast doesn't exist, has already completed or was cancelled. + +Use updateBroadcastProgress updates to get real-time progress status without polling. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Progress`: Broadcast progress.](../../danog/MadelineProto/Broadcast/Progress.html) + + + + +### `getCachedConfig(): array` + +Get cached server-side config. + + + +### `getCall(int $id): ?\danog\MadelineProto\VoIP` + +Get phone call information. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP` + +Get the phone call with the specified user ID. + + +Parameters: + +* `$userId`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState` + +Get call state. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [\danog\MadelineProto\VoIP\CallState](../../danog/MadelineProto/VoIP/CallState.html) + + + + +### `getCdnConfig(): void` + +Store RSA keys for CDN datacenters. + + + +### `getConfig(array $config = []): array` + +Get cached (or eventually re-fetch) server-side config. + + +Parameters: + +* `$config`: `array` Current config + + + +### `getDNSClient(): \Amp\Dns\DnsResolver` + +Get async DNS client. + + +#### See also: +* `\Amp\Dns\DnsResolver` + + + + +### `getDhConfig(): array` + +Get diffie-hellman configuration. + + + +### `getDialogIds(): list` + +Get dialog IDs. + + + +### `getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}` + +Get download info of file +Returns an array with the following structure:. + +`$info['ext']` - The file extension +`$info['name']` - The file name, without the extension +`$info['mime']` - The file mime type +`$info['size']` - The file size + + +Parameters: + +* `$messageMedia`: `mixed` File ID + + + +### `getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string` + +Get download link of media file. + + +Parameters: + +* `$media`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string` +* `$scriptUrl`: `?string` +* `$size`: `?int` +* `$name`: `?string` +* `$mime`: `?string` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)` + +Get event handler (or plugin instance). + + +Parameters: + +* `$class`: `(class-string|null)` + + +#### See also: +* `\danog\MadelineProto\Ipc\EventHandlerProxy` +* `\__PHP_Incomplete_Class` + + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getFileInfo(mixed $constructor): array` + +Get info about file. + + +Parameters: + +* `$constructor`: `mixed` File ID + + + +### `getFullDialogs(): array` + +Get full info of all dialogs. + +Bots should use getDialogIds, instead. + + + +### `getFullInfo(mixed $id): array` + +Get full info about peer, returns an FullInfo object. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* [https://docs.madelineproto.xyz/FullInfo.html](https://docs.madelineproto.xyz/FullInfo.html) + + + + +### `getHTTPClient(): \Amp\Http\Client\HttpClient` + +Get async HTTP client. + + +#### See also: +* `\Amp\Http\Client\HttpClient` + + + + +### `getHint(): string` + +Get current password hint. + + + +### `getId(mixed $id): int` + +Get the bot API ID of a peer. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))` + +Get info about peer, returns an Info object. + +If passed a secret chat ID, returns information about the user, not about the secret chat. +Use getSecretChat to return information about the secret chat. + + +Parameters: + +* `$id`: `mixed` Peer +* `$type`: `\danog\MadelineProto\API::INFO_TYPE_*` Whether to generate an Input*, an InputPeer or the full set of constructors + + +#### See also: +* [https://docs.madelineproto.xyz/Info.html](https://docs.madelineproto.xyz/Info.html) +* `\danog\MadelineProto\API::INFO_TYPE_*` + + + + +### `getLogger(): \danog\MadelineProto\Logger` + +Get logger. + + +#### See also: +* [`\danog\MadelineProto\Logger`: Logger class.](../../danog/MadelineProto/Logger.html) + + + + +### `getMaps(): ?int` + +Get current number of memory-mapped regions, UNIX only. + + + +### `getMaxMaps(): ?int` + +Get maximum number of memory-mapped regions, UNIX only. +Use testFibers to get the maximum number of fibers on any platform. + + + +### `getMethodNamespaces(): array` + +Get TL namespaces. + + + +### `getMethodsNamespaced(): array` + +Get namespaced methods (method => namespace). + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null` + +Obtain a certain event handler plugin instance. + + +Parameters: + +* `$class`: `class-string` + +return T|null + + +#### See also: +* [`\danog\MadelineProto\PluginEventHandler`: Plugin event handler class.](../../danog/MadelineProto/PluginEventHandler.html) +* `\danog\MadelineProto\Ipc\EventHandlerProxy` + + + + +### `getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo` + +Gets info of the propic of a user. + + +Parameters: + +* `$data`: `mixed` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `getPsrLogger(): \Psr\Log\LoggerInterface` + +Get PSR logger. + + +#### See also: +* `\Psr\Log\LoggerInterface` + + + + +### `getPwrChat(mixed $id, bool $fullfetch = true): array` + +Get full info about peer (including full list of channel members), returns a Chat object. + + +Parameters: + +* `$id`: `mixed` Peer +* `$fullfetch`: `bool` + + +#### See also: +* [https://docs.madelineproto.xyz/Chat.html](https://docs.madelineproto.xyz/Chat.html) + + + + +### `getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat` + +Get secret chat. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + +#### See also: +* [`\danog\MadelineProto\SecretChats\SecretChat`: Represents a secret chat.](../../danog/MadelineProto/SecretChats/SecretChat.html) + + + + +### `getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage` + +Gets a secret chat message. + + +Parameters: + +* `$chatId`: `integer` Secret chat ID. +* `$randomId`: `integer` Secret chat message ID. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\SecretMessage`: Represents New encrypted message.](../../danog/MadelineProto/EventHandler/Message/SecretMessage.html) + + + + +### `getSelf(): array|false` + +Get info about the logged-in user, cached. + +Use fullGetSelf to bypass the cache. + + + +### `getSessionName(): string` + +Returns the session name. + + + +### `getSettings(): \danog\MadelineProto\Settings` + +Return current settings. + + +#### See also: +* [`\danog\MadelineProto\Settings`: Settings class used for configuring MadelineProto.](../../danog/MadelineProto/Settings.html) + + + + +### `getSponsoredMessages((int|string|array) $peer): ?array` + +Get sponsored messages for channel. +This method will return an array of [sponsored message objects](https://docs.madelineproto.xyz/API_docs/constructors/sponsoredMessage.html). + +See [the API documentation](https://core.telegram.org/api/sponsored-messages) for more info on how to handle sponsored messages. + + +Parameters: + +* `$peer`: `(int|string|array)` Channel ID, or Update, or Message, or Peer. + + + +### `getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream` + +Provide a stream for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` +* `$size`: `?int` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `getStreamPipe(): \Amp\ByteStream\Pipe` + +Obtains a pipe that can be used to upload a file from a stream. + + +#### See also: +* `\Amp\ByteStream\Pipe` + + + + +### `getTL(): \danog\MadelineProto\TL\TLInterface` + +Get TL serializer. + + +#### See also: +* [\danog\MadelineProto\TL\TLInterface](../../danog/MadelineProto/TL/TLInterface.html) + + + + +### `getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*` + +Get type of peer. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* `\danog\MadelineProto\API::PEER_TYPE_*` + + + + +### `getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list` + +Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**. + +`getUpdates` will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + + +Parameters: + +* `$params`: `array{offset?: int, limit?: int, timeout?: float}` Params + + + +### `getWebMessage(string $message): string` + +Get a message to show to the user when starting the bot. + + +Parameters: + +* `$message`: `string` + + + +### `getWebWarnings(): string` + +Get various warnings to show to the user in the web UI. + + + +### `hasAdmins(): bool` + +Check if has admins. + + + +### `hasEventHandler(): bool` + +Check if an event handler instance is present. + + + +### `hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool` + +Check if a certain event handler plugin is installed. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) + + + + +### `hasReportPeers(): bool` + +Check if has report peers. + + + +### `hasSecretChat((array|int) $chat): bool` + +Check whether secret chat exists. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `importAuthorization(array $authorization, int $mainDcID): array` + +Import authorization. + + +Parameters: + +* `$authorization`: `array` Authorization info +* `$mainDcID`: `int` Main DC ID + + + +### `inflateStripped(string $stripped): string` + +Inflate stripped photosize to full JPG payload. + + +Parameters: + +* `$stripped`: `string` Stripped photosize + + + +### `initSelfRestart(): void` + +Initialize self-restart hack. + + + +### `isAltervista(): bool` + +Whether this is altervista. + + + +### `isArrayOrAlike(mixed $var): bool` + +Check if is array or similar (traversable && countable && arrayAccess). + + +Parameters: + +* `$var`: `mixed` Value to check + + + +### `isBot(mixed $peer): bool` + +Check if the specified peer is a bot. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isForum(mixed $peer): bool` + +Check if the specified peer is a forum. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isIpc(): bool` + +Whether we're an IPC client instance. + + + +### `isIpcWorker(): bool` + +Whether we're an IPC server process (as opposed to an event handler). + + + +### `isPlayPaused(int $id): bool` + +Whether the currently playing audio file is paused. + + +Parameters: + +* `$id`: `int` + + + +### `isPremium(): bool` + +Returns whether the current user is a premium user, cached. + + + +### `isSelfBot(): bool` + +Returns whether the current user is a bot. + + + +### `isSelfUser(): bool` + +Returns whether the current user is a user. + + + +### `isTestMode(): boolean` + +Whether we're currently connected to the test DCs. + + + +### `logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void` + +Logger. + + +Parameters: + +* `$param`: `mixed` Parameter +* `$level`: `int` Logging level +* `$file`: `string` File where the message originated + + + +### `logout(): void` + +Logout the session. + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string` + +Provide a buffered reader for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `openFileAppendOnly(string $path): \Amp\File\File` + +Opens a file in append-only mode. + + +Parameters: + +* `$path`: `string` File path. + + +#### See also: +* `\Amp\File\File` + + + + +### `packDouble(float $value): string` + +Convert double to binary version. + + +Parameters: + +* `$value`: `float` Value to convert + + + +### `packSignedInt(integer $value): string` + +Convert integer to base256 signed int. + + +Parameters: + +* `$value`: `integer` Value to convert + + + +### `packSignedLong(int $value): string` + +Convert integer to base256 long. + + +Parameters: + +* `$value`: `int` Value to convert + + + +### `packUnsignedInt(int $value): string` + +Convert value to unsigned base256 int. + + +Parameters: + +* `$value`: `int` Value + + + +### `pausePlay(int $id): void` + +Pauses playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `peerIsset(mixed $id): bool` + +Check if peer is present in internal peer database. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `phoneLogin(string $number, integer $sms_type = 5): array` + +Login as user. + + +Parameters: + +* `$number`: `string` Phone number +* `$sms_type`: `integer` SMS type + + + +### `posmod(int $a, int $b): int` + +Positive modulo +Works just like the % (modulus) operator, only returns always a postive number. + + +Parameters: + +* `$a`: `int` A +* `$b`: `int` B + + + +### `processDownloadServerPing(string $path, string $payload): void` + +Internal endpoint used by the download server. + + +Parameters: + +* `$path`: `string` +* `$payload`: `string` + + + +### `qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode` + +Initiates QR code login. + +Returns a QR code login helper object, that can be used to render the QR code, display the link directly, wait for login, QR code expiration and much more. + +Returns null if we're already logged in, or if we're waiting for a password (use getAuthorization to distinguish between the two cases). + + +#### See also: +* [`\danog\MadelineProto\TL\Types\LoginQrCode`: Represents a login QR code.](../../danog/MadelineProto/TL/Types/LoginQrCode.html) + + + + +### `random(integer $length): string` + +Get secure random string of specified length. + + +Parameters: + +* `$length`: `integer` Length + + + +### `randomInt(integer $modulus = 0): int` + +Get random integer. + + +Parameters: + +* `$modulus`: `integer` Modulus + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `refreshFullPeerCache(mixed $id): void` + +Refresh full peer cache for a certain peer. + + +Parameters: + +* `$id`: `mixed` The peer to refresh + + + +### `refreshPeerCache(mixed ...$ids): void` + +Refresh peer cache for a certain peer. + + +Parameters: + +* `...$ids`: `mixed` + + + +### `report(string $message, string $parseMode = ''): void` + +Report an error to the previously set peer. + + +Parameters: + +* `$message`: `string` Error to report +* `$parseMode`: `string` Parse mode + + + +### `reportMemoryProfile(): void` + +Report memory profile with memprof. + + + +### `requestCall(mixed $user): \danog\MadelineProto\VoIP` + +Request VoIP call. + + +Parameters: + +* `$user`: `mixed` User + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `requestSecretChat(mixed $user): int` + +Request secret chat. + + +Parameters: + +* `$user`: `mixed` User to start secret chat with + + + +### `resetUpdateState(): void` + +Reset the update state and fetch all updates from the beginning. + + + +### `restart(): void` + +Restart update loop. + + + +### `resumePlay(int $id): void` + +Resumes playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `rethrow(Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `Throwable` + + +#### See also: +* `Throwable` + + + + +### `rleDecode(string $string): string` + +null-byte RLE decode. + + +Parameters: + +* `$string`: `string` Data to decode + + + +### `rleEncode(string $string): string` + +null-byte RLE encode. + + +Parameters: + +* `$string`: `string` Data to encode + + + +### `sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendCustomEvent(mixed $payload): void` + +Sends an updateCustomEvent update to the event handler. + + +Parameters: + +* `$payload`: `mixed` + + + +### `sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$duration`: `?int` +* `$width`: `?int` +* `$height`: `?int` +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a message. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` Cancellation + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>` + +Sends a message to all report peers (admins of the bot). + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$stickerSet`: `array` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `setNoop(): void` + +Set NOOP update handler, ignoring all updates. + + + +### `setReportPeers((int|string|array<(int|string)>) $userOrId): void` + +Set peer(s) where to send errors occurred in the event loop. + + +Parameters: + +* `$userOrId`: `(int|string|array<(int|string)>)` Username(s) or peer ID(s) + + + +### `setWebhook(string $webhookUrl): void` + +Set webhook update handler. + + +Parameters: + +* `$webhookUrl`: `string` Webhook URL + + + +### `skipPlay(int $id): void` + +When called, skips to the next file in the playlist. + + +Parameters: + +* `$id`: `int` + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `start(): array` + +Log in to telegram (via CLI or web). + + + +### `stop(): void` + +Stop update loop. + + + +### `stopPlay(int $id): void` + +Stops playing all files in the call, clears the main and the hold playlist. + + +Parameters: + +* `$id`: `int` + + + +### `stringToStream(string $str): \Amp\ByteStream\ReadableBuffer` + +Converts a string into an async amphp stream. + + +Parameters: + +* `$str`: `string` + + +#### See also: +* `\Amp\ByteStream\ReadableBuffer` + + + + +### `subscribeToUpdates(mixed $channel): bool` + +Subscribe to event handler updates for a channel/supergroup we're not a member of. + + +Parameters: + +* `$channel`: `mixed` Channel/supergroup to subscribe to + + +Return value: False if we were already subscribed + + +### `tdToMTProto(array $params): array` + +Convert TD to MTProto parameters. + + +Parameters: + +* `$params`: `array` Parameters + + + +### `tdToTdcli(mixed $params): array` + +Convert TD parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Parameters + + + +### `tdcliToTd(mixed $params, array $key = NULL): array` + +Convert tdcli parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Params +* `$key`: `array` Key + + + +### `testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}` + +Test fibers. + + +Parameters: + +* `$fiberCount`: `int` + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `unpackDouble(string $value): float` + +Unpack binary double. + + +Parameters: + +* `$value`: `string` Value to unpack + + + +### `unpackFileId(string $fileId): array` + +Unpack bot API file ID. + + +Parameters: + +* `$fileId`: `string` Bot API file ID + + +Return value: Unpacked file ID + + +### `unpackSignedInt(string $value): int` + +Unpack base256 signed int. + + +Parameters: + +* `$value`: `string` base256 int + + + +### `unpackSignedLong(string $value): int` + +Unpack base256 signed long. + + +Parameters: + +* `$value`: `string` base256 long + + + +### `unpackSignedLongString((string|int|array) $value): string` + +Unpack base256 signed long to string. + + +Parameters: + +* `$value`: `(string|int|array)` base256 long + + + +### `unsetEventHandler(): void` + +Unset event handler. + + + +### `update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void` + +Update the 2FA password. + +The params array can contain password, new_password, email and hint params. + + +Parameters: + +* `$params`: `array{password?: string, new_password?: string, email?: string, hint?: string}` The params + + + +### `updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void` + +Parse, update and store settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file to secret chat. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from callable. + +The callable must accept two parameters: int $offset, int $size +The callable must return a string with the contest of the file at the specified offset and size. + + +Parameters: + +* `$callable`: `callable(int, int, ?Cancellation): strin)` Callable (offset, length) => data +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable(float, float, float): voi)` Status callback +* `$seekable`: `boolean` Whether chunks can be fetched out of order +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from stream. + + +Parameters: + +* `$stream`: `mixed` PHP resource or AMPHP async stream +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Reupload telegram file. + + +Parameters: + +* `$media`: `mixed` Telegram file +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from URL. + + +Parameters: + +* `$url`: `(string|\danog\MadelineProto\FileCallbackInterface)` URL of file +* `$size`: `integer` Size of file +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>` + +Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` Class name + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) +* [`\danog\MadelineProto\EventHandlerIssue`: Represents an event handler issue.](../../danog/MadelineProto/EventHandlerIssue.html) + + + + +### `viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool` + +Mark sponsored message as read. + + +Parameters: + +* `$peer`: `(int|array)` Channel ID, or Update, or Message, or Peer. +* `$message`: `(string|array{random_id: string})` Random ID or sponsored message to mark as read. + + + +### `wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media` + +Wrap a media constructor into an abstract Media object. + + +Parameters: + +* `$media`: `array` +* `$protected`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage` + +Wrap a Message constructor into an abstract Message object. + + +Parameters: + +* `$message`: `array` +* `$scheduled`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractMessage`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/AbstractMessage.html) + + + + +### `wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned` + +Wrap a Pin constructor into an abstract Pinned object. + + +Parameters: + +* `$message`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Pinned`: Indicates that some messages were pinned/unpinned.](../../danog/MadelineProto/EventHandler/Pinned.html) + + + + +### `wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update` + +Wrap an Update constructor into an abstract Update object. + + +Parameters: + +* `$update`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../danog/MadelineProto/EventHandler/Update.html) + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/AsyncTools.md b/docs/PHP/danog/MadelineProto/AsyncTools.md new file mode 100644 index 0000000000..cac1c59709 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/AsyncTools.md @@ -0,0 +1,380 @@ +--- +title: "danog\\MadelineProto\\AsyncTools: Async tools." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\AsyncTools` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Async tools. + + + + +## Constants +* `danog\MadelineProto\AsyncTools::ALL_MIMES`: + + +## Method list: +* [`rethrow(\Throwable $e): void`](#rethrow) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`sleep(float $time): void`](#sleep) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`echo(string $string): void`](#echo) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) + +## Methods: +### `rethrow(\Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `\Throwable` + + +#### See also: +* `\Throwable` + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/BotApiFileId.md b/docs/PHP/danog/MadelineProto/BotApiFileId.md new file mode 100644 index 0000000000..5ce1c40b56 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/BotApiFileId.md @@ -0,0 +1,48 @@ +--- +title: "danog\\MadelineProto\\BotApiFileId: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc..." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\BotApiFileId` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates a bot API file ID to upload using sendDocument, sendPhoto etc... + + + +## Properties +* `$fileId`: `string` +* `$size`: `int` +* `$fileName`: `string` +* `$protected`: `bool` + +## Method list: +* [`__construct(string $fileId, int<1, max> $size, string $fileName, bool $protected)`](#__construct) + +## Methods: +### `__construct(string $fileId, int<1, max> $size, string $fileName, bool $protected)` + + + + +Parameters: + +* `$fileId`: `string` The file ID +* `$size`: `int<1, max>` The file size +* `$fileName`: `string` The original file name +* `$protected`: `bool` Whether the original file is protected + + +#### See also: +* `max` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Broadcast/Action.md b/docs/PHP/danog/MadelineProto/Broadcast/Action.md new file mode 100644 index 0000000000..d4671fdc57 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Broadcast/Action.md @@ -0,0 +1,42 @@ +--- +title: "danog\\MadelineProto\\Broadcast\\Action: Interface that represents a broadcast action." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Broadcast\Action` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Interface that represents a broadcast action. + + + + +## Method list: +* [`act(integer $broadcastId, integer $peer, \Amp\Cancellation $cancellation): void`](#act) + +## Methods: +### `act(integer $broadcastId, integer $peer, \Amp\Cancellation $cancellation): void` + +Do something with a single peer. + + +Parameters: + +* `$broadcastId`: `integer` Broadcast ID +* `$peer`: `integer` Broadcast peer +* `$cancellation`: `\Amp\Cancellation` Cancellation token + + +#### See also: +* `\Amp\Cancellation` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Broadcast/Filter.md b/docs/PHP/danog/MadelineProto/Broadcast/Filter.md new file mode 100644 index 0000000000..f7ca9ff7ef --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Broadcast/Filter.md @@ -0,0 +1,54 @@ +--- +title: "danog\\MadelineProto\\Broadcast\\Filter: Broadcast filter." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Broadcast\Filter` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Broadcast filter. + + + +## Properties +* `$allowUsers`: `bool` +* `$allowBots`: `bool` +* `$allowGroups`: `bool` +* `$allowChannels`: `bool` +* `$blacklist`: `list` +* `$whitelist`: `(list | null)` If null all IDs are allowed (*) + +## Method list: +* [`__construct(bool $allowUsers, bool $allowBots, bool $allowGroups, bool $allowChannels, array $blacklist = [], ?array $whitelist = NULL)`](#__construct) +* [`default(): self`](#default) + +## Methods: +### `__construct(bool $allowUsers, bool $allowBots, bool $allowGroups, bool $allowChannels, array $blacklist = [], ?array $whitelist = NULL)` + + + + +Parameters: + +* `$allowUsers`: `bool` +* `$allowBots`: `bool` +* `$allowGroups`: `bool` +* `$allowChannels`: `bool` +* `$blacklist`: `array` +* `$whitelist`: `?array` + + + +### `default(): self` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Broadcast/Progress.md b/docs/PHP/danog/MadelineProto/Broadcast/Progress.md new file mode 100644 index 0000000000..51b38d975e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Broadcast/Progress.md @@ -0,0 +1,26 @@ +--- +title: "danog\\MadelineProto\\Broadcast\\Progress: Broadcast progress." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Broadcast\Progress` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Broadcast progress. + + + +## Properties +* `$percent`: `int` Completion percentage. +* `$broadcastId`: `int` Broadcast ID +* `$status`: `danog\MadelineProto\Broadcast\Status` Broadcast status +* `$pendingCount`: `int` Pending number of peers +* `$successCount`: `int` Successful number of peers +* `$failCount`: `int` Failed number of peers +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Broadcast/Status.md b/docs/PHP/danog/MadelineProto/Broadcast/Status.md new file mode 100644 index 0000000000..cda4bf24e2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Broadcast/Status.md @@ -0,0 +1,67 @@ +--- +title: "danog\\MadelineProto\\Broadcast\\Status: Broadcast status." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Broadcast\Status` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Broadcast status. + + + + +## Constants +* `danog\MadelineProto\Broadcast\Status::GATHERING_PEERS`: + +* `danog\MadelineProto\Broadcast\Status::BROADCASTING`: + +* `danog\MadelineProto\Broadcast\Status::FINISHED`: + +* `danog\MadelineProto\Broadcast\Status::CANCELLED`: + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Conversion.md b/docs/PHP/danog/MadelineProto/Conversion.md new file mode 100644 index 0000000000..7b0e90a967 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Conversion.md @@ -0,0 +1,108 @@ +--- +title: "danog\\MadelineProto\\Conversion: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Conversion` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + + + + + +## Properties +* `$tdesktop_base_path`: `mixed` +* `$tdesktop_user_base_path`: `mixed` +* `$tdesktop_key`: `mixed` + +## Method list: +* [`importAuthorization(array $authorization, int $main_dc_id, string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): \danog\MadelineProto\API`](#importAuthorization) +* [`telethon(string $session, string $new_session, (\danog\MadelineProto\SettingsAbstract|null) $settings = NULL): \danog\MadelineProto\API`](#telethon) +* [`pyrogram(string $session, string $new_session, (\danog\MadelineProto\SettingsAbstract|null) $settings = NULL): \danog\MadelineProto\API`](#pyrogram) +* [`zerobias(array|string $session, string $new_session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): \danog\MadelineProto\API`](#zerobias) + +## Methods: +### `importAuthorization(array $authorization, int $main_dc_id, string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): \danog\MadelineProto\API` + +Import authorization from raw auth key and DC id. + + +Parameters: + +* `$authorization`: `array` Authorization info, DC ID => auth key +* `$main_dc_id`: `int` +* `$session`: `string` +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` +* [`\danog\MadelineProto\API`: Main API wrapper for MadelineProto.](../../danog/MadelineProto/API.html) + + + + +### `telethon(string $session, string $new_session, (\danog\MadelineProto\SettingsAbstract|null) $settings = NULL): \danog\MadelineProto\API` + +Convert telethon session. + + +Parameters: + +* `$session`: `string` Telethon session file +* `$new_session`: `string` MadelineProto session directory to create +* `$settings`: `(\danog\MadelineProto\SettingsAbstract|null)` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` +* [`\danog\MadelineProto\API`: Main API wrapper for MadelineProto.](../../danog/MadelineProto/API.html) + + + + +### `pyrogram(string $session, string $new_session, (\danog\MadelineProto\SettingsAbstract|null) $settings = NULL): \danog\MadelineProto\API` + +Convert pyrogram session. + + +Parameters: + +* `$session`: `string` Pyrogram session file +* `$new_session`: `string` MadelineProto session directory to create +* `$settings`: `(\danog\MadelineProto\SettingsAbstract|null)` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` +* [`\danog\MadelineProto\API`: Main API wrapper for MadelineProto.](../../danog/MadelineProto/API.html) + + + + +### `zerobias(array|string $session, string $new_session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): \danog\MadelineProto\API` + + + + +Parameters: + +* `$session`: `array|string` +* `$new_session`: `string` +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` +* [`\danog\MadelineProto\API`: Main API wrapper for MadelineProto.](../../danog/MadelineProto/API.html) + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler.md b/docs/PHP/danog/MadelineProto/EventHandler.md new file mode 100644 index 0000000000..7fd378069f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler.md @@ -0,0 +1,3318 @@ +--- +title: "danog\\MadelineProto\\EventHandler: Event handler." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Event handler. + + + +## Properties +* `$auth`: `\danog\MadelineProto\Namespace\Auth` +* `$account`: `\danog\MadelineProto\Namespace\Account` +* `$users`: `\danog\MadelineProto\Namespace\Users` +* `$contacts`: `\danog\MadelineProto\Namespace\Contacts` +* `$messages`: `\danog\MadelineProto\Namespace\Messages` +* `$updates`: `\danog\MadelineProto\Namespace\Updates` +* `$photos`: `\danog\MadelineProto\Namespace\Photos` +* `$upload`: `\danog\MadelineProto\Namespace\Upload` +* `$help`: `\danog\MadelineProto\Namespace\Help` +* `$channels`: `\danog\MadelineProto\Namespace\Channels` +* `$bots`: `\danog\MadelineProto\Namespace\Bots` +* `$payments`: `\danog\MadelineProto\Namespace\Payments` +* `$stickers`: `\danog\MadelineProto\Namespace\Stickers` +* `$phone`: `\danog\MadelineProto\Namespace\Phone` +* `$langpack`: `\danog\MadelineProto\Namespace\Langpack` +* `$folders`: `\danog\MadelineProto\Namespace\Folders` +* `$stats`: `\danog\MadelineProto\Namespace\Stats` +* `$chatlists`: `\danog\MadelineProto\Namespace\Chatlists` +* `$stories`: `\danog\MadelineProto\Namespace\Stories` +* `$premium`: `\danog\MadelineProto\Namespace\Premium` +* `$smsjobs`: `\danog\MadelineProto\Namespace\Smsjobs` +* `$fragment`: `\danog\MadelineProto\Namespace\Fragment` + +## Method list: +* [`startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoop) +* [`startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoopBot) +* [`getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop`](#getPeriodicLoop) +* [`getPeriodicLoops(): array`](#getPeriodicLoops) +* [`getReportPeers(): (string|int|array<(string|int)>)`](#getReportPeers) +* [`getPluginPaths(): (non-empty-string|non-empty-list|null)`](#getPluginPaths) +* [`getPlugins(): array>`](#getPlugins) +* [`MTProtoToBotAPI(array $data): array`](#MTProtoToBotAPI) +* [`MTProtoToTd(mixed $params): array`](#MTProtoToTd) +* [`MTProtoToTdcli(mixed $params): array`](#MTProtoToTdcli) +* [`acceptCall(int $id): void`](#acceptCall) +* [`acceptSecretChat(array $params): void`](#acceptSecretChat) +* [`arr(mixed ...$params): array`](#arr) +* [`base64urlDecode(string $data): string`](#base64urlDecode) +* [`base64urlEncode(string $data): string`](#base64urlEncode) +* [`botAPIToMTProto(array $arguments): array`](#botAPIToMTProto) +* [`botLogin(string $token): ?array`](#botLogin) +* [`broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int`](#broadcastCustom) +* [`broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastForwardMessages) +* [`broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastMessages) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null`](#callGetCurrent) +* [`callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void`](#callPlay) +* [`callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void`](#callPlayOnHold) +* [`callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void`](#callSetOutput) +* [`canConvertOgg(): bool`](#canConvertOgg) +* [`canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool`](#canUseFFmpeg) +* [`cancelBroadcast(integer $id): void`](#cancelBroadcast) +* [`closeConnection(string $message): void`](#closeConnection) +* [`complete2faLogin(string $password): array`](#complete2faLogin) +* [`completePhoneLogin(string $code): array`](#completePhoneLogin) +* [`completeSignup(string $first_name, string $last_name = ''): array`](#completeSignup) +* [`discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void`](#discardCall) +* [`discardSecretChat(int $chat): void`](#discardSecretChat) +* [`downloadServer(string $session): void`](#downloadServer) +* [`downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToBrowser) +* [`downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToCallable) +* [`downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToDir) +* [`downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToFile) +* [`downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response`](#downloadToResponse) +* [`downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#downloadToReturnedStream) +* [`downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToStream) +* [`echo(string $string): void`](#echo) +* [`end(array $what): T`](#end) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`exportAuthorization(): array{0: (int|string), 1: string}`](#exportAuthorization) +* [`extractBotAPIFile(array $info): ?array`](#extractBotAPIFile) +* [`extractMessage(array $updates): array`](#extractMessage) +* [`extractMessageId(array $updates): int`](#extractMessageId) +* [`extractMessageUpdate(array $updates): array`](#extractMessageUpdate) +* [`extractUpdates(array $updates): array`](#extractUpdates) +* [`fileGetContents(string $url): string`](#fileGetContents) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`fullChatLastUpdated(mixed $id): int`](#fullChatLastUpdated) +* [`fullGetSelf(): array|false`](#fullGetSelf) +* [`genVectorHash(array $longs): string`](#genVectorHash) +* [`getAdminIds(): array`](#getAdminIds) +* [`getAllCalls(): array`](#getAllCalls) +* [`getAllMethods(): array`](#getAllMethods) +* [`getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)`](#getAuthorization) +* [`getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress`](#getBroadcastProgress) +* [`getCachedConfig(): array`](#getCachedConfig) +* [`getCall(int $id): ?\danog\MadelineProto\VoIP`](#getCall) +* [`getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP`](#getCallByPeer) +* [`getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState`](#getCallState) +* [`getCdnConfig(): void`](#getCdnConfig) +* [`getConfig(array $config = []): array`](#getConfig) +* [`getDNSClient(): \Amp\Dns\DnsResolver`](#getDNSClient) +* [`getDhConfig(): array`](#getDhConfig) +* [`getDialogIds(): list`](#getDialogIds) +* [`getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}`](#getDownloadInfo) +* [`getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string`](#getDownloadLink) +* [`getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)`](#getEventHandler) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getFileInfo(mixed $constructor): array`](#getFileInfo) +* [`getFullDialogs(): array`](#getFullDialogs) +* [`getFullInfo(mixed $id): array`](#getFullInfo) +* [`getHTTPClient(): \Amp\Http\Client\HttpClient`](#getHTTPClient) +* [`getHint(): string`](#getHint) +* [`getId(mixed $id): int`](#getId) +* [`getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))`](#getInfo) +* [`getLogger(): \danog\MadelineProto\Logger`](#getLogger) +* [`getMaps(): ?int`](#getMaps) +* [`getMaxMaps(): ?int`](#getMaxMaps) +* [`getMethodNamespaces(): array`](#getMethodNamespaces) +* [`getMethodsNamespaced(): array`](#getMethodsNamespaced) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null`](#getPlugin) +* [`getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo`](#getPropicInfo) +* [`getPsrLogger(): \Psr\Log\LoggerInterface`](#getPsrLogger) +* [`getPwrChat(mixed $id, bool $fullfetch = true): array`](#getPwrChat) +* [`getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat`](#getSecretChat) +* [`getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage`](#getSecretMessage) +* [`getSelf(): array|false`](#getSelf) +* [`getSessionName(): string`](#getSessionName) +* [`getSettings(): \danog\MadelineProto\Settings`](#getSettings) +* [`getSponsoredMessages((int|string|array) $peer): ?array`](#getSponsoredMessages) +* [`getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`getStreamPipe(): \Amp\ByteStream\Pipe`](#getStreamPipe) +* [`getTL(): \danog\MadelineProto\TL\TLInterface`](#getTL) +* [`getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*`](#getType) +* [`getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list`](#getUpdates) +* [`getWebMessage(string $message): string`](#getWebMessage) +* [`getWebWarnings(): string`](#getWebWarnings) +* [`hasAdmins(): bool`](#hasAdmins) +* [`hasEventHandler(): bool`](#hasEventHandler) +* [`hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool`](#hasPlugin) +* [`hasReportPeers(): bool`](#hasReportPeers) +* [`hasSecretChat((array|int) $chat): bool`](#hasSecretChat) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`importAuthorization(array $authorization, int $mainDcID): array`](#importAuthorization) +* [`inflateStripped(string $stripped): string`](#inflateStripped) +* [`initSelfRestart(): void`](#initSelfRestart) +* [`isAltervista(): bool`](#isAltervista) +* [`isArrayOrAlike(mixed $var): bool`](#isArrayOrAlike) +* [`isBot(mixed $peer): bool`](#isBot) +* [`isForum(mixed $peer): bool`](#isForum) +* [`isIpc(): bool`](#isIpc) +* [`isIpcWorker(): bool`](#isIpcWorker) +* [`isPlayPaused(int $id): bool`](#isPlayPaused) +* [`isPremium(): bool`](#isPremium) +* [`isSelfBot(): bool`](#isSelfBot) +* [`isSelfUser(): bool`](#isSelfUser) +* [`isTestMode(): boolean`](#isTestMode) +* [`logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void`](#logger) +* [`logout(): void`](#logout) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string`](#openBuffered) +* [`openFileAppendOnly(string $path): \Amp\File\File`](#openFileAppendOnly) +* [`packDouble(float $value): string`](#packDouble) +* [`packSignedInt(integer $value): string`](#packSignedInt) +* [`packSignedLong(int $value): string`](#packSignedLong) +* [`packUnsignedInt(int $value): string`](#packUnsignedInt) +* [`pausePlay(int $id): void`](#pausePlay) +* [`peerIsset(mixed $id): bool`](#peerIsset) +* [`phoneLogin(string $number, integer $sms_type = 5): array`](#phoneLogin) +* [`posmod(int $a, int $b): int`](#posmod) +* [`processDownloadServerPing(string $path, string $payload): void`](#processDownloadServerPing) +* [`qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode`](#qrLogin) +* [`random(integer $length): string`](#random) +* [`randomInt(integer $modulus = 0): int`](#randomInt) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`refreshFullPeerCache(mixed $id): void`](#refreshFullPeerCache) +* [`refreshPeerCache(mixed ...$ids): void`](#refreshPeerCache) +* [`report(string $message, string $parseMode = ''): void`](#report) +* [`reportMemoryProfile(): void`](#reportMemoryProfile) +* [`requestCall(mixed $user): \danog\MadelineProto\VoIP`](#requestCall) +* [`requestSecretChat(mixed $user): int`](#requestSecretChat) +* [`resetUpdateState(): void`](#resetUpdateState) +* [`restart(): void`](#restart) +* [`resumePlay(int $id): void`](#resumePlay) +* [`rethrow(Throwable $e): void`](#rethrow) +* [`rleDecode(string $string): string`](#rleDecode) +* [`rleEncode(string $string): string`](#rleEncode) +* [`sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendAudio) +* [`sendCustomEvent(mixed $payload): void`](#sendCustomEvent) +* [`sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocument) +* [`sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocumentPhoto) +* [`sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendGif) +* [`sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendMessage) +* [`sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>`](#sendMessageToAdmins) +* [`sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendPhoto) +* [`sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendSticker) +* [`sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVideo) +* [`sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVoice) +* [`setNoop(): void`](#setNoop) +* [`setReportPeers((int|string|array<(int|string)>) $userOrId): void`](#setReportPeers) +* [`setWebhook(string $webhookUrl): void`](#setWebhook) +* [`skipPlay(int $id): void`](#skipPlay) +* [`sleep(float $time): void`](#sleep) +* [`start(): array`](#start) +* [`stop(): void`](#stop) +* [`stopPlay(int $id): void`](#stopPlay) +* [`stringToStream(string $str): \Amp\ByteStream\ReadableBuffer`](#stringToStream) +* [`subscribeToUpdates(mixed $channel): bool`](#subscribeToUpdates) +* [`tdToMTProto(array $params): array`](#tdToMTProto) +* [`tdToTdcli(mixed $params): array`](#tdToTdcli) +* [`tdcliToTd(mixed $params, array $key = NULL): array`](#tdcliToTd) +* [`testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}`](#testFibers) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`unpackDouble(string $value): float`](#unpackDouble) +* [`unpackFileId(string $fileId): array`](#unpackFileId) +* [`unpackSignedInt(string $value): int`](#unpackSignedInt) +* [`unpackSignedLong(string $value): int`](#unpackSignedLong) +* [`unpackSignedLongString((string|int|array) $value): string`](#unpackSignedLongString) +* [`unsetEventHandler(): void`](#unsetEventHandler) +* [`update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void`](#update2fa) +* [`updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void`](#updateSettings) +* [`upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#upload) +* [`uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadEncrypted) +* [`uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromCallable) +* [`uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromStream) +* [`uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromTgfile) +* [`uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromUrl) +* [`validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>`](#validateEventHandlerClass) +* [`viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool`](#viewSponsoredMessage) +* [`wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media`](#wrapMedia) +* [`wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage`](#wrapMessage) +* [`wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned`](#wrapPin) +* [`wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update`](#wrapUpdate) +* [`initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void`](#initDbProperties) +* [`saveDbProperties(): void`](#saveDbProperties) + +## Methods: +### `startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto as a bot and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$token`: `string` Bot token +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop` + +Obtain a PeriodicLoop instance created by the Cron attribute. + + +Parameters: + +* `$name`: `string` Method name + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getPeriodicLoops(): array` + +Obtain all PeriodicLoop instances created by the Cron attribute. + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getReportPeers(): (string|int|array<(string|int)>)` + +Get peers where to send error reports. + + + +### `getPluginPaths(): (non-empty-string|non-empty-list|null)` + +Obtain a path or a list of paths that will be recursively searched for plugins. + +Plugin filenames end with Plugin.php, and will be included automatically. + + +#### See also: +* `non-empty-string` +* `non-empty-list` + + + + +### `getPlugins(): array>` + +Obtain a list of plugin event handlers to use, in addition with those found by getPluginPath. + + + +### `MTProtoToBotAPI(array $data): array` + +Convert MTProto parameters to bot API parameters. + + +Parameters: + +* `$data`: `array` Data + + + +### `MTProtoToTd(mixed $params): array` + +MTProto to TD params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `MTProtoToTdcli(mixed $params): array` + +MTProto to TDCLI params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `acceptCall(int $id): void` + +Accept call. + + +Parameters: + +* `$id`: `int` + + + +### `acceptSecretChat(array $params): void` + +Accept secret chat. + + +Parameters: + +* `$params`: `array` Secret chat ID + + + +### `arr(mixed ...$params): array` + +Create array. + + +Parameters: + +* `...$params`: `mixed` Params + + + +### `base64urlDecode(string $data): string` + +base64URL decode. + + +Parameters: + +* `$data`: `string` Data to decode + + + +### `base64urlEncode(string $data): string` + +Base64URL encode. + + +Parameters: + +* `$data`: `string` Data to encode + + + +### `botAPIToMTProto(array $arguments): array` + +Convert bot API parameters to MTProto parameters. + + +Parameters: + +* `$arguments`: `array` Arguments + + + +### `botLogin(string $token): ?array` + +Login as bot. + + +Parameters: + +* `$token`: `string` Bot token + + + +### `broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int` + +Executes a custom broadcast action with all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$action`: `\danog\MadelineProto\Broadcast\Action` A custom, serializable Action class that will be called once for every peer. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Action`: Interface that represents a broadcast action.](../../danog/MadelineProto/Broadcast/Action.html) +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Forwards a list of messages to all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$from_peer`: `mixed` Bot API ID or Update, from where to forward the messages. +* `$message_ids`: `list` IDs of the messages to forward. +* `$drop_author`: `bool` If true, will forward messages without quoting the original author. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Sends a list of messages to all peers (users, chats, channels) of the bot. + +A simplified version of this method is also available: broadcastForwardMessages can work with pre-prepared messages. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$messages`: `array` The messages to send: an array of arrays, containing parameters to pass to messages.sendMessage. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null` + +Get the file that is currently being played. + +Will return a string with the object ID of the stream if we're currently playing a stream, otherwise returns the related LocalFile or RemoteUrl. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) + + + + +### `callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void` + +Play file in call. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void` + +Play files on hold in call. + + +Parameters: + +* `$id`: `int` +* `...$files`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void` + +Set output file or stream for incoming OPUS audio packets in a call. + +Will write an OGG OPUS stream to the specified file or stream. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* `\Amp\ByteStream\WritableStream` + + + + +### `canConvertOgg(): bool` + +Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot. + + + +### `canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool` + +Whether we can convert any audio/video file using ffmpeg. + + +Parameters: + +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `cancelBroadcast(integer $id): void` + +Cancel a running broadcast. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + + +### `closeConnection(string $message): void` + +Close connection with client, connected via web. + + +Parameters: + +* `$message`: `string` Message + + + +### `complete2faLogin(string $password): array` + +Complete 2FA login. + + +Parameters: + +* `$password`: `string` Password + + + +### `completePhoneLogin(string $code): array` + +Complet user login using login code. + + +Parameters: + +* `$code`: `string` Login code + + + +### `completeSignup(string $first_name, string $last_name = ''): array` + +Complete signup to Telegram. + + +Parameters: + +* `$first_name`: `string` First name +* `$last_name`: `string` Last name + + + +### `discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void` + +Discard call. + + +Parameters: + +* `$id`: `int` +* `$reason`: `\danog\MadelineProto\VoIP\DiscardReason` +* `$rating`: `int<1, 5>` Call rating in stars +* `$comment`: `string` Additional comment on call quality. + + +#### See also: +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `discardSecretChat(int $chat): void` + +Discard secret chat. + + +Parameters: + +* `$chat`: `int` Secret chat ID + + + +### `downloadServer(string $session): void` + +Downloads a file to the browser using the specified session file. + + +Parameters: + +* `$session`: `string` + + + +### `downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to browser. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$cb`: `(null|callable)` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Cancellation` + + + + +### `downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to callable. +The callable must accept two parameters: string $payload, int $offset +The callable will be called (possibly out of order, depending on the value of $seekable). + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$callable`: `(callable|\danog\MadelineProto\FileCallbackInterface)` Chunk callback +* `$cb`: `callable` Status callback +* `$seekable`: `bool` Whether the callable can be called out of order +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to stop downloading (inclusive) +* `$part_size`: `int` Size of each chunk +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file to directory. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$dir`: `(string|\danog\MadelineProto\FileCallbackInterface)` Directory where to download the file +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$file`: `(string|\danog\MadelineProto\FileCallbackInterface)` Downloaded file path +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response` + +Download file to amphp/http-server response. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$request`: `\Amp\Http\Server\Request` Request +* `$cb`: `callable` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Http\Server\Request` +* `\Amp\Cancellation` +* `\Amp\Http\Server\Response` + + + + +### `downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Download file to an amphp stream, returning it. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to stream. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$stream`: `(mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream)` Stream where to download file +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `resource` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `end(array $what): T` + +Get final element of array. + + +Parameters: + +* `$what`: `array` Array + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `exportAuthorization(): array{0: (int|string), 1: string}` + +Export authorization. + + + +### `extractBotAPIFile(array $info): ?array` + +Extract file info from bot API message. + + +Parameters: + +* `$info`: `array` Bot API message object + + + +### `extractMessage(array $updates): array` + +Extract a message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageId(array $updates): int` + +Extract a message ID from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageUpdate(array $updates): array` + +Extract an update message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractUpdates(array $updates): array` + +Extract Update constructors from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `fileGetContents(string $url): string` + +Get contents of remote file asynchronously. + + +Parameters: + +* `$url`: `string` URL + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `fullChatLastUpdated(mixed $id): int` + +When was full info for this chat last cached. + + +Parameters: + +* `$id`: `mixed` Chat ID + + + +### `fullGetSelf(): array|false` + +Get info about the logged-in user, not cached. + + + +### `genVectorHash(array $longs): string` + +Generate MTProto vector hash. + +Returns a vector hash. + + +Parameters: + +* `$longs`: `array` IDs + + + +### `getAdminIds(): array` + +Get admin IDs (equal to all user report peers). + + + +### `getAllCalls(): array` + +Get all pending and running calls, indexed by user ID. + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getAllMethods(): array` + +Get full list of MTProto and API methods. + + + +### `getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)` + +Get authorization info. + + +#### See also: +* `\danog\MadelineProto\API::NOT_LOGGED_IN` +* `\danog\MadelineProto\API::WAITING_CODE` +* `\danog\MadelineProto\API::WAITING_SIGNUP` +* `\danog\MadelineProto\API::WAITING_PASSWORD` +* `\danog\MadelineProto\API::LOGGED_IN` +* `API::LOGGED_OUT` + + + + +### `getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress` + +Get the progress of a currently running broadcast. + +Will return null if the broadcast doesn't exist, has already completed or was cancelled. + +Use updateBroadcastProgress updates to get real-time progress status without polling. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Progress`: Broadcast progress.](../../danog/MadelineProto/Broadcast/Progress.html) + + + + +### `getCachedConfig(): array` + +Get cached server-side config. + + + +### `getCall(int $id): ?\danog\MadelineProto\VoIP` + +Get phone call information. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP` + +Get the phone call with the specified user ID. + + +Parameters: + +* `$userId`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState` + +Get call state. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [\danog\MadelineProto\VoIP\CallState](../../danog/MadelineProto/VoIP/CallState.html) + + + + +### `getCdnConfig(): void` + +Store RSA keys for CDN datacenters. + + + +### `getConfig(array $config = []): array` + +Get cached (or eventually re-fetch) server-side config. + + +Parameters: + +* `$config`: `array` Current config + + + +### `getDNSClient(): \Amp\Dns\DnsResolver` + +Get async DNS client. + + +#### See also: +* `\Amp\Dns\DnsResolver` + + + + +### `getDhConfig(): array` + +Get diffie-hellman configuration. + + + +### `getDialogIds(): list` + +Get dialog IDs. + + + +### `getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}` + +Get download info of file +Returns an array with the following structure:. + +`$info['ext']` - The file extension +`$info['name']` - The file name, without the extension +`$info['mime']` - The file mime type +`$info['size']` - The file size + + +Parameters: + +* `$messageMedia`: `mixed` File ID + + + +### `getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string` + +Get download link of media file. + + +Parameters: + +* `$media`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string` +* `$scriptUrl`: `?string` +* `$size`: `?int` +* `$name`: `?string` +* `$mime`: `?string` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)` + +Get event handler (or plugin instance). + + +Parameters: + +* `$class`: `(class-string|null)` + + +#### See also: +* `\danog\MadelineProto\Ipc\EventHandlerProxy` +* `\__PHP_Incomplete_Class` + + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getFileInfo(mixed $constructor): array` + +Get info about file. + + +Parameters: + +* `$constructor`: `mixed` File ID + + + +### `getFullDialogs(): array` + +Get full info of all dialogs. + +Bots should use getDialogIds, instead. + + + +### `getFullInfo(mixed $id): array` + +Get full info about peer, returns an FullInfo object. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* [https://docs.madelineproto.xyz/FullInfo.html](https://docs.madelineproto.xyz/FullInfo.html) + + + + +### `getHTTPClient(): \Amp\Http\Client\HttpClient` + +Get async HTTP client. + + +#### See also: +* `\Amp\Http\Client\HttpClient` + + + + +### `getHint(): string` + +Get current password hint. + + + +### `getId(mixed $id): int` + +Get the bot API ID of a peer. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))` + +Get info about peer, returns an Info object. + +If passed a secret chat ID, returns information about the user, not about the secret chat. +Use getSecretChat to return information about the secret chat. + + +Parameters: + +* `$id`: `mixed` Peer +* `$type`: `\danog\MadelineProto\API::INFO_TYPE_*` Whether to generate an Input*, an InputPeer or the full set of constructors + + +#### See also: +* [https://docs.madelineproto.xyz/Info.html](https://docs.madelineproto.xyz/Info.html) +* `\danog\MadelineProto\API::INFO_TYPE_*` + + + + +### `getLogger(): \danog\MadelineProto\Logger` + +Get logger. + + +#### See also: +* [`\danog\MadelineProto\Logger`: Logger class.](../../danog/MadelineProto/Logger.html) + + + + +### `getMaps(): ?int` + +Get current number of memory-mapped regions, UNIX only. + + + +### `getMaxMaps(): ?int` + +Get maximum number of memory-mapped regions, UNIX only. +Use testFibers to get the maximum number of fibers on any platform. + + + +### `getMethodNamespaces(): array` + +Get TL namespaces. + + + +### `getMethodsNamespaced(): array` + +Get namespaced methods (method => namespace). + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null` + +Obtain a certain event handler plugin instance. + + +Parameters: + +* `$class`: `class-string` + +return T|null + + +#### See also: +* [`\danog\MadelineProto\PluginEventHandler`: Plugin event handler class.](../../danog/MadelineProto/PluginEventHandler.html) +* `\danog\MadelineProto\Ipc\EventHandlerProxy` + + + + +### `getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo` + +Gets info of the propic of a user. + + +Parameters: + +* `$data`: `mixed` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `getPsrLogger(): \Psr\Log\LoggerInterface` + +Get PSR logger. + + +#### See also: +* `\Psr\Log\LoggerInterface` + + + + +### `getPwrChat(mixed $id, bool $fullfetch = true): array` + +Get full info about peer (including full list of channel members), returns a Chat object. + + +Parameters: + +* `$id`: `mixed` Peer +* `$fullfetch`: `bool` + + +#### See also: +* [https://docs.madelineproto.xyz/Chat.html](https://docs.madelineproto.xyz/Chat.html) + + + + +### `getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat` + +Get secret chat. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + +#### See also: +* [`\danog\MadelineProto\SecretChats\SecretChat`: Represents a secret chat.](../../danog/MadelineProto/SecretChats/SecretChat.html) + + + + +### `getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage` + +Gets a secret chat message. + + +Parameters: + +* `$chatId`: `integer` Secret chat ID. +* `$randomId`: `integer` Secret chat message ID. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\SecretMessage`: Represents New encrypted message.](../../danog/MadelineProto/EventHandler/Message/SecretMessage.html) + + + + +### `getSelf(): array|false` + +Get info about the logged-in user, cached. + +Use fullGetSelf to bypass the cache. + + + +### `getSessionName(): string` + +Returns the session name. + + + +### `getSettings(): \danog\MadelineProto\Settings` + +Return current settings. + + +#### See also: +* [`\danog\MadelineProto\Settings`: Settings class used for configuring MadelineProto.](../../danog/MadelineProto/Settings.html) + + + + +### `getSponsoredMessages((int|string|array) $peer): ?array` + +Get sponsored messages for channel. +This method will return an array of [sponsored message objects](https://docs.madelineproto.xyz/API_docs/constructors/sponsoredMessage.html). + +See [the API documentation](https://core.telegram.org/api/sponsored-messages) for more info on how to handle sponsored messages. + + +Parameters: + +* `$peer`: `(int|string|array)` Channel ID, or Update, or Message, or Peer. + + + +### `getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream` + +Provide a stream for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` +* `$size`: `?int` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `getStreamPipe(): \Amp\ByteStream\Pipe` + +Obtains a pipe that can be used to upload a file from a stream. + + +#### See also: +* `\Amp\ByteStream\Pipe` + + + + +### `getTL(): \danog\MadelineProto\TL\TLInterface` + +Get TL serializer. + + +#### See also: +* [\danog\MadelineProto\TL\TLInterface](../../danog/MadelineProto/TL/TLInterface.html) + + + + +### `getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*` + +Get type of peer. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* `\danog\MadelineProto\API::PEER_TYPE_*` + + + + +### `getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list` + +Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**. + +`getUpdates` will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + + +Parameters: + +* `$params`: `array{offset?: int, limit?: int, timeout?: float}` Params + + + +### `getWebMessage(string $message): string` + +Get a message to show to the user when starting the bot. + + +Parameters: + +* `$message`: `string` + + + +### `getWebWarnings(): string` + +Get various warnings to show to the user in the web UI. + + + +### `hasAdmins(): bool` + +Check if has admins. + + + +### `hasEventHandler(): bool` + +Check if an event handler instance is present. + + + +### `hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool` + +Check if a certain event handler plugin is installed. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) + + + + +### `hasReportPeers(): bool` + +Check if has report peers. + + + +### `hasSecretChat((array|int) $chat): bool` + +Check whether secret chat exists. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `importAuthorization(array $authorization, int $mainDcID): array` + +Import authorization. + + +Parameters: + +* `$authorization`: `array` Authorization info +* `$mainDcID`: `int` Main DC ID + + + +### `inflateStripped(string $stripped): string` + +Inflate stripped photosize to full JPG payload. + + +Parameters: + +* `$stripped`: `string` Stripped photosize + + + +### `initSelfRestart(): void` + +Initialize self-restart hack. + + + +### `isAltervista(): bool` + +Whether this is altervista. + + + +### `isArrayOrAlike(mixed $var): bool` + +Check if is array or similar (traversable && countable && arrayAccess). + + +Parameters: + +* `$var`: `mixed` Value to check + + + +### `isBot(mixed $peer): bool` + +Check if the specified peer is a bot. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isForum(mixed $peer): bool` + +Check if the specified peer is a forum. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isIpc(): bool` + +Whether we're an IPC client instance. + + + +### `isIpcWorker(): bool` + +Whether we're an IPC server process (as opposed to an event handler). + + + +### `isPlayPaused(int $id): bool` + +Whether the currently playing audio file is paused. + + +Parameters: + +* `$id`: `int` + + + +### `isPremium(): bool` + +Returns whether the current user is a premium user, cached. + + + +### `isSelfBot(): bool` + +Returns whether the current user is a bot. + + + +### `isSelfUser(): bool` + +Returns whether the current user is a user. + + + +### `isTestMode(): boolean` + +Whether we're currently connected to the test DCs. + + + +### `logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void` + +Logger. + + +Parameters: + +* `$param`: `mixed` Parameter +* `$level`: `int` Logging level +* `$file`: `string` File where the message originated + + + +### `logout(): void` + +Logout the session. + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string` + +Provide a buffered reader for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `openFileAppendOnly(string $path): \Amp\File\File` + +Opens a file in append-only mode. + + +Parameters: + +* `$path`: `string` File path. + + +#### See also: +* `\Amp\File\File` + + + + +### `packDouble(float $value): string` + +Convert double to binary version. + + +Parameters: + +* `$value`: `float` Value to convert + + + +### `packSignedInt(integer $value): string` + +Convert integer to base256 signed int. + + +Parameters: + +* `$value`: `integer` Value to convert + + + +### `packSignedLong(int $value): string` + +Convert integer to base256 long. + + +Parameters: + +* `$value`: `int` Value to convert + + + +### `packUnsignedInt(int $value): string` + +Convert value to unsigned base256 int. + + +Parameters: + +* `$value`: `int` Value + + + +### `pausePlay(int $id): void` + +Pauses playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `peerIsset(mixed $id): bool` + +Check if peer is present in internal peer database. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `phoneLogin(string $number, integer $sms_type = 5): array` + +Login as user. + + +Parameters: + +* `$number`: `string` Phone number +* `$sms_type`: `integer` SMS type + + + +### `posmod(int $a, int $b): int` + +Positive modulo +Works just like the % (modulus) operator, only returns always a postive number. + + +Parameters: + +* `$a`: `int` A +* `$b`: `int` B + + + +### `processDownloadServerPing(string $path, string $payload): void` + +Internal endpoint used by the download server. + + +Parameters: + +* `$path`: `string` +* `$payload`: `string` + + + +### `qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode` + +Initiates QR code login. + +Returns a QR code login helper object, that can be used to render the QR code, display the link directly, wait for login, QR code expiration and much more. + +Returns null if we're already logged in, or if we're waiting for a password (use getAuthorization to distinguish between the two cases). + + +#### See also: +* [`\danog\MadelineProto\TL\Types\LoginQrCode`: Represents a login QR code.](../../danog/MadelineProto/TL/Types/LoginQrCode.html) + + + + +### `random(integer $length): string` + +Get secure random string of specified length. + + +Parameters: + +* `$length`: `integer` Length + + + +### `randomInt(integer $modulus = 0): int` + +Get random integer. + + +Parameters: + +* `$modulus`: `integer` Modulus + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `refreshFullPeerCache(mixed $id): void` + +Refresh full peer cache for a certain peer. + + +Parameters: + +* `$id`: `mixed` The peer to refresh + + + +### `refreshPeerCache(mixed ...$ids): void` + +Refresh peer cache for a certain peer. + + +Parameters: + +* `...$ids`: `mixed` + + + +### `report(string $message, string $parseMode = ''): void` + +Report an error to the previously set peer. + + +Parameters: + +* `$message`: `string` Error to report +* `$parseMode`: `string` Parse mode + + + +### `reportMemoryProfile(): void` + +Report memory profile with memprof. + + + +### `requestCall(mixed $user): \danog\MadelineProto\VoIP` + +Request VoIP call. + + +Parameters: + +* `$user`: `mixed` User + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `requestSecretChat(mixed $user): int` + +Request secret chat. + + +Parameters: + +* `$user`: `mixed` User to start secret chat with + + + +### `resetUpdateState(): void` + +Reset the update state and fetch all updates from the beginning. + + + +### `restart(): void` + +Restart update loop. + + + +### `resumePlay(int $id): void` + +Resumes playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `rethrow(Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `Throwable` + + +#### See also: +* `Throwable` + + + + +### `rleDecode(string $string): string` + +null-byte RLE decode. + + +Parameters: + +* `$string`: `string` Data to decode + + + +### `rleEncode(string $string): string` + +null-byte RLE encode. + + +Parameters: + +* `$string`: `string` Data to encode + + + +### `sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendCustomEvent(mixed $payload): void` + +Sends an updateCustomEvent update to the event handler. + + +Parameters: + +* `$payload`: `mixed` + + + +### `sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$duration`: `?int` +* `$width`: `?int` +* `$height`: `?int` +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a message. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` Cancellation + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>` + +Sends a message to all report peers (admins of the bot). + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$stickerSet`: `array` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `setNoop(): void` + +Set NOOP update handler, ignoring all updates. + + + +### `setReportPeers((int|string|array<(int|string)>) $userOrId): void` + +Set peer(s) where to send errors occurred in the event loop. + + +Parameters: + +* `$userOrId`: `(int|string|array<(int|string)>)` Username(s) or peer ID(s) + + + +### `setWebhook(string $webhookUrl): void` + +Set webhook update handler. + + +Parameters: + +* `$webhookUrl`: `string` Webhook URL + + + +### `skipPlay(int $id): void` + +When called, skips to the next file in the playlist. + + +Parameters: + +* `$id`: `int` + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `start(): array` + +Log in to telegram (via CLI or web). + + + +### `stop(): void` + +Stop update loop. + + + +### `stopPlay(int $id): void` + +Stops playing all files in the call, clears the main and the hold playlist. + + +Parameters: + +* `$id`: `int` + + + +### `stringToStream(string $str): \Amp\ByteStream\ReadableBuffer` + +Converts a string into an async amphp stream. + + +Parameters: + +* `$str`: `string` + + +#### See also: +* `\Amp\ByteStream\ReadableBuffer` + + + + +### `subscribeToUpdates(mixed $channel): bool` + +Subscribe to event handler updates for a channel/supergroup we're not a member of. + + +Parameters: + +* `$channel`: `mixed` Channel/supergroup to subscribe to + + +Return value: False if we were already subscribed + + +### `tdToMTProto(array $params): array` + +Convert TD to MTProto parameters. + + +Parameters: + +* `$params`: `array` Parameters + + + +### `tdToTdcli(mixed $params): array` + +Convert TD parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Parameters + + + +### `tdcliToTd(mixed $params, array $key = NULL): array` + +Convert tdcli parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Params +* `$key`: `array` Key + + + +### `testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}` + +Test fibers. + + +Parameters: + +* `$fiberCount`: `int` + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `unpackDouble(string $value): float` + +Unpack binary double. + + +Parameters: + +* `$value`: `string` Value to unpack + + + +### `unpackFileId(string $fileId): array` + +Unpack bot API file ID. + + +Parameters: + +* `$fileId`: `string` Bot API file ID + + +Return value: Unpacked file ID + + +### `unpackSignedInt(string $value): int` + +Unpack base256 signed int. + + +Parameters: + +* `$value`: `string` base256 int + + + +### `unpackSignedLong(string $value): int` + +Unpack base256 signed long. + + +Parameters: + +* `$value`: `string` base256 long + + + +### `unpackSignedLongString((string|int|array) $value): string` + +Unpack base256 signed long to string. + + +Parameters: + +* `$value`: `(string|int|array)` base256 long + + + +### `unsetEventHandler(): void` + +Unset event handler. + + + +### `update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void` + +Update the 2FA password. + +The params array can contain password, new_password, email and hint params. + + +Parameters: + +* `$params`: `array{password?: string, new_password?: string, email?: string, hint?: string}` The params + + + +### `updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void` + +Parse, update and store settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file to secret chat. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from callable. + +The callable must accept two parameters: int $offset, int $size +The callable must return a string with the contest of the file at the specified offset and size. + + +Parameters: + +* `$callable`: `callable(int, int, ?Cancellation): strin)` Callable (offset, length) => data +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable(float, float, float): voi)` Status callback +* `$seekable`: `boolean` Whether chunks can be fetched out of order +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from stream. + + +Parameters: + +* `$stream`: `mixed` PHP resource or AMPHP async stream +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Reupload telegram file. + + +Parameters: + +* `$media`: `mixed` Telegram file +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from URL. + + +Parameters: + +* `$url`: `(string|\danog\MadelineProto\FileCallbackInterface)` URL of file +* `$size`: `integer` Size of file +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>` + +Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` Class name + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) +* [`\danog\MadelineProto\EventHandlerIssue`: Represents an event handler issue.](../../danog/MadelineProto/EventHandlerIssue.html) + + + + +### `viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool` + +Mark sponsored message as read. + + +Parameters: + +* `$peer`: `(int|array)` Channel ID, or Update, or Message, or Peer. +* `$message`: `(string|array{random_id: string})` Random ID or sponsored message to mark as read. + + + +### `wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media` + +Wrap a media constructor into an abstract Media object. + + +Parameters: + +* `$media`: `array` +* `$protected`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage` + +Wrap a Message constructor into an abstract Message object. + + +Parameters: + +* `$message`: `array` +* `$scheduled`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractMessage`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/AbstractMessage.html) + + + + +### `wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned` + +Wrap a Pin constructor into an abstract Pinned object. + + +Parameters: + +* `$message`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Pinned`: Indicates that some messages were pinned/unpinned.](../../danog/MadelineProto/EventHandler/Pinned.html) + + + + +### `wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update` + +Wrap an Update constructor into an abstract Update object. + + +Parameters: + +* `$update`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void` + +Initialize database properties. + + +Parameters: + +* `$settings`: `\danog\AsyncOrm\Settings` +* `$tablePrefix`: `string` + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `saveDbProperties(): void` + +Save all properties. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/AbstractMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/AbstractMessage.md new file mode 100644 index 0000000000..e9c5372796 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/AbstractMessage.md @@ -0,0 +1,536 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\AbstractMessage: Represents an incoming or outgoing message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\AbstractMessage` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents an incoming or outgoing message. + + + +## Properties +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/AbstractPoll.md b/docs/PHP/danog/MadelineProto/EventHandler/AbstractPoll.md new file mode 100644 index 0000000000..421926f0f6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/AbstractPoll.md @@ -0,0 +1,57 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\AbstractPoll: Poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\AbstractPoll` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Poll + + + +## Properties +* `$id`: `int` ID of the poll +* `$closed`: `bool` Whether the poll is closed and doesn’t accept any more answers +* `$question`: `string` The question of the poll +* `$questionEntities`: `list` Styled text entities in the question of the poll. +* `$answers`: `list` The possible answers +* `$closePeriod`: `?int` Amount of time in seconds the poll will be active after creation, 5-600 +* `$closeDate`: `?int` Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future +* `$recentVoters`: `list` IDs of the last users that recently voted in the poll +* `$totalVoters`: `int` Total number of people that voted in the poll + +## Method list: +* [`fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll`](#fromRawPoll) +* [`getQuestionHTML(bool $allowTelegramTags = false): string`](#getQuestionHTML) + +## Methods: +### `fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll` + + + + +Parameters: + +* `$rawPoll`: `array` + + + +### `getQuestionHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the question. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.md new file mode 100644 index 0000000000..79e886bb01 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.md @@ -0,0 +1,796 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\AbstractPrivateMessage: Represents a private or secret chat message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\AbstractPrivateMessage` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a private or secret chat message. + + + +## Properties +* `$message`: `string` Content of the message +* `$fwdInfo`: `?danog\MadelineProto\EventHandler\ForwardedInfo` Info about a forwarded message +* `$command`: `?string` Bot command (if present) +* `$commandType`: `?danog\MadelineProto\EventHandler\CommandType` Bot command type (if present) +* `$commandArgs`: `list` Bot command arguments (if present) +* `$protected`: `bool` Whether this message is protected +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$media`: `(danog\MadelineProto\EventHandler\Media\Audio | danog\MadelineProto\EventHandler\Media\Document | danog\MadelineProto\EventHandler\Media\DocumentPhoto | danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\MaskSticker | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\RoundVideo | danog\MadelineProto\EventHandler\Media\Sticker | danog\MadelineProto\EventHandler\Media\Video | danog\MadelineProto\EventHandler\Media\Voice | null)` Attached media. +* `$fromScheduled`: `bool` Whether this message is a *sent* scheduled message +* `$viaBotId`: `?int` If the message was generated by an inline query, ID of the bot that generated it +* `$editDate`: `?int` Last edit date of the message +* `$keyboard`: `(danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard | danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard | null)` Inline or reply keyboard. +* `$imported`: `bool` Whether this message was [imported from a foreign chat service](https://core.telegram.org/api/import) +* `$psaType`: `?string` For Public Service Announcement messages, the PSA type +* `$nextSent`: `?self` +* `$views`: `?int` View counter for messages from channels or forwarded from channels +* `$forwards`: `?int` Forward counter for messages from channels or forwarded from channels +* `$signature`: `?string` Author of the post, if signatures are enabled for messages from channels or forwarded from channels +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text +* `$groupedId`: `?int` Group ID for albums. + +All messages associated to the same album will have an identical grouped ID. +* `$poll`: `?danog\MadelineProto\EventHandler\AbstractPoll` The poll +* `$scheduled`: `bool` Whether this message is a scheduled message +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`screenShot(): \danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken`](#screenShot) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`getOurReactions(): list<(string|int)>`](#getOurReactions) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool`](#report) +* [`saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void`](#saveContact) +* [`removeContact(): void`](#removeContact) +* [`inviteToChannel((string|int) $channel): void`](#inviteToChannel) +* [`addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>`](#addReaction) +* [`delReaction((string|int) $reaction): list<(string|int)>`](#delReaction) +* [`translate(string $toLang): string`](#translate) +* [`editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#replyOrEdit) +* [`forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>`](#forward) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `screenShot(): \danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken` + +Notify the other user in a private chat that a screenshot of the chat was taken. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken`: A screenshot of the chat was taken.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html) + + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `getOurReactions(): list<(string|int)>` + +Get our reactions on the message. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void` + +Save message sender to your account contacts. + + +Parameters: + +* `$firstName`: `string` First name +* `$lastName`: `(string|null)` Last name +* `$phoneNumber`: `(string|null)` Telegram ID of the other user +* `$addPhonePrivacyException`: `bool` Allow the other user to see our phone number? + + + +### `removeContact(): void` + +Remove message sender from your account contacts. + + + +### `inviteToChannel((string|int) $channel): void` + +Invite message sender to requested channel. + + +Parameters: + +* `$channel`: `(string|int)` Username, Channel ID + + + +### `addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>` + +Add reaction to message. + + +Parameters: + +* `$reaction`: `(string|int)` reaction +* `$big`: `bool` Whether a bigger and longer reaction should be shown +* `$addToRecent`: `bool` Add this reaction to the recent reactions list. + + + +### `delReaction((string|int) $reaction): list<(string|int)>` + +Delete reaction from message. + + +Parameters: + +* `$reaction`: `(string|int)` string or int Reaction + + + +### `translate(string $toLang): string` + +Translate text message(for media translate it caption). + + +Parameters: + +* `$toLang`: `string` Two-letter ISO 639-1 language code of the language to which the message is translated + + + +### `editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +### `replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +If the message is outgoing, will edit the message's text, otherwise will reply to the message. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) + + + + +### `forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>` + +Forwards messages by their IDs. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer +* `$id`: `list` IDs of messages +* `$dropAuthor`: `bool` Whether to forward messages without quoting the original author +* `$dropCaption`: `bool` Whether to strip captions from media +* `$topicId`: `int` Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$score`: `boolean` When forwarding games, whether to include your score in the game +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. + + +#### See also: +* `non-empty-list` + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the message. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/AbstractStory.md b/docs/PHP/danog/MadelineProto/EventHandler/AbstractStory.md new file mode 100644 index 0000000000..fa483782dc --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/AbstractStory.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\AbstractStory: Represents a Telegram Story." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\AbstractStory` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a Telegram Story. + + + +## Properties +* `$senderId`: `int` ID of the sender of the story +* `$id`: `int` Story ID +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action.md b/docs/PHP/danog/MadelineProto/EventHandler/Action.md new file mode 100644 index 0000000000..2ea9664872 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action: In-progress actions." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +In-progress actions. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/Cancel.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/Cancel.md new file mode 100644 index 0000000000..a4b947e62d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/Cancel.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\Cancel: Invalidate all previous action updates. E.g. when user deletes entered text or aborts a video upload." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\Cancel` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Invalidate all previous action updates. E.g. when user deletes entered text or aborts a video upload. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/ChooseContact.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/ChooseContact.md new file mode 100644 index 0000000000..3701764ce3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/ChooseContact.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\ChooseContact: User is selecting a contact to share." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\ChooseContact` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is selecting a contact to share. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/ChooseSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/ChooseSticker.md new file mode 100644 index 0000000000..4a94d9897b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/ChooseSticker.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\ChooseSticker: User is choosing a sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\ChooseSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is choosing a sticker. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/EmojiSeen.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/EmojiSeen.md new file mode 100644 index 0000000000..b1903d6e4a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/EmojiSeen.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\EmojiSeen: User is watching an animated emoji reaction triggered by another user, [click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\EmojiSeen` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is watching an animated emoji reaction triggered by another user, [click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions). + + + +## Properties +* `$emoticon`: `string` Emoji + +## Method list: +* [`__construct(string $emoticon)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(string $emoticon)` + + + + +Parameters: + +* `$emoticon`: `string` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/EmojiTap.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/EmojiTap.md new file mode 100644 index 0000000000..f62cad9176 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/EmojiTap.md @@ -0,0 +1,49 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\EmojiTap: User has clicked on an animated emoji triggering a [reaction, click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\EmojiTap` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User has clicked on an animated emoji triggering a [reaction, click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions). + + + +## Properties +* `$emoticon`: `string` Emoji +* `$id`: `int` Message ID of the animated emoji that was clicked +* `$animation`: `list` t: number of seconds that passed since the previous tap in the array, the first tap uses a value of `0.0`. +i: 1-based index of the randomly chosen animation for the tap (equivalent to the index of a specific emoji-related animation in [stickerPack](https://core.telegram.org/constructor/stickerPack) + 1). + +## Method list: +* [`__construct(string $emoticon, ?int $id, array $animation)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(string $emoticon, ?int $id, array $animation)` + + + + +Parameters: + +* `$emoticon`: `string` +* `$id`: `?int` +* `$animation`: `array` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/GamePlay.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/GamePlay.md new file mode 100644 index 0000000000..91f684f12e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/GamePlay.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\GamePlay: User is playing a game." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\GamePlay` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is playing a game. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/GeoLocation.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/GeoLocation.md new file mode 100644 index 0000000000..aaab09c561 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/GeoLocation.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\GeoLocation: User is selecting a location to share." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\GeoLocation` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is selecting a location to share. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/GroupCallSpeaking.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/GroupCallSpeaking.md new file mode 100644 index 0000000000..47f567a960 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/GroupCallSpeaking.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\GroupCallSpeaking: User is currently speaking in the group call." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\GroupCallSpeaking` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is currently speaking in the group call. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/HistoryImport.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/HistoryImport.md new file mode 100644 index 0000000000..013fa7ef6b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/HistoryImport.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\HistoryImport: Chat history is being imported." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\HistoryImport` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Chat history is being imported. + + + +## Properties +* `$progress`: `?int` Progress percentage + +## Method list: +* [`__construct(?int $progress)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(?int $progress)` + + + + +Parameters: + +* `$progress`: `?int` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordAudio.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordAudio.md new file mode 100644 index 0000000000..70a5629842 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordAudio.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\RecordAudio: User is recording a voice message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\RecordAudio` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is recording a voice message. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordRound.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordRound.md new file mode 100644 index 0000000000..3e0ebd24e2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordRound.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\RecordRound: User is recording a round video to share." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\RecordRound` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is recording a round video to share. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordVideo.md new file mode 100644 index 0000000000..a272fa77ff --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/RecordVideo.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\RecordVideo: User is recording a video." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\RecordVideo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is recording a video. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/Typing.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/Typing.md new file mode 100644 index 0000000000..8e46751e6a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/Typing.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\Typing: User is typing." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\Typing` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is typing. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadAudio.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadAudio.md new file mode 100644 index 0000000000..389aea2427 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadAudio.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\UploadAudio: User is uploading a voice message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\UploadAudio` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is uploading a voice message. + + + +## Properties +* `$progress`: `?int` Progress percentage + +## Method list: +* [`__construct(?int $progress)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(?int $progress)` + + + + +Parameters: + +* `$progress`: `?int` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadDocument.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadDocument.md new file mode 100644 index 0000000000..a243b0dd48 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadDocument.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\UploadDocument: User is uploading a file." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\UploadDocument` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is uploading a file. + + + +## Properties +* `$progress`: `?int` Progress percentage + +## Method list: +* [`__construct(?int $progress)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(?int $progress)` + + + + +Parameters: + +* `$progress`: `?int` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadPhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadPhoto.md new file mode 100644 index 0000000000..a2dd0cd6d9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadPhoto.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\UploadPhoto: User is uploading a photo." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\UploadPhoto` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is uploading a photo. + + + +## Properties +* `$progress`: `?int` Progress percentage + +## Method list: +* [`__construct(?int $progress)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(?int $progress)` + + + + +Parameters: + +* `$progress`: `?int` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadRound.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadRound.md new file mode 100644 index 0000000000..359325ab22 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadRound.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\UploadRound: User is uploading a round video." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\UploadRound` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is uploading a round video. + + + +## Properties +* `$progress`: `?int` Progress percentage + +## Method list: +* [`__construct(?int $progress)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(?int $progress)` + + + + +Parameters: + +* `$progress`: `?int` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadVideo.md new file mode 100644 index 0000000000..f1fe612f07 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Action/UploadVideo.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Action\\UploadVideo: User is uploading a video." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Action\UploadVideo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +User is uploading a video. + + + +## Properties +* `$progress`: `?int` Progress percentage + +## Method list: +* [`__construct(?int $progress)`](#__construct) +* [`toRawAction(): array`](#toRawAction) + +## Methods: +### `__construct(?int $progress)` + + + + +Parameters: + +* `$progress`: `?int` + + + +### `toRawAction(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Attributes/Cron.md b/docs/PHP/danog/MadelineProto/EventHandler/Attributes/Cron.md new file mode 100644 index 0000000000..9dee3882be --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Attributes/Cron.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Attributes\\Cron: Attribute that enables periodic execution of a certain method." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Attributes\Cron` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Attribute that enables periodic execution of a certain method. + + + +## Properties +* `$period`: `float` + +## Method list: +* [`__construct(float $period)`](#__construct) + +## Methods: +### `__construct(float $period)` + + + + +Parameters: + +* `$period`: `float` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Attributes/Handler.md b/docs/PHP/danog/MadelineProto/EventHandler/Attributes/Handler.md new file mode 100644 index 0000000000..4e7da4ebf2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Attributes/Handler.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Attributes\\Handler: Attribute that marks a handler method." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Attributes\Handler` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Attribute that marks a handler method. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/BotApp.md b/docs/PHP/danog/MadelineProto/EventHandler/BotApp.md new file mode 100644 index 0000000000..6e0465853f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/BotApp.md @@ -0,0 +1,31 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\BotApp: Represents information about a [named bot web app](https://core.telegram.org/api/bots/webapps#named-bot-web-apps)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\BotApp` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents information about a [named bot web app](https://core.telegram.org/api/bots/webapps#named-bot-web-apps). + + + +## Properties +* `$id`: `int` App ID +* `$accessHash`: `int` Access hash +* `$name`: `string` Bot web app short name, used to generate [named bot web app deep links](https://core.telegram.org/api/links#named-bot-web-app-links). +* `$title`: `string` Bot web app title. +* `$description`: `string` Bot web app description. +* `$photo`: `?danog\MadelineProto\EventHandler\Media\Photo` Bot web app photo. +* `$document`: `?danog\MadelineProto\EventHandler\Media\Document` Bot web app animation. +* `$hash`: `int` Hash to pass to [messages.getBotApp](https://docs.madelineproto.xyz/API_docs/methods/messages.getBotApp.html), to avoid refetching bot app info if it hasn’t changed. +* `$inactive`: `?bool` Whether the web app was never used by the user, and confirmation must be asked from the user before opening it. +* `$requestWriteAccess`: `?bool` The bot is asking permission to send messages to the user: if the user agrees, set the write_allowed flag when invoking [messages.requestAppWebView](https://docs.madelineproto.xyz/API_docs/methods/messages.requestAppWebView.html). +* `$hasSettings`: `?bool` +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/BotCommands.md b/docs/PHP/danog/MadelineProto/EventHandler/BotCommands.md new file mode 100644 index 0000000000..21dfff0341 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/BotCommands.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\BotCommands: The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\BotCommands` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed. + + + +## Properties +* `$botId`: `int` ID of the bot that changed its command set. +* `$chatId`: `int` The affected chat. +* `$commands`: `list` New bot commands. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/CallbackQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/CallbackQuery.md new file mode 100644 index 0000000000..f36cfe0905 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/CallbackQuery.md @@ -0,0 +1,42 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\CallbackQuery: Represents a query sent by the user by clicking on a button." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\CallbackQuery` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a button. + + + +## Properties +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.md b/docs/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.md new file mode 100644 index 0000000000..24879597d9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.md @@ -0,0 +1,50 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Channel\\ChannelParticipant: A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Channel\ChannelParticipant` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel). + + + +## Properties +* `$viaChatlist`: `bool` Whether the participant joined using a [chat folder deep link »](https://core.telegram.org/api/links#chat-folder-links). +* `$chatId`: `int` Channel ID +* `$date`: `int` Date of the event +* `$actorId`: `int` User that triggered the change (inviter, admin that kicked the user, or the even the userId itself) +* `$userId`: `int` User that was affected by the change +* `$prevParticipant`: `?danog\MadelineProto\EventHandler\Participant` Previous participant status +* `$newParticipant`: `?danog\MadelineProto\EventHandler\Participant` New participant status +* `$inviteLink`: `?danog\MadelineProto\EventHandler\ChatInvite` Chat invite used to join the channel/supergroup + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawChannelParticipant)`](#__construct) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawChannelParticipant)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawChannelParticipant`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.md b/docs/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.md new file mode 100644 index 0000000000..2ed501ad48 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Channel\\MessageForwards: Indicates that the forward counter of a message in a channel has changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Channel\MessageForwards` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Indicates that the forward counter of a message in a channel has changed. + + + +## Properties +* `$chatId`: `int` Channel ID +* `$id`: `int` ID of the message +* `$forwards`: `int` New forward counter +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.md b/docs/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.md new file mode 100644 index 0000000000..d1bb7bbd9f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Channel\\MessageViewsChanged: Indicates that the view counter of a message in a channel has changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Channel\MessageViewsChanged` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Indicates that the view counter of a message in a channel has changed. + + + +## Properties +* `$chatId`: `int` Channel ID +* `$id`: `int` ID of the message +* `$views`: `int` New view counter +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.md b/docs/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.md new file mode 100644 index 0000000000..8fb81a4a0c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.md @@ -0,0 +1,21 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Channel\\UpdateChannel: A new channel is available, or info about an existing channel was changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Channel\UpdateChannel` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A new channel is available, or info about an existing channel was changed. + + + +## Properties +* `$chatId`: `int` Channel ID +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite.md b/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite.md new file mode 100644 index 0000000000..f99f0702f3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ChatInvite: Chat invite link that was used by the user to send the [join request »](https://core.telegram.org/api/invites#join-requests)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ChatInvite` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Chat invite link that was used by the user to send the [join request »](https://core.telegram.org/api/invites#join-requests). + + + + +## Method list: +* [`fromRawChatInvite(array $rawChatInvite): self`](#fromRawChatInvite) + +## Methods: +### `fromRawChatInvite(array $rawChatInvite): self` + + + + +Parameters: + +* `$rawChatInvite`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInviteExported.md b/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInviteExported.md new file mode 100644 index 0000000000..36adebbe18 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInviteExported.md @@ -0,0 +1,48 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ChatInvite\\ChatInviteExported: Represents an exported chat invite." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ChatInvite\ChatInviteExported` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an exported chat invite. + + + +## Properties +* `$revoked`: `bool` Whether this chat invite was revoked. +* `$permanent`: `bool` Whether this chat invite has no expiration. +* `$requestNeeded`: `bool` Whether users importing this invite link will have to be [approved to join the channel or group](https://core.telegram.org/api/invites#join-requests). +* `$link`: `string` Chat invitation link. +* `$adminId`: `int` ID of the admin that created this chat invite. +* `$date`: `int` When was this chat invite last modified. +* `$created`: `?int` When was this chat invite last modified. +* `$expire`: `?int` When does this chat invite expire. +* `$limit`: `?int` Maximum number of users that can join using this link. +* `$used`: `?int` How many users joined using this link. +* `$requested`: `?int` Number of users that have already used this link to join. +* `$title`: `?string` Custom description for the invite link, visible only to admins. + +## Method list: +* [`fromRawChatInvite(array $rawChatInvite): self`](#fromRawChatInvite) + +## Methods: +### `fromRawChatInvite(array $rawChatInvite): self` + + + + +Parameters: + +* `$rawChatInvite`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInvitePublicJoin.md b/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInvitePublicJoin.md new file mode 100644 index 0000000000..f0bf720ba5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInvitePublicJoin.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ChatInvite\\ChatInvitePublicJoin: Used in updates and in the channel log to indicate when a user is requesting to join or has joined a [discussion group](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ChatInvite\ChatInvitePublicJoin` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Used in updates and in the channel log to indicate when a user is requesting to join or has joined a [discussion group](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group). + + + + +## Method list: +* [`fromRawChatInvite(array $rawChatInvite): self`](#fromRawChatInvite) + +## Methods: +### `fromRawChatInvite(array $rawChatInvite): self` + + + + +Parameters: + +* `$rawChatInvite`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.md b/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.md new file mode 100644 index 0000000000..151c619bea --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.md @@ -0,0 +1,21 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ChatInviteRequester: Indicates someone has requested to join a chat or channel." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ChatInviteRequester` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Indicates someone has requested to join a chat or channel. + + + +## Properties +* `$chatId`: `int` The chat or channel in question +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.md b/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.md new file mode 100644 index 0000000000..f3191db507 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.md @@ -0,0 +1,25 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ChatInviteRequester\\BotChatInviteRequest: Indicates someone has requested to join a chat or channel (bots only)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ChatInviteRequester\BotChatInviteRequest` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Indicates someone has requested to join a chat or channel (bots only). + + + +## Properties +* `$date`: `int` When was the [join request »](https://core.telegram.org/api/invites#join-requests) made +* `$userId`: `int` The user ID that is asking to join the chat or channel +* `$about`: `string` Bio of the user +* `$invite`: `danog\MadelineProto\EventHandler\ChatInvite` Chat invite link that was used by the user to send the [join request »](https://core.telegram.org/api/invites#join-requests) +* `$chatId`: `int` The chat or channel in question +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.md b/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.md new file mode 100644 index 0000000000..3810cd6782 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ChatInviteRequester\\PendingJoinRequests: Someone has requested to join a chat or channel." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ChatInviteRequester\PendingJoinRequests` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Someone has requested to join a chat or channel. + + + +## Properties +* `$pending`: `int` Number of pending [join requests »](https://core.telegram.org/api/invites#join-requests) for the chat or channel +* `$recent`: `list` IDs of users that have recently requested to join +* `$chatId`: `int` The chat or channel in question +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Command.md b/docs/PHP/danog/MadelineProto/EventHandler/Command.md new file mode 100644 index 0000000000..49e2de3027 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Command.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Command: Represents a bot command that can be used in a chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Command` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a bot command that can be used in a chat. + + + +## Properties +* `$command`: `string` `/command` name. +* `$description`: `string` Description of the command. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/CommandType.md b/docs/PHP/danog/MadelineProto/EventHandler/CommandType.md new file mode 100644 index 0000000000..2149174eae --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/CommandType.md @@ -0,0 +1,65 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\CommandType: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\CommandType` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Constants +* `danog\MadelineProto\EventHandler\CommandType::SLASH`: + +* `danog\MadelineProto\EventHandler\CommandType::DOT`: + +* `danog\MadelineProto\EventHandler\CommandType::BANG`: + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Delete.md b/docs/PHP/danog/MadelineProto/EventHandler/Delete.md new file mode 100644 index 0000000000..621e1ef1ea --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Delete.md @@ -0,0 +1,21 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Delete: Indicates that some messages were deleted." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Delete` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Indicates that some messages were deleted. + + + +## Properties +* `$ids`: `list` List of identifiers of deleted messages +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.md new file mode 100644 index 0000000000..ac5373689b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Delete\\DeleteChannelMessages: Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Delete\DeleteChannelMessages` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted. + + + +## Properties +* `$chatId`: `int` Channel ID +* `$ids`: `list` List of identifiers of deleted messages +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.md new file mode 100644 index 0000000000..88c5460f56 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.md @@ -0,0 +1,21 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Delete\\DeleteMessages: Some messages were deleted in a private chat or simple group." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Delete\DeleteMessages` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Some messages were deleted in a private chat or simple group. + + + +## Properties +* `$ids`: `list` List of identifiers of deleted messages +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.md new file mode 100644 index 0000000000..d9f89a735e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Delete\\DeleteScheduledMessages: Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Delete\DeleteScheduledMessages` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat. + + + +## Properties +* `$chatId`: `int` Peer +* `$ids`: `list` List of identifiers of deleted messages +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FilterNot.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FilterNot.md new file mode 100644 index 0000000000..3dae29ae5c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FilterNot.md @@ -0,0 +1,92 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Combinator\\FilterNot: NOTs a filter." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Combinator\FilterNot` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +NOTs a filter. + + + + +## Method list: +* [`__construct(\danog\MadelineProto\EventHandler\Filter\Filter $filter)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(\danog\MadelineProto\EventHandler\Filter\Filter $filter)` + + + + +Parameters: + +* `$filter`: `\danog\MadelineProto\EventHandler\Filter\Filter` + + +#### See also: +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersAnd.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersAnd.md new file mode 100644 index 0000000000..ec92a5d40e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersAnd.md @@ -0,0 +1,92 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Combinator\\FiltersAnd: ANDs multiple filters." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Combinator\FiltersAnd` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +ANDs multiple filters. + + + + +## Method list: +* [`__construct(\danog\MadelineProto\EventHandler\Filter\Filter ...$filters)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(\danog\MadelineProto\EventHandler\Filter\Filter ...$filters)` + + + + +Parameters: + +* `...$filters`: `\danog\MadelineProto\EventHandler\Filter\Filter` + + +#### See also: +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersOr.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersOr.md new file mode 100644 index 0000000000..8e1c937350 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersOr.md @@ -0,0 +1,92 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Combinator\\FiltersOr: ORs multiple filters." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Combinator\FiltersOr` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +ORs multiple filters. + + + + +## Method list: +* [`__construct(\danog\MadelineProto\EventHandler\Filter\Filter ...$filters)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(\danog\MadelineProto\EventHandler\Filter\Filter ...$filters)` + + + + +Parameters: + +* `...$filters`: `\danog\MadelineProto\EventHandler\Filter\Filter` + + +#### See also: +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Filter.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Filter.md new file mode 100644 index 0000000000..bdd9ca6b02 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Filter.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Filter: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Filter` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterAllowAll.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterAllowAll.md new file mode 100644 index 0000000000..f7073905c2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterAllowAll.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterAllowAll: Allow all updates." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterAllowAll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow all updates. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterButtonQueryData.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterButtonQueryData.md new file mode 100644 index 0000000000..232532fbb5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterButtonQueryData.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterButtonQueryData: Filters based on the content of a button query." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterButtonQueryData` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Filters based on the content of a button query. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterChannel.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterChannel.md new file mode 100644 index 0000000000..d476e47902 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterChannel.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterChannel: Allow only updates coming from channels." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterChannel` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only updates coming from channels. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommand.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommand.md new file mode 100644 index 0000000000..51cdf8d389 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommand.md @@ -0,0 +1,94 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterCommand: Allow only messages containing the specified command." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterCommand` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages containing the specified command. + + + +## Properties +* `$commandTypes`: `array` + +## Method list: +* [`__construct(string $command, list<\danog\MadelineProto\EventHandler\CommandType> $types = [ 0 => \danog\MadelineProto\EventHandler\CommandType::BANG, 1 => \danog\MadelineProto\EventHandler\CommandType::DOT, 2 => \danog\MadelineProto\EventHandler\CommandType::SLASH,])`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $command, list<\danog\MadelineProto\EventHandler\CommandType> $types = [ 0 => \danog\MadelineProto\EventHandler\CommandType::BANG, 1 => \danog\MadelineProto\EventHandler\CommandType::DOT, 2 => \danog\MadelineProto\EventHandler\CommandType::SLASH,])` + + + + +Parameters: + +* `$command`: `string` Command +* `$types`: `list<\danog\MadelineProto\EventHandler\CommandType>` Command types, if empty all command types are allowed. + + +#### See also: +* [\danog\MadelineProto\EventHandler\CommandType](../../../../danog/MadelineProto/EventHandler/CommandType.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommandCaseInsensitive.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommandCaseInsensitive.md new file mode 100644 index 0000000000..8191b84fdc --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommandCaseInsensitive.md @@ -0,0 +1,94 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterCommandCaseInsensitive: Allow only messages containing the specified case-insensitive command." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterCommandCaseInsensitive` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages containing the specified case-insensitive command. + + + +## Properties +* `$commandTypes`: `list` + +## Method list: +* [`__construct(string $command, list<\danog\MadelineProto\EventHandler\CommandType> $types = [ 0 => \danog\MadelineProto\EventHandler\CommandType::BANG, 1 => \danog\MadelineProto\EventHandler\CommandType::DOT, 2 => \danog\MadelineProto\EventHandler\CommandType::SLASH,])`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $command, list<\danog\MadelineProto\EventHandler\CommandType> $types = [ 0 => \danog\MadelineProto\EventHandler\CommandType::BANG, 1 => \danog\MadelineProto\EventHandler\CommandType::DOT, 2 => \danog\MadelineProto\EventHandler\CommandType::SLASH,])` + + + + +Parameters: + +* `$command`: `string` Command +* `$types`: `list<\danog\MadelineProto\EventHandler\CommandType>` Command types, if empty all command types are allowed. + + +#### See also: +* [\danog\MadelineProto\EventHandler\CommandType](../../../../danog/MadelineProto/EventHandler/CommandType.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterEdited.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterEdited.md new file mode 100644 index 0000000000..c7a7c57e0c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterEdited.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterEdited: Allows messages that were edited." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterEdited` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows messages that were edited. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterEnded.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterEnded.md new file mode 100644 index 0000000000..fc6bc26b8a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterEnded.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterEnded: Allow only ended calls." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterEnded` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only ended calls. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwarded.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwarded.md new file mode 100644 index 0000000000..bb9b66acdd --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwarded.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterForwarded: Allow only forwarded messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterForwarded` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only forwarded messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwardedFrom.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwardedFrom.md new file mode 100644 index 0000000000..940b8ff174 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwardedFrom.md @@ -0,0 +1,87 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterForwardedFrom: Allow only forwarded messages from a certain sender." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterForwardedFrom` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only forwarded messages from a certain sender. + + + + +## Method list: +* [`__construct(string|int $peer)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string|int $peer)` + + + + +Parameters: + +* `$peer`: `string|int` + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromAdmin.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromAdmin.md new file mode 100644 index 0000000000..44ba6bdcb7 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromAdmin.md @@ -0,0 +1,75 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterFromAdmin: Allow only messages coming from the admin (defined as the peers returned by getReportPeers)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterFromAdmin` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages coming from the admin (defined as the peers returned by getReportPeers). + + + + +## Method list: +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromBot.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromBot.md new file mode 100644 index 0000000000..2ff866f3fc --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromBot.md @@ -0,0 +1,75 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterFromBot: Allow only messages coming from bots." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterFromBot` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages coming from bots. + + + + +## Method list: +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSender.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSender.md new file mode 100644 index 0000000000..dc72813e11 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSender.md @@ -0,0 +1,87 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterFromSender: Allow incoming or outgoing group messages made by a certain sender." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterFromSender` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow incoming or outgoing group messages made by a certain sender. + + + + +## Method list: +* [`__construct(string|int $peer)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string|int $peer)` + + + + +Parameters: + +* `$peer`: `string|int` + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSenders.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSenders.md new file mode 100644 index 0000000000..31bcc10897 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSenders.md @@ -0,0 +1,87 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterFromSenders: Allow incoming or outgoing group messages made by a certain list of senders." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterFromSenders` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow incoming or outgoing group messages made by a certain list of senders. + + + + +## Method list: +* [`__construct(string|int ...$idOrUsername)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string|int ...$idOrUsername)` + + + + +Parameters: + +* `...$idOrUsername`: `string|int` + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterGroup.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterGroup.md new file mode 100644 index 0000000000..0bfa54fa65 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterGroup.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterGroup: Allow only updates coming from groups." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterGroup` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only updates coming from groups. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterIncoming.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterIncoming.md new file mode 100644 index 0000000000..32436c950b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterIncoming.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterIncoming: Allow only incoming messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterIncoming` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only incoming messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterMedia.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterMedia.md new file mode 100644 index 0000000000..fd41bdb4c5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterMedia.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterMedia: Allow any media messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterMedia` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow any media messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterMessage.md new file mode 100644 index 0000000000..344ff0ffac --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterMessage.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterMessage: Allow any non-service message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterMessage` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow any non-service message. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterNoMedia.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterNoMedia.md new file mode 100644 index 0000000000..c8c9723f13 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterNoMedia.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterNoMedia: Allow any messages except media messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterNoMedia` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow any messages except media messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterNotEdited.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterNotEdited.md new file mode 100644 index 0000000000..a3eaf925a2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterNotEdited.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterNotEdited: Allows messages that weren't edited." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterNotEdited` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows messages that weren't edited. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterOutgoing.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterOutgoing.md new file mode 100644 index 0000000000..7756209f79 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterOutgoing.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterOutgoing: Allow only outgoing messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterOutgoing` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only outgoing messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPeer.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPeer.md new file mode 100644 index 0000000000..51b86d04b0 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPeer.md @@ -0,0 +1,87 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterPeer: Allow messages coming from or sent to a certain peer." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterPeer` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow messages coming from or sent to a certain peer. + + + + +## Method list: +* [`__construct(string|int $peer)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string|int $peer)` + + + + +Parameters: + +* `$peer`: `string|int` + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPoll.md new file mode 100644 index 0000000000..4dba0e5ad7 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPoll.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterPoll: Allow only messages that contain a poll." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterPoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that contain a poll. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPrivate.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPrivate.md new file mode 100644 index 0000000000..dea1f35e7f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterPrivate.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterPrivate: Allow only updates coming from private chats." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterPrivate` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only updates coming from private chats. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegex.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegex.md new file mode 100644 index 0000000000..876af95c12 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegex.md @@ -0,0 +1,94 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterRegex: Allow only messages or button queries matching the specified regex." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterRegex` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages or button queries matching the specified regex. + + + + +## Method list: +* [`__construct(non-empty-string $regex, int-mask<0, 256, 512> $flags = 0, int $offset = 0)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(non-empty-string $regex, int-mask<0, 256, 512> $flags = 0, int $offset = 0)` + + + + +Parameters: + +* `$regex`: `non-empty-string` +* `$flags`: `int-mask<0, 256, 512>` +* `$offset`: `int` + + +#### See also: +* `non-empty-string` +* `int-mask` + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegexMatchAll.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegexMatchAll.md new file mode 100644 index 0000000000..54d3eb7beb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegexMatchAll.md @@ -0,0 +1,93 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterRegexMatchAll: Allow only messages or button queries matching the specified regex." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterRegexMatchAll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages or button queries matching the specified regex. + + + + +## Method list: +* [`__construct(non-empty-string $regex, int $flags = 0, int $offset = 0)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(non-empty-string $regex, int $flags = 0, int $offset = 0)` + + + + +Parameters: + +* `$regex`: `non-empty-string` +* `$flags`: `int` +* `$offset`: `int` + + +#### See also: +* `non-empty-string` + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterReply.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterReply.md new file mode 100644 index 0000000000..aa151fe4a5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterReply.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterReply: Allow messages that reply to other messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterReply` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow messages that reply to other messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterReplyToSelf.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterReplyToSelf.md new file mode 100644 index 0000000000..7ffe69c53f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterReplyToSelf.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterReplyToSelf: Allow messages that reply to one of our messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterReplyToSelf` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow messages that reply to one of our messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRunning.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRunning.md new file mode 100644 index 0000000000..afccb3e5e5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterRunning.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterRunning: Allow only running calls." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterRunning` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only running calls. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSecret.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSecret.md new file mode 100644 index 0000000000..a59eb0b576 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSecret.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterSecret: Allow only updates coming from secret chats." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterSecret` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only updates coming from secret chats. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSender.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSender.md new file mode 100644 index 0000000000..1fd8f3c0c4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSender.md @@ -0,0 +1,87 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterSender: Allow incoming or outgoing group messages made by a certain sender." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterSender` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow incoming or outgoing group messages made by a certain sender. + + + + +## Method list: +* [`__construct(string|int $peer)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string|int $peer)` + + + + +Parameters: + +* `$peer`: `string|int` + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSenders.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSenders.md new file mode 100644 index 0000000000..84026808f2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterSenders.md @@ -0,0 +1,87 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterSenders: Allow incoming or outgoing group messages made by a certain list of senders." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterSenders` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow incoming or outgoing group messages made by a certain list of senders. + + + + +## Method list: +* [`__construct(string|int ...$idOrUsername)`](#__construct) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string|int ...$idOrUsername)` + + + + +Parameters: + +* `...$idOrUsername`: `string|int` + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](../../../../danog/MadelineProto/EventHandler/Filter/Filter.html) + + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterService.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterService.md new file mode 100644 index 0000000000..e1c1eca0ca --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterService.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterService: Allow only service messages of any type." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterService` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only service messages of any type. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterText.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterText.md new file mode 100644 index 0000000000..039a25b8df --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterText.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterText: Allow only messages with a specific content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterText` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages with a specific content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextCaseInsensitive.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextCaseInsensitive.md new file mode 100644 index 0000000000..490e06c703 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextCaseInsensitive.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextCaseInsensitive: Allow only messages with a specific case-insensitive content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextCaseInsensitive` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages with a specific case-insensitive content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContains.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContains.md new file mode 100644 index 0000000000..bf9f201f1e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContains.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextContains: Allow only messages that contain a specific content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextContains` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that contain a specific content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContainsCaseInsensitive.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContainsCaseInsensitive.md new file mode 100644 index 0000000000..0603ae43bb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContainsCaseInsensitive.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextContainsCaseInsensitive: Allow only messages that contain a specific case-insensitive content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextContainsCaseInsensitive` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that contain a specific case-insensitive content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEnds.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEnds.md new file mode 100644 index 0000000000..4585fa2093 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEnds.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextEnds: Allow only messages that ends with a specific content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextEnds` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that ends with a specific content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEndsCaseInsensitive.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEndsCaseInsensitive.md new file mode 100644 index 0000000000..4ca49e678a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEndsCaseInsensitive.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextEndsCaseInsensitive: Allow only messages that ends with a specific case-insensitive content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextEndsCaseInsensitive` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that ends with a specific case-insensitive content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStarts.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStarts.md new file mode 100644 index 0000000000..045c98d7ba --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStarts.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextStarts: Allow only messages that start with a specific content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextStarts` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that start with a specific content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStartsCaseInsensitive.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStartsCaseInsensitive.md new file mode 100644 index 0000000000..854959b8ea --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStartsCaseInsensitive.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTextStartsCaseInsensitive: Allow only messages that start with a specific case-insensitive content." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTextStartsCaseInsensitive` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that start with a specific case-insensitive content. + + + + +## Method list: +* [`__construct(string $content)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(string $content)` + + + + +Parameters: + +* `$content`: `string` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopic.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopic.md new file mode 100644 index 0000000000..ec027951d5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopic.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTopic: Allow only messages coming from groups that has topics (Supergroups only)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTopic` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages coming from groups that has topics (Supergroups only). + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopicId.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopicId.md new file mode 100644 index 0000000000..84af346da0 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopicId.md @@ -0,0 +1,86 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\FilterTopicId: Allow only messages with a specific topic id (Supergroups only)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\FilterTopicId` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages with a specific topic id (Supergroups only). + + + + +## Method list: +* [`__construct(int $topicId)`](#__construct) +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `__construct(int $topicId)` + + + + +Parameters: + +* `$topicId`: `int` + + + +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterAudio.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterAudio.md new file mode 100644 index 0000000000..18c0bb52af --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterAudio.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterAudio: Allow only audio files." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterAudio` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only audio files. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocument.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocument.md new file mode 100644 index 0000000000..b8897679e5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocument.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterDocument: Allow only documents." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterDocument` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only documents. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocumentPhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocumentPhoto.md new file mode 100644 index 0000000000..dbff419354 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocumentPhoto.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterDocumentPhoto: Allow only documents containing an image." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterDocumentPhoto` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only documents containing an image. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterGif.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterGif.md new file mode 100644 index 0000000000..11efdb4109 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterGif.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterGif: Allow only GIFs." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterGif` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only GIFs. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterPhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterPhoto.md new file mode 100644 index 0000000000..96b182bebe --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterPhoto.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterPhoto: Allow only photos." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterPhoto` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only photos. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterRoundVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterRoundVideo.md new file mode 100644 index 0000000000..9dc6e0b28d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterRoundVideo.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterRoundVideo: Allow only round videos." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterRoundVideo` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only round videos. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterSticker.md new file mode 100644 index 0000000000..dea02e77cd --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterSticker.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterSticker: Allow only stickers." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterSticker` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only stickers. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVideo.md new file mode 100644 index 0000000000..5c1d1d3c14 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVideo.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterVideo: Allow only videos." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterVideo` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only videos. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVoice.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVoice.md new file mode 100644 index 0000000000..6d3d645d1b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVoice.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Media\\FilterVoice: Allow only voice messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Media\FilterVoice` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only voice messages. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterMultiplePoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterMultiplePoll.md new file mode 100644 index 0000000000..e8fdf2f2bf --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterMultiplePoll.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Poll\\FilterMultiplePoll: Allow only messages that contain a multiple poll." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Poll\FilterMultiplePoll` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that contain a multiple poll. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterQuizPoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterQuizPoll.md new file mode 100644 index 0000000000..58bfaa492f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterQuizPoll.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Poll\\FilterQuizPoll: Allow only messages that contain a quiz poll." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Poll\FilterQuizPoll` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that contain a quiz poll. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterSinglePoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterSinglePoll.md new file mode 100644 index 0000000000..fd9572c0c8 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterSinglePoll.md @@ -0,0 +1,74 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Filter\\Poll\\FilterSinglePoll: Allow only messages that contain a single poll." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Filter\Poll\FilterSinglePoll` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages that contain a single poll. + + + + +## Method list: +* [`apply(\danog\MadelineProto\EventHandler\Update $update): bool`](#apply) +* [`initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter`](#initialize) +* [`fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter`](#fromReflectionType) + +## Methods: +### `apply(\danog\MadelineProto\EventHandler\Update $update): bool` + + + + +Parameters: + +* `$update`: `\danog\MadelineProto\EventHandler\Update` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initialize(\danog\MadelineProto\EventHandler $API): \danog\MadelineProto\EventHandler\Filter\Filter` + +Run some initialization logic, optionally returning a new filter to replace the current one. + + +Parameters: + +* `$API`: `\danog\MadelineProto\EventHandler` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../../danog/MadelineProto/EventHandler.html) + + + + +### `fromReflectionType(\ReflectionType $type): \danog\MadelineProto\EventHandler\Filter\Filter` + + + + +Parameters: + +* `$type`: `\ReflectionType` + + +#### See also: +* `\ReflectionType` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/ForwardedInfo.md b/docs/PHP/danog/MadelineProto/EventHandler/ForwardedInfo.md new file mode 100644 index 0000000000..09ec355148 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/ForwardedInfo.md @@ -0,0 +1,27 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\ForwardedInfo: Info about a forwarded message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\ForwardedInfo` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Info about a forwarded message. + + + +## Properties +* `$date`: `int` When was the message originally sent +* `$fromId`: `?int` The ID of the user that originally sent the message +* `$fromName`: `?string` The name of the user that originally sent the message +* `$forwardedChannelMsgId`: `?int` ID of the channel message that was forwarded +* `$forwardedChannelMsgAuthor`: `?string` For channels and if signatures are enabled, author of the channel message that was forwareded +* `$savedFromId`: `?int` Only for messages forwarded to Saved Messages, full info about the user/channel that originally sent the message +* `$savedFromMsgId`: `?int` Only for messages forwarded to Saved Messages, ID of the message that was forwarded from the original user/channel +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/InlineQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/InlineQuery.md new file mode 100644 index 0000000000..40ed5330da --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/InlineQuery.md @@ -0,0 +1,30 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\InlineQuery: An incoming inline query." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\InlineQuery` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +An incoming inline query. + + + +## Properties +* `$queryId`: `int` Query ID +* `$query`: `string` Text of query +* `$userId`: `int` User that sent the query +* `$offset`: `string` Offset to navigate through results +* `$geo`: `?danog\MadelineProto\EventHandler\Media\GeoPoint` Attached geolocation +* `$peerType`: `danog\MadelineProto\EventHandler\InlineQueryPeerType` Type of the chat from which the inline query was sent. +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Keyboard.md b/docs/PHP/danog/MadelineProto/EventHandler/Keyboard.md new file mode 100644 index 0000000000..dafd55cee3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Keyboard.md @@ -0,0 +1,64 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Keyboard: Represents an inline or reply keyboard." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Keyboard` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents an inline or reply keyboard. + + + +## Properties +* `$buttons`: `non-empty-list>` + +## Method list: +* [`fromRawReplyMarkup(array $rawReplyMarkup): ?self`](#fromRawReplyMarkup) +* [`pressByCoordinates(int $row, int $column, bool $waitForResult): mixed`](#pressByCoordinates) +* [`press(string $label, bool $waitForResult): mixed`](#press) + +## Methods: +### `fromRawReplyMarkup(array $rawReplyMarkup): ?self` + + + + +Parameters: + +* `$rawReplyMarkup`: `array` + + + +### `pressByCoordinates(int $row, int $column, bool $waitForResult): mixed` + +Press button at the specified keyboard coordinates. + + +Parameters: + +* `$row`: `int` +* `$column`: `int` +* `$waitForResult`: `bool` If true, waits for a result from the bot before returning. + + + +### `press(string $label, bool $waitForResult): mixed` + +Presses the first keyboard button with the specified label. + + +Parameters: + +* `$label`: `string` +* `$waitForResult`: `bool` If true, waits for a result from the bot before returning. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Keyboard/InlineKeyboard.md b/docs/PHP/danog/MadelineProto/EventHandler/Keyboard/InlineKeyboard.md new file mode 100644 index 0000000000..c3c27d2d6b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Keyboard/InlineKeyboard.md @@ -0,0 +1,64 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Keyboard\\InlineKeyboard: Represents an inline keyboard." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an inline keyboard. + + + +## Properties +* `$buttons`: `non-empty-list>` + +## Method list: +* [`fromRawReplyMarkup(array $rawReplyMarkup): ?self`](#fromRawReplyMarkup) +* [`pressByCoordinates(int $row, int $column, bool $waitForResult): mixed`](#pressByCoordinates) +* [`press(string $label, bool $waitForResult): mixed`](#press) + +## Methods: +### `fromRawReplyMarkup(array $rawReplyMarkup): ?self` + + + + +Parameters: + +* `$rawReplyMarkup`: `array` + + + +### `pressByCoordinates(int $row, int $column, bool $waitForResult): mixed` + +Press button at the specified keyboard coordinates. + + +Parameters: + +* `$row`: `int` +* `$column`: `int` +* `$waitForResult`: `bool` If true, waits for a result from the bot before returning. + + + +### `press(string $label, bool $waitForResult): mixed` + +Presses the first keyboard button with the specified label. + + +Parameters: + +* `$label`: `string` +* `$waitForResult`: `bool` If true, waits for a result from the bot before returning. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Keyboard/ReplyKeyboard.md b/docs/PHP/danog/MadelineProto/EventHandler/Keyboard/ReplyKeyboard.md new file mode 100644 index 0000000000..5767a254c4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Keyboard/ReplyKeyboard.md @@ -0,0 +1,64 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Keyboard\\ReplyKeyboard: Represents a reply keyboard." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a reply keyboard. + + + +## Properties +* `$buttons`: `non-empty-list>` + +## Method list: +* [`fromRawReplyMarkup(array $rawReplyMarkup): ?self`](#fromRawReplyMarkup) +* [`pressByCoordinates(int $row, int $column, bool $waitForResult): mixed`](#pressByCoordinates) +* [`press(string $label, bool $waitForResult): mixed`](#press) + +## Methods: +### `fromRawReplyMarkup(array $rawReplyMarkup): ?self` + + + + +Parameters: + +* `$rawReplyMarkup`: `array` + + + +### `pressByCoordinates(int $row, int $column, bool $waitForResult): mixed` + +Press button at the specified keyboard coordinates. + + +Parameters: + +* `$row`: `int` +* `$column`: `int` +* `$waitForResult`: `bool` If true, waits for a result from the bot before returning. + + + +### `press(string $label, bool $waitForResult): mixed` + +Presses the first keyboard button with the specified label. + + +Parameters: + +* `$label`: `string` +* `$waitForResult`: `bool` If true, waits for a result from the bot before returning. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media.md b/docs/PHP/danog/MadelineProto/EventHandler/Media.md new file mode 100644 index 0000000000..890c5d5c36 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media.md @@ -0,0 +1,118 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media: Represents a generic media." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a generic media. + + + +## Properties +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractAudio.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractAudio.md new file mode 100644 index 0000000000..f9a0571d05 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractAudio.md @@ -0,0 +1,119 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\AbstractAudio: Represents a generic audio file." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\AbstractAudio` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a generic audio file. + + + +## Properties +* `$duration`: `int` Audio duration in seconds +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractSticker.md new file mode 100644 index 0000000000..1f20e63873 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractSticker.md @@ -0,0 +1,122 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\AbstractSticker: Represents a generic sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\AbstractSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a generic sticker. + + + +## Properties +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractVideo.md new file mode 100644 index 0000000000..02a4d9621a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/AbstractVideo.md @@ -0,0 +1,122 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\AbstractVideo: Represents a generic video." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\AbstractVideo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a generic video. + + + +## Properties +* `$duration`: `float` Video duration in seconds +* `$supportsStreaming`: `bool` Whether the video supports streaming +* `$width`: `int` Video width +* `$height`: `int` Video height +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/AnimatedSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/AnimatedSticker.md new file mode 100644 index 0000000000..017bfb3f34 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/AnimatedSticker.md @@ -0,0 +1,123 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\AnimatedSticker: Represents an animated sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\AnimatedSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an animated sticker. + + + +## Properties +* `$premiumSticker`: `bool` Whether this is a premium sticker and a premium sticker animation must be played. +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Audio.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Audio.md new file mode 100644 index 0000000000..1fcc8983ba --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Audio.md @@ -0,0 +1,121 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Audio: Represents an audio file." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Audio` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an audio file. + + + +## Properties +* `$title`: `?string` Song name +* `$performer`: `?string` Performer +* `$duration`: `int` Audio duration in seconds +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/CustomEmoji.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/CustomEmoji.md new file mode 100644 index 0000000000..4ca38d3a14 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/CustomEmoji.md @@ -0,0 +1,124 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\CustomEmoji: Represents a custom emoji sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\CustomEmoji` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a custom emoji sticker. + + + +## Properties +* `$free`: `bool` Whether this custom emoji can be sent by non-Premium users +* `$textColor`: `bool` Whether the color of this TGS custom emoji should be changed to the text color when used in messages, the accent color if used as emoji status, white on chat photos, or another appropriate color based on context. +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Document.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Document.md new file mode 100644 index 0000000000..087695cbaa --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Document.md @@ -0,0 +1,118 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Document: Represents a document." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Document` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a document. + + + +## Properties +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/DocumentPhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/DocumentPhoto.md new file mode 100644 index 0000000000..e1c85e7a10 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/DocumentPhoto.md @@ -0,0 +1,121 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\DocumentPhoto: Represents a photo uploaded as a document." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\DocumentPhoto` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a photo uploaded as a document. + + + +## Properties +* `$hasStickers`: `bool` If true; the current media has attached mask stickers. +* `$width`: `int` +* `$height`: `int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/GeoPoint.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/GeoPoint.md new file mode 100644 index 0000000000..c50ced084a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/GeoPoint.md @@ -0,0 +1,40 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\GeoPoint: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\GeoPoint` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + + + + + +## Properties +* `$long`: `int` Longitude +* `$lat`: `int` Latitude +* `$accessHash`: `int` Access hash +* `$accuracyRadius`: `int` The estimated horizontal accuracy of the location, in meters; as defined by the sender. + +## Method list: +* [`__construct(array $rawGeoPoint)`](#__construct) + +## Methods: +### `__construct(array $rawGeoPoint)` + + + + +Parameters: + +* `$rawGeoPoint`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Gif.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Gif.md new file mode 100644 index 0000000000..9038d3f5b8 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Gif.md @@ -0,0 +1,137 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Gif: Represents a GIF (or an MPEG4 file without sound)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Gif` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a GIF (or an MPEG4 file without sound). + + + +## Properties +* `$hasStickers`: `bool` If true; the current media has attached mask stickers. +* `$duration`: `float` Video duration in seconds +* `$supportsStreaming`: `bool` Whether the video supports streaming +* `$width`: `int` Video width +* `$height`: `int` Video height +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`save(): bool`](#save) +* [`unsave(): bool`](#unsave) +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `save(): bool` + +Add GIF to saved gifs list. + + + +### `unsave(): bool` + +Remove GIF from saved gifs list. + + + +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/MaskPosition.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/MaskPosition.md new file mode 100644 index 0000000000..734b7b17b4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/MaskPosition.md @@ -0,0 +1,67 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\MaskPosition: Position of the mask" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\MaskPosition` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Position of the mask + + + + +## Constants +* `danog\MadelineProto\EventHandler\Media\MaskPosition::Forehead`: + +* `danog\MadelineProto\EventHandler\Media\MaskPosition::Eyes`: + +* `danog\MadelineProto\EventHandler\Media\MaskPosition::Mouth`: + +* `danog\MadelineProto\EventHandler\Media\MaskPosition::Chin`: + +## Properties +* `$name`: `string` +* `$value`: `int` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/MaskSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/MaskSticker.md new file mode 100644 index 0000000000..655c3f03f1 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/MaskSticker.md @@ -0,0 +1,132 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\MaskSticker: Represents a mask sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\MaskSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a mask sticker. + + + +## Properties +* `$position`: `danog\MadelineProto\EventHandler\Media\MaskPosition` Part of the face, relative to which the mask should be placed. +* `$x`: `float` Shift by X-axis measured in widths of the mask scaled to the face size, from left to right. + +For example, -1.0 will place the mask just to the left of the default mask position. +* `$y`: `float` Shift by Y-axis measured in widths of the mask scaled to the face size, from left to right. + +For example, -1.0 will place the mask just below the default mask position. +* `$zoom`: `float` Mask scaling coefficient. + +For example, 2.0 means a doubled size. +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/MediaStory.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/MediaStory.md new file mode 100644 index 0000000000..b273a7f65b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/MediaStory.md @@ -0,0 +1,39 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\MediaStory: Represents a forwarded story." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\MediaStory` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a forwarded story. + + + +## Properties +* `$viaMention`: `bool` +* `$senderId`: `int` +* `$storyId`: `int` + +## Method list: +* [`getStory(): ?\danog\MadelineProto\EventHandler\AbstractStory`](#getStory) + +## Methods: +### `getStory(): ?\danog\MadelineProto\EventHandler\AbstractStory` + +Get story. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Photo.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Photo.md new file mode 100644 index 0000000000..ef49e7de56 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Photo.md @@ -0,0 +1,119 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Photo: Represents a photo." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Photo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a photo. + + + +## Properties +* `$hasStickers`: `bool` If true; the current media has attached mask stickers. +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/RoundVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/RoundVideo.md new file mode 100644 index 0000000000..cade80f99f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/RoundVideo.md @@ -0,0 +1,122 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\RoundVideo: Represents a round video." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\RoundVideo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a round video. + + + +## Properties +* `$duration`: `float` Video duration in seconds +* `$supportsStreaming`: `bool` Whether the video supports streaming +* `$width`: `int` Video width +* `$height`: `int` Video height +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/StaticSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/StaticSticker.md new file mode 100644 index 0000000000..2bc890faf4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/StaticSticker.md @@ -0,0 +1,123 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\StaticSticker: Represents a static sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\StaticSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a static sticker. + + + +## Properties +* `$premiumSticker`: `bool` Whether this is a premium sticker and a premium sticker animation must be played. +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Sticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Sticker.md new file mode 100644 index 0000000000..fa077fde53 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Sticker.md @@ -0,0 +1,123 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Sticker: Represents a sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Sticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a sticker. + + + +## Properties +* `$premiumSticker`: `bool` Whether this is a premium sticker and a premium sticker animation must be played. +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Video.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Video.md new file mode 100644 index 0000000000..5371ca5bf3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Video.md @@ -0,0 +1,123 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Video: Represents a video." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Video` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a video. + + + +## Properties +* `$hasStickers`: `bool` If true; the current media has attached mask stickers. +* `$duration`: `float` Video duration in seconds +* `$supportsStreaming`: `bool` Whether the video supports streaming +* `$width`: `int` Video width +* `$height`: `int` Video height +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/VideoSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/VideoSticker.md new file mode 100644 index 0000000000..cb1c898e80 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/VideoSticker.md @@ -0,0 +1,124 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\VideoSticker: Represents a video sticker." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\VideoSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a video sticker. + + + +## Properties +* `$duration`: `float` +* `$premiumSticker`: `bool` Whether this is a premium sticker and a premium sticker animation must be played. +* `$emoji`: `string` Emoji representation of sticker +* `$stickerset`: `array` Associated stickerset +* `$width`: `?int` +* `$height`: `?int` +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Media/Voice.md b/docs/PHP/danog/MadelineProto/EventHandler/Media/Voice.md new file mode 100644 index 0000000000..a80d8f0cfa --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Media/Voice.md @@ -0,0 +1,120 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Media\\Voice: Represents a voice message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Media\Voice` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a voice message. + + + +## Properties +* `$waveform`: `(list> | null)` 100 values from 0 to 31, representing a waveform. +* `$duration`: `int` Audio duration in seconds +* `$size`: `int` Media filesize +* `$fileName`: `string` Media file name +* `$fileExt`: `string` Media file extension +* `$creationDate`: `int` Media creation date +* `$mimeType`: `string` Media MIME type +* `$ttl`: `?int` Time-to-live of media +* `$thumbs`: `list` Thumbnails +* `$videoThumbs`: `list` Video thumbnails +* `$spoiler`: `bool` Whether the media should be hidden behind a spoiler +* `$botApiFileId`: `string` File ID in bot API format (always present even for users) +* `$botApiFileUniqueId`: `string` Unique file ID in bot API format (always present even for users) +* `$encrypted`: `bool` Whether this media originates from a secret chat. +* `$thumb`: `?danog\MadelineProto\TL\Types\Bytes` Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90) only for secret chats. +* `$thumbHeight`: `?int` Thumbnail height only for secret chats. +* `$thumbWidth`: `?int` Thumbnail width only for secret chats. +* `$protected`: `bool` Whether this media is protected + +## Method list: +* [`getDownloadLink((string|null) $scriptUrl = NULL): string`](#getDownloadLink) +* [`getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToDir) +* [`downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string`](#downloadToFile) +* [`getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}`](#getDownloadInfo) + +## Methods: +### `getDownloadLink((string|null) $scriptUrl = NULL): string` + +Gets a download link for any file up to 4GB. + + +Parameters: + +* `$scriptUrl`: `(string|null)` Optional path to custom download script (not needed when running via web) + + + +### `getStream((callable(float, float, float): voi)|null) $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Get a readable amp stream with the file contents. + + +Parameters: + +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$offset`: `int` +* `$end`: `int` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToDir(string $dir = NULL, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to working directory or passed path. + + +Parameters: + +* `$dir`: `string` Directory where to download the file +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `downloadToFile(string $file, (callable(float, float, float): voi)|null) $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): string` + +Download the media to file. + + +Parameters: + +* `$file`: `string` Downloaded file path +* `$cb`: `(callable(float, float, float): voi)|null)` Progress callback +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getDownloadInfo(): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string}` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message.md b/docs/PHP/danog/MadelineProto/EventHandler/Message.md new file mode 100644 index 0000000000..d8ac20bc54 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message.md @@ -0,0 +1,784 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message: Represents an incoming or outgoing message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents an incoming or outgoing message. + + + +## Properties +* `$message`: `string` Content of the message +* `$fwdInfo`: `?danog\MadelineProto\EventHandler\ForwardedInfo` Info about a forwarded message +* `$command`: `?string` Bot command (if present) +* `$commandType`: `?danog\MadelineProto\EventHandler\CommandType` Bot command type (if present) +* `$commandArgs`: `list` Bot command arguments (if present) +* `$protected`: `bool` Whether this message is protected +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$media`: `(danog\MadelineProto\EventHandler\Media\Audio | danog\MadelineProto\EventHandler\Media\Document | danog\MadelineProto\EventHandler\Media\DocumentPhoto | danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\MaskSticker | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\RoundVideo | danog\MadelineProto\EventHandler\Media\Sticker | danog\MadelineProto\EventHandler\Media\Video | danog\MadelineProto\EventHandler\Media\Voice | null)` Attached media. +* `$fromScheduled`: `bool` Whether this message is a *sent* scheduled message +* `$viaBotId`: `?int` If the message was generated by an inline query, ID of the bot that generated it +* `$editDate`: `?int` Last edit date of the message +* `$keyboard`: `(danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard | danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard | null)` Inline or reply keyboard. +* `$imported`: `bool` Whether this message was [imported from a foreign chat service](https://core.telegram.org/api/import) +* `$psaType`: `?string` For Public Service Announcement messages, the PSA type +* `$nextSent`: `?self` +* `$views`: `?int` View counter for messages from channels or forwarded from channels +* `$forwards`: `?int` Forward counter for messages from channels or forwarded from channels +* `$signature`: `?string` Author of the post, if signatures are enabled for messages from channels or forwarded from channels +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text +* `$groupedId`: `?int` Group ID for albums. + +All messages associated to the same album will have an identical grouped ID. +* `$poll`: `?danog\MadelineProto\EventHandler\AbstractPoll` The poll +* `$scheduled`: `bool` Whether this message is a scheduled message +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`getOurReactions(): list<(string|int)>`](#getOurReactions) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool`](#report) +* [`saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void`](#saveContact) +* [`removeContact(): void`](#removeContact) +* [`inviteToChannel((string|int) $channel): void`](#inviteToChannel) +* [`addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>`](#addReaction) +* [`delReaction((string|int) $reaction): list<(string|int)>`](#delReaction) +* [`translate(string $toLang): string`](#translate) +* [`editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#replyOrEdit) +* [`forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>`](#forward) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `getOurReactions(): list<(string|int)>` + +Get our reactions on the message. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void` + +Save message sender to your account contacts. + + +Parameters: + +* `$firstName`: `string` First name +* `$lastName`: `(string|null)` Last name +* `$phoneNumber`: `(string|null)` Telegram ID of the other user +* `$addPhonePrivacyException`: `bool` Allow the other user to see our phone number? + + + +### `removeContact(): void` + +Remove message sender from your account contacts. + + + +### `inviteToChannel((string|int) $channel): void` + +Invite message sender to requested channel. + + +Parameters: + +* `$channel`: `(string|int)` Username, Channel ID + + + +### `addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>` + +Add reaction to message. + + +Parameters: + +* `$reaction`: `(string|int)` reaction +* `$big`: `bool` Whether a bigger and longer reaction should be shown +* `$addToRecent`: `bool` Add this reaction to the recent reactions list. + + + +### `delReaction((string|int) $reaction): list<(string|int)>` + +Delete reaction from message. + + +Parameters: + +* `$reaction`: `(string|int)` string or int Reaction + + + +### `translate(string $toLang): string` + +Translate text message(for media translate it caption). + + +Parameters: + +* `$toLang`: `string` Two-letter ISO 639-1 language code of the language to which the message is translated + + + +### `editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +### `replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +If the message is outgoing, will edit the message's text, otherwise will reply to the message. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) + + + + +### `forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>` + +Forwards messages by their IDs. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer +* `$id`: `list` IDs of messages +* `$dropAuthor`: `bool` Whether to forward messages without quoting the original author +* `$dropCaption`: `bool` Whether to strip captions from media +* `$topicId`: `int` Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$score`: `boolean` When forwarding games, whether to include your score in the game +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. + + +#### See also: +* `non-empty-list` + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the message. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.md new file mode 100644 index 0000000000..690b8b50fa --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.md @@ -0,0 +1,868 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\ChannelMessage: Represents an incoming or outgoing channel message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\ChannelMessage` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an incoming or outgoing channel message. + + + +## Properties +* `$message`: `string` Content of the message +* `$fwdInfo`: `?danog\MadelineProto\EventHandler\ForwardedInfo` Info about a forwarded message +* `$command`: `?string` Bot command (if present) +* `$commandType`: `?danog\MadelineProto\EventHandler\CommandType` Bot command type (if present) +* `$commandArgs`: `list` Bot command arguments (if present) +* `$protected`: `bool` Whether this message is protected +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$media`: `(danog\MadelineProto\EventHandler\Media\Audio | danog\MadelineProto\EventHandler\Media\Document | danog\MadelineProto\EventHandler\Media\DocumentPhoto | danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\MaskSticker | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\RoundVideo | danog\MadelineProto\EventHandler\Media\Sticker | danog\MadelineProto\EventHandler\Media\Video | danog\MadelineProto\EventHandler\Media\Voice | null)` Attached media. +* `$fromScheduled`: `bool` Whether this message is a *sent* scheduled message +* `$viaBotId`: `?int` If the message was generated by an inline query, ID of the bot that generated it +* `$editDate`: `?int` Last edit date of the message +* `$keyboard`: `(danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard | danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard | null)` Inline or reply keyboard. +* `$imported`: `bool` Whether this message was [imported from a foreign chat service](https://core.telegram.org/api/import) +* `$psaType`: `?string` For Public Service Announcement messages, the PSA type +* `$nextSent`: `?self` +* `$views`: `?int` View counter for messages from channels or forwarded from channels +* `$forwards`: `?int` Forward counter for messages from channels or forwarded from channels +* `$signature`: `?string` Author of the post, if signatures are enabled for messages from channels or forwarded from channels +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text +* `$groupedId`: `?int` Group ID for albums. + +All messages associated to the same album will have an identical grouped ID. +* `$poll`: `?danog\MadelineProto\EventHandler\AbstractPoll` The poll +* `$scheduled`: `bool` Whether this message is a scheduled message +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`getDiscussion(): ?\danog\MadelineProto\EventHandler\Message\GroupMessage`](#getDiscussion) +* [`disableSignatures(): void`](#disableSignatures) +* [`enableSignatures(): void`](#enableSignatures) +* [`getMember((string|integer) $member): \danog\MadelineProto\EventHandler\Participant`](#getMember) +* [`view(): void`](#view) +* [`hideHistory(): void`](#hideHistory) +* [`unhideHistory(): void`](#unhideHistory) +* [`enableProtection(): void`](#enableProtection) +* [`disableProtection(): void`](#disableProtection) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`getOurReactions(): list<(string|int)>`](#getOurReactions) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool`](#report) +* [`saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void`](#saveContact) +* [`removeContact(): void`](#removeContact) +* [`inviteToChannel((string|int) $channel): void`](#inviteToChannel) +* [`addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>`](#addReaction) +* [`delReaction((string|int) $reaction): list<(string|int)>`](#delReaction) +* [`translate(string $toLang): string`](#translate) +* [`editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#replyOrEdit) +* [`forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>`](#forward) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `getDiscussion(): ?\danog\MadelineProto\EventHandler\Message\GroupMessage` + +Obtains the copy of the current message, that was sent to the linked group. + +Can be used to reply in the comment section, for example: + +```php +$update->getDiscussion()->reply("Comment"); +``` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\GroupMessage`: Represents an incoming or outgoing group message.](../../../../danog/MadelineProto/EventHandler/Message/GroupMessage.html) + + + + +### `disableSignatures(): void` + +Disable message signatures in channels. + + + +### `enableSignatures(): void` + +Enable message signatures in channels. + + + +### `getMember((string|integer) $member): \danog\MadelineProto\EventHandler\Participant` + +Get info about a [channel/supergroup](https://core.telegram.org/api/channel) participant. + + +Parameters: + +* `$member`: `(string|integer)` Participant to get info about. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Participant`: Info about a channel participant.](../../../../danog/MadelineProto/EventHandler/Participant.html) + + + + +### `view(): void` + +Increase the view counter of a current message in the channel. + + + +### `hideHistory(): void` + +Hide message history for new channel users. + + + +### `unhideHistory(): void` + +Unhide message history for new channel users. + + + +### `enableProtection(): void` + +Enable [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) on a channel. + + + +### `disableProtection(): void` + +Disable [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) on a channel. + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `getOurReactions(): list<(string|int)>` + +Get our reactions on the message. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void` + +Save message sender to your account contacts. + + +Parameters: + +* `$firstName`: `string` First name +* `$lastName`: `(string|null)` Last name +* `$phoneNumber`: `(string|null)` Telegram ID of the other user +* `$addPhonePrivacyException`: `bool` Allow the other user to see our phone number? + + + +### `removeContact(): void` + +Remove message sender from your account contacts. + + + +### `inviteToChannel((string|int) $channel): void` + +Invite message sender to requested channel. + + +Parameters: + +* `$channel`: `(string|int)` Username, Channel ID + + + +### `addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>` + +Add reaction to message. + + +Parameters: + +* `$reaction`: `(string|int)` reaction +* `$big`: `bool` Whether a bigger and longer reaction should be shown +* `$addToRecent`: `bool` Add this reaction to the recent reactions list. + + + +### `delReaction((string|int) $reaction): list<(string|int)>` + +Delete reaction from message. + + +Parameters: + +* `$reaction`: `(string|int)` string or int Reaction + + + +### `translate(string $toLang): string` + +Translate text message(for media translate it caption). + + +Parameters: + +* `$toLang`: `string` Two-letter ISO 639-1 language code of the language to which the message is translated + + + +### `editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +### `replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +If the message is outgoing, will edit the message's text, otherwise will reply to the message. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>` + +Forwards messages by their IDs. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer +* `$id`: `list` IDs of messages +* `$dropAuthor`: `bool` Whether to forward messages without quoting the original author +* `$dropCaption`: `bool` Whether to strip captions from media +* `$topicId`: `int` Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$score`: `boolean` When forwarding games, whether to include your score in the game +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. + + +#### See also: +* `non-empty-list` + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the message. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/BankCard.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/BankCard.md new file mode 100644 index 0000000000..1115c01149 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/BankCard.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\BankCard: Indicates a credit card number." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\BankCard` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Indicates a credit card number. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Blockquote.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Blockquote.md new file mode 100644 index 0000000000..570ca1a726 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Blockquote.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Blockquote: Message entity representing a block quote." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Blockquote` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a block quote. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Bold.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Bold.md new file mode 100644 index 0000000000..d7101803eb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Bold.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Bold: Message entity representing bold text." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Bold` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing bold text. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/BotCommand.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/BotCommand.md new file mode 100644 index 0000000000..6a21ebf5f5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/BotCommand.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\BotCommand: Message entity representing a bot /command." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\BotCommand` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a bot /command. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Cashtag.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Cashtag.md new file mode 100644 index 0000000000..9f95a47a55 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Cashtag.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Cashtag: Message entity representing a $cashtag." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Cashtag` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a $cashtag. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Code.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Code.md new file mode 100644 index 0000000000..591ef73565 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Code.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Code: Message entity representing a codeblock." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Code` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a codeblock. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/CustomEmoji.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/CustomEmoji.md new file mode 100644 index 0000000000..84ece83fc8 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/CustomEmoji.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\CustomEmoji: Represents a custom emoji." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\CustomEmoji` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Represents a custom emoji. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) +* `$documentId`: `int` Document ID of the [custom emoji](https://core.telegram.org/api/custom-emoji). + +## Method list: +* [`__construct(int $offset, int $length, int $documentId)`](#__construct) +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `__construct(int $offset, int $length, int $documentId)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` +* `$documentId`: `int` + + + +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Email.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Email.md new file mode 100644 index 0000000000..f776a7d4d4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Email.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Email: Message entity representing an email@example.com." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Email` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing an email@example.com. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Hashtag.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Hashtag.md new file mode 100644 index 0000000000..adc747b91f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Hashtag.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Hashtag: #hashtag message entity." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Hashtag` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +#hashtag message entity. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/InputMentionName.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/InputMentionName.md new file mode 100644 index 0000000000..bec40fc9ca --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/InputMentionName.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\InputMentionName: Message entity representing a [user mention](https://core.telegram.org/api/mentions) created by the user, not returned by the API." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\InputMentionName` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a [user mention](https://core.telegram.org/api/mentions) created by the user, not returned by the API. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) +* `$userId`: `(string | int)` Identifier of the user that was mentioned + +## Method list: +* [`__construct(int $offset, int $length, string|int $userId)`](#__construct) +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `__construct(int $offset, int $length, string|int $userId)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` +* `$userId`: `string|int` + + + +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Italic.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Italic.md new file mode 100644 index 0000000000..75137a06f1 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Italic.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Italic: Message entity representing italic text." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Italic` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing italic text. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Mention.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Mention.md new file mode 100644 index 0000000000..f30ca553d2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Mention.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Mention: Message entity mentioning the current user." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Mention` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity mentioning the current user. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/MentionName.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/MentionName.md new file mode 100644 index 0000000000..eed3ed1e57 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/MentionName.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\MentionName: Message entity representing a [user mention](https://core.telegram.org/api/mentions)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\MentionName` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a [user mention](https://core.telegram.org/api/mentions). + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) +* `$userId`: `int` Identifier of the user that was mentioned + +## Method list: +* [`__construct(int $offset, int $length, int $userId)`](#__construct) +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `__construct(int $offset, int $length, int $userId)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` +* `$userId`: `int` + + + +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.md new file mode 100644 index 0000000000..c43f101711 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\MessageEntity: Master class for message entities." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\MessageEntity` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Master class for message entities. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) + +## Methods: +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +### `toBotAPI(): array` + +Convert entity to bot API entity. + + + +### `toMTProto(): array` + +Convert entity to MTProto entity. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Phone.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Phone.md new file mode 100644 index 0000000000..dd3558282a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Phone.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Phone: Message entity representing a phone number." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Phone` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a phone number. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Pre.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Pre.md new file mode 100644 index 0000000000..b5796cad63 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Pre.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Pre: Message entity representing a preformatted codeblock, allowing the user to specify a programming language for the codeblock." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Pre` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a preformatted codeblock, allowing the user to specify a programming language for the codeblock. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) +* `$language`: `string` Programming language of the code + +## Method list: +* [`__construct(int $offset, int $length, string $language)`](#__construct) +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `__construct(int $offset, int $length, string $language)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` +* `$language`: `string` + + + +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Spoiler.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Spoiler.md new file mode 100644 index 0000000000..ad3907cd49 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Spoiler.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Spoiler: Message entity representing a spoiler." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Spoiler` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a spoiler. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Strike.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Strike.md new file mode 100644 index 0000000000..e5ca206c2f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Strike.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Strike: Message entity representing strikethrough text." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Strike` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing strikethrough text. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/TextUrl.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/TextUrl.md new file mode 100644 index 0000000000..db38aaf985 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/TextUrl.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\TextUrl: Message entity representing a text url: for in-text urls like https://google.com use Url." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\TextUrl` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing a text url: for in-text urls like https://google.com use Url. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) +* `$url`: `string` The actual URL + +## Method list: +* [`__construct(int $offset, int $length, string $url)`](#__construct) +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `__construct(int $offset, int $length, string $url)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` +* `$url`: `string` + + + +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Underline.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Underline.md new file mode 100644 index 0000000000..1b79d7ece3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Underline.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Underline: Message entity representing underlined text." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Underline` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing underlined text. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Url.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Url.md new file mode 100644 index 0000000000..ce0b67bed6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Entities/Url.md @@ -0,0 +1,77 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Entities\\Url: Message entity representing an in-text url: https://google.com; for text urls, use TextUrl." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Entities\Url` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Message entity representing an in-text url: https://google.com; for text urls, use TextUrl. + + + +## Properties +* `$offset`: `int` Offset of message entity within message (in UTF-16 code units) +* `$length`: `int` Length of message entity within message (in UTF-16 code units) + +## Method list: +* [`toBotAPI(): array`](#toBotAPI) +* [`toMTProto(): array`](#toMTProto) +* [`__construct(int $offset, int $length)`](#__construct) +* [`fromRawEntities(list $entities): list`](#fromRawEntities) +* [`fromRawEntity(array $entity): self`](#fromRawEntity) + +## Methods: +### `toBotAPI(): array` + + + + + +### `toMTProto(): array` + + + + + +### `__construct(int $offset, int $length)` + + + + +Parameters: + +* `$offset`: `int` +* `$length`: `int` + + + +### `fromRawEntities(list $entities): list` + + + + +Parameters: + +* `$entities`: `list` + + + +### `fromRawEntity(array $entity): self` + + + + +Parameters: + +* `$entity`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.md new file mode 100644 index 0000000000..d4e2ddc33e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.md @@ -0,0 +1,1057 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\GroupMessage: Represents an incoming or outgoing group message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\GroupMessage` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an incoming or outgoing group message. + + + +## Properties +* `$message`: `string` Content of the message +* `$fwdInfo`: `?danog\MadelineProto\EventHandler\ForwardedInfo` Info about a forwarded message +* `$command`: `?string` Bot command (if present) +* `$commandType`: `?danog\MadelineProto\EventHandler\CommandType` Bot command type (if present) +* `$commandArgs`: `list` Bot command arguments (if present) +* `$protected`: `bool` Whether this message is protected +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$media`: `(danog\MadelineProto\EventHandler\Media\Audio | danog\MadelineProto\EventHandler\Media\Document | danog\MadelineProto\EventHandler\Media\DocumentPhoto | danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\MaskSticker | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\RoundVideo | danog\MadelineProto\EventHandler\Media\Sticker | danog\MadelineProto\EventHandler\Media\Video | danog\MadelineProto\EventHandler\Media\Voice | null)` Attached media. +* `$fromScheduled`: `bool` Whether this message is a *sent* scheduled message +* `$viaBotId`: `?int` If the message was generated by an inline query, ID of the bot that generated it +* `$editDate`: `?int` Last edit date of the message +* `$keyboard`: `(danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard | danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard | null)` Inline or reply keyboard. +* `$imported`: `bool` Whether this message was [imported from a foreign chat service](https://core.telegram.org/api/import) +* `$psaType`: `?string` For Public Service Announcement messages, the PSA type +* `$nextSent`: `?self` +* `$views`: `?int` View counter for messages from channels or forwarded from channels +* `$forwards`: `?int` Forward counter for messages from channels or forwarded from channels +* `$signature`: `?string` Author of the post, if signatures are enabled for messages from channels or forwarded from channels +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text +* `$groupedId`: `?int` Group ID for albums. + +All messages associated to the same album will have an identical grouped ID. +* `$poll`: `?danog\MadelineProto\EventHandler\AbstractPoll` The poll +* `$scheduled`: `bool` Whether this message is a scheduled message +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`getMember((string|integer|null) $member = NULL): \danog\MadelineProto\EventHandler\Participant`](#getMember) +* [`hideMembers(): void`](#hideMembers) +* [`unhideMembers(): void`](#unhideMembers) +* [`hideHistory(): void`](#hideHistory) +* [`unhideHistory(): void`](#unhideHistory) +* [`ban(int $untilDate = 0): void`](#ban) +* [`unban(int $untilDate = 0): void`](#unban) +* [`kick(): void`](#kick) +* [`deleteAll(bool $forEveryone = true, int $maxId = 0): void`](#deleteAll) +* [`deleteUserMessages((string|integer|null) $member = NULL): void`](#deleteUserMessages) +* [`toSuperGroup(): integer`](#toSuperGroup) +* [`enableAntiSpam(): void`](#enableAntiSpam) +* [`disableAntiSpam(): void`](#disableAntiSpam) +* [`enableTopics(): void`](#enableTopics) +* [`disableTopics(): void`](#disableTopics) +* [`createTopic(string $title, (\danog\MadelineProto\EventHandler\Topic\IconColor|int) $icon = \danog\MadelineProto\EventHandler\Topic\IconColor::NONE): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated`](#createTopic) +* [`editTopic(string $title, integer $icon = 0, (integer|null) $topicId = NULL): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited`](#editTopic) +* [`openTopic((integer|null) $topicId = NULL): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited`](#openTopic) +* [`closeTopic((integer|null) $topicId = NULL): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited`](#closeTopic) +* [`deleteTopic((integer|null) $topicId = NULL): void`](#deleteTopic) +* [`enableSlowMode(integer $seconds): void`](#enableSlowMode) +* [`disableSlowMode(): void`](#disableSlowMode) +* [`enableProtection(): void`](#enableProtection) +* [`disableProtection(): void`](#disableProtection) +* [`enableJoinToComment(): void`](#enableJoinToComment) +* [`disableJoinToComment(): void`](#disableJoinToComment) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`getOurReactions(): list<(string|int)>`](#getOurReactions) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool`](#report) +* [`saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void`](#saveContact) +* [`removeContact(): void`](#removeContact) +* [`inviteToChannel((string|int) $channel): void`](#inviteToChannel) +* [`addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>`](#addReaction) +* [`delReaction((string|int) $reaction): list<(string|int)>`](#delReaction) +* [`translate(string $toLang): string`](#translate) +* [`editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#replyOrEdit) +* [`forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>`](#forward) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `getMember((string|integer|null) $member = NULL): \danog\MadelineProto\EventHandler\Participant` + +Get info about a [channel/supergroup](https://core.telegram.org/api/channel) participant. + + +Parameters: + +* `$member`: `(string|integer|null)` Participant to get info about; can be empty or null to get info about the sender of the message. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Participant`: Info about a channel participant.](../../../../danog/MadelineProto/EventHandler/Participant.html) + + + + +### `hideMembers(): void` + +Hide the participants list in a [supergroup](https://core.telegram.org/api/channel). +The supergroup must have at least `hidden_members_group_size_min` participants in order to use this method, as specified by the [client configuration parameters »](https://core.telegram.org/api/config#client-configuration). + + + +### `unhideMembers(): void` + +Display the participants list in a [supergroup](https://core.telegram.org/api/channel). +The supergroup must have at least `hidden_members_group_size_min` participants in order to use this method, as specified by the [client configuration parameters »](https://core.telegram.org/api/config#client-configuration). + + + +### `hideHistory(): void` + +Hide message history for new supergroup users. + + + +### `unhideHistory(): void` + +Unhide message history for new supergroup users. + + + +### `ban(int $untilDate = 0): void` + +Ban message sender from current supergroup. + + +Parameters: + +* `$untilDate`: `int` Validity of said permissions (it is considered forever any value less then 30 seconds or more then 366 days). + + + +### `unban(int $untilDate = 0): void` + +Unban message sender from current supergroup. + + +Parameters: + +* `$untilDate`: `int` Validity of said permissions (it is considered forever any value less then 30 seconds or more then 366 days). + + + +### `kick(): void` + +Kick message sender from current supergroup. + + + +### `deleteAll(bool $forEveryone = true, int $maxId = 0): void` + +Delete all supergroup message. + + +Parameters: + +* `$forEveryone`: `bool` +* `$maxId`: `int` + + + +### `deleteUserMessages((string|integer|null) $member = NULL): void` + +Delete all messages sent by a specific participant of a given supergroup. + + +Parameters: + +* `$member`: `(string|integer|null)` The participant whose messages should be deleted, if null or absent defaults to the sender of the message. + + + +### `toSuperGroup(): integer` + +Turn a [basic group into a supergroup](https://core.telegram.org/api/channel#migration). + + +Return value: the channel id we migrated to + + +### `enableAntiSpam(): void` + +Enable the [native antispam system](https://core.telegram.org/api/antispam). + + + +### `disableAntiSpam(): void` + +Disable the [native antispam system](https://core.telegram.org/api/antispam). + + + +### `enableTopics(): void` + +Enable [forum functionality](https://core.telegram.org/api/forum) in a supergroup. + + + +### `disableTopics(): void` + +Disable [forum functionality](https://core.telegram.org/api/forum) in a supergroup. + + + +### `createTopic(string $title, (\danog\MadelineProto\EventHandler\Topic\IconColor|int) $icon = \danog\MadelineProto\EventHandler\Topic\IconColor::NONE): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated` + +Create a [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights). + + +Parameters: + +* `$title`: `string` Topic title (maximum UTF-8 length: 128) +* `$icon`: `(\danog\MadelineProto\EventHandler\Topic\IconColor|int)` Icon color, or ID of the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon. + [Telegram Premium](https://core.telegram.org/api/premium) users can use any custom emoji, other users can only use the custom emojis contained in the [inputStickerSetEmojiDefaultTopicIcons](https://docs.madelineproto.xyz/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.html) emoji pack. + If no custom emoji icon is specified, specifies the color of the fallback topic icon + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Topic\IconColor`: Specifies the color of the fallback topic icon (RGB) if no custom emoji icon is specified.](../../../../danog/MadelineProto/EventHandler/Topic/IconColor.html) +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated`: A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html) + + + + +### `editTopic(string $title, integer $icon = 0, (integer|null) $topicId = NULL): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited` + +Edit a [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights). + + +Parameters: + +* `$title`: `string` Topic title (maximum UTF-8 length: 128) +* `$icon`: `integer` ID of the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon. [Telegram Premium](https://core.telegram.org/api/premium) users can use any custom emoji, other users can only use the custom emojis contained in the [inputStickerSetEmojiDefaultTopicIcons](https://docs.madelineproto.xyz/API_docs/constructors/inputStickerSetEmojiDefaultTopicIcons.html) emoji pack. Pass 0 to switch to the fallback topic icon. +* `$topicId`: `(integer|null)` Topic ID, if absent defaults to the topic where this message was sent. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited`: [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) + + + + +### `openTopic((integer|null) $topicId = NULL): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited` + +Open a [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights). + + +Parameters: + +* `$topicId`: `(integer|null)` Topic ID, if absent defaults to the topic where this message was sent. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited`: [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) + + + + +### `closeTopic((integer|null) $topicId = NULL): \danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited` + +Close a [forum topic](https://core.telegram.org/api/forum); requires [`manage_topics` rights](https://core.telegram.org/api/rights). + + +Parameters: + +* `$topicId`: `(integer|null)` Topic ID, if absent defaults to the topic where this message was sent. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited`: [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) + + + + +### `deleteTopic((integer|null) $topicId = NULL): void` + +Delete message history of a [forum topic](https://core.telegram.org/api/forum). + + +Parameters: + +* `$topicId`: `(integer|null)` Topic ID, if absent defaults to the topic where this message was sent. + + + +### `enableSlowMode(integer $seconds): void` + +Toggle supergroup slow mode: Users will only be able to send one message every `$seconds` seconds. + + +Parameters: + +* `$seconds`: `integer` Users will only be able to send one message every `$seconds` seconds + + + +### `disableSlowMode(): void` + +Disable supergroup slow mode. + + + +### `enableProtection(): void` + +Enable or disable [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) on a chat. + + + +### `disableProtection(): void` + +Enable or disable [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) on a chat. + + + +### `enableJoinToComment(): void` + +Enable to all users [should join a discussion group in order to comment on a post »](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group). + + + +### `disableJoinToComment(): void` + +Disable to all users [should join a discussion group in order to comment on a post »](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group). + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `getOurReactions(): list<(string|int)>` + +Get our reactions on the message. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void` + +Save message sender to your account contacts. + + +Parameters: + +* `$firstName`: `string` First name +* `$lastName`: `(string|null)` Last name +* `$phoneNumber`: `(string|null)` Telegram ID of the other user +* `$addPhonePrivacyException`: `bool` Allow the other user to see our phone number? + + + +### `removeContact(): void` + +Remove message sender from your account contacts. + + + +### `inviteToChannel((string|int) $channel): void` + +Invite message sender to requested channel. + + +Parameters: + +* `$channel`: `(string|int)` Username, Channel ID + + + +### `addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>` + +Add reaction to message. + + +Parameters: + +* `$reaction`: `(string|int)` reaction +* `$big`: `bool` Whether a bigger and longer reaction should be shown +* `$addToRecent`: `bool` Add this reaction to the recent reactions list. + + + +### `delReaction((string|int) $reaction): list<(string|int)>` + +Delete reaction from message. + + +Parameters: + +* `$reaction`: `(string|int)` string or int Reaction + + + +### `translate(string $toLang): string` + +Translate text message(for media translate it caption). + + +Parameters: + +* `$toLang`: `string` Two-letter ISO 639-1 language code of the language to which the message is translated + + + +### `editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +### `replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +If the message is outgoing, will edit the message's text, otherwise will reply to the message. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>` + +Forwards messages by their IDs. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer +* `$id`: `list` IDs of messages +* `$dropAuthor`: `bool` Whether to forward messages without quoting the original author +* `$dropCaption`: `bool` Whether to strip captions from media +* `$topicId`: `int` Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$score`: `boolean` When forwarding games, whether to include your score in the game +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. + + +#### See also: +* `non-empty-list` + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the message. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.md new file mode 100644 index 0000000000..cf1f9dd0e2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.md @@ -0,0 +1,796 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\PrivateMessage: Represents an incoming or outgoing private message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\PrivateMessage` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an incoming or outgoing private message. + + + +## Properties +* `$message`: `string` Content of the message +* `$fwdInfo`: `?danog\MadelineProto\EventHandler\ForwardedInfo` Info about a forwarded message +* `$command`: `?string` Bot command (if present) +* `$commandType`: `?danog\MadelineProto\EventHandler\CommandType` Bot command type (if present) +* `$commandArgs`: `list` Bot command arguments (if present) +* `$protected`: `bool` Whether this message is protected +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$media`: `(danog\MadelineProto\EventHandler\Media\Audio | danog\MadelineProto\EventHandler\Media\Document | danog\MadelineProto\EventHandler\Media\DocumentPhoto | danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\MaskSticker | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\RoundVideo | danog\MadelineProto\EventHandler\Media\Sticker | danog\MadelineProto\EventHandler\Media\Video | danog\MadelineProto\EventHandler\Media\Voice | null)` Attached media. +* `$fromScheduled`: `bool` Whether this message is a *sent* scheduled message +* `$viaBotId`: `?int` If the message was generated by an inline query, ID of the bot that generated it +* `$editDate`: `?int` Last edit date of the message +* `$keyboard`: `(danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard | danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard | null)` Inline or reply keyboard. +* `$imported`: `bool` Whether this message was [imported from a foreign chat service](https://core.telegram.org/api/import) +* `$psaType`: `?string` For Public Service Announcement messages, the PSA type +* `$nextSent`: `?self` +* `$views`: `?int` View counter for messages from channels or forwarded from channels +* `$forwards`: `?int` Forward counter for messages from channels or forwarded from channels +* `$signature`: `?string` Author of the post, if signatures are enabled for messages from channels or forwarded from channels +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text +* `$groupedId`: `?int` Group ID for albums. + +All messages associated to the same album will have an identical grouped ID. +* `$poll`: `?danog\MadelineProto\EventHandler\AbstractPoll` The poll +* `$scheduled`: `bool` Whether this message is a scheduled message +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`screenShot(): \danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken`](#screenShot) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`getOurReactions(): list<(string|int)>`](#getOurReactions) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool`](#report) +* [`saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void`](#saveContact) +* [`removeContact(): void`](#removeContact) +* [`inviteToChannel((string|int) $channel): void`](#inviteToChannel) +* [`addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>`](#addReaction) +* [`delReaction((string|int) $reaction): list<(string|int)>`](#delReaction) +* [`translate(string $toLang): string`](#translate) +* [`editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#replyOrEdit) +* [`forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>`](#forward) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `screenShot(): \danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken` + + + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken`: A screenshot of the chat was taken.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html) + + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `getOurReactions(): list<(string|int)>` + +Get our reactions on the message. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void` + +Save message sender to your account contacts. + + +Parameters: + +* `$firstName`: `string` First name +* `$lastName`: `(string|null)` Last name +* `$phoneNumber`: `(string|null)` Telegram ID of the other user +* `$addPhonePrivacyException`: `bool` Allow the other user to see our phone number? + + + +### `removeContact(): void` + +Remove message sender from your account contacts. + + + +### `inviteToChannel((string|int) $channel): void` + +Invite message sender to requested channel. + + +Parameters: + +* `$channel`: `(string|int)` Username, Channel ID + + + +### `addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>` + +Add reaction to message. + + +Parameters: + +* `$reaction`: `(string|int)` reaction +* `$big`: `bool` Whether a bigger and longer reaction should be shown +* `$addToRecent`: `bool` Add this reaction to the recent reactions list. + + + +### `delReaction((string|int) $reaction): list<(string|int)>` + +Delete reaction from message. + + +Parameters: + +* `$reaction`: `(string|int)` string or int Reaction + + + +### `translate(string $toLang): string` + +Translate text message(for media translate it caption). + + +Parameters: + +* `$toLang`: `string` Two-letter ISO 639-1 language code of the language to which the message is translated + + + +### `editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +### `replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +If the message is outgoing, will edit the message's text, otherwise will reply to the message. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>` + +Forwards messages by their IDs. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer +* `$id`: `list` IDs of messages +* `$dropAuthor`: `bool` Whether to forward messages without quoting the original author +* `$dropCaption`: `bool` Whether to strip captions from media +* `$topicId`: `int` Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$score`: `boolean` When forwarding games, whether to include your score in the game +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. + + +#### See also: +* `non-empty-list` + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the message. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/ReportReason.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/ReportReason.md new file mode 100644 index 0000000000..75c3fd50a7 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/ReportReason.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\ReportReason: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\ReportReason` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Constants +* `danog\MadelineProto\EventHandler\Message\ReportReason::SPAM`: Report for spam + +* `danog\MadelineProto\EventHandler\Message\ReportReason::VIOLENCE`: Report for violence + +* `danog\MadelineProto\EventHandler\Message\ReportReason::PORNOGRAPHY`: Report for pornography + +* `danog\MadelineProto\EventHandler\Message\ReportReason::CHILD_ABUSE`: Report for child abuse + +* `danog\MadelineProto\EventHandler\Message\ReportReason::COPYRIGHT`: Report for copyrighted content + +* `danog\MadelineProto\EventHandler\Message\ReportReason::GEO_IRRELEVANT`: Report an irrelevant geogroup + +* `danog\MadelineProto\EventHandler\Message\ReportReason::FAKE`: Report for impersonation + +* `danog\MadelineProto\EventHandler\Message\ReportReason::ILLEGAL_DRUGS`: Report for illegal drugs + +* `danog\MadelineProto\EventHandler\Message\ReportReason::PERSONAL_DETAILS`: Report for divulgation of personal details + +* `danog\MadelineProto\EventHandler\Message\ReportReason::OTHER`: Other + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.md new file mode 100644 index 0000000000..aabede7c7a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.md @@ -0,0 +1,794 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\SecretMessage: Represents New encrypted message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\SecretMessage` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents New encrypted message. + + + +## Properties +* `$message`: `string` Content of the message +* `$fwdInfo`: `?danog\MadelineProto\EventHandler\ForwardedInfo` Info about a forwarded message +* `$command`: `?string` Bot command (if present) +* `$commandType`: `?danog\MadelineProto\EventHandler\CommandType` Bot command type (if present) +* `$commandArgs`: `list` Bot command arguments (if present) +* `$protected`: `bool` Whether this message is protected +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$media`: `(danog\MadelineProto\EventHandler\Media\Audio | danog\MadelineProto\EventHandler\Media\Document | danog\MadelineProto\EventHandler\Media\DocumentPhoto | danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\MaskSticker | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\RoundVideo | danog\MadelineProto\EventHandler\Media\Sticker | danog\MadelineProto\EventHandler\Media\Video | danog\MadelineProto\EventHandler\Media\Voice | null)` Attached media. +* `$fromScheduled`: `bool` Whether this message is a *sent* scheduled message +* `$viaBotId`: `?int` If the message was generated by an inline query, ID of the bot that generated it +* `$editDate`: `?int` Last edit date of the message +* `$keyboard`: `(danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard | danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard | null)` Inline or reply keyboard. +* `$imported`: `bool` Whether this message was [imported from a foreign chat service](https://core.telegram.org/api/import) +* `$psaType`: `?string` For Public Service Announcement messages, the PSA type +* `$nextSent`: `?self` +* `$views`: `?int` View counter for messages from channels or forwarded from channels +* `$forwards`: `?int` Forward counter for messages from channels or forwarded from channels +* `$signature`: `?string` Author of the post, if signatures are enabled for messages from channels or forwarded from channels +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text +* `$groupedId`: `?int` Group ID for albums. + +All messages associated to the same album will have an identical grouped ID. +* `$poll`: `?danog\MadelineProto\EventHandler\AbstractPoll` The poll +* `$scheduled`: `bool` Whether this message is a scheduled message +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`getReply(string $class = 'danog\\MadelineProto\\EventHandler\\Message\\SecretMessage'): ?\danog\MadelineProto\EventHandler\Message\SecretMessage`](#getReply) +* [`screenShot(): \danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken`](#screenShot) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`getOurReactions(): list<(string|int)>`](#getOurReactions) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool`](#report) +* [`saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void`](#saveContact) +* [`removeContact(): void`](#removeContact) +* [`inviteToChannel((string|int) $channel): void`](#inviteToChannel) +* [`addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>`](#addReaction) +* [`delReaction((string|int) $reaction): list<(string|int)>`](#delReaction) +* [`translate(string $toLang): string`](#translate) +* [`editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message`](#replyOrEdit) +* [`forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>`](#forward) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) +* [`isReply(): bool`](#isReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `getReply(string $class = 'danog\\MadelineProto\\EventHandler\\Message\\SecretMessage'): ?\danog\MadelineProto\EventHandler\Message\SecretMessage` + + + + +Parameters: + +* `$class`: `string` + + + +### `screenShot(): \danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken` + + + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken`: A screenshot of the chat was taken.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html) + + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `getOurReactions(): list<(string|int)>` + +Get our reactions on the message. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `saveContact(string $firstName, (string|null) $lastName = NULL, (string|null) $phoneNumber = NULL, bool $addPhonePrivacyException = false): void` + +Save message sender to your account contacts. + + +Parameters: + +* `$firstName`: `string` First name +* `$lastName`: `(string|null)` Last name +* `$phoneNumber`: `(string|null)` Telegram ID of the other user +* `$addPhonePrivacyException`: `bool` Allow the other user to see our phone number? + + + +### `removeContact(): void` + +Remove message sender from your account contacts. + + + +### `inviteToChannel((string|int) $channel): void` + +Invite message sender to requested channel. + + +Parameters: + +* `$channel`: `(string|int)` Username, Channel ID + + + +### `addReaction((string|int) $reaction, bool $big = false, bool $addToRecent = true): list<(string|int)>` + +Add reaction to message. + + +Parameters: + +* `$reaction`: `(string|int)` reaction +* `$big`: `bool` Whether a bigger and longer reaction should be shown +* `$addToRecent`: `bool` Add this reaction to the recent reactions list. + + + +### `delReaction((string|int) $reaction): list<(string|int)>` + +Delete reaction from message. + + +Parameters: + +* `$reaction`: `(string|int)` string or int Reaction + + + +### `translate(string $toLang): string` + +Translate text message(for media translate it caption). + + +Parameters: + +* `$toLang`: `string` Two-letter ISO 639-1 language code of the language to which the message is translated + + + +### `editText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +### `replyOrEdit(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (int|null) $scheduleDate = NULL, bool $noWebpage = false): \danog\MadelineProto\EventHandler\Message` + +If the message is outgoing, will edit the message's text, otherwise will reply to the message. + + +Parameters: + +* `$message`: `string` New message +* `$parseMode`: `\danog\MadelineProto\ParseMode` Whether to parse HTML or Markdown markup in the message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) + + + + +### `forward((integer|string) $peer, list $id = [], bool $dropAuthor = false, bool $dropCaption = false, int $topicId = 1, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $score = false, (integer|null) $scheduleDate = NULL, (integer|string|null) $sendAs = NULL): non-empty-list<\danog\MadelineProto\EventHandler\Message>` + +Forwards messages by their IDs. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer +* `$id`: `list` IDs of messages +* `$dropAuthor`: `bool` Whether to forward messages without quoting the original author +* `$dropCaption`: `bool` Whether to strip captions from media +* `$topicId`: `int` Destination [forum topic](https://core.telegram.org/api/forum#forum-topics) +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$score`: `boolean` When forwarding games, whether to include your score in the game +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. + + +#### See also: +* `non-empty-list` + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the message. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.md new file mode 100644 index 0000000000..2933a9cec3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.md @@ -0,0 +1,540 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogBotAllowed: We have given the bot permission to send us direct messages." +description: "The optional fields specify how did we authorize the bot to send us messages.\n" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogBotAllowed` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +We have given the bot permission to send us direct messages. + +The optional fields specify how did we authorize the bot to send us messages. + + +## Properties +* `$attachMenu`: `bool` We have authorized the bot to send us messages by installing the bot’s [attachment menu](https://core.telegram.org/api/bots/attach). +* `$domain`: `?string` We have authorized the bot to send us messages by logging into a website via [Telegram Login »](https://core.telegram.org/widgets/login); this field contains the domain name of the website on which the user has logged in. +* `$app`: `?danog\MadelineProto\EventHandler\BotApp` We have authorized the bot to send us messages by opening the specified [bot web app](https://core.telegram.org/api/bots/webapps). +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.md new file mode 100644 index 0000000000..055741cabe --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogChannelCreated: The channel was created." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogChannelCreated` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The channel was created. + + + +## Properties +* `$title`: `string` Original channel/supergroup title +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$title`: `string` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.md new file mode 100644 index 0000000000..2e46eb0fe3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.md @@ -0,0 +1,559 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogChannelMigrateFrom: Indicates the channel was [migrated](https://core.telegram.org/api/channel) from the specified chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogChannelMigrateFrom` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Indicates the channel was [migrated](https://core.telegram.org/api/channel) from the specified chat. + + + +## Properties +* `$oldTitle`: `string` The old chat title +* `$oldChatId`: `int` The old chat title +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $oldTitle, int $oldChatId)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $oldTitle, int $oldChatId)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$oldTitle`: `string` +* `$oldChatId`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.md new file mode 100644 index 0000000000..06b056e2c2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogChatJoinedByLink: A user joined the chat via an invite link." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogChatJoinedByLink` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A user joined the chat via an invite link. + + + +## Properties +* `$inviterId`: `int` ID of the user that created the invite link +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $inviterId)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $inviterId)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$inviterId`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.md new file mode 100644 index 0000000000..103220782e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogChatMigrateTo: Indicates the chat was [migrated](https://core.telegram.org/api/channel) to the specified supergroup." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogChatMigrateTo` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Indicates the chat was [migrated](https://core.telegram.org/api/channel) to the specified supergroup. + + + +## Properties +* `$channelId`: `int` The supergroup it was migrated to +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $channelId)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $channelId)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$channelId`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.md new file mode 100644 index 0000000000..7f87022446 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.md @@ -0,0 +1,536 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogContactSignUp: A contact just signed up to telegram." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogContactSignUp` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A contact just signed up to telegram. + + + +## Properties +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.md new file mode 100644 index 0000000000..90328a13ef --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.md @@ -0,0 +1,559 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogCreated: A chat or channel was created." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogCreated` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A chat or channel was created. + + + +## Properties +* `$title`: `string` Title of the created chat or channel +* `$users`: `list` List of group members +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title, array $users)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title, array $users)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$title`: `string` +* `$users`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.md new file mode 100644 index 0000000000..7ee98e132a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogDeleteMessages: Deleted messages." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogDeleteMessages` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Deleted messages. + + + +## Properties +* `$ids`: `list` List of deleted message IDs. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $ids)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $ids)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$ids`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.md new file mode 100644 index 0000000000..5611bc0518 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.md @@ -0,0 +1,559 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGameScore: Someone scored in a game." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGameScore` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Someone scored in a game. + + + +## Properties +* `$gameId`: `int` Game ID +* `$score`: `int` Score +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $gameId, int $score)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $gameId, int $score)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$gameId`: `int` +* `$score`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.md new file mode 100644 index 0000000000..269976d8aa --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.md @@ -0,0 +1,561 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGeoProximityReached: A user of the chat is now in proximity of another user." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGeoProximityReached` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A user of the chat is now in proximity of another user. + + + +## Properties +* `$fromId`: `int` The user or chat that is now in proximity of to_id +* `$toId`: `int` The user or chat that subscribed to [live geolocation proximity alerts](https://core.telegram.org/api/live-location#proximity-alert) +* `$distance`: `int` Distance, in meters (0-100000) +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $fromId, int $toId, int $distance)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $fromId, int $toId, int $distance)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$fromId`: `int` +* `$toId`: `int` +* `$distance`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.md new file mode 100644 index 0000000000..8cae1d90d9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.md @@ -0,0 +1,565 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGiftPremium: Info about a gifted Telegram Premium subscription." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGiftPremium` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Info about a gifted Telegram Premium subscription. + + + +## Properties +* `$currency`: `string` Three-letter ISO 4217 [currency](https://core.telegram.org/bots/payments#supported-currencies) code +* `$amount`: `int` Price of the gift in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in [currencies.json](https://core.telegram.org/bots/payments/currencies.json), it shows the number of digits past the decimal point for each currency (2 for the majority of currencies). +* `$months`: `int` Duration of the gifted Telegram Premium subscription +* `$cryptoCurrency`: `?int` If the gift was bought using a cryptocurrency, the cryptocurrency name. +* `$cryptoAmount`: `?int` If the gift was bought using a cryptocurrency, price of the gift in the smallest units of a cryptocurrency. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $currency, int $amount, int $months, ?int $cryptoCurrency, ?int $cryptoAmount)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $currency, int $amount, int $months, ?int $cryptoCurrency, ?int $cryptoAmount)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$currency`: `string` +* `$amount`: `int` +* `$months`: `int` +* `$cryptoCurrency`: `?int` +* `$cryptoAmount`: `?int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.md new file mode 100644 index 0000000000..6500a68ef2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.md @@ -0,0 +1,538 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGroupCall: Represents a service message about a group call." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Represents a service message about a group call. + + + +## Properties +* `$callId`: `int` Group call ID +* `$accessHash`: `int` Group call access hash +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.md new file mode 100644 index 0000000000..4e5e1e9226 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.md @@ -0,0 +1,560 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGroupCall\\GroupCall: The group call has started or ended." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCall` +[Back to index](../../../../../../index.html) + +> Author: Daniil Gentili + + +The group call has started or ended. + + + +## Properties +* `$ended`: `bool` Whether that group call ended or not. +* `$duration`: `?int` Group call duration +* `$callId`: `int` Group call ID +* `$accessHash`: `int` Group call access hash +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?int $duration)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?int $duration)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$duration`: `?int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.md new file mode 100644 index 0000000000..1e50d08448 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.md @@ -0,0 +1,559 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGroupCall\\GroupCallInvited: A set of users was invited to the group call." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallInvited` +[Back to index](../../../../../../index.html) + +> Author: Daniil Gentili + + +A set of users was invited to the group call. + + + +## Properties +* `$users`: `array` The invited users +* `$callId`: `int` Group call ID +* `$accessHash`: `int` Group call access hash +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $users)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $users)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$users`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.md new file mode 100644 index 0000000000..04a6591050 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.md @@ -0,0 +1,559 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogGroupCall\\GroupCallScheduled: A group call was scheduled." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallScheduled` +[Back to index](../../../../../../index.html) + +> Author: Daniil Gentili + + +A group call was scheduled. + + + +## Properties +* `$scheduleDate`: `int` When is this group call scheduled to start +* `$callId`: `int` Group call ID +* `$accessHash`: `int` Group call access hash +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $scheduleDate)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $scheduleDate)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$scheduleDate`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.md new file mode 100644 index 0000000000..645839069d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.md @@ -0,0 +1,536 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogHistoryCleared: Chat history was cleared." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogHistoryCleared` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Chat history was cleared. + + + +## Properties +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.md new file mode 100644 index 0000000000..615576dad5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.md @@ -0,0 +1,536 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogMemberJoinedByRequest: A user was accepted into the group by an admin." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogMemberJoinedByRequest` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A user was accepted into the group by an admin. + + + +## Properties +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.md new file mode 100644 index 0000000000..1f278c6e99 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogMemberLeft: A member left the chat or channel." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogMemberLeft` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A member left the chat or channel. + + + +## Properties +* `$left`: `int` ID of the user that left the channel +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $left)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $left)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$left`: `int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.md new file mode 100644 index 0000000000..b7f5409279 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogMembersJoined: Some members joined the chat or channel." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogMembersJoined` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Some members joined the chat or channel. + + + +## Properties +* `$joined`: `list` List of IDs of the users that joined the chat or channel. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $joined)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $joined)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$joined`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.md new file mode 100644 index 0000000000..9109330f2c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.md @@ -0,0 +1,550 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogMessagePinned: A message was pinned in a chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogMessagePinned` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A message was pinned in a chat. + + + +## Properties +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`getPinnedMessage(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getPinnedMessage) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `getPinnedMessage(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Gets the pinned message. + +May return null if the pinned message was deleted. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.md new file mode 100644 index 0000000000..4df1eb963a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.md @@ -0,0 +1,538 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogPeerRequested: Contains info about a peer that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) button." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogPeerRequested` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Contains info about a peer that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) button. + + + +## Properties +* `$buttonId`: `int` buttonId contained in the [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) +* `$peers`: `list` The shared peers +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.md new file mode 100644 index 0000000000..447afc15b5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.md @@ -0,0 +1,564 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogPhoneCall: A phone call." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogPhoneCall` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A phone call. + + + +## Properties +* `$video`: `bool` Is this a video call? +* `$callId`: `int` Call ID +* `$reason`: `?DiscardReason` If the call has ended, the reason why it ended +* `$duration`: `?int` Duration of the call in seconds +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, bool $video, int $callId, ?\danog\MadelineProto\VoIP\DiscardReason $reason, ?int $duration)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, bool $video, int $callId, ?\danog\MadelineProto\VoIP\DiscardReason $reason, ?int $duration)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$video`: `bool` +* `$callId`: `int` +* `$reason`: `?\danog\MadelineProto\VoIP\DiscardReason` +* `$duration`: `?int` + + +#### See also: +* `\danog\MadelineProto\MTProto` +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../../../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.md new file mode 100644 index 0000000000..2141d418a4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.md @@ -0,0 +1,558 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogPhotoChanged: The photo of the dialog was changed or deleted." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogPhotoChanged` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The photo of the dialog was changed or deleted. + + + +## Properties +* `$photo`: `?Photo` New photo (or no photo if it was deleted) +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?\danog\MadelineProto\EventHandler\Media\Photo $photo)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?\danog\MadelineProto\EventHandler\Media\Photo $photo)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$photo`: `?\danog\MadelineProto\EventHandler\Media\Photo` + + +#### See also: +* `\danog\MadelineProto\MTProto` +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../../../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.md new file mode 100644 index 0000000000..94e3b4cccf --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.md @@ -0,0 +1,537 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogReadMessages: Messages marked as read." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogReadMessages` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Messages marked as read. + + + +## Properties +* `$ids`: `list` List of message IDs. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.md new file mode 100644 index 0000000000..711947bc60 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogScreenshotTaken: A screenshot of the chat was taken." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A screenshot of the chat was taken. + + + +## Properties +* `$ids`: `list` List of affected message ids that appeared on the screenshot, only for secret chats. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $ids = [])`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, array $ids = [])` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$ids`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.md new file mode 100644 index 0000000000..2d1e5f0dab --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogSetChatTheme: The chat theme was changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogSetChatTheme` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The chat theme was changed. + + + +## Properties +* `$emoticon`: `string` The emoji that identifies a chat theme +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $emoticon)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $emoticon)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$emoticon`: `string` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.md new file mode 100644 index 0000000000..bbe4c50a20 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.md @@ -0,0 +1,560 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogSetChatWallPaper: The [wallpaper](https://core.telegram.org/api/wallpapers) of the current chat was changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogSetChatWallPaper` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The [wallpaper](https://core.telegram.org/api/wallpapers) of the current chat was changed. + + + +## Properties +* `$wallpaper`: `Wallpaper` New [wallpaper](https://core.telegram.org/api/wallpapers) +* `$same`: `bool` Whether the user applied a wallpaper previously sent by the other user in a DialogSetChatWallPaper message. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, \danog\MadelineProto\EventHandler\Wallpaper $wallpaper, bool $same = false)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, \danog\MadelineProto\EventHandler\Wallpaper $wallpaper, bool $same = false)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$wallpaper`: `\danog\MadelineProto\EventHandler\Wallpaper` +* `$same`: `bool` + + +#### See also: +* `\danog\MadelineProto\MTProto` +* [`\danog\MadelineProto\EventHandler\Wallpaper`: Represents a [wallpaper](https://core.telegram.org/api/wallpapers).](../../../../../danog/MadelineProto/EventHandler/Wallpaper.html) + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.md new file mode 100644 index 0000000000..43d00f6549 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.md @@ -0,0 +1,559 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogSetTTL: The Time-To-Live of messages in this chat was changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The Time-To-Live of messages in this chat was changed. + + + +## Properties +* `$period`: `int` New Time-To-Live of all messages sent in this chat; if 0, autodeletion was disabled. +* `$autoSettingFrom`: `?int` If set, the chat TTL setting was set not due to a manual change by one of participants, but automatically because one of the participants has the [default TTL settings enabled »](https://docs.madelineproto.xyz/API_docs/methods/messages.setDefaultHistoryTTL.html). For example, when a user writes to us for the first time and we have set a default messages TTL of 1 week, this service message (with auto_setting_from=our_userid) will be emitted before our first message. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $period, ?int $autoSettingFrom)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, int $period, ?int $autoSettingFrom)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$period`: `int` +* `$autoSettingFrom`: `?int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.md new file mode 100644 index 0000000000..c98aeaaab3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.md @@ -0,0 +1,558 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogSuggestProfilePhoto: A new profile picture was suggested using [photos.uploadContactProfilePhoto](https://docs.madelineproto.xyz/API_docs/methods/photos.uploadContactProfilePhoto.html)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogSuggestProfilePhoto` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A new profile picture was suggested using [photos.uploadContactProfilePhoto](https://docs.madelineproto.xyz/API_docs/methods/photos.uploadContactProfilePhoto.html). + + + +## Properties +* `$photo`: `?Photo` The photo that the user suggested we set as profile picture. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?\danog\MadelineProto\EventHandler\Media\Photo $photo)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?\danog\MadelineProto\EventHandler\Media\Photo $photo)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$photo`: `?\danog\MadelineProto\EventHandler\Media\Photo` + + +#### See also: +* `\danog\MadelineProto\MTProto` +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../../../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.md new file mode 100644 index 0000000000..cae0482a0b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.md @@ -0,0 +1,557 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogTitleChanged: The title of a channel or group has changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogTitleChanged` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The title of a channel or group has changed. + + + +## Properties +* `$title`: `string` New title +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$title`: `string` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.md new file mode 100644 index 0000000000..f2a9222a15 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.md @@ -0,0 +1,561 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogTopicCreated: A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created. + + + +## Properties +* `$title`: `string` Topic name. +* `$iconColor`: `int` If no custom emoji icon is specified, specifies the color of the fallback topic icon (RGB), one of 0x6FB9F0, 0xFFD67E, 0xCB86DB, 0x8EEE98, 0xFF93B2, or 0xFB6F5F. +* `$iconEmojiId`: `?int` ID of the [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title, int $iconColor, ?int $iconEmojiId)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $title, int $iconColor, ?int $iconEmojiId)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$title`: `string` +* `$iconColor`: `int` +* `$iconEmojiId`: `?int` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.md new file mode 100644 index 0000000000..7e3e0e58cd --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.md @@ -0,0 +1,571 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogTopicEdited: [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +[Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited. + + + +## Properties +* `$title`: `?string` If not null, indicates that the topic name has changed, contains the new topic name. + +Ignore this field if null. +* `$iconEmojiId`: `?int` If not null, indicates that the topic icon has changed, and contains the ID of the new [custom emoji](https://core.telegram.org/api/custom-emoji) used as topic icon (0 if it was removed). + +Ignore this field if null. +* `$closed`: `?bool` If not null, indicates whether the topic was opened or closed. + +Ignore this field if null. +* `$hidden`: `?bool` If not null, indicates whether the topic was hidden or unhidden (only valid for the “General” topic, id=1). + +Ignore this field if null. +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?string $title, ?int $iconEmojiId, ?bool $closed, ?bool $hidden)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, ?string $title, ?int $iconEmojiId, ?bool $closed, ?bool $hidden)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$title`: `?string` +* `$iconEmojiId`: `?int` +* `$closed`: `?bool` +* `$hidden`: `?bool` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.md new file mode 100644 index 0000000000..5c7d8c202d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.md @@ -0,0 +1,560 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\Service\\DialogWebView: Data from an opened [reply keyboard bot web app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user & bot side service message)." +description: "Clients should display a service message with the text Data from the «$text» button was transferred to the bot.\n" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\Service\DialogWebView` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Data from an opened [reply keyboard bot web app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user & bot side service message). + +Clients should display a service message with the text Data from the «$text» button was transferred to the bot. + + +## Properties +* `$text`: `string` Text of the [keyboardButtonSimpleWebView](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonSimpleWebView.html) that was pressed to open the web app. +* `$data`: `?string` Relayed data. (bot side service message) +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $text, ?string $data)`](#__construct) +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawMessage, array $info, string $text, ?string $data)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawMessage`: `array` +* `$info`: `array` +* `$text`: `string` +* `$data`: `?string` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.md b/docs/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.md new file mode 100644 index 0000000000..5fc7d49c5f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.md @@ -0,0 +1,536 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Message\\ServiceMessage: Represents info about a service message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Message\ServiceMessage` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents info about a service message. + + + +## Properties +* `$id`: `int` Message ID +* `$out`: `bool` Whether the message is outgoing +* `$chatId`: `int` ID of the chat where the message was sent +* `$senderId`: `int` ID of the sender of the message +* `$replyToMsgId`: `?int` ID of the message to which this message is replying +* `$date`: `int` When was the message sent +* `$topicId`: `?int` ID of the forum topic where the message was sent +* `$threadId`: `?int` ID of the message thread where the message was sent +* `$replyToScheduled`: `bool` Whether this is a reply to a scheduled message +* `$mentioned`: `bool` Whether we were mentioned in this message +* `$silent`: `bool` Whether this message was sent without any notification (silently) +* `$ttlPeriod`: `?int` Time-to-live of the message + +## Method list: +* [`isReply(): bool`](#isReply) +* [`getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T`](#getReply) +* [`delete(boolean $revoke = true): void`](#delete) +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyDocument) +* [`replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVideo) +* [`replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyGif) +* [`replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyAudio) +* [`replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyVoice) +* [`replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replyPhoto) +* [`replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#replySticker) +* [`sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendText) +* [`block(): bool`](#block) +* [`unblock(): bool`](#unblock) +* [`getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>`](#getStories) +* [`setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool`](#setAction) +* [`read(bool $readAll = false): boolean`](#read) +* [`enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#enableTTL) +* [`disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`](#disableTTL) +* [`enableAutoTranslate(): bool`](#enableAutoTranslate) +* [`disableAutoTranslate(): bool`](#disableAutoTranslate) + +## Methods: +### `isReply(): bool` + +Check if the current message replies to another message. + + + +### `getReply(class-string $class = 'danog\\MadelineProto\\EventHandler\\AbstractMessage'): ?T` + +Get replied-to message. + +May return null if the replied-to message was deleted or if the message does not reply to any other message. + + +Parameters: + +* `$class`: `class-string` Only return a reply if it is of the specified type, return null otherwise. + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply to the message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `replyDocument((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVideo((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyGif((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyAudio((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyVoice((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replyPhoto((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `replySticker((\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Reply a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendText(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $noWebpage = false, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Send a text message. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Only for bots, disallows further re-forwarding and saving of the messages, even if the destination chat doesn’t have [content protection](https://telegram.org/blog/protected-content-delete-by-date-and-more) enabled +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `block(): bool` + +Adds the user to the blacklist. + + + +### `unblock(): bool` + +Deletes the user from the blacklist. + + + +### `getStories(): list<\danog\MadelineProto\EventHandler\AbstractStory>` + +Get user stories. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractStory`: Represents a Telegram Story.](../../../../danog/MadelineProto/EventHandler/AbstractStory.html) + + + + +### `setAction(\danog\MadelineProto\EventHandler\Action $action = \danog\MadelineProto\EventHandler\Action\Typing::__set_state(array(]]): bool` + +Sends a current user typing event +(see [SendMessageAction](https://docs.madelineproto.xyz/API_docs/types/SendMessageAction.html) for all event types) to a conversation partner or group. + + +Parameters: + +* `$action`: `\danog\MadelineProto\EventHandler\Action` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Action`: In-progress actions.](../../../../danog/MadelineProto/EventHandler/Action.html) + + + + +### `read(bool $readAll = false): boolean` + +Mark selected message as read. + + +Parameters: + +* `$readAll`: `bool` + + +Return value: if set, read all messages in current chat. + + +### `enableTTL(int<1, max> $seconds = 86400): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Set maximum Time-To-Live of all messages in the specified chat. + + +Parameters: + +* `$seconds`: `int<1, max>` Automatically delete all messages sent in the chat after this many seconds + + +#### See also: +* `max` +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `disableTTL(): \danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL` + +Disable Time-To-Live of all messages in the specified chat. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL`: The Time-To-Live of messages in this chat was changed.](../../../../danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) + + + + +### `enableAutoTranslate(): bool` + +Show the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +### `disableAutoTranslate(): bool` + +Hide the [real-time chat translation popup](https://core.telegram.org/api/translation) for a certain chat. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant.md new file mode 100644 index 0000000000..d11af0d9db --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant: Info about a channel participant." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Info about a channel participant. + + + + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Admin.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Admin.md new file mode 100644 index 0000000000..6ea84bfc63 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Admin.md @@ -0,0 +1,44 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Admin: Admin." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Admin` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Admin. + + + +## Properties +* `$canEdit`: `bool` Can this admin promote other admins with the same permissions? +* `$self`: `bool` Is this the current user +* `$userId`: `int` Admin user ID +* `$inviterId`: `?int` User that invited the admin to the channel/group +* `$promotedBy`: `int` User that promoted the user to admin +* `$date`: `int` When did the user join +* `$adminRights`: `danog\MadelineProto\EventHandler\Participant\Rights\Admin` Admin [rights](https://core.telegram.org/api/rights) +* `$rank`: `string` The role (rank) of the admin in the group: just an arbitrary string, `admin` by default + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Banned.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Banned.md new file mode 100644 index 0000000000..98395af6e4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Banned.md @@ -0,0 +1,41 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Banned: Banned/kicked user." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Banned` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Banned/kicked user. + + + +## Properties +* `$left`: `bool` Whether the user has left the group +* `$peer`: `int` The banned peer +* `$kickedBy`: `int` User was kicked by the specified admin +* `$date`: `int` When did the user join the group +* `$bannedRights`: `danog\MadelineProto\EventHandler\Participant\Rights\Banned` Banned [rights](https://core.telegram.org/api/rights) + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Creator.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Creator.md new file mode 100644 index 0000000000..d7f79c765c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Creator.md @@ -0,0 +1,39 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Creator: Channel/supergroup creator." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Creator` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Channel/supergroup creator. + + + +## Properties +* `$userId`: `int` User ID +* `$adminRights`: `danog\MadelineProto\EventHandler\Participant\Rights\Admin` Creator admin rights +* `$rank`: `string` The role (rank) of the group creator in the group: just an arbitrary string, `admin` by default + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Left.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Left.md new file mode 100644 index 0000000000..0f3de1c2ee --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Left.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Left: A participant that left the channel/supergroup." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Left` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A participant that left the channel/supergroup. + + + +## Properties +* `$peer`: `int` The peer that left + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Member.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Member.md new file mode 100644 index 0000000000..c946a33179 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Member.md @@ -0,0 +1,38 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Member: Channel/supergroup participant." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Member` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Channel/supergroup participant. + + + +## Properties +* `$userId`: `int` Participant user ID +* `$date`: `int` Date joined + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/MySelf.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/MySelf.md new file mode 100644 index 0000000000..da87c948a1 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/MySelf.md @@ -0,0 +1,40 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\MySelf: Myself." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\MySelf` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Myself. + + + +## Properties +* `$viaRequest`: `bool` Whether I joined upon specific approval of an admin +* `$userId`: `int` User ID +* `$inviterId`: `?int` User that invited me to the channel/supergroup +* `$date`: `int` When did I join the channel/supergroup + +## Method list: +* [`fromRawParticipant(array $rawParticipant): self`](#fromRawParticipant) + +## Methods: +### `fromRawParticipant(array $rawParticipant): self` + + + + +Parameters: + +* `$rawParticipant`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights.md new file mode 100644 index 0000000000..b2982ae5d4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Rights: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Rights` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Admin.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Admin.md new file mode 100644 index 0000000000..12adf53edc --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Admin.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Rights\\Admin: Represents the rights of an admin in a [channel/supergroup](https://core.telegram.org/api/channel)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Rights\Admin` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Represents the rights of an admin in a [channel/supergroup](https://core.telegram.org/api/channel). + + + +## Properties +* `$changeInfo`: `bool` If set, allows the admin to modify the description of the [channel/supergroup](https://core.telegram.org/api/channel) +* `$postMessages`: `bool` If set, allows the admin to post messages in the [channel](https://core.telegram.org/api/channel) +* `$editMessages`: `bool` If set, allows the admin to also edit messages from other admins in the [channel](https://core.telegram.org/api/channel) +* `$deleteMessages`: `bool` If set, allows the admin to also delete messages from other admins in the [channel](https://core.telegram.org/api/channel) +* `$banUsers`: `bool` If set, allows the admin to ban users from the [channel/supergroup](https://core.telegram.org/api/channel) +* `$inviteUsers`: `bool` If set, allows the admin to invite users in the [channel/supergroup](https://core.telegram.org/api/channel) +* `$pinMessages`: `bool` If set, allows the admin to pin messages in the [channel/supergroup](https://core.telegram.org/api/channel) +* `$addAdmins`: `bool` If set, allows the admin to add other admins with the same (or more limited) permissions in the [channel/supergroup](https://core.telegram.org/api/channel) +* `$anonymous`: `bool` Whether this admin is anonymous +* `$manageCall`: `bool` If set, allows the admin to change group call/livestream settings +* `$other`: `bool` Set this flag if none of the other flags are set, +but you still want the user to be an admin: if this or any of the other flags are set, +the admin can get the chat [admin log](https://core.telegram.org/api/recent-actions), get [chat statistics](https://core.telegram.org/api/stats), get [message statistics in channels](https://core.telegram.org/api/stats), get channel members, +see anonymous administrators in supergroups and ignore slow mode. +* `$manageTopics`: `bool` If set, allows the admin to create, delete or modify [forum topics »](https://core.telegram.org/api/forum#forum-topics). +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Banned.md b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Banned.md new file mode 100644 index 0000000000..87ee8805d9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Banned.md @@ -0,0 +1,40 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Participant\\Rights\\Banned: Represents the rights of a normal user in a [supergroup/channel/chat](https://core.telegram.org/api/channel). In this case, the flags are inverted: if set, a flag does not allow a user to do X." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Participant\Rights\Banned` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Represents the rights of a normal user in a [supergroup/channel/chat](https://core.telegram.org/api/channel). In this case, the flags are inverted: if set, a flag does not allow a user to do X. + + + +## Properties +* `$viewMessages`: `bool` If set, does not allow a user to view messages in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendMessages`: `bool` If set, does not allow a user to send messages in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendMedia`: `bool` If set, does not allow a user to send any media in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendStickers`: `bool` If set, does not allow a user to send stickers in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendGifs`: `bool` If set, does not allow a user to send stickers in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendGames`: `bool` If set, does not allow a user to send games in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendInline`: `bool` If set, does not allow a user to use inline bots in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$embedLinks`: `bool` If set, does not allow a user to embed links in the messages of a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendPolls`: `bool` If set, does not allow a user to send polls in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$changeInfo`: `bool` If set, does not allow any user to change the description of a [supergroup/chat](https://core.telegram.org/api/channel) +* `$inviteUsers`: `bool` If set, does not allow any user to invite users in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$pinMessages`: `bool` If set, does not allow any user to pin messages in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$manageTopics`: `bool` If set, does not allow any user to create, delete or modify [forum topics »](https://core.telegram.org/api/forum#forum-topics). +* `$sendPhotos`: `bool` If set, does not allow a user to send photos in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendVideos`: `bool` If set, does not allow a user to send videos in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendRoundvideos`: `bool` If set, does not allow a user to send round videos in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendAudios`: `bool` If set, does not allow a user to send audio files in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendDocs`: `bool` If set, does not allow a user to send documents in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$sendPlain`: `bool` If set, does not allow a user to send text messages in a [supergroup/chat](https://core.telegram.org/api/channel) +* `$untilDate`: `int` Validity of said permissions (it is considered forever any value less then 30 seconds or more then 366 days). +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Pinned.md b/docs/PHP/danog/MadelineProto/EventHandler/Pinned.md new file mode 100644 index 0000000000..4af1c3eeeb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Pinned.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Pinned: Indicates that some messages were pinned/unpinned." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Pinned` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Indicates that some messages were pinned/unpinned. + + + +## Properties +* `$pinned`: `bool` Whether the messages were pinned or unpinned. +* `$ids`: `list` List of identifiers of pinned messages. +* `$chatId`: `int` ID of the chat where the messages were pinned. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.md new file mode 100644 index 0000000000..5bbdcf1588 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Pinned\\PinnedChannelMessages: Represents messages that were pinned/unpinned in a [channel](https://core.telegram.org/api/channel)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Pinned\PinnedChannelMessages` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents messages that were pinned/unpinned in a [channel](https://core.telegram.org/api/channel). + + + +## Properties +* `$pinned`: `bool` Whether the messages were pinned or unpinned. +* `$ids`: `list` List of identifiers of pinned messages. +* `$chatId`: `int` ID of the chat where the messages were pinned. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.md new file mode 100644 index 0000000000..278a01ce92 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Pinned\\PinnedGroupMessages: Represents messages that were pinned/unpinned in a [chat/supergroup](https://core.telegram.org/api/channel)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Pinned\PinnedGroupMessages` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents messages that were pinned/unpinned in a [chat/supergroup](https://core.telegram.org/api/channel). + + + +## Properties +* `$pinned`: `bool` Whether the messages were pinned or unpinned. +* `$ids`: `list` List of identifiers of pinned messages. +* `$chatId`: `int` ID of the chat where the messages were pinned. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.md b/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.md new file mode 100644 index 0000000000..f3bc929e31 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Pinned\\PinnedPrivateMessages: Some messages were pinned in a private chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Pinned\PinnedPrivateMessages` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Some messages were pinned in a private chat. + + + +## Properties +* `$pinned`: `bool` Whether the messages were pinned or unpinned. +* `$ids`: `list` List of identifiers of pinned messages. +* `$chatId`: `int` ID of the chat where the messages were pinned. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Plugin/RestartPlugin.md b/docs/PHP/danog/MadelineProto/EventHandler/Plugin/RestartPlugin.md new file mode 100644 index 0000000000..246ceb00e6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Plugin/RestartPlugin.md @@ -0,0 +1,3334 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Plugin\\RestartPlugin: Plugin that offers a /restart command to admins that can be used to restart the bot, applying changes." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Plugin\RestartPlugin` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Plugin that offers a /restart command to admins that can be used to restart the bot, applying changes. + + + +## Properties +* `$auth`: `\danog\MadelineProto\Namespace\Auth` +* `$account`: `\danog\MadelineProto\Namespace\Account` +* `$users`: `\danog\MadelineProto\Namespace\Users` +* `$contacts`: `\danog\MadelineProto\Namespace\Contacts` +* `$messages`: `\danog\MadelineProto\Namespace\Messages` +* `$updates`: `\danog\MadelineProto\Namespace\Updates` +* `$photos`: `\danog\MadelineProto\Namespace\Photos` +* `$upload`: `\danog\MadelineProto\Namespace\Upload` +* `$help`: `\danog\MadelineProto\Namespace\Help` +* `$channels`: `\danog\MadelineProto\Namespace\Channels` +* `$bots`: `\danog\MadelineProto\Namespace\Bots` +* `$payments`: `\danog\MadelineProto\Namespace\Payments` +* `$stickers`: `\danog\MadelineProto\Namespace\Stickers` +* `$phone`: `\danog\MadelineProto\Namespace\Phone` +* `$langpack`: `\danog\MadelineProto\Namespace\Langpack` +* `$folders`: `\danog\MadelineProto\Namespace\Folders` +* `$stats`: `\danog\MadelineProto\Namespace\Stats` +* `$chatlists`: `\danog\MadelineProto\Namespace\Chatlists` +* `$stories`: `\danog\MadelineProto\Namespace\Stories` +* `$premium`: `\danog\MadelineProto\Namespace\Premium` +* `$smsjobs`: `\danog\MadelineProto\Namespace\Smsjobs` +* `$fragment`: `\danog\MadelineProto\Namespace\Fragment` + +## Method list: +* [`cmd(\danog\MadelineProto\EventHandler\SimpleFilter\Incoming&danog\MadelineProto\EventHandler\Message&danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin $_): void`](#cmd) +* [`getPluginPaths(): array|string|null`](#getPluginPaths) +* [`isPluginEnabled(): bool`](#isPluginEnabled) +* [`startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoop) +* [`startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoopBot) +* [`getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop`](#getPeriodicLoop) +* [`getPeriodicLoops(): array`](#getPeriodicLoops) +* [`getReportPeers(): (string|int|array<(string|int)>)`](#getReportPeers) +* [`getPlugins(): array>`](#getPlugins) +* [`MTProtoToBotAPI(array $data): array`](#MTProtoToBotAPI) +* [`MTProtoToTd(mixed $params): array`](#MTProtoToTd) +* [`MTProtoToTdcli(mixed $params): array`](#MTProtoToTdcli) +* [`acceptCall(int $id): void`](#acceptCall) +* [`acceptSecretChat(array $params): void`](#acceptSecretChat) +* [`arr(mixed ...$params): array`](#arr) +* [`base64urlDecode(string $data): string`](#base64urlDecode) +* [`base64urlEncode(string $data): string`](#base64urlEncode) +* [`botAPIToMTProto(array $arguments): array`](#botAPIToMTProto) +* [`botLogin(string $token): ?array`](#botLogin) +* [`broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int`](#broadcastCustom) +* [`broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastForwardMessages) +* [`broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastMessages) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null`](#callGetCurrent) +* [`callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void`](#callPlay) +* [`callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void`](#callPlayOnHold) +* [`callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void`](#callSetOutput) +* [`canConvertOgg(): bool`](#canConvertOgg) +* [`canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool`](#canUseFFmpeg) +* [`cancelBroadcast(integer $id): void`](#cancelBroadcast) +* [`closeConnection(string $message): void`](#closeConnection) +* [`complete2faLogin(string $password): array`](#complete2faLogin) +* [`completePhoneLogin(string $code): array`](#completePhoneLogin) +* [`completeSignup(string $first_name, string $last_name = ''): array`](#completeSignup) +* [`discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void`](#discardCall) +* [`discardSecretChat(int $chat): void`](#discardSecretChat) +* [`downloadServer(string $session): void`](#downloadServer) +* [`downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToBrowser) +* [`downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToCallable) +* [`downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToDir) +* [`downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToFile) +* [`downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response`](#downloadToResponse) +* [`downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#downloadToReturnedStream) +* [`downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToStream) +* [`echo(string $string): void`](#echo) +* [`end(array $what): T`](#end) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`exportAuthorization(): array{0: (int|string), 1: string}`](#exportAuthorization) +* [`extractBotAPIFile(array $info): ?array`](#extractBotAPIFile) +* [`extractMessage(array $updates): array`](#extractMessage) +* [`extractMessageId(array $updates): int`](#extractMessageId) +* [`extractMessageUpdate(array $updates): array`](#extractMessageUpdate) +* [`extractUpdates(array $updates): array`](#extractUpdates) +* [`fileGetContents(string $url): string`](#fileGetContents) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`fullChatLastUpdated(mixed $id): int`](#fullChatLastUpdated) +* [`fullGetSelf(): array|false`](#fullGetSelf) +* [`genVectorHash(array $longs): string`](#genVectorHash) +* [`getAdminIds(): array`](#getAdminIds) +* [`getAllCalls(): array`](#getAllCalls) +* [`getAllMethods(): array`](#getAllMethods) +* [`getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)`](#getAuthorization) +* [`getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress`](#getBroadcastProgress) +* [`getCachedConfig(): array`](#getCachedConfig) +* [`getCall(int $id): ?\danog\MadelineProto\VoIP`](#getCall) +* [`getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP`](#getCallByPeer) +* [`getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState`](#getCallState) +* [`getCdnConfig(): void`](#getCdnConfig) +* [`getConfig(array $config = []): array`](#getConfig) +* [`getDNSClient(): \Amp\Dns\DnsResolver`](#getDNSClient) +* [`getDhConfig(): array`](#getDhConfig) +* [`getDialogIds(): list`](#getDialogIds) +* [`getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}`](#getDownloadInfo) +* [`getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string`](#getDownloadLink) +* [`getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)`](#getEventHandler) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getFileInfo(mixed $constructor): array`](#getFileInfo) +* [`getFullDialogs(): array`](#getFullDialogs) +* [`getFullInfo(mixed $id): array`](#getFullInfo) +* [`getHTTPClient(): \Amp\Http\Client\HttpClient`](#getHTTPClient) +* [`getHint(): string`](#getHint) +* [`getId(mixed $id): int`](#getId) +* [`getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))`](#getInfo) +* [`getLogger(): \danog\MadelineProto\Logger`](#getLogger) +* [`getMaps(): ?int`](#getMaps) +* [`getMaxMaps(): ?int`](#getMaxMaps) +* [`getMethodNamespaces(): array`](#getMethodNamespaces) +* [`getMethodsNamespaced(): array`](#getMethodsNamespaced) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null`](#getPlugin) +* [`getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo`](#getPropicInfo) +* [`getPsrLogger(): \Psr\Log\LoggerInterface`](#getPsrLogger) +* [`getPwrChat(mixed $id, bool $fullfetch = true): array`](#getPwrChat) +* [`getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat`](#getSecretChat) +* [`getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage`](#getSecretMessage) +* [`getSelf(): array|false`](#getSelf) +* [`getSessionName(): string`](#getSessionName) +* [`getSettings(): \danog\MadelineProto\Settings`](#getSettings) +* [`getSponsoredMessages((int|string|array) $peer): ?array`](#getSponsoredMessages) +* [`getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`getStreamPipe(): \Amp\ByteStream\Pipe`](#getStreamPipe) +* [`getTL(): \danog\MadelineProto\TL\TLInterface`](#getTL) +* [`getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*`](#getType) +* [`getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list`](#getUpdates) +* [`getWebMessage(string $message): string`](#getWebMessage) +* [`getWebWarnings(): string`](#getWebWarnings) +* [`hasAdmins(): bool`](#hasAdmins) +* [`hasEventHandler(): bool`](#hasEventHandler) +* [`hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool`](#hasPlugin) +* [`hasReportPeers(): bool`](#hasReportPeers) +* [`hasSecretChat((array|int) $chat): bool`](#hasSecretChat) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`importAuthorization(array $authorization, int $mainDcID): array`](#importAuthorization) +* [`inflateStripped(string $stripped): string`](#inflateStripped) +* [`initSelfRestart(): void`](#initSelfRestart) +* [`isAltervista(): bool`](#isAltervista) +* [`isArrayOrAlike(mixed $var): bool`](#isArrayOrAlike) +* [`isBot(mixed $peer): bool`](#isBot) +* [`isForum(mixed $peer): bool`](#isForum) +* [`isIpc(): bool`](#isIpc) +* [`isIpcWorker(): bool`](#isIpcWorker) +* [`isPlayPaused(int $id): bool`](#isPlayPaused) +* [`isPremium(): bool`](#isPremium) +* [`isSelfBot(): bool`](#isSelfBot) +* [`isSelfUser(): bool`](#isSelfUser) +* [`isTestMode(): boolean`](#isTestMode) +* [`logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void`](#logger) +* [`logout(): void`](#logout) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string`](#openBuffered) +* [`openFileAppendOnly(string $path): \Amp\File\File`](#openFileAppendOnly) +* [`packDouble(float $value): string`](#packDouble) +* [`packSignedInt(integer $value): string`](#packSignedInt) +* [`packSignedLong(int $value): string`](#packSignedLong) +* [`packUnsignedInt(int $value): string`](#packUnsignedInt) +* [`pausePlay(int $id): void`](#pausePlay) +* [`peerIsset(mixed $id): bool`](#peerIsset) +* [`phoneLogin(string $number, integer $sms_type = 5): array`](#phoneLogin) +* [`posmod(int $a, int $b): int`](#posmod) +* [`processDownloadServerPing(string $path, string $payload): void`](#processDownloadServerPing) +* [`qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode`](#qrLogin) +* [`random(integer $length): string`](#random) +* [`randomInt(integer $modulus = 0): int`](#randomInt) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`refreshFullPeerCache(mixed $id): void`](#refreshFullPeerCache) +* [`refreshPeerCache(mixed ...$ids): void`](#refreshPeerCache) +* [`report(string $message, string $parseMode = ''): void`](#report) +* [`reportMemoryProfile(): void`](#reportMemoryProfile) +* [`requestCall(mixed $user): \danog\MadelineProto\VoIP`](#requestCall) +* [`requestSecretChat(mixed $user): int`](#requestSecretChat) +* [`resetUpdateState(): void`](#resetUpdateState) +* [`restart(): void`](#restart) +* [`resumePlay(int $id): void`](#resumePlay) +* [`rethrow(Throwable $e): void`](#rethrow) +* [`rleDecode(string $string): string`](#rleDecode) +* [`rleEncode(string $string): string`](#rleEncode) +* [`sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendAudio) +* [`sendCustomEvent(mixed $payload): void`](#sendCustomEvent) +* [`sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocument) +* [`sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocumentPhoto) +* [`sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendGif) +* [`sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendMessage) +* [`sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>`](#sendMessageToAdmins) +* [`sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendPhoto) +* [`sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendSticker) +* [`sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVideo) +* [`sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVoice) +* [`setNoop(): void`](#setNoop) +* [`setReportPeers((int|string|array<(int|string)>) $userOrId): void`](#setReportPeers) +* [`setWebhook(string $webhookUrl): void`](#setWebhook) +* [`skipPlay(int $id): void`](#skipPlay) +* [`sleep(float $time): void`](#sleep) +* [`start(): array`](#start) +* [`stop(): void`](#stop) +* [`stopPlay(int $id): void`](#stopPlay) +* [`stringToStream(string $str): \Amp\ByteStream\ReadableBuffer`](#stringToStream) +* [`subscribeToUpdates(mixed $channel): bool`](#subscribeToUpdates) +* [`tdToMTProto(array $params): array`](#tdToMTProto) +* [`tdToTdcli(mixed $params): array`](#tdToTdcli) +* [`tdcliToTd(mixed $params, array $key = NULL): array`](#tdcliToTd) +* [`testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}`](#testFibers) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`unpackDouble(string $value): float`](#unpackDouble) +* [`unpackFileId(string $fileId): array`](#unpackFileId) +* [`unpackSignedInt(string $value): int`](#unpackSignedInt) +* [`unpackSignedLong(string $value): int`](#unpackSignedLong) +* [`unpackSignedLongString((string|int|array) $value): string`](#unpackSignedLongString) +* [`unsetEventHandler(): void`](#unsetEventHandler) +* [`update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void`](#update2fa) +* [`updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void`](#updateSettings) +* [`upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#upload) +* [`uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadEncrypted) +* [`uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromCallable) +* [`uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromStream) +* [`uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromTgfile) +* [`uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromUrl) +* [`validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>`](#validateEventHandlerClass) +* [`viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool`](#viewSponsoredMessage) +* [`wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media`](#wrapMedia) +* [`wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage`](#wrapMessage) +* [`wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned`](#wrapPin) +* [`wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update`](#wrapUpdate) +* [`initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void`](#initDbProperties) +* [`saveDbProperties(): void`](#saveDbProperties) + +## Methods: +### `cmd(\danog\MadelineProto\EventHandler\SimpleFilter\Incoming&danog\MadelineProto\EventHandler\Message&danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin $_): void` + + + + +Parameters: + +* `$_`: `\danog\MadelineProto\EventHandler\SimpleFilter\Incoming&danog\MadelineProto\EventHandler\Message&danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin` + + +#### See also: +* `\danog\MadelineProto\EventHandler\SimpleFilter\Incoming&danog\MadelineProto\EventHandler\Message&danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin` + + + + +### `getPluginPaths(): array|string|null` + +Plugins can require other plugins ONLY with the getPlugins() method. + + + +### `isPluginEnabled(): bool` + +Whether the plugin is enabled. + + + +### `startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto as a bot and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$token`: `string` Bot token +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop` + +Obtain a PeriodicLoop instance created by the Cron attribute. + + +Parameters: + +* `$name`: `string` Method name + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getPeriodicLoops(): array` + +Obtain all PeriodicLoop instances created by the Cron attribute. + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getReportPeers(): (string|int|array<(string|int)>)` + +Get peers where to send error reports. + + + +### `getPlugins(): array>` + +Obtain a list of plugin event handlers to use, in addition with those found by getPluginPath. + + + +### `MTProtoToBotAPI(array $data): array` + +Convert MTProto parameters to bot API parameters. + + +Parameters: + +* `$data`: `array` Data + + + +### `MTProtoToTd(mixed $params): array` + +MTProto to TD params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `MTProtoToTdcli(mixed $params): array` + +MTProto to TDCLI params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `acceptCall(int $id): void` + +Accept call. + + +Parameters: + +* `$id`: `int` + + + +### `acceptSecretChat(array $params): void` + +Accept secret chat. + + +Parameters: + +* `$params`: `array` Secret chat ID + + + +### `arr(mixed ...$params): array` + +Create array. + + +Parameters: + +* `...$params`: `mixed` Params + + + +### `base64urlDecode(string $data): string` + +base64URL decode. + + +Parameters: + +* `$data`: `string` Data to decode + + + +### `base64urlEncode(string $data): string` + +Base64URL encode. + + +Parameters: + +* `$data`: `string` Data to encode + + + +### `botAPIToMTProto(array $arguments): array` + +Convert bot API parameters to MTProto parameters. + + +Parameters: + +* `$arguments`: `array` Arguments + + + +### `botLogin(string $token): ?array` + +Login as bot. + + +Parameters: + +* `$token`: `string` Bot token + + + +### `broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int` + +Executes a custom broadcast action with all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$action`: `\danog\MadelineProto\Broadcast\Action` A custom, serializable Action class that will be called once for every peer. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Action`: Interface that represents a broadcast action.](../../../../danog/MadelineProto/Broadcast/Action.html) +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Forwards a list of messages to all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$from_peer`: `mixed` Bot API ID or Update, from where to forward the messages. +* `$message_ids`: `list` IDs of the messages to forward. +* `$drop_author`: `bool` If true, will forward messages without quoting the original author. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Sends a list of messages to all peers (users, chats, channels) of the bot. + +A simplified version of this method is also available: broadcastForwardMessages can work with pre-prepared messages. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$messages`: `array` The messages to send: an array of arrays, containing parameters to pass to messages.sendMessage. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null` + +Get the file that is currently being played. + +Will return a string with the object ID of the stream if we're currently playing a stream, otherwise returns the related LocalFile or RemoteUrl. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) + + + + +### `callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void` + +Play file in call. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void` + +Play files on hold in call. + + +Parameters: + +* `$id`: `int` +* `...$files`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void` + +Set output file or stream for incoming OPUS audio packets in a call. + +Will write an OGG OPUS stream to the specified file or stream. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* `\Amp\ByteStream\WritableStream` + + + + +### `canConvertOgg(): bool` + +Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot. + + + +### `canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool` + +Whether we can convert any audio/video file using ffmpeg. + + +Parameters: + +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `cancelBroadcast(integer $id): void` + +Cancel a running broadcast. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + + +### `closeConnection(string $message): void` + +Close connection with client, connected via web. + + +Parameters: + +* `$message`: `string` Message + + + +### `complete2faLogin(string $password): array` + +Complete 2FA login. + + +Parameters: + +* `$password`: `string` Password + + + +### `completePhoneLogin(string $code): array` + +Complet user login using login code. + + +Parameters: + +* `$code`: `string` Login code + + + +### `completeSignup(string $first_name, string $last_name = ''): array` + +Complete signup to Telegram. + + +Parameters: + +* `$first_name`: `string` First name +* `$last_name`: `string` Last name + + + +### `discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void` + +Discard call. + + +Parameters: + +* `$id`: `int` +* `$reason`: `\danog\MadelineProto\VoIP\DiscardReason` +* `$rating`: `int<1, 5>` Call rating in stars +* `$comment`: `string` Additional comment on call quality. + + +#### See also: +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `discardSecretChat(int $chat): void` + +Discard secret chat. + + +Parameters: + +* `$chat`: `int` Secret chat ID + + + +### `downloadServer(string $session): void` + +Downloads a file to the browser using the specified session file. + + +Parameters: + +* `$session`: `string` + + + +### `downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to browser. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$cb`: `(null|callable)` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Cancellation` + + + + +### `downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to callable. +The callable must accept two parameters: string $payload, int $offset +The callable will be called (possibly out of order, depending on the value of $seekable). + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$callable`: `(callable|\danog\MadelineProto\FileCallbackInterface)` Chunk callback +* `$cb`: `callable` Status callback +* `$seekable`: `bool` Whether the callable can be called out of order +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to stop downloading (inclusive) +* `$part_size`: `int` Size of each chunk +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file to directory. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$dir`: `(string|\danog\MadelineProto\FileCallbackInterface)` Directory where to download the file +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$file`: `(string|\danog\MadelineProto\FileCallbackInterface)` Downloaded file path +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response` + +Download file to amphp/http-server response. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$request`: `\Amp\Http\Server\Request` Request +* `$cb`: `callable` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Http\Server\Request` +* `\Amp\Cancellation` +* `\Amp\Http\Server\Response` + + + + +### `downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Download file to an amphp stream, returning it. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to stream. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$stream`: `(mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream)` Stream where to download file +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* `resource` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `end(array $what): T` + +Get final element of array. + + +Parameters: + +* `$what`: `array` Array + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `exportAuthorization(): array{0: (int|string), 1: string}` + +Export authorization. + + + +### `extractBotAPIFile(array $info): ?array` + +Extract file info from bot API message. + + +Parameters: + +* `$info`: `array` Bot API message object + + + +### `extractMessage(array $updates): array` + +Extract a message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageId(array $updates): int` + +Extract a message ID from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageUpdate(array $updates): array` + +Extract an update message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractUpdates(array $updates): array` + +Extract Update constructors from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `fileGetContents(string $url): string` + +Get contents of remote file asynchronously. + + +Parameters: + +* `$url`: `string` URL + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `fullChatLastUpdated(mixed $id): int` + +When was full info for this chat last cached. + + +Parameters: + +* `$id`: `mixed` Chat ID + + + +### `fullGetSelf(): array|false` + +Get info about the logged-in user, not cached. + + + +### `genVectorHash(array $longs): string` + +Generate MTProto vector hash. + +Returns a vector hash. + + +Parameters: + +* `$longs`: `array` IDs + + + +### `getAdminIds(): array` + +Get admin IDs (equal to all user report peers). + + + +### `getAllCalls(): array` + +Get all pending and running calls, indexed by user ID. + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../../../danog/MadelineProto/VoIP.html) + + + + +### `getAllMethods(): array` + +Get full list of MTProto and API methods. + + + +### `getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)` + +Get authorization info. + + +#### See also: +* `\danog\MadelineProto\API::NOT_LOGGED_IN` +* `\danog\MadelineProto\API::WAITING_CODE` +* `\danog\MadelineProto\API::WAITING_SIGNUP` +* `\danog\MadelineProto\API::WAITING_PASSWORD` +* `\danog\MadelineProto\API::LOGGED_IN` +* `API::LOGGED_OUT` + + + + +### `getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress` + +Get the progress of a currently running broadcast. + +Will return null if the broadcast doesn't exist, has already completed or was cancelled. + +Use updateBroadcastProgress updates to get real-time progress status without polling. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Progress`: Broadcast progress.](../../../../danog/MadelineProto/Broadcast/Progress.html) + + + + +### `getCachedConfig(): array` + +Get cached server-side config. + + + +### `getCall(int $id): ?\danog\MadelineProto\VoIP` + +Get phone call information. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../../../danog/MadelineProto/VoIP.html) + + + + +### `getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP` + +Get the phone call with the specified user ID. + + +Parameters: + +* `$userId`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../../../danog/MadelineProto/VoIP.html) + + + + +### `getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState` + +Get call state. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [\danog\MadelineProto\VoIP\CallState](../../../../danog/MadelineProto/VoIP/CallState.html) + + + + +### `getCdnConfig(): void` + +Store RSA keys for CDN datacenters. + + + +### `getConfig(array $config = []): array` + +Get cached (or eventually re-fetch) server-side config. + + +Parameters: + +* `$config`: `array` Current config + + + +### `getDNSClient(): \Amp\Dns\DnsResolver` + +Get async DNS client. + + +#### See also: +* `\Amp\Dns\DnsResolver` + + + + +### `getDhConfig(): array` + +Get diffie-hellman configuration. + + + +### `getDialogIds(): list` + +Get dialog IDs. + + + +### `getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}` + +Get download info of file +Returns an array with the following structure:. + +`$info['ext']` - The file extension +`$info['name']` - The file name, without the extension +`$info['mime']` - The file mime type +`$info['size']` - The file size + + +Parameters: + +* `$messageMedia`: `mixed` File ID + + + +### `getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string` + +Get download link of media file. + + +Parameters: + +* `$media`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string` +* `$scriptUrl`: `?string` +* `$size`: `?int` +* `$name`: `?string` +* `$mime`: `?string` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)` + +Get event handler (or plugin instance). + + +Parameters: + +* `$class`: `(class-string|null)` + + +#### See also: +* `\danog\MadelineProto\Ipc\EventHandlerProxy` +* `\__PHP_Incomplete_Class` + + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getFileInfo(mixed $constructor): array` + +Get info about file. + + +Parameters: + +* `$constructor`: `mixed` File ID + + + +### `getFullDialogs(): array` + +Get full info of all dialogs. + +Bots should use getDialogIds, instead. + + + +### `getFullInfo(mixed $id): array` + +Get full info about peer, returns an FullInfo object. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* [https://docs.madelineproto.xyz/FullInfo.html](https://docs.madelineproto.xyz/FullInfo.html) + + + + +### `getHTTPClient(): \Amp\Http\Client\HttpClient` + +Get async HTTP client. + + +#### See also: +* `\Amp\Http\Client\HttpClient` + + + + +### `getHint(): string` + +Get current password hint. + + + +### `getId(mixed $id): int` + +Get the bot API ID of a peer. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))` + +Get info about peer, returns an Info object. + +If passed a secret chat ID, returns information about the user, not about the secret chat. +Use getSecretChat to return information about the secret chat. + + +Parameters: + +* `$id`: `mixed` Peer +* `$type`: `\danog\MadelineProto\API::INFO_TYPE_*` Whether to generate an Input*, an InputPeer or the full set of constructors + + +#### See also: +* [https://docs.madelineproto.xyz/Info.html](https://docs.madelineproto.xyz/Info.html) +* `\danog\MadelineProto\API::INFO_TYPE_*` + + + + +### `getLogger(): \danog\MadelineProto\Logger` + +Get logger. + + +#### See also: +* [`\danog\MadelineProto\Logger`: Logger class.](../../../../danog/MadelineProto/Logger.html) + + + + +### `getMaps(): ?int` + +Get current number of memory-mapped regions, UNIX only. + + + +### `getMaxMaps(): ?int` + +Get maximum number of memory-mapped regions, UNIX only. +Use testFibers to get the maximum number of fibers on any platform. + + + +### `getMethodNamespaces(): array` + +Get TL namespaces. + + + +### `getMethodsNamespaced(): array` + +Get namespaced methods (method => namespace). + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null` + +Obtain a certain event handler plugin instance. + + +Parameters: + +* `$class`: `class-string` + +return T|null + + +#### See also: +* [`\danog\MadelineProto\PluginEventHandler`: Plugin event handler class.](../../../../danog/MadelineProto/PluginEventHandler.html) +* `\danog\MadelineProto\Ipc\EventHandlerProxy` + + + + +### `getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo` + +Gets info of the propic of a user. + + +Parameters: + +* `$data`: `mixed` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `getPsrLogger(): \Psr\Log\LoggerInterface` + +Get PSR logger. + + +#### See also: +* `\Psr\Log\LoggerInterface` + + + + +### `getPwrChat(mixed $id, bool $fullfetch = true): array` + +Get full info about peer (including full list of channel members), returns a Chat object. + + +Parameters: + +* `$id`: `mixed` Peer +* `$fullfetch`: `bool` + + +#### See also: +* [https://docs.madelineproto.xyz/Chat.html](https://docs.madelineproto.xyz/Chat.html) + + + + +### `getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat` + +Get secret chat. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + +#### See also: +* [`\danog\MadelineProto\SecretChats\SecretChat`: Represents a secret chat.](../../../../danog/MadelineProto/SecretChats/SecretChat.html) + + + + +### `getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage` + +Gets a secret chat message. + + +Parameters: + +* `$chatId`: `integer` Secret chat ID. +* `$randomId`: `integer` Secret chat message ID. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\SecretMessage`: Represents New encrypted message.](../../../../danog/MadelineProto/EventHandler/Message/SecretMessage.html) + + + + +### `getSelf(): array|false` + +Get info about the logged-in user, cached. + +Use fullGetSelf to bypass the cache. + + + +### `getSessionName(): string` + +Returns the session name. + + + +### `getSettings(): \danog\MadelineProto\Settings` + +Return current settings. + + +#### See also: +* [`\danog\MadelineProto\Settings`: Settings class used for configuring MadelineProto.](../../../../danog/MadelineProto/Settings.html) + + + + +### `getSponsoredMessages((int|string|array) $peer): ?array` + +Get sponsored messages for channel. +This method will return an array of [sponsored message objects](https://docs.madelineproto.xyz/API_docs/constructors/sponsoredMessage.html). + +See [the API documentation](https://core.telegram.org/api/sponsored-messages) for more info on how to handle sponsored messages. + + +Parameters: + +* `$peer`: `(int|string|array)` Channel ID, or Update, or Message, or Peer. + + + +### `getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream` + +Provide a stream for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` +* `$size`: `?int` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `getStreamPipe(): \Amp\ByteStream\Pipe` + +Obtains a pipe that can be used to upload a file from a stream. + + +#### See also: +* `\Amp\ByteStream\Pipe` + + + + +### `getTL(): \danog\MadelineProto\TL\TLInterface` + +Get TL serializer. + + +#### See also: +* [\danog\MadelineProto\TL\TLInterface](../../../../danog/MadelineProto/TL/TLInterface.html) + + + + +### `getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*` + +Get type of peer. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* `\danog\MadelineProto\API::PEER_TYPE_*` + + + + +### `getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list` + +Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**. + +`getUpdates` will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + + +Parameters: + +* `$params`: `array{offset?: int, limit?: int, timeout?: float}` Params + + + +### `getWebMessage(string $message): string` + +Get a message to show to the user when starting the bot. + + +Parameters: + +* `$message`: `string` + + + +### `getWebWarnings(): string` + +Get various warnings to show to the user in the web UI. + + + +### `hasAdmins(): bool` + +Check if has admins. + + + +### `hasEventHandler(): bool` + +Check if an event handler instance is present. + + + +### `hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool` + +Check if a certain event handler plugin is installed. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) + + + + +### `hasReportPeers(): bool` + +Check if has report peers. + + + +### `hasSecretChat((array|int) $chat): bool` + +Check whether secret chat exists. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../../../danog/MadelineProto/TextEntities.html) + + + + +### `importAuthorization(array $authorization, int $mainDcID): array` + +Import authorization. + + +Parameters: + +* `$authorization`: `array` Authorization info +* `$mainDcID`: `int` Main DC ID + + + +### `inflateStripped(string $stripped): string` + +Inflate stripped photosize to full JPG payload. + + +Parameters: + +* `$stripped`: `string` Stripped photosize + + + +### `initSelfRestart(): void` + +Initialize self-restart hack. + + + +### `isAltervista(): bool` + +Whether this is altervista. + + + +### `isArrayOrAlike(mixed $var): bool` + +Check if is array or similar (traversable && countable && arrayAccess). + + +Parameters: + +* `$var`: `mixed` Value to check + + + +### `isBot(mixed $peer): bool` + +Check if the specified peer is a bot. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isForum(mixed $peer): bool` + +Check if the specified peer is a forum. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isIpc(): bool` + +Whether we're an IPC client instance. + + + +### `isIpcWorker(): bool` + +Whether we're an IPC server process (as opposed to an event handler). + + + +### `isPlayPaused(int $id): bool` + +Whether the currently playing audio file is paused. + + +Parameters: + +* `$id`: `int` + + + +### `isPremium(): bool` + +Returns whether the current user is a premium user, cached. + + + +### `isSelfBot(): bool` + +Returns whether the current user is a bot. + + + +### `isSelfUser(): bool` + +Returns whether the current user is a user. + + + +### `isTestMode(): boolean` + +Whether we're currently connected to the test DCs. + + + +### `logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void` + +Logger. + + +Parameters: + +* `$param`: `mixed` Parameter +* `$level`: `int` Logging level +* `$file`: `string` File where the message originated + + + +### `logout(): void` + +Logout the session. + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string` + +Provide a buffered reader for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `openFileAppendOnly(string $path): \Amp\File\File` + +Opens a file in append-only mode. + + +Parameters: + +* `$path`: `string` File path. + + +#### See also: +* `\Amp\File\File` + + + + +### `packDouble(float $value): string` + +Convert double to binary version. + + +Parameters: + +* `$value`: `float` Value to convert + + + +### `packSignedInt(integer $value): string` + +Convert integer to base256 signed int. + + +Parameters: + +* `$value`: `integer` Value to convert + + + +### `packSignedLong(int $value): string` + +Convert integer to base256 long. + + +Parameters: + +* `$value`: `int` Value to convert + + + +### `packUnsignedInt(int $value): string` + +Convert value to unsigned base256 int. + + +Parameters: + +* `$value`: `int` Value + + + +### `pausePlay(int $id): void` + +Pauses playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `peerIsset(mixed $id): bool` + +Check if peer is present in internal peer database. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `phoneLogin(string $number, integer $sms_type = 5): array` + +Login as user. + + +Parameters: + +* `$number`: `string` Phone number +* `$sms_type`: `integer` SMS type + + + +### `posmod(int $a, int $b): int` + +Positive modulo +Works just like the % (modulus) operator, only returns always a postive number. + + +Parameters: + +* `$a`: `int` A +* `$b`: `int` B + + + +### `processDownloadServerPing(string $path, string $payload): void` + +Internal endpoint used by the download server. + + +Parameters: + +* `$path`: `string` +* `$payload`: `string` + + + +### `qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode` + +Initiates QR code login. + +Returns a QR code login helper object, that can be used to render the QR code, display the link directly, wait for login, QR code expiration and much more. + +Returns null if we're already logged in, or if we're waiting for a password (use getAuthorization to distinguish between the two cases). + + +#### See also: +* [`\danog\MadelineProto\TL\Types\LoginQrCode`: Represents a login QR code.](../../../../danog/MadelineProto/TL/Types/LoginQrCode.html) + + + + +### `random(integer $length): string` + +Get secure random string of specified length. + + +Parameters: + +* `$length`: `integer` Length + + + +### `randomInt(integer $modulus = 0): int` + +Get random integer. + + +Parameters: + +* `$modulus`: `integer` Modulus + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `refreshFullPeerCache(mixed $id): void` + +Refresh full peer cache for a certain peer. + + +Parameters: + +* `$id`: `mixed` The peer to refresh + + + +### `refreshPeerCache(mixed ...$ids): void` + +Refresh peer cache for a certain peer. + + +Parameters: + +* `...$ids`: `mixed` + + + +### `report(string $message, string $parseMode = ''): void` + +Report an error to the previously set peer. + + +Parameters: + +* `$message`: `string` Error to report +* `$parseMode`: `string` Parse mode + + + +### `reportMemoryProfile(): void` + +Report memory profile with memprof. + + + +### `requestCall(mixed $user): \danog\MadelineProto\VoIP` + +Request VoIP call. + + +Parameters: + +* `$user`: `mixed` User + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../../../danog/MadelineProto/VoIP.html) + + + + +### `requestSecretChat(mixed $user): int` + +Request secret chat. + + +Parameters: + +* `$user`: `mixed` User to start secret chat with + + + +### `resetUpdateState(): void` + +Reset the update state and fetch all updates from the beginning. + + + +### `restart(): void` + +Restart update loop. + + + +### `resumePlay(int $id): void` + +Resumes playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `rethrow(Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `Throwable` + + +#### See also: +* `Throwable` + + + + +### `rleDecode(string $string): string` + +null-byte RLE decode. + + +Parameters: + +* `$string`: `string` Data to decode + + + +### `rleEncode(string $string): string` + +null-byte RLE encode. + + +Parameters: + +* `$string`: `string` Data to encode + + + +### `sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendCustomEvent(mixed $payload): void` + +Sends an updateCustomEvent update to the event handler. + + +Parameters: + +* `$payload`: `mixed` + + + +### `sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$duration`: `?int` +* `$width`: `?int` +* `$height`: `?int` +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a message. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` Cancellation + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>` + +Sends a message to all report peers (admins of the bot). + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$stickerSet`: `array` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `setNoop(): void` + +Set NOOP update handler, ignoring all updates. + + + +### `setReportPeers((int|string|array<(int|string)>) $userOrId): void` + +Set peer(s) where to send errors occurred in the event loop. + + +Parameters: + +* `$userOrId`: `(int|string|array<(int|string)>)` Username(s) or peer ID(s) + + + +### `setWebhook(string $webhookUrl): void` + +Set webhook update handler. + + +Parameters: + +* `$webhookUrl`: `string` Webhook URL + + + +### `skipPlay(int $id): void` + +When called, skips to the next file in the playlist. + + +Parameters: + +* `$id`: `int` + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `start(): array` + +Log in to telegram (via CLI or web). + + + +### `stop(): void` + +Stop update loop. + + + +### `stopPlay(int $id): void` + +Stops playing all files in the call, clears the main and the hold playlist. + + +Parameters: + +* `$id`: `int` + + + +### `stringToStream(string $str): \Amp\ByteStream\ReadableBuffer` + +Converts a string into an async amphp stream. + + +Parameters: + +* `$str`: `string` + + +#### See also: +* `\Amp\ByteStream\ReadableBuffer` + + + + +### `subscribeToUpdates(mixed $channel): bool` + +Subscribe to event handler updates for a channel/supergroup we're not a member of. + + +Parameters: + +* `$channel`: `mixed` Channel/supergroup to subscribe to + + +Return value: False if we were already subscribed + + +### `tdToMTProto(array $params): array` + +Convert TD to MTProto parameters. + + +Parameters: + +* `$params`: `array` Parameters + + + +### `tdToTdcli(mixed $params): array` + +Convert TD parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Parameters + + + +### `tdcliToTd(mixed $params, array $key = NULL): array` + +Convert tdcli parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Params +* `$key`: `array` Key + + + +### `testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}` + +Test fibers. + + +Parameters: + +* `$fiberCount`: `int` + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `unpackDouble(string $value): float` + +Unpack binary double. + + +Parameters: + +* `$value`: `string` Value to unpack + + + +### `unpackFileId(string $fileId): array` + +Unpack bot API file ID. + + +Parameters: + +* `$fileId`: `string` Bot API file ID + + +Return value: Unpacked file ID + + +### `unpackSignedInt(string $value): int` + +Unpack base256 signed int. + + +Parameters: + +* `$value`: `string` base256 int + + + +### `unpackSignedLong(string $value): int` + +Unpack base256 signed long. + + +Parameters: + +* `$value`: `string` base256 long + + + +### `unpackSignedLongString((string|int|array) $value): string` + +Unpack base256 signed long to string. + + +Parameters: + +* `$value`: `(string|int|array)` base256 long + + + +### `unsetEventHandler(): void` + +Unset event handler. + + + +### `update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void` + +Update the 2FA password. + +The params array can contain password, new_password, email and hint params. + + +Parameters: + +* `$params`: `array{password?: string, new_password?: string, email?: string, hint?: string}` The params + + + +### `updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void` + +Parse, update and store settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file to secret chat. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../../../danog/MadelineProto/BotApiFileId.html) +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from callable. + +The callable must accept two parameters: int $offset, int $size +The callable must return a string with the contest of the file at the specified offset and size. + + +Parameters: + +* `$callable`: `callable(int, int, ?Cancellation): strin)` Callable (offset, length) => data +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable(float, float, float): voi)` Status callback +* `$seekable`: `boolean` Whether chunks can be fetched out of order +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from stream. + + +Parameters: + +* `$stream`: `mixed` PHP resource or AMPHP async stream +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Reupload telegram file. + + +Parameters: + +* `$media`: `mixed` Telegram file +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from URL. + + +Parameters: + +* `$url`: `(string|\danog\MadelineProto\FileCallbackInterface)` URL of file +* `$size`: `integer` Size of file +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>` + +Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` Class name + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../../../danog/MadelineProto/EventHandler.html) +* [`\danog\MadelineProto\EventHandlerIssue`: Represents an event handler issue.](../../../../danog/MadelineProto/EventHandlerIssue.html) + + + + +### `viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool` + +Mark sponsored message as read. + + +Parameters: + +* `$peer`: `(int|array)` Channel ID, or Update, or Message, or Peer. +* `$message`: `(string|array{random_id: string})` Random ID or sponsored message to mark as read. + + + +### `wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media` + +Wrap a media constructor into an abstract Media object. + + +Parameters: + +* `$media`: `array` +* `$protected`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage` + +Wrap a Message constructor into an abstract Message object. + + +Parameters: + +* `$message`: `array` +* `$scheduled`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractMessage`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/AbstractMessage.html) + + + + +### `wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned` + +Wrap a Pin constructor into an abstract Pinned object. + + +Parameters: + +* `$message`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Pinned`: Indicates that some messages were pinned/unpinned.](../../../../danog/MadelineProto/EventHandler/Pinned.html) + + + + +### `wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update` + +Wrap an Update constructor into an abstract Update object. + + +Parameters: + +* `$update`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void` + +Initialize database properties. + + +Parameters: + +* `$settings`: `\danog\AsyncOrm\Settings` +* `$tablePrefix`: `string` + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `saveDbProperties(): void` + +Save all properties. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Poll/MultiplePoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Poll/MultiplePoll.md new file mode 100644 index 0000000000..344cf62b2b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Poll/MultiplePoll.md @@ -0,0 +1,57 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Poll\\MultiplePoll: Represents a poll with multiple options can be chosen as answer" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Poll\MultiplePoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a poll with multiple options can be chosen as answer + + + +## Properties +* `$id`: `int` ID of the poll +* `$closed`: `bool` Whether the poll is closed and doesn’t accept any more answers +* `$question`: `string` The question of the poll +* `$questionEntities`: `list` Styled text entities in the question of the poll. +* `$answers`: `list` The possible answers +* `$closePeriod`: `?int` Amount of time in seconds the poll will be active after creation, 5-600 +* `$closeDate`: `?int` Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future +* `$recentVoters`: `list` IDs of the last users that recently voted in the poll +* `$totalVoters`: `int` Total number of people that voted in the poll + +## Method list: +* [`fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll`](#fromRawPoll) +* [`getQuestionHTML(bool $allowTelegramTags = false): string`](#getQuestionHTML) + +## Methods: +### `fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll` + + + + +Parameters: + +* `$rawPoll`: `array` + + + +### `getQuestionHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the question. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Poll/PollAnswer.md b/docs/PHP/danog/MadelineProto/EventHandler/Poll/PollAnswer.md new file mode 100644 index 0000000000..8fbc85f42e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Poll/PollAnswer.md @@ -0,0 +1,42 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Poll\\PollAnswer: Represents a possible answer of a poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Poll\PollAnswer` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a possible answer of a poll + + + +## Properties +* `$text`: `string` Textual representation of the answer +* `$entities`: `list` Styled text entities in the answer. +* `$option`: `string` The param that has to be passed to [messages.sendVote](https://docs.madelineproto.xyz/API_docs/methods/messages.sendVote.html) +* `$chosen`: `?bool` Whether we have chosen this answer +* `$correct`: `?bool` For quizzes, whether the option we have chosen is correct +* `$voters`: `?int` How many users voted for this option + +## Method list: +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) + +## Methods: +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the answer. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Poll/QuizPoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Poll/QuizPoll.md new file mode 100644 index 0000000000..afca8291eb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Poll/QuizPoll.md @@ -0,0 +1,71 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Poll\\QuizPoll: Represents a quiz (with wrong and correct answers, results shown in the return type) poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Poll\QuizPoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a quiz (with wrong and correct answers, results shown in the return type) poll + + + +## Properties +* `$solution`: `?string` Explanation of quiz solution +* `$solutionEntities`: `list` Message [entities](https://core.telegram.org/api/entities) for styled text in quiz solution +* `$id`: `int` ID of the poll +* `$closed`: `bool` Whether the poll is closed and doesn’t accept any more answers +* `$question`: `string` The question of the poll +* `$questionEntities`: `list` Styled text entities in the question of the poll. +* `$answers`: `list` The possible answers +* `$closePeriod`: `?int` Amount of time in seconds the poll will be active after creation, 5-600 +* `$closeDate`: `?int` Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future +* `$recentVoters`: `list` IDs of the last users that recently voted in the poll +* `$totalVoters`: `int` Total number of people that voted in the poll + +## Method list: +* [`getSolutionHTML(bool $allowTelegramTags = false): ?string`](#getSolutionHTML) +* [`fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll`](#fromRawPoll) +* [`getQuestionHTML(bool $allowTelegramTags = false): string`](#getQuestionHTML) + +## Methods: +### `getSolutionHTML(bool $allowTelegramTags = false): ?string` + +Get an HTML version of the solution. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +### `fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll` + + + + +Parameters: + +* `$rawPoll`: `array` + + + +### `getQuestionHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the question. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Poll/SinglePoll.md b/docs/PHP/danog/MadelineProto/EventHandler/Poll/SinglePoll.md new file mode 100644 index 0000000000..f44f8e4bdd --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Poll/SinglePoll.md @@ -0,0 +1,57 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Poll\\SinglePoll: Represents a poll with a option can be chosen as answer" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Poll\SinglePoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a poll with a option can be chosen as answer + + + +## Properties +* `$id`: `int` ID of the poll +* `$closed`: `bool` Whether the poll is closed and doesn’t accept any more answers +* `$question`: `string` The question of the poll +* `$questionEntities`: `list` Styled text entities in the question of the poll. +* `$answers`: `list` The possible answers +* `$closePeriod`: `?int` Amount of time in seconds the poll will be active after creation, 5-600 +* `$closeDate`: `?int` Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future +* `$recentVoters`: `list` IDs of the last users that recently voted in the poll +* `$totalVoters`: `int` Total number of people that voted in the poll + +## Method list: +* [`fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll`](#fromRawPoll) +* [`getQuestionHTML(bool $allowTelegramTags = false): string`](#getQuestionHTML) + +## Methods: +### `fromRawPoll(array $rawPoll): \danog\MadelineProto\EventHandler\AbstractPoll` + + + + +Parameters: + +* `$rawPoll`: `array` + + + +### `getQuestionHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the question. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy.md new file mode 100644 index 0000000000..00bfa58a8c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy: Indicates some privacy rules for a user or set of users." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Indicates some privacy rules for a user or set of users. + + + +## Properties +* `$rule`: `danog\MadelineProto\EventHandler\Privacy\Rule` New privacy rule. +* `$appliesTo`: `list` Peers to which the privacy rules apply +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/Rule.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/Rule.md new file mode 100644 index 0000000000..04815cce76 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/Rule.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\Rule: Represents a privacy rule." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\Rule` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a privacy rule. + + + + +## Constants +* `danog\MadelineProto\EventHandler\Privacy\Rule::STATUS_TIMESTAMP`: Whether we can see the last online timestamp of this user + +* `danog\MadelineProto\EventHandler\Privacy\Rule::CHAT_INVITE`: Whether the user can be invited to chats + +* `danog\MadelineProto\EventHandler\Privacy\Rule::PHONE_CALL`: Whether the user accepts phone calls + +* `danog\MadelineProto\EventHandler\Privacy\Rule::PHONE_P2P`: Whether P2P connections in phone calls with this user are allowed + +* `danog\MadelineProto\EventHandler\Privacy\Rule::FORWARDS`: Whether messages forwarded from the user will be [anonymously forwarded](https://telegram.org/blog/unsend-privacy-emoji#anonymous-forwarding) + +* `danog\MadelineProto\EventHandler\Privacy\Rule::PROFILE_PHOTO`: Whether the profile picture of the user is visible + +* `danog\MadelineProto\EventHandler\Privacy\Rule::PHONE_NUMBER`: Whether the user allows us to see his phone number + +* `danog\MadelineProto\EventHandler\Privacy\Rule::ADDED_BY_PHONE`: Whether this user can be added to our contact list by their phone number + +* `danog\MadelineProto\EventHandler\Privacy\Rule::VOICE_MESSAGES`: Whether the user accepts voice messages + +* `danog\MadelineProto\EventHandler\Privacy\Rule::ABOUT`: Whether the user can see our bio. + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination.md new file mode 100644 index 0000000000..9db8758952 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination: To whom does a privacy rule apply?" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +To whom does a privacy rule apply? + + + + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowAll.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowAll.md new file mode 100644 index 0000000000..c576a8ab82 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowAll.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\AllowAll: Allow all users." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowAll` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow all users. + + + + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowChatParticipants.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowChatParticipants.md new file mode 100644 index 0000000000..2d71276ee6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowChatParticipants.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\AllowChatParticipants: Allow all participants of certain chats." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowChatParticipants` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow all participants of certain chats. + + + +## Properties +* `$chats`: `array` Allowed chats + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowCloseFriends.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowCloseFriends.md new file mode 100644 index 0000000000..ab774d89f0 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowCloseFriends.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\AllowCloseFriends: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowCloseFriends` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowContacts.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowContacts.md new file mode 100644 index 0000000000..f881a7fc2a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowContacts.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\AllowContacts: Allow all contacts." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowContacts` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow all contacts. + + + + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowUsers.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowUsers.md new file mode 100644 index 0000000000..e922452623 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowUsers.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\AllowUsers: Allow only certain user." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowUsers` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Allow only certain user. + + + +## Properties +* `$users`: `array` Allowed users + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowAll.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowAll.md new file mode 100644 index 0000000000..58516f0e09 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowAll.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\DisallowAll: Disallow all users." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowAll` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Disallow all users. + + + + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowChatParticipants.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowChatParticipants.md new file mode 100644 index 0000000000..0a68e3ca10 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowChatParticipants.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\DisallowChatParticipants: Disallow only participants of certain chats." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowChatParticipants` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Disallow only participants of certain chats. + + + +## Properties +* `$chats`: `array` Allowed chats + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowContacts.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowContacts.md new file mode 100644 index 0000000000..a8ef7aa241 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowContacts.md @@ -0,0 +1,35 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\DisallowContacts: Disallow only contacts." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowContacts` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Disallow only contacts. + + + + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowUsers.md b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowUsers.md new file mode 100644 index 0000000000..ef02bf9d97 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowUsers.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Privacy\\RuleDestination\\DisallowUsers: Disallow only certain users." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowUsers` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Disallow only certain users. + + + +## Properties +* `$users`: `array` Allowed users + +## Method list: +* [`fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination`](#fromRawRule) + +## Methods: +### `fromRawRule(array $rawRule): \danog\MadelineProto\EventHandler\Privacy\RuleDestination` + + + + +Parameters: + +* `$rawRule`: `array` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.md new file mode 100644 index 0000000000..cc2ae38af2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.md @@ -0,0 +1,46 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Query\\ButtonQuery: Represents a query sent by the user by clicking on a button." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Query\ButtonQuery` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a button. + + + +## Properties +* `$data`: `string` Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field. +* `$matches`: `list` Regex matches, if a filter regex is present. +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.md new file mode 100644 index 0000000000..231d6dbb42 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.md @@ -0,0 +1,148 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Query\\ChatButtonQuery: Represents a query sent by the user by clicking on a button in a chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Query\ChatButtonQuery` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a button in a chat. + + + +## Properties +* `$data`: `string` Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field. +* `$matches`: `list` Regex matches, if a filter regex is present. +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. +* `$chatId`: `int` Chat where the inline keyboard was sent +* `$messageId`: `int` Message ID + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) +* [`editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false, (int|null) $scheduleDate = NULL): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`delete(boolean $revoke = true): void`](#delete) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`report(ReportReason $reason, string $message): bool`](#report) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +### `editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false, (int|null) $scheduleDate = NULL): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$parseMode`: `ParseMode` Whether to parse HTML or Markdown markup in the message +* `$noWebpage`: `bool` Disable webpage preview +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages + + +#### See also: +* `ParseMode` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `report(ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* `ReportReason` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.md new file mode 100644 index 0000000000..e764073151 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.md @@ -0,0 +1,145 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Query\\ChatGameQuery: Represents a query sent by the user by clicking on a \"Play game\" button in a chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Query\ChatGameQuery` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a "Play game" button in a chat. + + + +## Properties +* `$gameShortName`: `string` Short name of a Game to be returned, serves as the unique identifier for the game +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. +* `$chatId`: `int` Chat where the inline keyboard was sent +* `$messageId`: `int` Message ID + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) +* [`editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false, (int|null) $scheduleDate = NULL): \danog\MadelineProto\EventHandler\Message`](#editText) +* [`editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message`](#editReplyMarkup) +* [`delete(boolean $revoke = true): void`](#delete) +* [`pin(bool $pmOneside = false, bool $silent = false): void`](#pin) +* [`unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update`](#unpin) +* [`report(ReportReason $reason, string $message): bool`](#report) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +### `editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false, (int|null) $scheduleDate = NULL): \danog\MadelineProto\EventHandler\Message` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$parseMode`: `ParseMode` Whether to parse HTML or Markdown markup in the message +* `$noWebpage`: `bool` Disable webpage preview +* `$scheduleDate`: `(int|null)` Scheduled message date for scheduled messages + + +#### See also: +* `ParseMode` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `editReplyMarkup(array $replyMarkup): \danog\MadelineProto\EventHandler\Message` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `delete(boolean $revoke = true): void` + +Delete the message. + + +Parameters: + +* `$revoke`: `boolean` Whether to delete the message for all participants of the chat. + + + +### `pin(bool $pmOneside = false, bool $silent = false): void` + +Pin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + + +### `unpin(bool $pmOneside = false, bool $silent = false): ?\danog\MadelineProto\EventHandler\Update` + +Unpin a message. + + +Parameters: + +* `$pmOneside`: `bool` Whether the message should only be pinned on the local side of a one-to-one chat +* `$silent`: `bool` Pin the message silently, without triggering a notification + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `report(ReportReason $reason, string $message): bool` + +Report a message in a chat for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `ReportReason` Why are these messages being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* `ReportReason` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.md new file mode 100644 index 0000000000..4cdd5c467d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.md @@ -0,0 +1,43 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Query\\GameQuery: Represents a query sent by the user by clicking on a \"Play game\" button." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Query\GameQuery` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a "Play game" button. + + + +## Properties +* `$gameShortName`: `string` Short name of a Game to be returned, serves as the unique identifier for the game +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.md new file mode 100644 index 0000000000..2690b05e10 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.md @@ -0,0 +1,79 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Query\\InlineButtonQuery: Represents a query sent by the user by clicking on a button in an inline message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Query\InlineButtonQuery` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a button in an inline message. + + + +## Properties +* `$data`: `string` Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field. +* `$matches`: `list` Regex matches, if a filter regex is present. +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. +* `$inlineMessageId`: `string` Inline message ID + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) +* [`editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false): void`](#editText) +* [`editReplyMarkup(array $replyMarkup): void`](#editReplyMarkup) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +### `editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false): void` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$parseMode`: `ParseMode` Whether to parse HTML or Markdown markup in the message +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* `ParseMode` + + + + +### `editReplyMarkup(array $replyMarkup): void` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.md b/docs/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.md new file mode 100644 index 0000000000..92fabec243 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.md @@ -0,0 +1,76 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Query\\InlineGameQuery: Represents a query sent by the user by clicking on a \"Play game\" button in an inline message." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Query\InlineGameQuery` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a query sent by the user by clicking on a "Play game" button in an inline message. + + + +## Properties +* `$gameShortName`: `string` Short name of a Game to be returned, serves as the unique identifier for the game +* `$queryId`: `int` Query ID +* `$userId`: `int` ID of the user that pressed the button +* `$chatInstance`: `int` Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games. +* `$inlineMessageId`: `string` Inline message ID + +## Method list: +* [`answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool`](#answer) +* [`editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false): void`](#editText) +* [`editReplyMarkup(array $replyMarkup): void`](#editReplyMarkup) + +## Methods: +### `answer(string $message, bool $alert = false, (string|null) $url = NULL, int $cacheTime = 300): bool` + + + + +Parameters: + +* `$message`: `string` Popup to show +* `$alert`: `bool` Whether to show the message as a popup instead of a toast notification +* `$url`: `(string|null)` URL to open +* `$cacheTime`: `int` Cache validity (default set to 5 min based on telegram official docs ...) + + + +### `editText(string $message, (array|null) $replyMarkup = NULL, ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, bool $noWebpage = false): void` + +Edit message text. + + +Parameters: + +* `$message`: `string` New message +* `$replyMarkup`: `(array|null)` Reply markup for inline keyboards +* `$parseMode`: `ParseMode` Whether to parse HTML or Markdown markup in the message +* `$noWebpage`: `bool` Disable webpage preview + + +#### See also: +* `ParseMode` + + + + +### `editReplyMarkup(array $replyMarkup): void` + +Edit message keyboard. + + +Parameters: + +* `$replyMarkup`: `array` Reply markup for inline keyboards + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Ended.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Ended.md new file mode 100644 index 0000000000..f2a3035345 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Ended.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\Ended: Represents an ended call" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\Ended` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an ended call + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdmin.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdmin.md new file mode 100644 index 0000000000..02850c33df --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdmin.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\FromAdmin: Allows messages from the bot admin" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows messages from the bot admin + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdminOrOutgoing.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdminOrOutgoing.md new file mode 100644 index 0000000000..1ce96830ce --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdminOrOutgoing.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\FromAdminOrOutgoing: Allows messages from the bot admin or outgoing messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\FromAdminOrOutgoing` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows messages from the bot admin or outgoing messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasAudio.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasAudio.md new file mode 100644 index 0000000000..7374c4fbcb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasAudio.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasAudio: Allows only audio messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasAudio` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only audio messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocument.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocument.md new file mode 100644 index 0000000000..34e8ecead6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocument.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasDocument: Allows only documents" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasDocument` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only documents + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocumentPhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocumentPhoto.md new file mode 100644 index 0000000000..e689002b4b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocumentPhoto.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasDocumentPhoto: Allows only document photos" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasDocumentPhoto` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only document photos + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasGif.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasGif.md new file mode 100644 index 0000000000..1f18dbdd5b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasGif.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasGif: Allows only GIFs" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasGif` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only GIFs + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMedia.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMedia.md new file mode 100644 index 0000000000..c118ade8a7 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMedia.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasMedia: Allows only media messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasMedia` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only media messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMultiplePoll.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMultiplePoll.md new file mode 100644 index 0000000000..d9bdb38b23 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMultiplePoll.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasMultiplePoll: Allows only messages that contain a multiple poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasMultiplePoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages that contain a multiple poll + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasNoMedia.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasNoMedia.md new file mode 100644 index 0000000000..345d42d314 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasNoMedia.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasNoMedia: Allows only messages with no media" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasNoMedia` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages with no media + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPhoto.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPhoto.md new file mode 100644 index 0000000000..3315898203 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPhoto.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasPhoto: Allows only photos" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasPhoto` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only photos + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPoll.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPoll.md new file mode 100644 index 0000000000..89d89e2912 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPoll.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasPoll: Allows only messages that contain a poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasPoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages that contain a poll + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasQuizPoll.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasQuizPoll.md new file mode 100644 index 0000000000..917b1333c9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasQuizPoll.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasQuizPoll: Allows only messages that contain a quiz poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasQuizPoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages that contain a quiz poll + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasRoundVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasRoundVideo.md new file mode 100644 index 0000000000..a2c0e1e84d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasRoundVideo.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasRoundVideo: Allows only round videos" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasRoundVideo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only round videos + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSinglePoll.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSinglePoll.md new file mode 100644 index 0000000000..3eaf54b704 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSinglePoll.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasSinglePoll: Allows only messages that contain a single poll" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasSinglePoll` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages that contain a single poll + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSticker.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSticker.md new file mode 100644 index 0000000000..e442e27585 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSticker.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasSticker: Allows only stickers" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasSticker` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only stickers + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasTopic.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasTopic.md new file mode 100644 index 0000000000..6fa8ed2dba --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasTopic.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasTopic: Allow only messages coming from groups that has topics (Supergroups only)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasTopic` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only messages coming from groups that has topics (Supergroups only). + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVideo.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVideo.md new file mode 100644 index 0000000000..a07206cfc2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVideo.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasVideo: Allows only videos" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasVideo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only videos + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVoice.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVoice.md new file mode 100644 index 0000000000..ac71ca05a1 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVoice.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\HasVoice: Allows only voice messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\HasVoice` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only voice messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Incoming.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Incoming.md new file mode 100644 index 0000000000..ec9594bab3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Incoming.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\Incoming: Represents an incoming message" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\Incoming` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an incoming message + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsEdited.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsEdited.md new file mode 100644 index 0000000000..aefb5b426f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsEdited.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\IsEdited: Allows messages that were edited." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\IsEdited` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows messages that were edited. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsForwarded.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsForwarded.md new file mode 100644 index 0000000000..4aaf2aca8b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsForwarded.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\IsForwarded: Allows only forwarded messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\IsForwarded` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only forwarded messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsNotEdited.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsNotEdited.md new file mode 100644 index 0000000000..d2e214e89b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsNotEdited.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\IsNotEdited: Allows messages that weren't edited." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\IsNotEdited` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows messages that weren't edited. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReply.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReply.md new file mode 100644 index 0000000000..ed31ee909c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReply.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\IsReply: Allows only messages that reply to other messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\IsReply` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages that reply to other messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReplyToSelf.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReplyToSelf.md new file mode 100644 index 0000000000..d46dfb1415 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReplyToSelf.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\IsReplyToSelf: Allows only messages that reply to one of our messages" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\IsReplyToSelf` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allows only messages that reply to one of our messages + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Outgoing.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Outgoing.md new file mode 100644 index 0000000000..5daf6d295a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Outgoing.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\Outgoing: Represents an outgoing message" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\Outgoing` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an outgoing message + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Running.md b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Running.md new file mode 100644 index 0000000000..f5110ae3ab --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Running.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\SimpleFilter\\Running: Allow only currently running calls" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\SimpleFilter\Running` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Allow only currently running calls + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Story/Story.md b/docs/PHP/danog/MadelineProto/EventHandler/Story/Story.md new file mode 100644 index 0000000000..a2148996a3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Story/Story.md @@ -0,0 +1,173 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Story\\Story: Represents a Telegram story." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Story\Story` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a Telegram story. + + + +## Properties +* `$pinned`: `bool` Whether this story is pinned +* `$public`: `bool` Whether this story is visible to everyone +* `$closeFriends`: `bool` Whether this story is visible to only close friends of the user (@see Privacy::AllowCloseFriends) +* `$contacts`: `bool` Whether this story is only visible to your countacts +* `$selectedContacts`: `bool` Whether this story is only visible to a select list of contacts +* `$protected`: `bool` Whether this media is protected +* `$edited`: `bool` Whether this story was edited +* `$date`: `int` When was the story sent +* `$expireDate`: `int` Expiration date of the story +* `$caption`: `string` Story caption +* `$entities`: `list` Message [entities](https://core.telegram.org/api/entities) for story caption +* `$media`: `(danog\MadelineProto\EventHandler\Media\Gif | danog\MadelineProto\EventHandler\Media\Photo | danog\MadelineProto\EventHandler\Media\Video)` Attached media. +* `$privacy`: `list` +* `$sentReaction`: `(string | int | null)` Our reaction to the story +* `$reactionCount`: `?int` Reaction counter +* `$views`: `?int` View counter +* `$recentViewers`: `list` List of users who recently viewed the story +* `$matches`: `list` +Regex matches, if a filter regex is present +* `$matchesAll`: `array | mixed)>` +Regex matches, if a filter multiple match regex is present +* `$senderId`: `int` ID of the sender of the story +* `$id`: `int` Story ID + +## Method list: +* [`reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false): \danog\MadelineProto\EventHandler\Message`](#reply) +* [`delete(): void`](#delete) +* [`exportLink(): string`](#exportLink) +* [`report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message = ''): boolean`](#report) +* [`pin(): void`](#pin) +* [`unpin(): void`](#unpin) +* [`view(): boolean`](#view) +* [`addReaction((integer|string) $reaction, boolean $recent = true): \danog\MadelineProto\EventHandler\Story\StoryReaction`](#addReaction) +* [`delReaction(boolean $recent = true): \danog\MadelineProto\EventHandler\Story\StoryReaction`](#delReaction) +* [`getHTML(bool $allowTelegramTags = false): string`](#getHTML) + +## Methods: +### `reply(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false): \danog\MadelineProto\EventHandler\Message` + +Reply to the story. + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../../../danog/MadelineProto/ParseMode.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `delete(): void` + +Delete the story. + + + +### `exportLink(): string` + +Export story link e.g: https://t.me/username/s/storyid. + + + +### `report(\danog\MadelineProto\EventHandler\Message\ReportReason $reason, string $message = ''): boolean` + +Report a story for violation of telegram’s Terms of Service. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\EventHandler\Message\ReportReason` Why is story being reported +* `$message`: `string` Comment for report moderation + + +#### See also: +* [\danog\MadelineProto\EventHandler\Message\ReportReason](../../../../danog/MadelineProto/EventHandler/Message/ReportReason.html) + + + + +### `pin(): void` + +Pin a story. + + + +### `unpin(): void` + +Unpin a story. + + + +### `view(): boolean` + +Mark story as read. + + + +### `addReaction((integer|string) $reaction, boolean $recent = true): \danog\MadelineProto\EventHandler\Story\StoryReaction` + +Reaction to story. + + +Parameters: + +* `$reaction`: `(integer|string)` string or int Reaction +* `$recent`: `boolean` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Story\StoryReaction`: Represents a reaction to a story.](../../../../danog/MadelineProto/EventHandler/Story/StoryReaction.html) + + + + +### `delReaction(boolean $recent = true): \danog\MadelineProto\EventHandler\Story\StoryReaction` + +Delete reaction from story. + + +Parameters: + +* `$recent`: `boolean` string or int Reaction + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Story\StoryReaction`: Represents a reaction to a story.](../../../../danog/MadelineProto/EventHandler/Story/StoryReaction.html) + + + + +### `getHTML(bool $allowTelegramTags = false): string` + +Get an HTML version of the story caption. + + +Parameters: + +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.md b/docs/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.md new file mode 100644 index 0000000000..f827ea1ac4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Story\\StoryDeleted: Represents a deleted story." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Story\StoryDeleted` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a deleted story. + + + +## Properties +* `$senderId`: `int` ID of the sender of the story +* `$id`: `int` Story ID +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.md b/docs/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.md new file mode 100644 index 0000000000..bff08fa379 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Story\\StoryReaction: Represents a reaction to a story." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Story\StoryReaction` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a reaction to a story. + + + +## Properties +* `$senderId`: `int` ID of the sender of the story +* `$id`: `int` Story ID +* `$reaction`: `(string | int | null)` +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Topic/IconColor.md b/docs/PHP/danog/MadelineProto/EventHandler/Topic/IconColor.md new file mode 100644 index 0000000000..5019077d8e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Topic/IconColor.md @@ -0,0 +1,73 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Topic\\IconColor: Specifies the color of the fallback topic icon (RGB) if no custom emoji icon is specified." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Topic\IconColor` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Specifies the color of the fallback topic icon (RGB) if no custom emoji icon is specified. + + + + +## Constants +* `danog\MadelineProto\EventHandler\Topic\IconColor::NONE`: + +* `danog\MadelineProto\EventHandler\Topic\IconColor::BLUE`: + +* `danog\MadelineProto\EventHandler\Topic\IconColor::YELLOW`: + +* `danog\MadelineProto\EventHandler\Topic\IconColor::PURPLE`: + +* `danog\MadelineProto\EventHandler\Topic\IconColor::GREEN`: + +* `danog\MadelineProto\EventHandler\Topic\IconColor::PINK`: + +* `danog\MadelineProto\EventHandler\Topic\IconColor::RED`: + +## Properties +* `$name`: `string` +* `$value`: `int` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Typing.md b/docs/PHP/danog/MadelineProto/EventHandler/Typing.md new file mode 100644 index 0000000000..b02918d455 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Typing.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Typing: A user is typing." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Typing` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +A user is typing. + + + +## Properties +* `$userId`: `int` The peer that is typing. +* `$action`: `danog\MadelineProto\EventHandler\Action` Whether the user is typing, sending a media or doing something else. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.md b/docs/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.md new file mode 100644 index 0000000000..b9c713c897 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Typing\\ChatUserTyping: The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Typing\ChatUserTyping` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + + + +## Properties +* `$chatId`: `int` Group ID. +* `$userId`: `int` The peer that is typing. +* `$action`: `danog\MadelineProto\EventHandler\Action` Whether the user is typing, sending a media or doing something else. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.md b/docs/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.md new file mode 100644 index 0000000000..974fc3322d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Typing\\SecretUserTyping: The user is preparing a message in a secret chat; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Typing\SecretUserTyping` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +The user is preparing a message in a secret chat; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + + + +## Properties +* `$chatId`: `int` Secret chat ID. +* `$userId`: `int` The peer that is typing. +* `$action`: `danog\MadelineProto\EventHandler\Action` Whether the user is typing, sending a media or doing something else. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.md b/docs/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.md new file mode 100644 index 0000000000..3fdbfdbd4d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.md @@ -0,0 +1,24 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Typing\\SupergroupUserTyping: A user is typing in a [supergroup](https://core.telegram.org/api/channel)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Typing\SupergroupUserTyping` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A user is typing in a [supergroup](https://core.telegram.org/api/channel). + + + +## Properties +* `$chatId`: `int` Channel ID. +* `$topicId`: `?int` [Topic](https://core.telegram.org/api/threads) ID. +* `$userId`: `int` The peer that is typing. +* `$action`: `danog\MadelineProto\EventHandler\Action` Whether the user is typing, sending a media or doing something else. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.md b/docs/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.md new file mode 100644 index 0000000000..9588ee894a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Typing\\UserTyping: The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Typing\UserTyping` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + + + +## Properties +* `$userId`: `int` The peer that is typing. +* `$action`: `danog\MadelineProto\EventHandler\Action` Whether the user is typing, sending a media or doing something else. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Update.md b/docs/PHP/danog/MadelineProto/EventHandler/Update.md new file mode 100644 index 0000000000..add974108c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Update.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Update: Represents a generic update." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Update` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a generic update. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Blocked.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Blocked.md new file mode 100644 index 0000000000..95644b5db4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Blocked.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Blocked: A peer was blocked." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Blocked` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A peer was blocked. + + + +## Properties +* `$blocked`: `bool` Whether blocked or unblocked. +* `$stories`: `bool` Whether we hid or unhid stories of this user +* `$userId`: `int` The user ID +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/BotStopped.md b/docs/PHP/danog/MadelineProto/EventHandler/User/BotStopped.md new file mode 100644 index 0000000000..62aef0e1b0 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/BotStopped.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\BotStopped: A bot was stopped or re-started." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\BotStopped` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A bot was stopped or re-started. + + + +## Properties +* `$date`: `int` When did this action occur +* `$stopped`: `bool` Whether the bot was stopped or started. +* `$userId`: `int` The user ID +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Phone.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Phone.md new file mode 100644 index 0000000000..39d35a1d10 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Phone.md @@ -0,0 +1,22 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Phone: A user’s phone number was changed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Phone` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +A user’s phone number was changed. + + + +## Properties +* `$userId`: `int` User ID +* `$number`: `string` New phone number. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status.md new file mode 100644 index 0000000000..7aaa0309ab --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status.md @@ -0,0 +1,43 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status: Contains a status update." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Contains a status update. + + + +## Properties +* `$userId`: `int` User identifier + +## Method list: +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.md new file mode 100644 index 0000000000..4bea686e77 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.md @@ -0,0 +1,63 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\Emoji: The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed or was removed." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\Emoji` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed or was removed. + + + +## Properties +* `$emojiId`: `?int` [Custom emoji document ID](https://core.telegram.org/api/custom-emoji) +* `$until`: `?int` This status is valid until this date +* `$userId`: `int` User identifier + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rawEmojiStatus)`](#__construct) +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rawEmojiStatus)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rawEmojiStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.md new file mode 100644 index 0000000000..216b450e8f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.md @@ -0,0 +1,43 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\EmptyStatus: User status has not been set yet." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\EmptyStatus` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +User status has not been set yet. + + + +## Properties +* `$userId`: `int` User identifier + +## Method list: +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.md new file mode 100644 index 0000000000..1402cfbdd1 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.md @@ -0,0 +1,43 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\LastMonth: Online status: last seen last month." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\LastMonth` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Online status: last seen last month. + + + +## Properties +* `$userId`: `int` User identifier + +## Method list: +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.md new file mode 100644 index 0000000000..ef5250b3f2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.md @@ -0,0 +1,43 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\LastWeek: Online status: last seen last week." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\LastWeek` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Online status: last seen last week. + + + +## Properties +* `$userId`: `int` User identifier + +## Method list: +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.md new file mode 100644 index 0000000000..babeb3d497 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.md @@ -0,0 +1,62 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\Offline: The user’s offline status." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\Offline` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +The user’s offline status. + + + +## Properties +* `$wasOnline`: `int` Time the user was last seen online +* `$userId`: `int` User identifier + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rowUserStatus)`](#__construct) +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rowUserStatus)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Online.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Online.md new file mode 100644 index 0000000000..20bf0bfcb5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Online.md @@ -0,0 +1,62 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\Online: Online status of the user." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\Online` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Online status of the user. + + + +## Properties +* `$expires`: `int` Time to expiration of the current online status +* `$userId`: `int` User identifier + +## Method list: +* [`__construct(\danog\MadelineProto\MTProto $API, array $rowUserStatus)`](#__construct) +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `__construct(\danog\MadelineProto\MTProto $API, array $rowUserStatus)` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.md new file mode 100644 index 0000000000..a8425adb67 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.md @@ -0,0 +1,43 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Status\\Recently: Online status: last seen recently." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Status\Recently` +[Back to index](../../../../../index.html) + +> Author: Daniil Gentili + + +Online status: last seen recently. + + + +## Properties +* `$userId`: `int` User identifier + +## Method list: +* [`fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status`](#fromRawStatus) + +## Methods: +### `fromRawStatus(\danog\MadelineProto\MTProto $API, array $rowUserStatus): ?\danog\MadelineProto\EventHandler\User\Status` + + + + +Parameters: + +* `$API`: `\danog\MadelineProto\MTProto` +* `$rowUserStatus`: `array` + + +#### See also: +* `\danog\MadelineProto\MTProto` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/Username.md b/docs/PHP/danog/MadelineProto/EventHandler/User/Username.md new file mode 100644 index 0000000000..a403543166 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/Username.md @@ -0,0 +1,24 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\Username: Changes were made to the user’s first name, last name or username." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\Username` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Changes were made to the user’s first name, last name or username. + + + +## Properties +* `$userId`: `int` User identifier +* `$firstName`: `string` New first name. Corresponds to the new value of `real_first_name` field of the [userFull](https://docs.madelineproto.xyz/API_docs/constructors/userFull.html) constructor. +* `$lastName`: `string` New last name. Corresponds to the new value of `real_last_name` field of the [userFull](https://docs.madelineproto.xyz/API_docs/constructors/userFull.html) constructor. +* `$usernames`: `list` +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/User/UsernameInfo.md b/docs/PHP/danog/MadelineProto/EventHandler/User/UsernameInfo.md new file mode 100644 index 0000000000..dad2ceb5b3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/User/UsernameInfo.md @@ -0,0 +1,23 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\User\\UsernameInfo: Represents an username." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\User\UsernameInfo` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents an username. + + + +## Properties +* `$bought`: `bool` Whether the username is bought, meaning it was bought on [fragment](https://fragment.com). +* `$active`: `bool` Whether the username is active. +* `$username`: `string` The username. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Wallpaper.md b/docs/PHP/danog/MadelineProto/EventHandler/Wallpaper.md new file mode 100644 index 0000000000..2661158af6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Wallpaper.md @@ -0,0 +1,29 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Wallpaper: Represents a [wallpaper](https://core.telegram.org/api/wallpapers)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Wallpaper` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a [wallpaper](https://core.telegram.org/api/wallpapers). + + + +## Properties +* `$id`: `int` Identifier +* `$accessHash`: `int` Access hash +* `$creator`: `bool` Whether we created this wallpaper +* `$default`: `bool` Whether this is the default wallpaper +* `$pattern`: `bool` Whether this is a [pattern wallpaper](https://core.telegram.org/api/wallpapers#pattern-wallpapers) +* `$dark`: `bool` Whether this wallpaper should be used in dark mode. +* `$uniqueId`: `string` Unique wallpaper ID, used when generating [wallpaper links](https://core.telegram.org/api/links#wallpaper-links) or [importing wallpaper links](https://core.telegram.org/api/wallpapers). +* `$media`: `danog\MadelineProto\EventHandler\Media\DocumentPhoto` The actual wallpaper +* `$settings`: `?danog\MadelineProto\EventHandler\Wallpaper\WallpaperSettings` Info on how to generate the wallpaper, according to [these instructions](https://core.telegram.org/api/wallpapers). +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandler/Wallpaper/WallpaperSettings.md b/docs/PHP/danog/MadelineProto/EventHandler/Wallpaper/WallpaperSettings.md new file mode 100644 index 0000000000..398f9a8803 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandler/Wallpaper/WallpaperSettings.md @@ -0,0 +1,28 @@ +--- +title: "danog\\MadelineProto\\EventHandler\\Wallpaper\\WallpaperSettings: Info on how to generate a wallpaper, according to [these instructions »](https://core.telegram.org/api/wallpapers)." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandler\Wallpaper\WallpaperSettings` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Info on how to generate a wallpaper, according to [these instructions »](https://core.telegram.org/api/wallpapers). + + + +## Properties +* `$blur`: `bool` For [image wallpapers](https://core.telegram.org/api/wallpapers#image-wallpapers): if set, the JPEG must be downscaled to fit in 450x450 square and then box-blurred with radius 12. +* `$motion`: `bool` If set, the background needs to be slightly moved when the device is rotated. +* `$backgroundColor`: `?int` Used for [solid](https://core.telegram.org/api/wallpapers#solid-fill), [gradient](https://core.telegram.org/api/wallpapers#gradient-fill) and [freeform gradient](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills. +* `$secondBackgroundColor`: `?int` Used for [gradient](https://core.telegram.org/api/wallpapers#gradient-fill) and [freeform gradient](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills. +* `$thirdBackgroundColor`: `?int` Used for [freeform gradient](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills. +* `$fourthBackgroundColor`: `?int` Used for [freeform gradient](https://core.telegram.org/api/wallpapers#freeform-gradient-fill) fills. +* `$intensity`: `int` Used for [pattern wallpapers](https://core.telegram.org/api/wallpapers#pattern-wallpapers). +* `$rotation`: `int` Clockwise rotation angle of the gradient, in degrees; 0-359. Should be always divisible by 45. +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/EventHandlerIssue.md b/docs/PHP/danog/MadelineProto/EventHandlerIssue.md new file mode 100644 index 0000000000..8fdbabdf02 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/EventHandlerIssue.md @@ -0,0 +1,64 @@ +--- +title: "danog\\MadelineProto\\EventHandlerIssue: Represents an event handler issue." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\EventHandlerIssue` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Represents an event handler issue. + + + +## Properties +* `$message`: `string` Issue message +* `$file`: `string` Issue file +* `$line`: `int` Issue line +* `$severe`: `bool` Whether the issue is severe enough to block inclusion + +## Method list: +* [`__construct(string $message, string $file, int $line, bool $severe)`](#__construct) +* [`log(): void`](#log) +* [`getHTML(): string`](#getHTML) +* [`throw(): void`](#throw) + +## Methods: +### `__construct(string $message, string $file, int $line, bool $severe)` + + + + +Parameters: + +* `$message`: `string` +* `$file`: `string` +* `$line`: `int` +* `$severe`: `bool` + + + +### `log(): void` + + + + + +### `getHTML(): string` + + + + + +### `throw(): void` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Exception.md b/docs/PHP/danog/MadelineProto/Exception.md new file mode 100644 index 0000000000..ce1c3a48a0 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Exception.md @@ -0,0 +1,156 @@ +--- +title: "danog\\MadelineProto\\Exception: Basic exception." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Exception` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Basic exception. + + + +## Properties +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct(mixed $message = NULL, mixed $code = 0, ?Throwable $previous = NULL, mixed $file = NULL, mixed $line = NULL)`](#__construct) +* [`extension(string $extensionName): self`](#extension) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct(mixed $message = NULL, mixed $code = 0, ?Throwable $previous = NULL, mixed $file = NULL, mixed $line = NULL)` + + + + +Parameters: + +* `$message`: `mixed` +* `$code`: `mixed` +* `$previous`: `?Throwable` +* `$file`: `mixed` +* `$line`: `mixed` + + +#### See also: +* `Throwable` + + + + +### `extension(string $extensionName): self` + +Complain about missing extensions. + + +Parameters: + +* `$extensionName`: `string` Extension name + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/FileCallback.md b/docs/PHP/danog/MadelineProto/FileCallback.md new file mode 100644 index 0000000000..02bdabb37d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/FileCallback.md @@ -0,0 +1,58 @@ +--- +title: "danog\\MadelineProto\\FileCallback: File callback interface." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\FileCallback` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +File callback interface. + + + +## Properties +* `$callback`: `callable` Callback. + +(float, float, float) +* `$file`: `mixed` + +## Method list: +* [`__construct(TT $file, callable $callback)`](#__construct) +* [`getFile(): TT`](#getFile) + +## Methods: +### `__construct(TT $file, callable $callback)` + +Construct file callback. + + +Parameters: + +* `$file`: `TT` File to download/upload +* `$callback`: `callable` + + +#### See also: +* `TT` + + + + +### `getFile(): TT` + +Get file. + + +#### See also: +* `TT` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/FileCallbackInterface.md b/docs/PHP/danog/MadelineProto/FileCallbackInterface.md new file mode 100644 index 0000000000..03d13fff72 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/FileCallbackInterface.md @@ -0,0 +1,30 @@ +--- +title: "danog\\MadelineProto\\FileCallbackInterface: File callback interface." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\FileCallbackInterface` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +File callback interface. + + + + +## Method list: +* [`getFile(): T`](#getFile) + +## Methods: +### `getFile(): T` + +Get file. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/LocalFile.md b/docs/PHP/danog/MadelineProto/LocalFile.md new file mode 100644 index 0000000000..9587aa47eb --- /dev/null +++ b/docs/PHP/danog/MadelineProto/LocalFile.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\LocalFile: Indicates a local file to upload." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\LocalFile` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates a local file to upload. + + + +## Properties +* `$file`: `string` + +## Method list: +* [`__construct(string $file)`](#__construct) + +## Methods: +### `__construct(string $file)` + + + + +Parameters: + +* `$file`: `string` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Logger.md b/docs/PHP/danog/MadelineProto/Logger.md new file mode 100644 index 0000000000..85baf3c07b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Logger.md @@ -0,0 +1,156 @@ +--- +title: "danog\\MadelineProto\\Logger: Logger class." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Logger` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Logger class. + + + + +## Constants +* `danog\MadelineProto\Logger::FOREGROUND`: + +* `danog\MadelineProto\Logger::BACKGROUND`: + +* `danog\MadelineProto\Logger::SET`: + +* `danog\MadelineProto\Logger::RESET`: + +* `danog\MadelineProto\Logger::ULTRA_VERBOSE`: Ultra verbose logging. + +* `danog\MadelineProto\Logger::VERBOSE`: Verbose logging. + +* `danog\MadelineProto\Logger::NOTICE`: Notice logging. + +* `danog\MadelineProto\Logger::WARNING`: Warning logging. + +* `danog\MadelineProto\Logger::ERROR`: Error logging. + +* `danog\MadelineProto\Logger::FATAL_ERROR`: Log only fatal errors. + +* `danog\MadelineProto\Logger::DEFAULT_LOGGER`: Default logger (syslog). + +* `danog\MadelineProto\Logger::FILE_LOGGER`: File logger. + +* `danog\MadelineProto\Logger::ECHO_LOGGER`: Echo logger. + +* `danog\MadelineProto\Logger::CALLABLE_LOGGER`: Callable logger. + +* `danog\MadelineProto\Logger::LEVEL_ULTRA_VERBOSE`: Ultra verbose level. + +* `danog\MadelineProto\Logger::LEVEL_VERBOSE`: Verbose level. + +* `danog\MadelineProto\Logger::LEVEL_NOTICE`: Notice level. + +* `danog\MadelineProto\Logger::LEVEL_WARNING`: Warning level. + +* `danog\MadelineProto\Logger::LEVEL_ERROR`: Error level. + +* `danog\MadelineProto\Logger::LEVEL_FATAL`: Fatal error level. + +* `danog\MadelineProto\Logger::LOGGER_DEFAULT`: Default logger (syslog). + +* `danog\MadelineProto\Logger::LOGGER_ECHO`: Echo logger. + +* `danog\MadelineProto\Logger::LOGGER_FILE`: File logger. + +* `danog\MadelineProto\Logger::LOGGER_CALLABLE`: Callable logger. + +## Properties +* `$default`: `?self` Default logger instance. + +## Method list: +* [`constructorFromSettings(\danog\MadelineProto\Settings\Logger $settings): self`](#constructorFromSettings) +* [`__construct(\danog\MadelineProto\Settings\Logger $settings, string $prefix = '')`](#__construct) +* [`truncate(): void`](#truncate) +* [`log(mixed $param, int $level = \self::NOTICE): void`](#log) +* [`logger(mixed $param, int $level = \self::NOTICE, string $file = ''): void`](#logger) +* [`getPsrLogger(): \Psr\Log\LoggerInterface`](#getPsrLogger) + +## Methods: +### `constructorFromSettings(\danog\MadelineProto\Settings\Logger $settings): self` + +Construct global static logger from MadelineProto settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\Settings\Logger` Settings instance + + +#### See also: +* [`\danog\MadelineProto\Settings\Logger`: Logger settings.](../../danog/MadelineProto/Settings/Logger.html) + + + + +### `__construct(\danog\MadelineProto\Settings\Logger $settings, string $prefix = '')` + +Construct logger. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\Settings\Logger` +* `$prefix`: `string` + + +#### See also: +* [`\danog\MadelineProto\Settings\Logger`: Logger settings.](../../danog/MadelineProto/Settings/Logger.html) + + + + +### `truncate(): void` + +Truncate logfile. + + + +### `log(mixed $param, int $level = \self::NOTICE): void` + +Log a message. + + +Parameters: + +* `$param`: `mixed` Message +* `$level`: `int` Logging level + + + +### `logger(mixed $param, int $level = \self::NOTICE, string $file = ''): void` + +Log a message. + + +Parameters: + +* `$param`: `mixed` Message to log +* `$level`: `int` Logging level +* `$file`: `string` File that originated the message + + + +### `getPsrLogger(): \Psr\Log\LoggerInterface` + +Get PSR logger. + + +#### See also: +* `\Psr\Log\LoggerInterface` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/MTProtoTools/DialogId.md b/docs/PHP/danog/MadelineProto/MTProtoTools/DialogId.md new file mode 100644 index 0000000000..51a676df4b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/MTProtoTools/DialogId.md @@ -0,0 +1,104 @@ +--- +title: "danog\\MadelineProto\\MTProtoTools\\DialogId: Represents the type of a bot API dialog ID." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\MTProtoTools\DialogId` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents the type of a bot API dialog ID. + + + + +## Constants +* `danog\MadelineProto\MTProtoTools\DialogId::USER`: + +* `danog\MadelineProto\MTProtoTools\DialogId::CHAT`: + +* `danog\MadelineProto\MTProtoTools\DialogId::CHANNEL_OR_SUPERGROUP`: + +* `danog\MadelineProto\MTProtoTools\DialogId::SECRET_CHAT`: + +## Properties +* `$name`: `string` + +## Method list: +* [`getType(integer $id): self`](#getType) +* [`isSupergroupOrChannel(int $id): bool`](#isSupergroupOrChannel) +* [`isChat(int $id): bool`](#isChat) +* [`isUser(int $id): bool`](#isUser) +* [`isSecretChat(int $id): bool`](#isSecretChat) +* [`cases(): array`](#cases) + +## Methods: +### `getType(integer $id): self` + +Get the type of a dialog using just its bot API dialog ID. + +For more detailed types, use API::getType, instead. + + +Parameters: + +* `$id`: `integer` Bot API ID. + + + +### `isSupergroupOrChannel(int $id): bool` + +Checks whether the provided bot API ID is a supergroup or channel ID. + + +Parameters: + +* `$id`: `int` + + + +### `isChat(int $id): bool` + +Checks whether the provided bot API ID is a chat ID. + + +Parameters: + +* `$id`: `int` + + + +### `isUser(int $id): bool` + +Checks whether the provided bot API ID is a user ID. + + +Parameters: + +* `$id`: `int` + + + +### `isSecretChat(int $id): bool` + +Checks whether the provided bot API ID is a secret chat ID. + + +Parameters: + +* `$id`: `int` + + + +### `cases(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/MyTelegramOrgWrapper.md b/docs/PHP/danog/MadelineProto/MyTelegramOrgWrapper.md new file mode 100644 index 0000000000..40d71853f5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/MyTelegramOrgWrapper.md @@ -0,0 +1,97 @@ +--- +title: "danog\\MadelineProto\\MyTelegramOrgWrapper: Wrapper for my.telegram.org." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\MyTelegramOrgWrapper` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Wrapper for my.telegram.org. + + + + +## Method list: +* [`__construct(\danog\MadelineProto\SettingsAbstract $settings)`](#__construct) +* [`login(string $number): void`](#login) +* [`completeLogin(string $password)`](#completeLogin) +* [`loggedIn(): bool`](#loggedIn) +* [`hasApp()`](#hasApp) +* [`getApp()`](#getApp) +* [`createApp(array $settings)`](#createApp) + +## Methods: +### `__construct(\danog\MadelineProto\SettingsAbstract $settings)` + +Constructor. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `login(string $number): void` + +Login. + + +Parameters: + +* `$number`: `string` Phone number + + + +### `completeLogin(string $password)` + +Complete login. + + +Parameters: + +* `$password`: `string` Password + + + +### `loggedIn(): bool` + +Whether we are logged in. + + + +### `hasApp()` + +Check if an app was already created. + + + +### `getApp()` + +Get the currently created app. + + + +### `createApp(array $settings)` + +Create an app. + + +Parameters: + +* `$settings`: `array` App parameters + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Ogg.md b/docs/PHP/danog/MadelineProto/Ogg.md new file mode 100644 index 0000000000..547747ba60 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Ogg.md @@ -0,0 +1,151 @@ +--- +title: "danog\\MadelineProto\\Ogg: Async OGG stream reader and writer." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Ogg` +[Back to index](../../index.html) + +> Author: Daniil Gentili +> Author: Charles-Édouard Coste + + +Async OGG stream reader and writer. + + + + +## Constants +* `danog\MadelineProto\Ogg::CONTINUATION`: + +* `danog\MadelineProto\Ogg::BOS`: + +* `danog\MadelineProto\Ogg::EOS`: + +* `danog\MadelineProto\Ogg::STATE_READ_HEADER`: + +* `danog\MadelineProto\Ogg::STATE_READ_COMMENT`: + +* `danog\MadelineProto\Ogg::STATE_STREAMING`: + +* `danog\MadelineProto\Ogg::STATE_END`: + +## Properties +* `$opusPackets`: `iterable` Opus packet iterator. +* `$vendorString`: `string` +* `$comments`: `list` + +## Method list: +* [`__construct(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL)`](#__construct) +* [`validate(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file, ?\Amp\Cancellation $cancellation = NULL): void`](#validate) +* [`convert((\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream) $in, (\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream) $oggOut, ?\Amp\Cancellation $cancellation = NULL): void`](#convert) +* [`validateOgg(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $f): void`](#validateOgg) +* [`convertWav((\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream) $wavIn, (\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream) $oggOut, ?\Amp\Cancellation $cancellation = NULL): void`](#convertWav) + +## Methods: +### `__construct(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL)` + +Constructor. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `validate(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file, ?\Amp\Cancellation $cancellation = NULL): void` + +Validate that the specified file, URL or stream is a valid VoIP OGG OPUS file. + + +Parameters: + +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `convert((\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream) $in, (\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream) $oggOut, ?\Amp\Cancellation $cancellation = NULL): void` + +Converts a file, URL, or stream of any format (including video) into an OGG audio stream suitable for consumption by MadelineProto's VoIP implementation. + + +Parameters: + +* `$in`: `(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream)` The input file, URL or stream. +* `$oggOut`: `(\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream)` The output file or stream. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +### `validateOgg(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $f): void` + +Validate that the specified OGG OPUS file can be played directly by MadelineProto, without doing any conversion. + + +Parameters: + +* `$f`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `convertWav((\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream) $wavIn, (\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream) $oggOut, ?\Amp\Cancellation $cancellation = NULL): void` + +Converts a file, URL, or stream in WAV format @ 48khz into an OGG audio stream suitable for consumption by MadelineProto's VoIP implementation. + + +Parameters: + +* `$wavIn`: `(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream)` The input file, URL or stream. +* `$oggOut`: `(\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream)` The output file or stream. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/OggWriter.md b/docs/PHP/danog/MadelineProto/OggWriter.md new file mode 100644 index 0000000000..c677730c89 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/OggWriter.md @@ -0,0 +1,71 @@ +--- +title: "danog\\MadelineProto\\OggWriter: Async OGG stream writer." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\OggWriter` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Async OGG stream writer. + + + +## Properties +* `$streamId`: `int` + +## Method list: +* [`__construct(\Amp\ByteStream\WritableStream $out, ?int $streamId = NULL)`](#__construct) +* [`writeHeader(int $channels, int $sampleRate, string $opusVersion): void`](#writeHeader) +* [`writeChunk(string $chunk, int $granuleDiff, bool $eos): void`](#writeChunk) + +## Methods: +### `__construct(\Amp\ByteStream\WritableStream $out, ?int $streamId = NULL)` + +Write an ogg OPUS file. + + +Parameters: + +* `$out`: `\Amp\ByteStream\WritableStream` +* `$streamId`: `?int` + + +#### See also: +* `\Amp\ByteStream\WritableStream` + + + + +### `writeHeader(int $channels, int $sampleRate, string $opusVersion): void` + + + + +Parameters: + +* `$channels`: `int` +* `$sampleRate`: `int` +* `$opusVersion`: `string` + + + +### `writeChunk(string $chunk, int $granuleDiff, bool $eos): void` + + + + +Parameters: + +* `$chunk`: `string` +* `$granuleDiff`: `int` +* `$eos`: `bool` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/PTSException.md b/docs/PHP/danog/MadelineProto/PTSException.md new file mode 100644 index 0000000000..bafea80bab --- /dev/null +++ b/docs/PHP/danog/MadelineProto/PTSException.md @@ -0,0 +1,136 @@ +--- +title: "danog\\MadelineProto\\PTSException: Internal error indicating a problem with Telegram's servers." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\PTSException` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Internal error indicating a problem with Telegram's servers. + + + +## Properties +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct(mixed $message, mixed $file = '')`](#__construct) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct(mixed $message, mixed $file = '')` + + + + +Parameters: + +* `$message`: `mixed` +* `$file`: `mixed` + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/ParseMode.md b/docs/PHP/danog/MadelineProto/ParseMode.md new file mode 100644 index 0000000000..951cfc1ea8 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/ParseMode.md @@ -0,0 +1,65 @@ +--- +title: "danog\\MadelineProto\\ParseMode: Indicates a parsing mode for text." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\ParseMode` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates a parsing mode for text. + + + + +## Constants +* `danog\MadelineProto\ParseMode::HTML`: + +* `danog\MadelineProto\ParseMode::MARKDOWN`: + +* `danog\MadelineProto\ParseMode::TEXT`: + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/PeerNotInDbException.md b/docs/PHP/danog/MadelineProto/PeerNotInDbException.md new file mode 100644 index 0000000000..dc3a29ec8d --- /dev/null +++ b/docs/PHP/danog/MadelineProto/PeerNotInDbException.md @@ -0,0 +1,144 @@ +--- +title: "danog\\MadelineProto\\PeerNotInDbException: Indicates that a specified peer (user, chat, channel) was not found in the internal MadelineProto peer database." +description: "\nThis can usually be fixed by enabling `setFullFetch(true)` in the [peer database settings](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Peer.html#setfullfetch-bool-fullfetch-self).\n" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\PeerNotInDbException` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates that a specified peer (user, chat, channel) was not found in the internal MadelineProto peer database. + + +This can usually be fixed by enabling `setFullFetch(true)` in the [peer database settings](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Peer.html#setfullfetch-bool-fullfetch-self). + + +## Properties +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct()`](#__construct) +* [`extension(string $extensionName): self`](#extension) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct()` + + + + + +### `extension(string $extensionName): self` + +Complain about missing extensions. + + +Parameters: + +* `$extensionName`: `string` Extension name + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/PluginEventHandler.md b/docs/PHP/danog/MadelineProto/PluginEventHandler.md new file mode 100644 index 0000000000..f7f1fb54f9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/PluginEventHandler.md @@ -0,0 +1,3317 @@ +--- +title: "danog\\MadelineProto\\PluginEventHandler: Plugin event handler class." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\PluginEventHandler` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Plugin event handler class. + + + +## Properties +* `$auth`: `\danog\MadelineProto\Namespace\Auth` +* `$account`: `\danog\MadelineProto\Namespace\Account` +* `$users`: `\danog\MadelineProto\Namespace\Users` +* `$contacts`: `\danog\MadelineProto\Namespace\Contacts` +* `$messages`: `\danog\MadelineProto\Namespace\Messages` +* `$updates`: `\danog\MadelineProto\Namespace\Updates` +* `$photos`: `\danog\MadelineProto\Namespace\Photos` +* `$upload`: `\danog\MadelineProto\Namespace\Upload` +* `$help`: `\danog\MadelineProto\Namespace\Help` +* `$channels`: `\danog\MadelineProto\Namespace\Channels` +* `$bots`: `\danog\MadelineProto\Namespace\Bots` +* `$payments`: `\danog\MadelineProto\Namespace\Payments` +* `$stickers`: `\danog\MadelineProto\Namespace\Stickers` +* `$phone`: `\danog\MadelineProto\Namespace\Phone` +* `$langpack`: `\danog\MadelineProto\Namespace\Langpack` +* `$folders`: `\danog\MadelineProto\Namespace\Folders` +* `$stats`: `\danog\MadelineProto\Namespace\Stats` +* `$chatlists`: `\danog\MadelineProto\Namespace\Chatlists` +* `$stories`: `\danog\MadelineProto\Namespace\Stories` +* `$premium`: `\danog\MadelineProto\Namespace\Premium` +* `$smsjobs`: `\danog\MadelineProto\Namespace\Smsjobs` +* `$fragment`: `\danog\MadelineProto\Namespace\Fragment` + +## Method list: +* [`getPluginPaths(): array|string|null`](#getPluginPaths) +* [`isPluginEnabled(): bool`](#isPluginEnabled) +* [`startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoop) +* [`startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoopBot) +* [`getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop`](#getPeriodicLoop) +* [`getPeriodicLoops(): array`](#getPeriodicLoops) +* [`getReportPeers(): (string|int|array<(string|int)>)`](#getReportPeers) +* [`getPlugins(): array>`](#getPlugins) +* [`MTProtoToBotAPI(array $data): array`](#MTProtoToBotAPI) +* [`MTProtoToTd(mixed $params): array`](#MTProtoToTd) +* [`MTProtoToTdcli(mixed $params): array`](#MTProtoToTdcli) +* [`acceptCall(int $id): void`](#acceptCall) +* [`acceptSecretChat(array $params): void`](#acceptSecretChat) +* [`arr(mixed ...$params): array`](#arr) +* [`base64urlDecode(string $data): string`](#base64urlDecode) +* [`base64urlEncode(string $data): string`](#base64urlEncode) +* [`botAPIToMTProto(array $arguments): array`](#botAPIToMTProto) +* [`botLogin(string $token): ?array`](#botLogin) +* [`broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int`](#broadcastCustom) +* [`broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastForwardMessages) +* [`broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastMessages) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null`](#callGetCurrent) +* [`callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void`](#callPlay) +* [`callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void`](#callPlayOnHold) +* [`callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void`](#callSetOutput) +* [`canConvertOgg(): bool`](#canConvertOgg) +* [`canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool`](#canUseFFmpeg) +* [`cancelBroadcast(integer $id): void`](#cancelBroadcast) +* [`closeConnection(string $message): void`](#closeConnection) +* [`complete2faLogin(string $password): array`](#complete2faLogin) +* [`completePhoneLogin(string $code): array`](#completePhoneLogin) +* [`completeSignup(string $first_name, string $last_name = ''): array`](#completeSignup) +* [`discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void`](#discardCall) +* [`discardSecretChat(int $chat): void`](#discardSecretChat) +* [`downloadServer(string $session): void`](#downloadServer) +* [`downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToBrowser) +* [`downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToCallable) +* [`downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToDir) +* [`downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToFile) +* [`downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response`](#downloadToResponse) +* [`downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#downloadToReturnedStream) +* [`downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToStream) +* [`echo(string $string): void`](#echo) +* [`end(array $what): T`](#end) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`exportAuthorization(): array{0: (int|string), 1: string}`](#exportAuthorization) +* [`extractBotAPIFile(array $info): ?array`](#extractBotAPIFile) +* [`extractMessage(array $updates): array`](#extractMessage) +* [`extractMessageId(array $updates): int`](#extractMessageId) +* [`extractMessageUpdate(array $updates): array`](#extractMessageUpdate) +* [`extractUpdates(array $updates): array`](#extractUpdates) +* [`fileGetContents(string $url): string`](#fileGetContents) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`fullChatLastUpdated(mixed $id): int`](#fullChatLastUpdated) +* [`fullGetSelf(): array|false`](#fullGetSelf) +* [`genVectorHash(array $longs): string`](#genVectorHash) +* [`getAdminIds(): array`](#getAdminIds) +* [`getAllCalls(): array`](#getAllCalls) +* [`getAllMethods(): array`](#getAllMethods) +* [`getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)`](#getAuthorization) +* [`getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress`](#getBroadcastProgress) +* [`getCachedConfig(): array`](#getCachedConfig) +* [`getCall(int $id): ?\danog\MadelineProto\VoIP`](#getCall) +* [`getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP`](#getCallByPeer) +* [`getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState`](#getCallState) +* [`getCdnConfig(): void`](#getCdnConfig) +* [`getConfig(array $config = []): array`](#getConfig) +* [`getDNSClient(): \Amp\Dns\DnsResolver`](#getDNSClient) +* [`getDhConfig(): array`](#getDhConfig) +* [`getDialogIds(): list`](#getDialogIds) +* [`getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}`](#getDownloadInfo) +* [`getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string`](#getDownloadLink) +* [`getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)`](#getEventHandler) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getFileInfo(mixed $constructor): array`](#getFileInfo) +* [`getFullDialogs(): array`](#getFullDialogs) +* [`getFullInfo(mixed $id): array`](#getFullInfo) +* [`getHTTPClient(): \Amp\Http\Client\HttpClient`](#getHTTPClient) +* [`getHint(): string`](#getHint) +* [`getId(mixed $id): int`](#getId) +* [`getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))`](#getInfo) +* [`getLogger(): \danog\MadelineProto\Logger`](#getLogger) +* [`getMaps(): ?int`](#getMaps) +* [`getMaxMaps(): ?int`](#getMaxMaps) +* [`getMethodNamespaces(): array`](#getMethodNamespaces) +* [`getMethodsNamespaced(): array`](#getMethodsNamespaced) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null`](#getPlugin) +* [`getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo`](#getPropicInfo) +* [`getPsrLogger(): \Psr\Log\LoggerInterface`](#getPsrLogger) +* [`getPwrChat(mixed $id, bool $fullfetch = true): array`](#getPwrChat) +* [`getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat`](#getSecretChat) +* [`getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage`](#getSecretMessage) +* [`getSelf(): array|false`](#getSelf) +* [`getSessionName(): string`](#getSessionName) +* [`getSettings(): \danog\MadelineProto\Settings`](#getSettings) +* [`getSponsoredMessages((int|string|array) $peer): ?array`](#getSponsoredMessages) +* [`getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`getStreamPipe(): \Amp\ByteStream\Pipe`](#getStreamPipe) +* [`getTL(): \danog\MadelineProto\TL\TLInterface`](#getTL) +* [`getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*`](#getType) +* [`getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list`](#getUpdates) +* [`getWebMessage(string $message): string`](#getWebMessage) +* [`getWebWarnings(): string`](#getWebWarnings) +* [`hasAdmins(): bool`](#hasAdmins) +* [`hasEventHandler(): bool`](#hasEventHandler) +* [`hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool`](#hasPlugin) +* [`hasReportPeers(): bool`](#hasReportPeers) +* [`hasSecretChat((array|int) $chat): bool`](#hasSecretChat) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`importAuthorization(array $authorization, int $mainDcID): array`](#importAuthorization) +* [`inflateStripped(string $stripped): string`](#inflateStripped) +* [`initSelfRestart(): void`](#initSelfRestart) +* [`isAltervista(): bool`](#isAltervista) +* [`isArrayOrAlike(mixed $var): bool`](#isArrayOrAlike) +* [`isBot(mixed $peer): bool`](#isBot) +* [`isForum(mixed $peer): bool`](#isForum) +* [`isIpc(): bool`](#isIpc) +* [`isIpcWorker(): bool`](#isIpcWorker) +* [`isPlayPaused(int $id): bool`](#isPlayPaused) +* [`isPremium(): bool`](#isPremium) +* [`isSelfBot(): bool`](#isSelfBot) +* [`isSelfUser(): bool`](#isSelfUser) +* [`isTestMode(): boolean`](#isTestMode) +* [`logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void`](#logger) +* [`logout(): void`](#logout) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string`](#openBuffered) +* [`openFileAppendOnly(string $path): \Amp\File\File`](#openFileAppendOnly) +* [`packDouble(float $value): string`](#packDouble) +* [`packSignedInt(integer $value): string`](#packSignedInt) +* [`packSignedLong(int $value): string`](#packSignedLong) +* [`packUnsignedInt(int $value): string`](#packUnsignedInt) +* [`pausePlay(int $id): void`](#pausePlay) +* [`peerIsset(mixed $id): bool`](#peerIsset) +* [`phoneLogin(string $number, integer $sms_type = 5): array`](#phoneLogin) +* [`posmod(int $a, int $b): int`](#posmod) +* [`processDownloadServerPing(string $path, string $payload): void`](#processDownloadServerPing) +* [`qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode`](#qrLogin) +* [`random(integer $length): string`](#random) +* [`randomInt(integer $modulus = 0): int`](#randomInt) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`refreshFullPeerCache(mixed $id): void`](#refreshFullPeerCache) +* [`refreshPeerCache(mixed ...$ids): void`](#refreshPeerCache) +* [`report(string $message, string $parseMode = ''): void`](#report) +* [`reportMemoryProfile(): void`](#reportMemoryProfile) +* [`requestCall(mixed $user): \danog\MadelineProto\VoIP`](#requestCall) +* [`requestSecretChat(mixed $user): int`](#requestSecretChat) +* [`resetUpdateState(): void`](#resetUpdateState) +* [`restart(): void`](#restart) +* [`resumePlay(int $id): void`](#resumePlay) +* [`rethrow(Throwable $e): void`](#rethrow) +* [`rleDecode(string $string): string`](#rleDecode) +* [`rleEncode(string $string): string`](#rleEncode) +* [`sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendAudio) +* [`sendCustomEvent(mixed $payload): void`](#sendCustomEvent) +* [`sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocument) +* [`sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocumentPhoto) +* [`sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendGif) +* [`sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendMessage) +* [`sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>`](#sendMessageToAdmins) +* [`sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendPhoto) +* [`sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendSticker) +* [`sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVideo) +* [`sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVoice) +* [`setNoop(): void`](#setNoop) +* [`setReportPeers((int|string|array<(int|string)>) $userOrId): void`](#setReportPeers) +* [`setWebhook(string $webhookUrl): void`](#setWebhook) +* [`skipPlay(int $id): void`](#skipPlay) +* [`sleep(float $time): void`](#sleep) +* [`start(): array`](#start) +* [`stop(): void`](#stop) +* [`stopPlay(int $id): void`](#stopPlay) +* [`stringToStream(string $str): \Amp\ByteStream\ReadableBuffer`](#stringToStream) +* [`subscribeToUpdates(mixed $channel): bool`](#subscribeToUpdates) +* [`tdToMTProto(array $params): array`](#tdToMTProto) +* [`tdToTdcli(mixed $params): array`](#tdToTdcli) +* [`tdcliToTd(mixed $params, array $key = NULL): array`](#tdcliToTd) +* [`testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}`](#testFibers) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`unpackDouble(string $value): float`](#unpackDouble) +* [`unpackFileId(string $fileId): array`](#unpackFileId) +* [`unpackSignedInt(string $value): int`](#unpackSignedInt) +* [`unpackSignedLong(string $value): int`](#unpackSignedLong) +* [`unpackSignedLongString((string|int|array) $value): string`](#unpackSignedLongString) +* [`unsetEventHandler(): void`](#unsetEventHandler) +* [`update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void`](#update2fa) +* [`updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void`](#updateSettings) +* [`upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#upload) +* [`uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadEncrypted) +* [`uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromCallable) +* [`uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromStream) +* [`uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromTgfile) +* [`uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromUrl) +* [`validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>`](#validateEventHandlerClass) +* [`viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool`](#viewSponsoredMessage) +* [`wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media`](#wrapMedia) +* [`wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage`](#wrapMessage) +* [`wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned`](#wrapPin) +* [`wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update`](#wrapUpdate) +* [`initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void`](#initDbProperties) +* [`saveDbProperties(): void`](#saveDbProperties) + +## Methods: +### `getPluginPaths(): array|string|null` + +Plugins can require other plugins ONLY with the getPlugins() method. + + + +### `isPluginEnabled(): bool` + +Whether the plugin is enabled. + + + +### `startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto as a bot and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$token`: `string` Bot token +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop` + +Obtain a PeriodicLoop instance created by the Cron attribute. + + +Parameters: + +* `$name`: `string` Method name + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getPeriodicLoops(): array` + +Obtain all PeriodicLoop instances created by the Cron attribute. + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getReportPeers(): (string|int|array<(string|int)>)` + +Get peers where to send error reports. + + + +### `getPlugins(): array>` + +Obtain a list of plugin event handlers to use, in addition with those found by getPluginPath. + + + +### `MTProtoToBotAPI(array $data): array` + +Convert MTProto parameters to bot API parameters. + + +Parameters: + +* `$data`: `array` Data + + + +### `MTProtoToTd(mixed $params): array` + +MTProto to TD params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `MTProtoToTdcli(mixed $params): array` + +MTProto to TDCLI params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `acceptCall(int $id): void` + +Accept call. + + +Parameters: + +* `$id`: `int` + + + +### `acceptSecretChat(array $params): void` + +Accept secret chat. + + +Parameters: + +* `$params`: `array` Secret chat ID + + + +### `arr(mixed ...$params): array` + +Create array. + + +Parameters: + +* `...$params`: `mixed` Params + + + +### `base64urlDecode(string $data): string` + +base64URL decode. + + +Parameters: + +* `$data`: `string` Data to decode + + + +### `base64urlEncode(string $data): string` + +Base64URL encode. + + +Parameters: + +* `$data`: `string` Data to encode + + + +### `botAPIToMTProto(array $arguments): array` + +Convert bot API parameters to MTProto parameters. + + +Parameters: + +* `$arguments`: `array` Arguments + + + +### `botLogin(string $token): ?array` + +Login as bot. + + +Parameters: + +* `$token`: `string` Bot token + + + +### `broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int` + +Executes a custom broadcast action with all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$action`: `\danog\MadelineProto\Broadcast\Action` A custom, serializable Action class that will be called once for every peer. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Action`: Interface that represents a broadcast action.](../../danog/MadelineProto/Broadcast/Action.html) +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Forwards a list of messages to all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$from_peer`: `mixed` Bot API ID or Update, from where to forward the messages. +* `$message_ids`: `list` IDs of the messages to forward. +* `$drop_author`: `bool` If true, will forward messages without quoting the original author. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Sends a list of messages to all peers (users, chats, channels) of the bot. + +A simplified version of this method is also available: broadcastForwardMessages can work with pre-prepared messages. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$messages`: `array` The messages to send: an array of arrays, containing parameters to pass to messages.sendMessage. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null` + +Get the file that is currently being played. + +Will return a string with the object ID of the stream if we're currently playing a stream, otherwise returns the related LocalFile or RemoteUrl. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) + + + + +### `callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void` + +Play file in call. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void` + +Play files on hold in call. + + +Parameters: + +* `$id`: `int` +* `...$files`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void` + +Set output file or stream for incoming OPUS audio packets in a call. + +Will write an OGG OPUS stream to the specified file or stream. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* `\Amp\ByteStream\WritableStream` + + + + +### `canConvertOgg(): bool` + +Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot. + + + +### `canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool` + +Whether we can convert any audio/video file using ffmpeg. + + +Parameters: + +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `cancelBroadcast(integer $id): void` + +Cancel a running broadcast. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + + +### `closeConnection(string $message): void` + +Close connection with client, connected via web. + + +Parameters: + +* `$message`: `string` Message + + + +### `complete2faLogin(string $password): array` + +Complete 2FA login. + + +Parameters: + +* `$password`: `string` Password + + + +### `completePhoneLogin(string $code): array` + +Complet user login using login code. + + +Parameters: + +* `$code`: `string` Login code + + + +### `completeSignup(string $first_name, string $last_name = ''): array` + +Complete signup to Telegram. + + +Parameters: + +* `$first_name`: `string` First name +* `$last_name`: `string` Last name + + + +### `discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void` + +Discard call. + + +Parameters: + +* `$id`: `int` +* `$reason`: `\danog\MadelineProto\VoIP\DiscardReason` +* `$rating`: `int<1, 5>` Call rating in stars +* `$comment`: `string` Additional comment on call quality. + + +#### See also: +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `discardSecretChat(int $chat): void` + +Discard secret chat. + + +Parameters: + +* `$chat`: `int` Secret chat ID + + + +### `downloadServer(string $session): void` + +Downloads a file to the browser using the specified session file. + + +Parameters: + +* `$session`: `string` + + + +### `downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to browser. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$cb`: `(null|callable)` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Cancellation` + + + + +### `downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to callable. +The callable must accept two parameters: string $payload, int $offset +The callable will be called (possibly out of order, depending on the value of $seekable). + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$callable`: `(callable|\danog\MadelineProto\FileCallbackInterface)` Chunk callback +* `$cb`: `callable` Status callback +* `$seekable`: `bool` Whether the callable can be called out of order +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to stop downloading (inclusive) +* `$part_size`: `int` Size of each chunk +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file to directory. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$dir`: `(string|\danog\MadelineProto\FileCallbackInterface)` Directory where to download the file +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$file`: `(string|\danog\MadelineProto\FileCallbackInterface)` Downloaded file path +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response` + +Download file to amphp/http-server response. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$request`: `\Amp\Http\Server\Request` Request +* `$cb`: `callable` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Http\Server\Request` +* `\Amp\Cancellation` +* `\Amp\Http\Server\Response` + + + + +### `downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Download file to an amphp stream, returning it. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to stream. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$stream`: `(mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream)` Stream where to download file +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `resource` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `end(array $what): T` + +Get final element of array. + + +Parameters: + +* `$what`: `array` Array + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `exportAuthorization(): array{0: (int|string), 1: string}` + +Export authorization. + + + +### `extractBotAPIFile(array $info): ?array` + +Extract file info from bot API message. + + +Parameters: + +* `$info`: `array` Bot API message object + + + +### `extractMessage(array $updates): array` + +Extract a message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageId(array $updates): int` + +Extract a message ID from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageUpdate(array $updates): array` + +Extract an update message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractUpdates(array $updates): array` + +Extract Update constructors from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `fileGetContents(string $url): string` + +Get contents of remote file asynchronously. + + +Parameters: + +* `$url`: `string` URL + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `fullChatLastUpdated(mixed $id): int` + +When was full info for this chat last cached. + + +Parameters: + +* `$id`: `mixed` Chat ID + + + +### `fullGetSelf(): array|false` + +Get info about the logged-in user, not cached. + + + +### `genVectorHash(array $longs): string` + +Generate MTProto vector hash. + +Returns a vector hash. + + +Parameters: + +* `$longs`: `array` IDs + + + +### `getAdminIds(): array` + +Get admin IDs (equal to all user report peers). + + + +### `getAllCalls(): array` + +Get all pending and running calls, indexed by user ID. + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getAllMethods(): array` + +Get full list of MTProto and API methods. + + + +### `getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)` + +Get authorization info. + + +#### See also: +* `\danog\MadelineProto\API::NOT_LOGGED_IN` +* `\danog\MadelineProto\API::WAITING_CODE` +* `\danog\MadelineProto\API::WAITING_SIGNUP` +* `\danog\MadelineProto\API::WAITING_PASSWORD` +* `\danog\MadelineProto\API::LOGGED_IN` +* `API::LOGGED_OUT` + + + + +### `getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress` + +Get the progress of a currently running broadcast. + +Will return null if the broadcast doesn't exist, has already completed or was cancelled. + +Use updateBroadcastProgress updates to get real-time progress status without polling. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Progress`: Broadcast progress.](../../danog/MadelineProto/Broadcast/Progress.html) + + + + +### `getCachedConfig(): array` + +Get cached server-side config. + + + +### `getCall(int $id): ?\danog\MadelineProto\VoIP` + +Get phone call information. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP` + +Get the phone call with the specified user ID. + + +Parameters: + +* `$userId`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState` + +Get call state. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [\danog\MadelineProto\VoIP\CallState](../../danog/MadelineProto/VoIP/CallState.html) + + + + +### `getCdnConfig(): void` + +Store RSA keys for CDN datacenters. + + + +### `getConfig(array $config = []): array` + +Get cached (or eventually re-fetch) server-side config. + + +Parameters: + +* `$config`: `array` Current config + + + +### `getDNSClient(): \Amp\Dns\DnsResolver` + +Get async DNS client. + + +#### See also: +* `\Amp\Dns\DnsResolver` + + + + +### `getDhConfig(): array` + +Get diffie-hellman configuration. + + + +### `getDialogIds(): list` + +Get dialog IDs. + + + +### `getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}` + +Get download info of file +Returns an array with the following structure:. + +`$info['ext']` - The file extension +`$info['name']` - The file name, without the extension +`$info['mime']` - The file mime type +`$info['size']` - The file size + + +Parameters: + +* `$messageMedia`: `mixed` File ID + + + +### `getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string` + +Get download link of media file. + + +Parameters: + +* `$media`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string` +* `$scriptUrl`: `?string` +* `$size`: `?int` +* `$name`: `?string` +* `$mime`: `?string` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)` + +Get event handler (or plugin instance). + + +Parameters: + +* `$class`: `(class-string|null)` + + +#### See also: +* `\danog\MadelineProto\Ipc\EventHandlerProxy` +* `\__PHP_Incomplete_Class` + + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getFileInfo(mixed $constructor): array` + +Get info about file. + + +Parameters: + +* `$constructor`: `mixed` File ID + + + +### `getFullDialogs(): array` + +Get full info of all dialogs. + +Bots should use getDialogIds, instead. + + + +### `getFullInfo(mixed $id): array` + +Get full info about peer, returns an FullInfo object. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* [https://docs.madelineproto.xyz/FullInfo.html](https://docs.madelineproto.xyz/FullInfo.html) + + + + +### `getHTTPClient(): \Amp\Http\Client\HttpClient` + +Get async HTTP client. + + +#### See also: +* `\Amp\Http\Client\HttpClient` + + + + +### `getHint(): string` + +Get current password hint. + + + +### `getId(mixed $id): int` + +Get the bot API ID of a peer. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))` + +Get info about peer, returns an Info object. + +If passed a secret chat ID, returns information about the user, not about the secret chat. +Use getSecretChat to return information about the secret chat. + + +Parameters: + +* `$id`: `mixed` Peer +* `$type`: `\danog\MadelineProto\API::INFO_TYPE_*` Whether to generate an Input*, an InputPeer or the full set of constructors + + +#### See also: +* [https://docs.madelineproto.xyz/Info.html](https://docs.madelineproto.xyz/Info.html) +* `\danog\MadelineProto\API::INFO_TYPE_*` + + + + +### `getLogger(): \danog\MadelineProto\Logger` + +Get logger. + + +#### See also: +* [`\danog\MadelineProto\Logger`: Logger class.](../../danog/MadelineProto/Logger.html) + + + + +### `getMaps(): ?int` + +Get current number of memory-mapped regions, UNIX only. + + + +### `getMaxMaps(): ?int` + +Get maximum number of memory-mapped regions, UNIX only. +Use testFibers to get the maximum number of fibers on any platform. + + + +### `getMethodNamespaces(): array` + +Get TL namespaces. + + + +### `getMethodsNamespaced(): array` + +Get namespaced methods (method => namespace). + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null` + +Obtain a certain event handler plugin instance. + + +Parameters: + +* `$class`: `class-string` + +return T|null + + +#### See also: +* [`\danog\MadelineProto\PluginEventHandler`: Plugin event handler class.](../../danog/MadelineProto/PluginEventHandler.html) +* `\danog\MadelineProto\Ipc\EventHandlerProxy` + + + + +### `getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo` + +Gets info of the propic of a user. + + +Parameters: + +* `$data`: `mixed` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `getPsrLogger(): \Psr\Log\LoggerInterface` + +Get PSR logger. + + +#### See also: +* `\Psr\Log\LoggerInterface` + + + + +### `getPwrChat(mixed $id, bool $fullfetch = true): array` + +Get full info about peer (including full list of channel members), returns a Chat object. + + +Parameters: + +* `$id`: `mixed` Peer +* `$fullfetch`: `bool` + + +#### See also: +* [https://docs.madelineproto.xyz/Chat.html](https://docs.madelineproto.xyz/Chat.html) + + + + +### `getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat` + +Get secret chat. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + +#### See also: +* [`\danog\MadelineProto\SecretChats\SecretChat`: Represents a secret chat.](../../danog/MadelineProto/SecretChats/SecretChat.html) + + + + +### `getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage` + +Gets a secret chat message. + + +Parameters: + +* `$chatId`: `integer` Secret chat ID. +* `$randomId`: `integer` Secret chat message ID. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\SecretMessage`: Represents New encrypted message.](../../danog/MadelineProto/EventHandler/Message/SecretMessage.html) + + + + +### `getSelf(): array|false` + +Get info about the logged-in user, cached. + +Use fullGetSelf to bypass the cache. + + + +### `getSessionName(): string` + +Returns the session name. + + + +### `getSettings(): \danog\MadelineProto\Settings` + +Return current settings. + + +#### See also: +* [`\danog\MadelineProto\Settings`: Settings class used for configuring MadelineProto.](../../danog/MadelineProto/Settings.html) + + + + +### `getSponsoredMessages((int|string|array) $peer): ?array` + +Get sponsored messages for channel. +This method will return an array of [sponsored message objects](https://docs.madelineproto.xyz/API_docs/constructors/sponsoredMessage.html). + +See [the API documentation](https://core.telegram.org/api/sponsored-messages) for more info on how to handle sponsored messages. + + +Parameters: + +* `$peer`: `(int|string|array)` Channel ID, or Update, or Message, or Peer. + + + +### `getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream` + +Provide a stream for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` +* `$size`: `?int` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `getStreamPipe(): \Amp\ByteStream\Pipe` + +Obtains a pipe that can be used to upload a file from a stream. + + +#### See also: +* `\Amp\ByteStream\Pipe` + + + + +### `getTL(): \danog\MadelineProto\TL\TLInterface` + +Get TL serializer. + + +#### See also: +* [\danog\MadelineProto\TL\TLInterface](../../danog/MadelineProto/TL/TLInterface.html) + + + + +### `getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*` + +Get type of peer. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* `\danog\MadelineProto\API::PEER_TYPE_*` + + + + +### `getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list` + +Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**. + +`getUpdates` will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + + +Parameters: + +* `$params`: `array{offset?: int, limit?: int, timeout?: float}` Params + + + +### `getWebMessage(string $message): string` + +Get a message to show to the user when starting the bot. + + +Parameters: + +* `$message`: `string` + + + +### `getWebWarnings(): string` + +Get various warnings to show to the user in the web UI. + + + +### `hasAdmins(): bool` + +Check if has admins. + + + +### `hasEventHandler(): bool` + +Check if an event handler instance is present. + + + +### `hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool` + +Check if a certain event handler plugin is installed. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) + + + + +### `hasReportPeers(): bool` + +Check if has report peers. + + + +### `hasSecretChat((array|int) $chat): bool` + +Check whether secret chat exists. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `importAuthorization(array $authorization, int $mainDcID): array` + +Import authorization. + + +Parameters: + +* `$authorization`: `array` Authorization info +* `$mainDcID`: `int` Main DC ID + + + +### `inflateStripped(string $stripped): string` + +Inflate stripped photosize to full JPG payload. + + +Parameters: + +* `$stripped`: `string` Stripped photosize + + + +### `initSelfRestart(): void` + +Initialize self-restart hack. + + + +### `isAltervista(): bool` + +Whether this is altervista. + + + +### `isArrayOrAlike(mixed $var): bool` + +Check if is array or similar (traversable && countable && arrayAccess). + + +Parameters: + +* `$var`: `mixed` Value to check + + + +### `isBot(mixed $peer): bool` + +Check if the specified peer is a bot. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isForum(mixed $peer): bool` + +Check if the specified peer is a forum. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isIpc(): bool` + +Whether we're an IPC client instance. + + + +### `isIpcWorker(): bool` + +Whether we're an IPC server process (as opposed to an event handler). + + + +### `isPlayPaused(int $id): bool` + +Whether the currently playing audio file is paused. + + +Parameters: + +* `$id`: `int` + + + +### `isPremium(): bool` + +Returns whether the current user is a premium user, cached. + + + +### `isSelfBot(): bool` + +Returns whether the current user is a bot. + + + +### `isSelfUser(): bool` + +Returns whether the current user is a user. + + + +### `isTestMode(): boolean` + +Whether we're currently connected to the test DCs. + + + +### `logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void` + +Logger. + + +Parameters: + +* `$param`: `mixed` Parameter +* `$level`: `int` Logging level +* `$file`: `string` File where the message originated + + + +### `logout(): void` + +Logout the session. + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string` + +Provide a buffered reader for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `openFileAppendOnly(string $path): \Amp\File\File` + +Opens a file in append-only mode. + + +Parameters: + +* `$path`: `string` File path. + + +#### See also: +* `\Amp\File\File` + + + + +### `packDouble(float $value): string` + +Convert double to binary version. + + +Parameters: + +* `$value`: `float` Value to convert + + + +### `packSignedInt(integer $value): string` + +Convert integer to base256 signed int. + + +Parameters: + +* `$value`: `integer` Value to convert + + + +### `packSignedLong(int $value): string` + +Convert integer to base256 long. + + +Parameters: + +* `$value`: `int` Value to convert + + + +### `packUnsignedInt(int $value): string` + +Convert value to unsigned base256 int. + + +Parameters: + +* `$value`: `int` Value + + + +### `pausePlay(int $id): void` + +Pauses playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `peerIsset(mixed $id): bool` + +Check if peer is present in internal peer database. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `phoneLogin(string $number, integer $sms_type = 5): array` + +Login as user. + + +Parameters: + +* `$number`: `string` Phone number +* `$sms_type`: `integer` SMS type + + + +### `posmod(int $a, int $b): int` + +Positive modulo +Works just like the % (modulus) operator, only returns always a postive number. + + +Parameters: + +* `$a`: `int` A +* `$b`: `int` B + + + +### `processDownloadServerPing(string $path, string $payload): void` + +Internal endpoint used by the download server. + + +Parameters: + +* `$path`: `string` +* `$payload`: `string` + + + +### `qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode` + +Initiates QR code login. + +Returns a QR code login helper object, that can be used to render the QR code, display the link directly, wait for login, QR code expiration and much more. + +Returns null if we're already logged in, or if we're waiting for a password (use getAuthorization to distinguish between the two cases). + + +#### See also: +* [`\danog\MadelineProto\TL\Types\LoginQrCode`: Represents a login QR code.](../../danog/MadelineProto/TL/Types/LoginQrCode.html) + + + + +### `random(integer $length): string` + +Get secure random string of specified length. + + +Parameters: + +* `$length`: `integer` Length + + + +### `randomInt(integer $modulus = 0): int` + +Get random integer. + + +Parameters: + +* `$modulus`: `integer` Modulus + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `refreshFullPeerCache(mixed $id): void` + +Refresh full peer cache for a certain peer. + + +Parameters: + +* `$id`: `mixed` The peer to refresh + + + +### `refreshPeerCache(mixed ...$ids): void` + +Refresh peer cache for a certain peer. + + +Parameters: + +* `...$ids`: `mixed` + + + +### `report(string $message, string $parseMode = ''): void` + +Report an error to the previously set peer. + + +Parameters: + +* `$message`: `string` Error to report +* `$parseMode`: `string` Parse mode + + + +### `reportMemoryProfile(): void` + +Report memory profile with memprof. + + + +### `requestCall(mixed $user): \danog\MadelineProto\VoIP` + +Request VoIP call. + + +Parameters: + +* `$user`: `mixed` User + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `requestSecretChat(mixed $user): int` + +Request secret chat. + + +Parameters: + +* `$user`: `mixed` User to start secret chat with + + + +### `resetUpdateState(): void` + +Reset the update state and fetch all updates from the beginning. + + + +### `restart(): void` + +Restart update loop. + + + +### `resumePlay(int $id): void` + +Resumes playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `rethrow(Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `Throwable` + + +#### See also: +* `Throwable` + + + + +### `rleDecode(string $string): string` + +null-byte RLE decode. + + +Parameters: + +* `$string`: `string` Data to decode + + + +### `rleEncode(string $string): string` + +null-byte RLE encode. + + +Parameters: + +* `$string`: `string` Data to encode + + + +### `sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendCustomEvent(mixed $payload): void` + +Sends an updateCustomEvent update to the event handler. + + +Parameters: + +* `$payload`: `mixed` + + + +### `sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$duration`: `?int` +* `$width`: `?int` +* `$height`: `?int` +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a message. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` Cancellation + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>` + +Sends a message to all report peers (admins of the bot). + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$stickerSet`: `array` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `setNoop(): void` + +Set NOOP update handler, ignoring all updates. + + + +### `setReportPeers((int|string|array<(int|string)>) $userOrId): void` + +Set peer(s) where to send errors occurred in the event loop. + + +Parameters: + +* `$userOrId`: `(int|string|array<(int|string)>)` Username(s) or peer ID(s) + + + +### `setWebhook(string $webhookUrl): void` + +Set webhook update handler. + + +Parameters: + +* `$webhookUrl`: `string` Webhook URL + + + +### `skipPlay(int $id): void` + +When called, skips to the next file in the playlist. + + +Parameters: + +* `$id`: `int` + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `start(): array` + +Log in to telegram (via CLI or web). + + + +### `stop(): void` + +Stop update loop. + + + +### `stopPlay(int $id): void` + +Stops playing all files in the call, clears the main and the hold playlist. + + +Parameters: + +* `$id`: `int` + + + +### `stringToStream(string $str): \Amp\ByteStream\ReadableBuffer` + +Converts a string into an async amphp stream. + + +Parameters: + +* `$str`: `string` + + +#### See also: +* `\Amp\ByteStream\ReadableBuffer` + + + + +### `subscribeToUpdates(mixed $channel): bool` + +Subscribe to event handler updates for a channel/supergroup we're not a member of. + + +Parameters: + +* `$channel`: `mixed` Channel/supergroup to subscribe to + + +Return value: False if we were already subscribed + + +### `tdToMTProto(array $params): array` + +Convert TD to MTProto parameters. + + +Parameters: + +* `$params`: `array` Parameters + + + +### `tdToTdcli(mixed $params): array` + +Convert TD parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Parameters + + + +### `tdcliToTd(mixed $params, array $key = NULL): array` + +Convert tdcli parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Params +* `$key`: `array` Key + + + +### `testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}` + +Test fibers. + + +Parameters: + +* `$fiberCount`: `int` + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `unpackDouble(string $value): float` + +Unpack binary double. + + +Parameters: + +* `$value`: `string` Value to unpack + + + +### `unpackFileId(string $fileId): array` + +Unpack bot API file ID. + + +Parameters: + +* `$fileId`: `string` Bot API file ID + + +Return value: Unpacked file ID + + +### `unpackSignedInt(string $value): int` + +Unpack base256 signed int. + + +Parameters: + +* `$value`: `string` base256 int + + + +### `unpackSignedLong(string $value): int` + +Unpack base256 signed long. + + +Parameters: + +* `$value`: `string` base256 long + + + +### `unpackSignedLongString((string|int|array) $value): string` + +Unpack base256 signed long to string. + + +Parameters: + +* `$value`: `(string|int|array)` base256 long + + + +### `unsetEventHandler(): void` + +Unset event handler. + + + +### `update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void` + +Update the 2FA password. + +The params array can contain password, new_password, email and hint params. + + +Parameters: + +* `$params`: `array{password?: string, new_password?: string, email?: string, hint?: string}` The params + + + +### `updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void` + +Parse, update and store settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file to secret chat. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from callable. + +The callable must accept two parameters: int $offset, int $size +The callable must return a string with the contest of the file at the specified offset and size. + + +Parameters: + +* `$callable`: `callable(int, int, ?Cancellation): strin)` Callable (offset, length) => data +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable(float, float, float): voi)` Status callback +* `$seekable`: `boolean` Whether chunks can be fetched out of order +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from stream. + + +Parameters: + +* `$stream`: `mixed` PHP resource or AMPHP async stream +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Reupload telegram file. + + +Parameters: + +* `$media`: `mixed` Telegram file +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from URL. + + +Parameters: + +* `$url`: `(string|\danog\MadelineProto\FileCallbackInterface)` URL of file +* `$size`: `integer` Size of file +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>` + +Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` Class name + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) +* [`\danog\MadelineProto\EventHandlerIssue`: Represents an event handler issue.](../../danog/MadelineProto/EventHandlerIssue.html) + + + + +### `viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool` + +Mark sponsored message as read. + + +Parameters: + +* `$peer`: `(int|array)` Channel ID, or Update, or Message, or Peer. +* `$message`: `(string|array{random_id: string})` Random ID or sponsored message to mark as read. + + + +### `wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media` + +Wrap a media constructor into an abstract Media object. + + +Parameters: + +* `$media`: `array` +* `$protected`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage` + +Wrap a Message constructor into an abstract Message object. + + +Parameters: + +* `$message`: `array` +* `$scheduled`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractMessage`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/AbstractMessage.html) + + + + +### `wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned` + +Wrap a Pin constructor into an abstract Pinned object. + + +Parameters: + +* `$message`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Pinned`: Indicates that some messages were pinned/unpinned.](../../danog/MadelineProto/EventHandler/Pinned.html) + + + + +### `wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update` + +Wrap an Update constructor into an abstract Update object. + + +Parameters: + +* `$update`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void` + +Initialize database properties. + + +Parameters: + +* `$settings`: `\danog\AsyncOrm\Settings` +* `$tablePrefix`: `string` + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `saveDbProperties(): void` + +Save all properties. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/PsrLogger.md b/docs/PHP/danog/MadelineProto/PsrLogger.md new file mode 100644 index 0000000000..b9b7b4d605 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/PsrLogger.md @@ -0,0 +1,209 @@ +--- +title: "danog\\MadelineProto\\PsrLogger: PSR-3 wrapper for MadelineProto's Logger." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\PsrLogger` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +PSR-3 wrapper for MadelineProto's Logger. + + + + +## Method list: +* [`__construct(\danog\MadelineProto\Logger $logger)`](#__construct) +* [`log(mixed $level, mixed $message, array $context = []): void`](#log) +* [`emergency((string|\Stringable) $message, array $context = []): void`](#emergency) +* [`alert((string|\Stringable) $message, array $context = []): void`](#alert) +* [`critical((string|\Stringable) $message, array $context = []): void`](#critical) +* [`error((string|\Stringable) $message, array $context = []): void`](#error) +* [`warning((string|\Stringable) $message, array $context = []): void`](#warning) +* [`notice((string|\Stringable) $message, array $context = []): void`](#notice) +* [`info((string|\Stringable) $message, array $context = []): void`](#info) +* [`debug((string|\Stringable) $message, array $context = []): void`](#debug) + +## Methods: +### `__construct(\danog\MadelineProto\Logger $logger)` + +Constructor. + + +Parameters: + +* `$logger`: `\danog\MadelineProto\Logger` + + +#### See also: +* [`\danog\MadelineProto\Logger`: Logger class.](../../danog/MadelineProto/Logger.html) + + + + +### `log(mixed $level, mixed $message, array $context = []): void` + +Logs with an arbitrary level. + + +Parameters: + +* `$level`: `mixed` +* `$message`: `mixed` +* `$context`: `array` + + + +### `emergency((string|\Stringable) $message, array $context = []): void` + +System is unusable. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `alert((string|\Stringable) $message, array $context = []): void` + +Action must be taken immediately. + +Example: Entire website down, database unavailable, etc. This should +trigger the SMS alerts and wake you up. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `critical((string|\Stringable) $message, array $context = []): void` + +Critical conditions. + +Example: Application component unavailable, unexpected exception. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `error((string|\Stringable) $message, array $context = []): void` + +Runtime errors that do not require immediate action but should typically +be logged and monitored. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `warning((string|\Stringable) $message, array $context = []): void` + +Exceptional occurrences that are not errors. + +Example: Use of deprecated APIs, poor use of an API, undesirable things +that are not necessarily wrong. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `notice((string|\Stringable) $message, array $context = []): void` + +Normal but significant events. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `info((string|\Stringable) $message, array $context = []): void` + +Interesting events. + +Example: User logs in, SQL logs. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +### `debug((string|\Stringable) $message, array $context = []): void` + +Detailed debug information. + + +Parameters: + +* `$message`: `(string|\Stringable)` +* `$context`: `array` + + +#### See also: +* `\Stringable` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/RPCError/FloodWaitError.md b/docs/PHP/danog/MadelineProto/RPCError/FloodWaitError.md new file mode 100644 index 0000000000..a17cd181e8 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/RPCError/FloodWaitError.md @@ -0,0 +1,191 @@ +--- +title: "danog\\MadelineProto\\RPCError\\FloodWaitError: Represents a FLOOD_WAIT_ RPC error returned by telegram." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\RPCError\FloodWaitError` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a FLOOD_WAIT_ RPC error returned by telegram. + + + +## Properties +* `$rpc`: `string` RPC error +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct(mixed $message = NULL, mixed $code = 0, mixed $caller = '', ?\Exception $previous = NULL)`](#__construct) +* [`getWaitTime(): int`](#getWaitTime) +* [`wait(): void`](#wait) +* [`localizeMessage(mixed $method, int $code, string $error): string`](#localizeMessage) +* [`getLocalization(): string`](#getLocalization) +* [`setLocalization(string $localization): void`](#setLocalization) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct(mixed $message = NULL, mixed $code = 0, mixed $caller = '', ?\Exception $previous = NULL)` + + + + +Parameters: + +* `$message`: `mixed` +* `$code`: `mixed` +* `$caller`: `mixed` +* `$previous`: `?\Exception` + + +#### See also: +* `\Exception` + + + + +### `getWaitTime(): int` + +Returns the required waiting period in seconds before repeating the RPC call. + + + +### `wait(): void` + +Waits for the required waiting period. + + + +### `localizeMessage(mixed $method, int $code, string $error): string` + + + + +Parameters: + +* `$method`: `mixed` +* `$code`: `int` +* `$error`: `string` + + + +### `getLocalization(): string` + +Get localized error name. + + + +### `setLocalization(string $localization): void` + +Set localized error name. + + +Parameters: + +* `$localization`: `string` + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/RPCErrorException.md b/docs/PHP/danog/MadelineProto/RPCErrorException.md new file mode 100644 index 0000000000..fdb443b744 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/RPCErrorException.md @@ -0,0 +1,177 @@ +--- +title: "danog\\MadelineProto\\RPCErrorException: Indicates an error returned by Telegram's API." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\RPCErrorException` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates an error returned by Telegram's API. + + + +## Properties +* `$rpc`: `string` RPC error +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`localizeMessage(mixed $method, int $code, string $error): string`](#localizeMessage) +* [`getLocalization(): string`](#getLocalization) +* [`setLocalization(string $localization): void`](#setLocalization) +* [`__construct(string $rpc, int $code = 0, mixed $caller = '', ?\danog\MadelineProto\Exception $previous = NULL)`](#__construct) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `localizeMessage(mixed $method, int $code, string $error): string` + + + + +Parameters: + +* `$method`: `mixed` +* `$code`: `int` +* `$error`: `string` + + + +### `getLocalization(): string` + +Get localized error name. + + + +### `setLocalization(string $localization): void` + +Set localized error name. + + +Parameters: + +* `$localization`: `string` + + + +### `__construct(string $rpc, int $code = 0, mixed $caller = '', ?\danog\MadelineProto\Exception $previous = NULL)` + + + + +Parameters: + +* `$rpc`: `string` +* `$code`: `int` +* `$caller`: `mixed` +* `$previous`: `?\danog\MadelineProto\Exception` + + +#### See also: +* [`\danog\MadelineProto\Exception`: Basic exception.](../../danog/MadelineProto/Exception.html) + + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/RemoteUrl.md b/docs/PHP/danog/MadelineProto/RemoteUrl.md new file mode 100644 index 0000000000..ca22756084 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/RemoteUrl.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\RemoteUrl: Indicates a remote URL to upload." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\RemoteUrl` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates a remote URL to upload. + + + +## Properties +* `$url`: `string` + +## Method list: +* [`__construct(string $url)`](#__construct) + +## Methods: +### `__construct(string $url)` + + + + +Parameters: + +* `$url`: `string` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/ResponseException.md b/docs/PHP/danog/MadelineProto/ResponseException.md new file mode 100644 index 0000000000..bfe6758c62 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/ResponseException.md @@ -0,0 +1,96 @@ +--- +title: "danog\\MadelineProto\\ResponseException: Indicates an error thrown when an unexpected response is received from telegram's servers." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\ResponseException` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates an error thrown when an unexpected response is received from telegram's servers. + + + + +## Method list: +* [`__construct(string $message = '', int $code = 0, ?Throwable $previous = NULL)`](#__construct) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) + +## Methods: +### `__construct(string $message = '', int $code = 0, ?Throwable $previous = NULL)` + + + + +Parameters: + +* `$message`: `string` +* `$code`: `int` +* `$previous`: `?Throwable` + + +#### See also: +* `Throwable` + + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/SecretChats/SecretChat.md b/docs/PHP/danog/MadelineProto/SecretChats/SecretChat.md new file mode 100644 index 0000000000..764da84817 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/SecretChats/SecretChat.md @@ -0,0 +1,45 @@ +--- +title: "danog\\MadelineProto\\SecretChats\\SecretChat: Represents a secret chat." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\SecretChats\SecretChat` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Represents a secret chat. + + + +## Properties +* `$created`: `int` Creation date +* `$chatId`: `int` Secret chat ID +* `$creator`: `bool` Whether we created this chat +* `$otherID`: `int` User ID of the other peer in the chat + +## Method list: +* [`getMessage(integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage`](#getMessage) + +## Methods: +### `getMessage(integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage` + +Gets a secret chat message. + + +Parameters: + +* `$randomId`: `integer` Secret chat message ID. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\SecretMessage`: Represents New encrypted message.](../../../danog/MadelineProto/EventHandler/Message/SecretMessage.html) + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/SecretPeerNotInDbException.md b/docs/PHP/danog/MadelineProto/SecretPeerNotInDbException.md new file mode 100644 index 0000000000..0ca9ccf468 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/SecretPeerNotInDbException.md @@ -0,0 +1,142 @@ +--- +title: "danog\\MadelineProto\\SecretPeerNotInDbException: Indicates that the specified secret chat wasn't found." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\SecretPeerNotInDbException` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates that the specified secret chat wasn't found. + + + +## Properties +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct()`](#__construct) +* [`extension(string $extensionName): self`](#extension) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct()` + + + + + +### `extension(string $extensionName): self` + +Complain about missing extensions. + + +Parameters: + +* `$extensionName`: `string` Extension name + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/SecurityException.md b/docs/PHP/danog/MadelineProto/SecurityException.md new file mode 100644 index 0000000000..f51d9befaa --- /dev/null +++ b/docs/PHP/danog/MadelineProto/SecurityException.md @@ -0,0 +1,96 @@ +--- +title: "danog\\MadelineProto\\SecurityException: Indicates a security error." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\SecurityException` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Indicates a security error. + + + + +## Method list: +* [`__construct(string $message = '', int $code = 0, ?Throwable $previous = NULL)`](#__construct) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) + +## Methods: +### `__construct(string $message = '', int $code = 0, ?Throwable $previous = NULL)` + + + + +Parameters: + +* `$message`: `string` +* `$code`: `int` +* `$previous`: `?Throwable` + + +#### See also: +* `Throwable` + + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings.md b/docs/PHP/danog/MadelineProto/Settings.md new file mode 100644 index 0000000000..748af7881a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings.md @@ -0,0 +1,465 @@ +--- +title: "danog\\MadelineProto\\Settings: Settings class used for configuring MadelineProto." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Settings class used for configuring MadelineProto. + + + + +## Method list: +* [`__construct()`](#__construct) +* [`merge(\danog\MadelineProto\SettingsAbstract $settings): void`](#merge) +* [`getAppInfo(): \danog\MadelineProto\Settings\AppInfo`](#getAppInfo) +* [`setAppInfo(\danog\MadelineProto\Settings\AppInfo $appInfo): self`](#setAppInfo) +* [`getAuth(): \danog\MadelineProto\Settings\Auth`](#getAuth) +* [`setAuth(\danog\MadelineProto\Settings\Auth $auth): self`](#setAuth) +* [`getConnection(): \danog\MadelineProto\Settings\Connection`](#getConnection) +* [`setConnection(\danog\MadelineProto\Settings\Connection $connection): self`](#setConnection) +* [`getFiles(): \danog\MadelineProto\Settings\Files`](#getFiles) +* [`setFiles(\danog\MadelineProto\Settings\Files $files): self`](#setFiles) +* [`getLogger(): \danog\MadelineProto\Settings\Logger`](#getLogger) +* [`setLogger(\danog\MadelineProto\Settings\Logger $logger): self`](#setLogger) +* [`getPeer(): \danog\MadelineProto\Settings\Peer`](#getPeer) +* [`setPeer(\danog\MadelineProto\Settings\Peer $peer): self`](#setPeer) +* [`getRpc(): \danog\MadelineProto\Settings\RPC`](#getRpc) +* [`setRpc(\danog\MadelineProto\Settings\RPC $rpc): self`](#setRpc) +* [`getSecretChats(): \danog\MadelineProto\Settings\SecretChats`](#getSecretChats) +* [`setSecretChats(\danog\MadelineProto\Settings\SecretChats $secretChats): self`](#setSecretChats) +* [`getSerialization(): \danog\MadelineProto\Settings\Serialization`](#getSerialization) +* [`setSerialization(\danog\MadelineProto\Settings\Serialization $serialization): self`](#setSerialization) +* [`getSchema(): \danog\MadelineProto\Settings\TLSchema`](#getSchema) +* [`setSchema(\danog\MadelineProto\Settings\TLSchema $schema): self`](#setSchema) +* [`getDb(): \danog\MadelineProto\Settings\DatabaseAbstract`](#getDb) +* [`setDb(\danog\MadelineProto\Settings\DatabaseAbstract $db): self`](#setDb) +* [`getIpc(): \danog\MadelineProto\Settings\Ipc`](#getIpc) +* [`setIpc(\danog\MadelineProto\Settings\Ipc $ipc): self`](#setIpc) +* [`applyChanges(): \danog\MadelineProto\SettingsAbstract`](#applyChanges) +* [`getTemplates(): \danog\MadelineProto\Settings\Templates`](#getTemplates) +* [`setTemplates(\danog\MadelineProto\Settings\Templates $templates): self`](#setTemplates) +* [`getVoip(): \danog\MadelineProto\Settings\VoIP`](#getVoip) +* [`setVoip(\danog\MadelineProto\Settings\VoIP $voip): self`](#setVoip) + +## Methods: +### `__construct()` + +Constructor. + + + +### `merge(\danog\MadelineProto\SettingsAbstract $settings): void` + +Merge another instance of settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `getAppInfo(): \danog\MadelineProto\Settings\AppInfo` + +Get app information. + + +#### See also: +* [`\danog\MadelineProto\Settings\AppInfo`: App information.](../../danog/MadelineProto/Settings/AppInfo.html) + + + + +### `setAppInfo(\danog\MadelineProto\Settings\AppInfo $appInfo): self` + +Set app information. + + +Parameters: + +* `$appInfo`: `\danog\MadelineProto\Settings\AppInfo` App information. + + +#### See also: +* [`\danog\MadelineProto\Settings\AppInfo`: App information.](../../danog/MadelineProto/Settings/AppInfo.html) + + + + +### `getAuth(): \danog\MadelineProto\Settings\Auth` + +Get cryptography settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Auth`: Cryptography settings.](../../danog/MadelineProto/Settings/Auth.html) + + + + +### `setAuth(\danog\MadelineProto\Settings\Auth $auth): self` + +Set cryptography settings. + + +Parameters: + +* `$auth`: `\danog\MadelineProto\Settings\Auth` Cryptography settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Auth`: Cryptography settings.](../../danog/MadelineProto/Settings/Auth.html) + + + + +### `getConnection(): \danog\MadelineProto\Settings\Connection` + +Get connection settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Connection`: Connection settings.](../../danog/MadelineProto/Settings/Connection.html) + + + + +### `setConnection(\danog\MadelineProto\Settings\Connection $connection): self` + +Set connection settings. + + +Parameters: + +* `$connection`: `\danog\MadelineProto\Settings\Connection` Connection settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Connection`: Connection settings.](../../danog/MadelineProto/Settings/Connection.html) + + + + +### `getFiles(): \danog\MadelineProto\Settings\Files` + +Get file management settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Files`: File management settings.](../../danog/MadelineProto/Settings/Files.html) + + + + +### `setFiles(\danog\MadelineProto\Settings\Files $files): self` + +Set file management settings. + + +Parameters: + +* `$files`: `\danog\MadelineProto\Settings\Files` File management settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Files`: File management settings.](../../danog/MadelineProto/Settings/Files.html) + + + + +### `getLogger(): \danog\MadelineProto\Settings\Logger` + +Get logger settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Logger`: Logger settings.](../../danog/MadelineProto/Settings/Logger.html) + + + + +### `setLogger(\danog\MadelineProto\Settings\Logger $logger): self` + +Set logger settings. + + +Parameters: + +* `$logger`: `\danog\MadelineProto\Settings\Logger` Logger settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Logger`: Logger settings.](../../danog/MadelineProto/Settings/Logger.html) + + + + +### `getPeer(): \danog\MadelineProto\Settings\Peer` + +Get peer database settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Peer`: Peer database settings.](../../danog/MadelineProto/Settings/Peer.html) + + + + +### `setPeer(\danog\MadelineProto\Settings\Peer $peer): self` + +Set peer database settings. + + +Parameters: + +* `$peer`: `\danog\MadelineProto\Settings\Peer` Peer database settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Peer`: Peer database settings.](../../danog/MadelineProto/Settings/Peer.html) + + + + +### `getRpc(): \danog\MadelineProto\Settings\RPC` + +Get RPC settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\RPC`: RPC settings.](../../danog/MadelineProto/Settings/RPC.html) + + + + +### `setRpc(\danog\MadelineProto\Settings\RPC $rpc): self` + +Set RPC settings. + + +Parameters: + +* `$rpc`: `\danog\MadelineProto\Settings\RPC` RPC settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\RPC`: RPC settings.](../../danog/MadelineProto/Settings/RPC.html) + + + + +### `getSecretChats(): \danog\MadelineProto\Settings\SecretChats` + +Get secret chat settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\SecretChats`: Secret chat settings.](../../danog/MadelineProto/Settings/SecretChats.html) + + + + +### `setSecretChats(\danog\MadelineProto\Settings\SecretChats $secretChats): self` + +Set secret chat settings. + + +Parameters: + +* `$secretChats`: `\danog\MadelineProto\Settings\SecretChats` Secret chat settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\SecretChats`: Secret chat settings.](../../danog/MadelineProto/Settings/SecretChats.html) + + + + +### `getSerialization(): \danog\MadelineProto\Settings\Serialization` + +Get serialization settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Serialization`: Serialization settings.](../../danog/MadelineProto/Settings/Serialization.html) + + + + +### `setSerialization(\danog\MadelineProto\Settings\Serialization $serialization): self` + +Set serialization settings. + + +Parameters: + +* `$serialization`: `\danog\MadelineProto\Settings\Serialization` Serialization settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Serialization`: Serialization settings.](../../danog/MadelineProto/Settings/Serialization.html) + + + + +### `getSchema(): \danog\MadelineProto\Settings\TLSchema` + +Get TL schema settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\TLSchema`: TL schema settings.](../../danog/MadelineProto/Settings/TLSchema.html) + + + + +### `setSchema(\danog\MadelineProto\Settings\TLSchema $schema): self` + +Set TL schema settings. + + +Parameters: + +* `$schema`: `\danog\MadelineProto\Settings\TLSchema` TL schema settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\TLSchema`: TL schema settings.](../../danog/MadelineProto/Settings/TLSchema.html) + + + + +### `getDb(): \danog\MadelineProto\Settings\DatabaseAbstract` + +Get database settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\DatabaseAbstract`: Base class for storage backends.](../../danog/MadelineProto/Settings/DatabaseAbstract.html) + + + + +### `setDb(\danog\MadelineProto\Settings\DatabaseAbstract $db): self` + +Set database settings. + + +Parameters: + +* `$db`: `\danog\MadelineProto\Settings\DatabaseAbstract` DatabaseAbstract settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\DatabaseAbstract`: Base class for storage backends.](../../danog/MadelineProto/Settings/DatabaseAbstract.html) + + + + +### `getIpc(): \danog\MadelineProto\Settings\Ipc` + +Get IPC server settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Ipc`: IPC server settings.](../../danog/MadelineProto/Settings/Ipc.html) + + + + +### `setIpc(\danog\MadelineProto\Settings\Ipc $ipc): self` + +Set IPC server settings. + + +Parameters: + +* `$ipc`: `\danog\MadelineProto\Settings\Ipc` IPC server settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Ipc`: IPC server settings.](../../danog/MadelineProto/Settings/Ipc.html) + + + + +### `applyChanges(): \danog\MadelineProto\SettingsAbstract` + + + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `getTemplates(): \danog\MadelineProto\Settings\Templates` + +Get template settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\Templates`: Web and CLI template settings for login.](../../danog/MadelineProto/Settings/Templates.html) + + + + +### `setTemplates(\danog\MadelineProto\Settings\Templates $templates): self` + +Set template settings. + + +Parameters: + +* `$templates`: `\danog\MadelineProto\Settings\Templates` Template settings + + +#### See also: +* [`\danog\MadelineProto\Settings\Templates`: Web and CLI template settings for login.](../../danog/MadelineProto/Settings/Templates.html) + + + + +### `getVoip(): \danog\MadelineProto\Settings\VoIP` + +Get voIP settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\VoIP`: VoIP settings.](../../danog/MadelineProto/Settings/VoIP.html) + + + + +### `setVoip(\danog\MadelineProto\Settings\VoIP $voip): self` + +Set voIP settings. + + +Parameters: + +* `$voip`: `\danog\MadelineProto\Settings\VoIP` VoIP settings. + + +#### See also: +* [`\danog\MadelineProto\Settings\VoIP`: VoIP settings.](../../danog/MadelineProto/Settings/VoIP.html) + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/AppInfo.md b/docs/PHP/danog/MadelineProto/Settings/AppInfo.md new file mode 100644 index 0000000000..fd6005982f --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/AppInfo.md @@ -0,0 +1,215 @@ +--- +title: "danog\\MadelineProto\\Settings\\AppInfo: App information." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\AppInfo` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +App information. + + + + +## Method list: +* [`__construct()`](#__construct) +* [`init(): void`](#init) +* [`hasApiInfo(): bool`](#hasApiInfo) +* [`getApiId(): int`](#getApiId) +* [`setApiId(int $apiId): self`](#setApiId) +* [`getApiHash(): string`](#getApiHash) +* [`setApiHash(string $apiHash): self`](#setApiHash) +* [`getDeviceModel(): string`](#getDeviceModel) +* [`setDeviceModel(string $deviceModel): self`](#setDeviceModel) +* [`getSystemVersion(): string`](#getSystemVersion) +* [`setSystemVersion(string $systemVersion): self`](#setSystemVersion) +* [`getAppVersion(): string`](#getAppVersion) +* [`setAppVersion(string $appVersion): self`](#setAppVersion) +* [`getLangCode(): string`](#getLangCode) +* [`setLangCode(string $langCode): self`](#setLangCode) +* [`getSystemLangCode(): string`](#getSystemLangCode) +* [`setSystemLangCode(string $langCode): self`](#setSystemLangCode) +* [`getLangPack(): string`](#getLangPack) +* [`setLangPack(string $langPack): self`](#setLangPack) +* [`getShowPrompt(): bool`](#getShowPrompt) +* [`setShowPrompt(bool $showPrompt): static`](#setShowPrompt) + +## Methods: +### `__construct()` + + + + + +### `init(): void` + + + + + +### `hasApiInfo(): bool` + +Check if the settings have API ID/hash information. + + + +### `getApiId(): int` + +Get API ID. + + + +### `setApiId(int $apiId): self` + +Set API ID. + + +Parameters: + +* `$apiId`: `int` API ID. + + + +### `getApiHash(): string` + +Get API hash. + + + +### `setApiHash(string $apiHash): self` + +Set API hash. + + +Parameters: + +* `$apiHash`: `string` API hash. + + + +### `getDeviceModel(): string` + +Get device model. + + + +### `setDeviceModel(string $deviceModel): self` + +Set device model. + + +Parameters: + +* `$deviceModel`: `string` Device model. + + + +### `getSystemVersion(): string` + +Get system version. + + + +### `setSystemVersion(string $systemVersion): self` + +Set system version. + + +Parameters: + +* `$systemVersion`: `string` System version. + + + +### `getAppVersion(): string` + +Get app version. + + + +### `setAppVersion(string $appVersion): self` + +Set app version. + + +Parameters: + +* `$appVersion`: `string` App version. + + + +### `getLangCode(): string` + +Get language code. + + + +### `setLangCode(string $langCode): self` + +Set language code. + + +Parameters: + +* `$langCode`: `string` Language code. + + + +### `getSystemLangCode(): string` + +Get system language code. + + + +### `setSystemLangCode(string $langCode): self` + +Set system language code. + + +Parameters: + +* `$langCode`: `string` Language code. + + + +### `getLangPack(): string` + +Get language pack. + + + +### `setLangPack(string $langPack): self` + +Set language pack. + + +Parameters: + +* `$langPack`: `string` Language pack. + + + +### `getShowPrompt(): bool` + +Get whether to show a prompt, asking to enter an API ID/API hash if none is provided. + + + +### `setShowPrompt(bool $showPrompt): static` + +Set whether to show a prompt, asking to enter an API ID/API hash if none is provided. + + +Parameters: + +* `$showPrompt`: `bool` Whether to show a prompt, asking to enter an API ID/API hash if none is provided. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Auth.md b/docs/PHP/danog/MadelineProto/Settings/Auth.md new file mode 100644 index 0000000000..f63452bad6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Auth.md @@ -0,0 +1,66 @@ +--- +title: "danog\\MadelineProto\\Settings\\Auth: Cryptography settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Auth` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Cryptography settings. + + + + +## Method list: +* [`getPfs(): bool`](#getPfs) +* [`setPfs(bool $pfs): self`](#setPfs) +* [`getMaxAuthTries(): int`](#getMaxAuthTries) +* [`setMaxAuthTries(int<1, max> $maxAuthTries): self`](#setMaxAuthTries) + +## Methods: +### `getPfs(): bool` + +Get whether to use PFS. + + + +### `setPfs(bool $pfs): self` + +Set whether to use PFS. + + +Parameters: + +* `$pfs`: `bool` Whether to use PFS + + + +### `getMaxAuthTries(): int` + +Get max tries for generating auth key. + + + +### `setMaxAuthTries(int<1, max> $maxAuthTries): self` + +Set max tries for generating auth key. + + +Parameters: + +* `$maxAuthTries`: `int<1, max>` Max tries for generating auth key + + +#### See also: +* `max` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Connection.md b/docs/PHP/danog/MadelineProto/Settings/Connection.md new file mode 100644 index 0000000000..47f5662f15 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Connection.md @@ -0,0 +1,468 @@ +--- +title: "danog\\MadelineProto\\Settings\\Connection: Connection settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Connection` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Connection settings. + + + + +## Method list: +* [`__construct()`](#__construct) +* [`init(): void`](#init) +* [`getProtocol(): string`](#getProtocol) +* [`setProtocol(class-string<\danog\MadelineProto\Stream\MTProtoBufferInterface> $protocol): self`](#setProtocol) +* [`getIpv6(): bool`](#getIpv6) +* [`setIpv6(bool $ipv6): self`](#setIpv6) +* [`getSslSubdomains(): array`](#getSslSubdomains) +* [`setSslSubdomains(array $sslSubdomains): self`](#setSslSubdomains) +* [`getMaxMediaSocketCount(): int`](#getMaxMediaSocketCount) +* [`setMaxMediaSocketCount(int $maxMediaSocketCount): self`](#setMaxMediaSocketCount) +* [`getRobinPeriod(): int`](#getRobinPeriod) +* [`setRobinPeriod(int $robinPeriod): self`](#setRobinPeriod) +* [`getProxies(): array, array>`](#getProxies) +* [`addProxy(class-string<\danog\MadelineProto\Stream\StreamInterface> $proxy, array $extra = []): self`](#addProxy) +* [`setProxies(array, list> $proxies): self`](#setProxies) +* [`clearProxies(): self`](#clearProxies) +* [`removeProxy(string $proxy, array $extra): self`](#removeProxy) +* [`getObfuscated(): bool`](#getObfuscated) +* [`setObfuscated(bool $obfuscated): self`](#setObfuscated) +* [`getTestMode(): bool`](#getTestMode) +* [`setTestMode(bool $testMode): self`](#setTestMode) +* [`getTransport(): class-string<\danog\MadelineProto\Stream\RawStreamInterface>`](#getTransport) +* [`setTransport(class-string<\danog\MadelineProto\Stream\RawStreamInterface> $transport): self`](#setTransport) +* [`getRetry(): bool`](#getRetry) +* [`setRetry(bool $retry): self`](#setRetry) +* [`getTimeout(): float`](#getTimeout) +* [`setTimeout(float $timeout): self`](#setTimeout) +* [`getPingInterval(): int`](#getPingInterval) +* [`setPingInterval(int $pingInterval): self`](#setPingInterval) +* [`getUseDoH(): bool`](#getUseDoH) +* [`setUseDoH(bool $useDoH): self`](#setUseDoH) +* [`getBindTo(): ?string`](#getBindTo) +* [`setBindTo((null|string) $bindTo): self`](#setBindTo) +* [`getRsaKeys(): array`](#getRsaKeys) +* [`setRsaKeys(array $rsaKeys): self`](#setRsaKeys) +* [`getTestRsaKeys(): array`](#getTestRsaKeys) +* [`setTestRsaKeys(array $testRsaKeys): self`](#setTestRsaKeys) + +## Methods: +### `__construct()` + + + + + +### `init(): void` + + + + + +### `getProtocol(): string` + +Get protocol identifier. + + + +### `setProtocol(class-string<\danog\MadelineProto\Stream\MTProtoBufferInterface> $protocol): self` + +Set protocol identifier. + +Available MTProto transport protocols (smaller overhead is better): + +* `\danog\MadelineProto\Stream\MTProtoTransport\AbridgedStream`: Lightest protocol available + * Overhead: Very small + * Minimum envelope length: 1 byte (length) + * Maximum envelope length: 4 bytes (length) + +* `\danog\MadelineProto\Stream\MTProtoTransport\IntermediateStream`: I guess they like having multiple protocols + * Overhead: small + * Minimum envelope length: 4 bytes (length) + * Maximum envelope length: 4 bytes (length) + +* `\danog\MadelineProto\Stream\MTProtoTransport\IntermediatePaddedStream`: Padded version of the intermediate protocol, to use with obfuscation enabled to bypass ISP blocks + * Overhead: small-medium + * Minimum envelope length: random + * Maximum envelope length: random + +* `\danog\MadelineProto\Stream\MTProtoTransport\FullStream`: The basic MTProto transport protocol + * Overhead: medium + * Minimum envelope length: 12 bytes (length+seqno+crc) + * Maximum envelope length: 12 bytes (length+seqno+crc) + * Pros: + * Initial integrity check with crc32 + * Transport sequence number check + + * Cons: + * Initial integrity check with crc32 is not that useful since the TCP protocol already uses it internally + * Transport sequence number check is also not that useful since transport sequence numbers are not encrypted and thus cannot be used to avoid replay attacks, and MadelineProto already uses MTProto sequence numbers and message ids for that. + +* `\danog\MadelineProto\Stream\MTProtoTransport\HttpStream`: MTProto over HTTP for browsers and webhosts + * Overhead: medium + * Pros: + * Can be used on restricted webhosts or browsers + * Cons: + * Very big envelope length + +* `\danog\MadelineProto\Stream\MTProtoTransport\HttpsStream`: MTProto over HTTPS for browsers and webhosts, very secure + * Overhead: high + * Pros: + * Can be used on restricted webhosts or browsers + * Provides an additional layer of security by trasmitting data over TLS + * Integrity checks with HMAC built into TLS + * Sequence number checks built into TLS + * Cons: + * Very big envelope length + * Requires an additional round of encryption + + +Parameters: + +* `$protocol`: `class-string<\danog\MadelineProto\Stream\MTProtoBufferInterface>` Protocol identifier + + +#### See also: +* `\danog\MadelineProto\Stream\MTProtoBufferInterface` + + + + +### `getIpv6(): bool` + +Get whether to use ipv6. + + + +### `setIpv6(bool $ipv6): self` + +Set whether to use ipv6. + + +Parameters: + +* `$ipv6`: `bool` Whether to use ipv6 + + + +### `getSslSubdomains(): array` + +Get subdomains of web.telegram.org for https protocol. + + + +### `setSslSubdomains(array $sslSubdomains): self` + +Set subdomains of web.telegram.org for https protocol. + + +Parameters: + +* `$sslSubdomains`: `array` Subdomains of web.telegram.org for https protocol. + + + +### `getMaxMediaSocketCount(): int` + +Get maximum media socket count. + + + +### `setMaxMediaSocketCount(int $maxMediaSocketCount): self` + +Set maximum media socket count. + + +Parameters: + +* `$maxMediaSocketCount`: `int` Maximum media socket count. + + + +### `getRobinPeriod(): int` + +Get robin period (seconds). + + + +### `setRobinPeriod(int $robinPeriod): self` + +Set robin period (seconds). + + +Parameters: + +* `$robinPeriod`: `int` Robin period (seconds). + + + +### `getProxies(): array, array>` + +Get proxy identifiers. + + +#### See also: +* `\danog\MadelineProto\Stream\StreamInterface` + + + + +### `addProxy(class-string<\danog\MadelineProto\Stream\StreamInterface> $proxy, array $extra = []): self` + +Add proxy identifier to list, one of:. + +* `\danog\MadelineProto\Stream\MTProtoTransport\ObfuscatedStream::class` +* `\danog\MadelineProto\Stream\Proxy\HttpProxy::class` +* `\danog\MadelineProto\Stream\Proxy\SocksProxy::class` + + +Parameters: + +* `$proxy`: `class-string<\danog\MadelineProto\Stream\StreamInterface>` Proxy identifier +* `$extra`: `array` Extra + + +#### See also: +* `\danog\MadelineProto\Stream\StreamInterface` + + + + +### `setProxies(array, list> $proxies): self` + +Set proxies. + +The key must be one of: + +* `\danog\MadelineProto\Stream\MTProtoTransport\ObfuscatedStream::class` +* `\danog\MadelineProto\Stream\Proxy\HttpProxy::class` +* `\danog\MadelineProto\Stream\Proxy\SocksProxy::class` + +The value must be a list of extra (URI, username, password) for that proxy. + + +Parameters: + +* `$proxies`: `array, list>` Proxies + + +#### See also: +* `\danog\MadelineProto\Stream\StreamInterface` + + + + +### `clearProxies(): self` + +Clear proxies. + + + +### `removeProxy(string $proxy, array $extra): self` + +Remove specific proxy pair. + + +Parameters: + +* `$proxy`: `string` +* `$extra`: `array` + + + +### `getObfuscated(): bool` + +Get whether to use the obfuscated protocol: useful to bypass ISP blocks. + + + +### `setObfuscated(bool $obfuscated): self` + +Set whether to use the obfuscated protocol: useful to bypass ISP blocks. + + +Parameters: + +* `$obfuscated`: `bool` Whether to use the obfuscated protocol. + + + +### `getTestMode(): bool` + +Get whether we're in test mode. + + + +### `setTestMode(bool $testMode): self` + +Set whether we're in test mode. + + +Parameters: + +* `$testMode`: `bool` Whether we're in test mode. + + + +### `getTransport(): class-string<\danog\MadelineProto\Stream\RawStreamInterface>` + +Get transport identifier. + + +#### See also: +* `\danog\MadelineProto\Stream\RawStreamInterface` + + + + +### `setTransport(class-string<\danog\MadelineProto\Stream\RawStreamInterface> $transport): self` + +Sets the transport protocol to use when connecting to telegram. +Not supported by HTTP and HTTPS protocols, obfuscation must be enabled. + +* `danog\MadelineProto\Stream\Transport`: Default TCP transport +* `danog\MadelineProto\Stream\WsTransport`: Plain websocket transport +* `danog\MadelineProto\Stream\WssTransport`: TLS websocket transport + + +Parameters: + +* `$transport`: `class-string<\danog\MadelineProto\Stream\RawStreamInterface>` Transport identifier. + + +#### See also: +* `\danog\MadelineProto\Stream\RawStreamInterface` + + + + +### `getRetry(): bool` + +Get whether to retry connection. + + + +### `setRetry(bool $retry): self` + +Set whether to retry connection. + + +Parameters: + +* `$retry`: `bool` Whether to retry connection. + + + +### `getTimeout(): float` + +Get connection timeout. + + + +### `setTimeout(float $timeout): self` + +Set connection timeout. + + +Parameters: + +* `$timeout`: `float` Connection timeout. + + + +### `getPingInterval(): int` + +Get ping interval. + + + +### `setPingInterval(int $pingInterval): self` + +Set ping interval. + + +Parameters: + +* `$pingInterval`: `int` Ping interval + + + +### `getUseDoH(): bool` + +Get whether to use DNS over HTTPS. + + + +### `setUseDoH(bool $useDoH): self` + +Set whether to use DNS over HTTPS. + + +Parameters: + +* `$useDoH`: `bool` Whether to use DNS over HTTPS + + + +### `getBindTo(): ?string` + +Get bind on specific address and port. + + + +### `setBindTo((null|string) $bindTo): self` + +Set bind on specific address and port. + + +Parameters: + +* `$bindTo`: `(null|string)` Bind on specific address and port. + + + +### `getRsaKeys(): array` + +Get RSA keys. + + + +### `setRsaKeys(array $rsaKeys): self` + +Set RSA keys. + + +Parameters: + +* `$rsaKeys`: `array` RSA keys + + + +### `getTestRsaKeys(): array` + +Get test RSA keys. + + + +### `setTestRsaKeys(array $testRsaKeys): self` + +Set test RSA keys. + + +Parameters: + +* `$testRsaKeys`: `array` Test RSA keys + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/DriverDatabaseAbstract.md b/docs/PHP/danog/MadelineProto/Settings/Database/DriverDatabaseAbstract.md new file mode 100644 index 0000000000..e362204ea3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/DriverDatabaseAbstract.md @@ -0,0 +1,270 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\DriverDatabaseAbstract: Base class for database backends." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\DriverDatabaseAbstract` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Base class for database backends. + + + + +## Method list: +* [`getEphemeralFilesystemPrefix(): ?string`](#getEphemeralFilesystemPrefix) +* [`setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static`](#setEphemeralFilesystemPrefix) +* [`getCacheTtl(): int`](#getCacheTtl) +* [`setCacheTtl((int|string) $cacheTtl): static`](#setCacheTtl) +* [`getPassword(): string`](#getPassword) +* [`setPassword(string $password): static`](#setPassword) +* [`getDatabase(): string|int`](#getDatabase) +* [`getUri(): string`](#getUri) +* [`setUri(string $uri): static`](#setUri) +* [`getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType`](#getSerializer) +* [`setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static`](#setSerializer) +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) + +## Methods: +### `getEphemeralFilesystemPrefix(): ?string` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + + +### `setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + +Parameters: + +* `$ephemeralFilesystemPrefix`: `?string` The database prefix + + + +### `getCacheTtl(): int` + +Get for how long to keep records in memory after last read, for cached backends. + + + +### `setCacheTtl((int|string) $cacheTtl): static` + +Set for how long to keep records in memory after last read, for cached backends. + +The cache TTL identifier can be a string like '+5 minutes'. +When data is retrieved from a database it is stored in memory. +This helps to reduce latency, improve speed and reduce mysql/postgres/redis load. +Data will be removed from the cache if last access was more than this amount of time. +Clean up is done once per minute. + + +Parameters: + +* `$cacheTtl`: `(int|string)` For how long to keep records in memory after last read, for cached backends. + + + +### `getPassword(): string` + +Get password. + + + +### `setPassword(string $password): static` + +Set password. + + +Parameters: + +* `$password`: `string` Password. + + + +### `getDatabase(): string|int` + +Get database name/ID. + + + +### `getUri(): string` + +Get database URI. + + + +### `setUri(string $uri): static` + +Set database URI. + + +Parameters: + +* `$uri`: `string` + + + +### `getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType` + + + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static` + +Which serializer to use by default. + +If null, the best serializer is chosen. + + +Parameters: + +* `$serializer`: `?\danog\MadelineProto\Settings\Database\SerializerType` + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/Memory.md b/docs/PHP/danog/MadelineProto/Settings/Database/Memory.md new file mode 100644 index 0000000000..b4f97ec77b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/Memory.md @@ -0,0 +1,130 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\Memory: Memory backend settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\Memory` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Memory backend settings. + + + + +## Method list: +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) + +## Methods: +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/Mysql.md b/docs/PHP/danog/MadelineProto/Settings/Database/Mysql.md new file mode 100644 index 0000000000..89a4e2b6ec --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/Mysql.md @@ -0,0 +1,361 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\Mysql: MySQL backend settings." +description: "\nMariaDb 10.2+ or Mysql 5.6+ required.\n" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\Mysql` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +MySQL backend settings. + + +MariaDb 10.2+ or Mysql 5.6+ required. + + + +## Method list: +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) +* [`getMaxConnections(): positive-int`](#getMaxConnections) +* [`setMaxConnections(positive-int $maxConnections): static`](#setMaxConnections) +* [`getIdleTimeout(): positive-int`](#getIdleTimeout) +* [`setIdleTimeout(positive-int $idleTimeout): static`](#setIdleTimeout) +* [`getDatabase(): string`](#getDatabase) +* [`setDatabase(string $database): static`](#setDatabase) +* [`getUsername(): string`](#getUsername) +* [`setUsername(string $username): static`](#setUsername) +* [`getUri(): string`](#getUri) +* [`setUri(string $uri): static`](#setUri) +* [`getEphemeralFilesystemPrefix(): ?string`](#getEphemeralFilesystemPrefix) +* [`setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static`](#setEphemeralFilesystemPrefix) +* [`getCacheTtl(): int`](#getCacheTtl) +* [`setCacheTtl((int|string) $cacheTtl): static`](#setCacheTtl) +* [`getPassword(): string`](#getPassword) +* [`setPassword(string $password): static`](#setPassword) +* [`getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType`](#getSerializer) +* [`setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static`](#setSerializer) +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) + +## Methods: +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `getMaxConnections(): positive-int` + +Get maximum connection limit. + + +#### See also: +* `positive-int` + + + + +### `setMaxConnections(positive-int $maxConnections): static` + +Set maximum connection limit. + + +Parameters: + +* `$maxConnections`: `positive-int` Maximum connection limit. + + +#### See also: +* `positive-int` + + + + +### `getIdleTimeout(): positive-int` + +Get idle timeout. + + +#### See also: +* `positive-int` + + + + +### `setIdleTimeout(positive-int $idleTimeout): static` + +Set idle timeout. + + +Parameters: + +* `$idleTimeout`: `positive-int` Idle timeout. + + +#### See also: +* `positive-int` + + + + +### `getDatabase(): string` + +Get database name. + + + +### `setDatabase(string $database): static` + +Set database name. + + +Parameters: + +* `$database`: `string` Database name. + + + +### `getUsername(): string` + +Get username. + + + +### `setUsername(string $username): static` + +Set username. + + +Parameters: + +* `$username`: `string` Username. + + + +### `getUri(): string` + +Get database URI. + + + +### `setUri(string $uri): static` + +Set database URI. + + +Parameters: + +* `$uri`: `string` Database URI. + + + +### `getEphemeralFilesystemPrefix(): ?string` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + + +### `setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + +Parameters: + +* `$ephemeralFilesystemPrefix`: `?string` The database prefix + + + +### `getCacheTtl(): int` + +Get for how long to keep records in memory after last read, for cached backends. + + + +### `setCacheTtl((int|string) $cacheTtl): static` + +Set for how long to keep records in memory after last read, for cached backends. + +The cache TTL identifier can be a string like '+5 minutes'. +When data is retrieved from a database it is stored in memory. +This helps to reduce latency, improve speed and reduce mysql/postgres/redis load. +Data will be removed from the cache if last access was more than this amount of time. +Clean up is done once per minute. + + +Parameters: + +* `$cacheTtl`: `(int|string)` For how long to keep records in memory after last read, for cached backends. + + + +### `getPassword(): string` + +Get password. + + + +### `setPassword(string $password): static` + +Set password. + + +Parameters: + +* `$password`: `string` Password. + + + +### `getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType` + + + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static` + +Which serializer to use by default. + +If null, the best serializer is chosen. + + +Parameters: + +* `$serializer`: `?\danog\MadelineProto\Settings\Database\SerializerType` + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/Postgres.md b/docs/PHP/danog/MadelineProto/Settings/Database/Postgres.md new file mode 100644 index 0000000000..c3f0f8ef21 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/Postgres.md @@ -0,0 +1,359 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\Postgres: Postgres backend settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\Postgres` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Postgres backend settings. + + + + +## Method list: +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) +* [`getMaxConnections(): positive-int`](#getMaxConnections) +* [`setMaxConnections(positive-int $maxConnections): static`](#setMaxConnections) +* [`getIdleTimeout(): positive-int`](#getIdleTimeout) +* [`setIdleTimeout(positive-int $idleTimeout): static`](#setIdleTimeout) +* [`getDatabase(): string`](#getDatabase) +* [`setDatabase(string $database): static`](#setDatabase) +* [`getUsername(): string`](#getUsername) +* [`setUsername(string $username): static`](#setUsername) +* [`getUri(): string`](#getUri) +* [`setUri(string $uri): static`](#setUri) +* [`getEphemeralFilesystemPrefix(): ?string`](#getEphemeralFilesystemPrefix) +* [`setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static`](#setEphemeralFilesystemPrefix) +* [`getCacheTtl(): int`](#getCacheTtl) +* [`setCacheTtl((int|string) $cacheTtl): static`](#setCacheTtl) +* [`getPassword(): string`](#getPassword) +* [`setPassword(string $password): static`](#setPassword) +* [`getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType`](#getSerializer) +* [`setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static`](#setSerializer) +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) + +## Methods: +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `getMaxConnections(): positive-int` + +Get maximum connection limit. + + +#### See also: +* `positive-int` + + + + +### `setMaxConnections(positive-int $maxConnections): static` + +Set maximum connection limit. + + +Parameters: + +* `$maxConnections`: `positive-int` Maximum connection limit. + + +#### See also: +* `positive-int` + + + + +### `getIdleTimeout(): positive-int` + +Get idle timeout. + + +#### See also: +* `positive-int` + + + + +### `setIdleTimeout(positive-int $idleTimeout): static` + +Set idle timeout. + + +Parameters: + +* `$idleTimeout`: `positive-int` Idle timeout. + + +#### See also: +* `positive-int` + + + + +### `getDatabase(): string` + +Get database name. + + + +### `setDatabase(string $database): static` + +Set database name. + + +Parameters: + +* `$database`: `string` Database name. + + + +### `getUsername(): string` + +Get username. + + + +### `setUsername(string $username): static` + +Set username. + + +Parameters: + +* `$username`: `string` Username. + + + +### `getUri(): string` + +Get database URI. + + + +### `setUri(string $uri): static` + +Set database URI. + + +Parameters: + +* `$uri`: `string` Database URI. + + + +### `getEphemeralFilesystemPrefix(): ?string` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + + +### `setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + +Parameters: + +* `$ephemeralFilesystemPrefix`: `?string` The database prefix + + + +### `getCacheTtl(): int` + +Get for how long to keep records in memory after last read, for cached backends. + + + +### `setCacheTtl((int|string) $cacheTtl): static` + +Set for how long to keep records in memory after last read, for cached backends. + +The cache TTL identifier can be a string like '+5 minutes'. +When data is retrieved from a database it is stored in memory. +This helps to reduce latency, improve speed and reduce mysql/postgres/redis load. +Data will be removed from the cache if last access was more than this amount of time. +Clean up is done once per minute. + + +Parameters: + +* `$cacheTtl`: `(int|string)` For how long to keep records in memory after last read, for cached backends. + + + +### `getPassword(): string` + +Get password. + + + +### `setPassword(string $password): static` + +Set password. + + +Parameters: + +* `$password`: `string` Password. + + + +### `getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType` + + + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static` + +Which serializer to use by default. + +If null, the best serializer is chosen. + + +Parameters: + +* `$serializer`: `?\danog\MadelineProto\Settings\Database\SerializerType` + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/Redis.md b/docs/PHP/danog/MadelineProto/Settings/Database/Redis.md new file mode 100644 index 0000000000..2e958bb408 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/Redis.md @@ -0,0 +1,282 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\Redis: Redis backend settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\Redis` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Redis backend settings. + + + + +## Method list: +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) +* [`getDatabase(): int`](#getDatabase) +* [`setDatabase(int $database): self`](#setDatabase) +* [`getUri(): string`](#getUri) +* [`setUri(string $uri): static`](#setUri) +* [`getEphemeralFilesystemPrefix(): ?string`](#getEphemeralFilesystemPrefix) +* [`setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static`](#setEphemeralFilesystemPrefix) +* [`getCacheTtl(): int`](#getCacheTtl) +* [`setCacheTtl((int|string) $cacheTtl): static`](#setCacheTtl) +* [`getPassword(): string`](#getPassword) +* [`setPassword(string $password): static`](#setPassword) +* [`getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType`](#getSerializer) +* [`setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static`](#setSerializer) +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) + +## Methods: +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `getDatabase(): int` + +Get database number. + + + +### `setDatabase(int $database): self` + +Set database number. + + +Parameters: + +* `$database`: `int` Database number. + + + +### `getUri(): string` + +Get database URI. + + + +### `setUri(string $uri): static` + +Set database URI. + + +Parameters: + +* `$uri`: `string` Database URI. + + + +### `getEphemeralFilesystemPrefix(): ?string` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + + +### `setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + +Parameters: + +* `$ephemeralFilesystemPrefix`: `?string` The database prefix + + + +### `getCacheTtl(): int` + +Get for how long to keep records in memory after last read, for cached backends. + + + +### `setCacheTtl((int|string) $cacheTtl): static` + +Set for how long to keep records in memory after last read, for cached backends. + +The cache TTL identifier can be a string like '+5 minutes'. +When data is retrieved from a database it is stored in memory. +This helps to reduce latency, improve speed and reduce mysql/postgres/redis load. +Data will be removed from the cache if last access was more than this amount of time. +Clean up is done once per minute. + + +Parameters: + +* `$cacheTtl`: `(int|string)` For how long to keep records in memory after last read, for cached backends. + + + +### `getPassword(): string` + +Get password. + + + +### `setPassword(string $password): static` + +Set password. + + +Parameters: + +* `$password`: `string` Password. + + + +### `getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType` + + + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static` + +Which serializer to use by default. + +If null, the best serializer is chosen. + + +Parameters: + +* `$serializer`: `?\danog\MadelineProto\Settings\Database\SerializerType` + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/SerializerType.md b/docs/PHP/danog/MadelineProto/Settings/Database/SerializerType.md new file mode 100644 index 0000000000..0eb760a3f3 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/SerializerType.md @@ -0,0 +1,63 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\SerializerType: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\SerializerType` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Constants +* `danog\MadelineProto\Settings\Database\SerializerType::SERIALIZE`: + +* `danog\MadelineProto\Settings\Database\SerializerType::IGBINARY`: + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Database/SqlAbstract.md b/docs/PHP/danog/MadelineProto/Settings/Database/SqlAbstract.md new file mode 100644 index 0000000000..99d5941fc4 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Database/SqlAbstract.md @@ -0,0 +1,359 @@ +--- +title: "danog\\MadelineProto\\Settings\\Database\\SqlAbstract: Generic db backend settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Database\SqlAbstract` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Generic db backend settings. + + + + +## Method list: +* [`getMaxConnections(): positive-int`](#getMaxConnections) +* [`setMaxConnections(positive-int $maxConnections): static`](#setMaxConnections) +* [`getIdleTimeout(): positive-int`](#getIdleTimeout) +* [`setIdleTimeout(positive-int $idleTimeout): static`](#setIdleTimeout) +* [`getDatabase(): string`](#getDatabase) +* [`setDatabase(string $database): static`](#setDatabase) +* [`getUsername(): string`](#getUsername) +* [`setUsername(string $username): static`](#setUsername) +* [`getUri(): string`](#getUri) +* [`setUri(string $uri): static`](#setUri) +* [`getEphemeralFilesystemPrefix(): ?string`](#getEphemeralFilesystemPrefix) +* [`setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static`](#setEphemeralFilesystemPrefix) +* [`getCacheTtl(): int`](#getCacheTtl) +* [`setCacheTtl((int|string) $cacheTtl): static`](#setCacheTtl) +* [`getPassword(): string`](#getPassword) +* [`setPassword(string $password): static`](#setPassword) +* [`getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType`](#getSerializer) +* [`setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static`](#setSerializer) +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) + +## Methods: +### `getMaxConnections(): positive-int` + +Get maximum connection limit. + + +#### See also: +* `positive-int` + + + + +### `setMaxConnections(positive-int $maxConnections): static` + +Set maximum connection limit. + + +Parameters: + +* `$maxConnections`: `positive-int` Maximum connection limit. + + +#### See also: +* `positive-int` + + + + +### `getIdleTimeout(): positive-int` + +Get idle timeout. + + +#### See also: +* `positive-int` + + + + +### `setIdleTimeout(positive-int $idleTimeout): static` + +Set idle timeout. + + +Parameters: + +* `$idleTimeout`: `positive-int` Idle timeout. + + +#### See also: +* `positive-int` + + + + +### `getDatabase(): string` + +Get database name. + + + +### `setDatabase(string $database): static` + +Set database name. + + +Parameters: + +* `$database`: `string` Database name. + + + +### `getUsername(): string` + +Get username. + + + +### `setUsername(string $username): static` + +Set username. + + +Parameters: + +* `$username`: `string` Username. + + + +### `getUri(): string` + +Get database URI. + + + +### `setUri(string $uri): static` + +Set database URI. + + +Parameters: + +* `$uri`: `string` Database URI. + + + +### `getEphemeralFilesystemPrefix(): ?string` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + + +### `setEphemeralFilesystemPrefix(?string $ephemeralFilesystemPrefix): static` + +If set, indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +Must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, +or else the session will be dropped from the database due to AUTH_KEY_DUPLICATED errors. + +Stopping the container and then deleting the session folder is 100% OK though. + + +Parameters: + +* `$ephemeralFilesystemPrefix`: `?string` The database prefix + + + +### `getCacheTtl(): int` + +Get for how long to keep records in memory after last read, for cached backends. + + + +### `setCacheTtl((int|string) $cacheTtl): static` + +Set for how long to keep records in memory after last read, for cached backends. + +The cache TTL identifier can be a string like '+5 minutes'. +When data is retrieved from a database it is stored in memory. +This helps to reduce latency, improve speed and reduce mysql/postgres/redis load. +Data will be removed from the cache if last access was more than this amount of time. +Clean up is done once per minute. + + +Parameters: + +* `$cacheTtl`: `(int|string)` For how long to keep records in memory after last read, for cached backends. + + + +### `getPassword(): string` + +Get password. + + + +### `setPassword(string $password): static` + +Set password. + + +Parameters: + +* `$password`: `string` Password. + + + +### `getSerializer(): ?\danog\MadelineProto\Settings\Database\SerializerType` + + + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `setSerializer(?\danog\MadelineProto\Settings\Database\SerializerType $serializer): static` + +Which serializer to use by default. + +If null, the best serializer is chosen. + + +Parameters: + +* `$serializer`: `?\danog\MadelineProto\Settings\Database\SerializerType` + + +#### See also: +* [\danog\MadelineProto\Settings\Database\SerializerType](../../../../danog/MadelineProto/Settings/Database/SerializerType.html) + + + + +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/DatabaseAbstract.md b/docs/PHP/danog/MadelineProto/Settings/DatabaseAbstract.md new file mode 100644 index 0000000000..d8901a8fee --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/DatabaseAbstract.md @@ -0,0 +1,130 @@ +--- +title: "danog\\MadelineProto\\Settings\\DatabaseAbstract: Base class for storage backends." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\DatabaseAbstract` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Base class for storage backends. + + + + +## Method list: +* [`getEnableFileReferenceDb(): bool`](#getEnableFileReferenceDb) +* [`setEnableFileReferenceDb(bool $enableFileReferenceDb): static`](#setEnableFileReferenceDb) +* [`getEnableMinDb(): bool`](#getEnableMinDb) +* [`setEnableMinDb(bool $enableMinDb): static`](#setEnableMinDb) +* [`getEnableUsernameDb(): bool`](#getEnableUsernameDb) +* [`setEnableUsernameDb(bool $enableUsernameDb): static`](#setEnableUsernameDb) +* [`getEnableFullPeerDb(): bool`](#getEnableFullPeerDb) +* [`setEnableFullPeerDb(bool $enableFullPeerDb): static`](#setEnableFullPeerDb) +* [`getEnablePeerInfoDb(): bool`](#getEnablePeerInfoDb) +* [`setEnablePeerInfoDb(bool $enablePeerInfoDb): static`](#setEnablePeerInfoDb) +* [`getOrmSettings(): \danog\AsyncOrm\Settings`](#getOrmSettings) + +## Methods: +### `getEnableFileReferenceDb(): bool` + +Get whether to enable the file reference database. If disabled, will break file downloads. + + + +### `setEnableFileReferenceDb(bool $enableFileReferenceDb): static` + +Set whether to enable the file reference database. If disabled, will break file downloads. + + +Parameters: + +* `$enableFileReferenceDb`: `bool` Whether to enable the file reference database. If disabled, will break file downloads. + + + +### `getEnableMinDb(): bool` + +Get whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `setEnableMinDb(bool $enableMinDb): static` + +Set whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + +Parameters: + +* `$enableMinDb`: `bool` Whether to enable the min database. If disabled, will break sendMessage (and other methods) in certain conditions. + + + +### `getEnableUsernameDb(): bool` + +Get whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `setEnableUsernameDb(bool $enableUsernameDb): static` + +Set whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + +Parameters: + +* `$enableUsernameDb`: `bool` Whether to enable the username database. If disabled, will break sendMessage (and other methods) with usernames. + + + +### `getEnableFullPeerDb(): bool` + +Get whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `setEnableFullPeerDb(bool $enableFullPeerDb): static` + +Set whether to enable the full peer info database. If disabled, will break getFullInfo. + + +Parameters: + +* `$enableFullPeerDb`: `bool` Whether to enable the full peer info database. If disabled, will break getFullInfo. + + + +### `getEnablePeerInfoDb(): bool` + +Get whether to enable the peer info database. If disabled, will break getInfo. + + + +### `setEnablePeerInfoDb(bool $enablePeerInfoDb): static` + +Set whether to enable the peer info database. If disabled, will break getInfo. + + +Parameters: + +* `$enablePeerInfoDb`: `bool` Whether to enable the peer info database. If disabled, will break getInfo. + + + +### `getOrmSettings(): \danog\AsyncOrm\Settings` + + + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Files.md b/docs/PHP/danog/MadelineProto/Settings/Files.md new file mode 100644 index 0000000000..ad2971e4b9 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Files.md @@ -0,0 +1,122 @@ +--- +title: "danog\\MadelineProto\\Settings\\Files: File management settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Files` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +File management settings. + + + + +## Method list: +* [`getAllowAutomaticUpload(): bool`](#getAllowAutomaticUpload) +* [`setAllowAutomaticUpload(bool $allowAutomaticUpload): self`](#setAllowAutomaticUpload) +* [`getUploadParallelChunks(): int`](#getUploadParallelChunks) +* [`setUploadParallelChunks(int $uploadParallelChunks): self`](#setUploadParallelChunks) +* [`getDownloadParallelChunks(): int`](#getDownloadParallelChunks) +* [`setDownloadParallelChunks(int $downloadParallelChunks): self`](#setDownloadParallelChunks) +* [`getReportBrokenMedia(): bool`](#getReportBrokenMedia) +* [`setReportBrokenMedia(bool $reportBrokenMedia): self`](#setReportBrokenMedia) +* [`getDownloadLink(): ?string`](#getDownloadLink) +* [`setDownloadLink(?string $downloadLink): self`](#setDownloadLink) + +## Methods: +### `getAllowAutomaticUpload(): bool` + +Get allow automatic upload of files from file paths present in constructors? + + + +### `setAllowAutomaticUpload(bool $allowAutomaticUpload): self` + +Set allow automatic upload of files from file paths present in constructors? + + +Parameters: + +* `$allowAutomaticUpload`: `bool` Allow automatic upload of files from file paths present in constructors? + + + +### `getUploadParallelChunks(): int` + +Get upload parallel chunk count. + + + +### `setUploadParallelChunks(int $uploadParallelChunks): self` + +Set upload parallel chunk count. + + +Parameters: + +* `$uploadParallelChunks`: `int` Upload parallel chunk count + + + +### `getDownloadParallelChunks(): int` + +Get download parallel chunk count. + + + +### `setDownloadParallelChunks(int $downloadParallelChunks): self` + +Set download parallel chunk count. + + +Parameters: + +* `$downloadParallelChunks`: `int` Download parallel chunk count + + + +### `getReportBrokenMedia(): bool` + +Get whether to report undownloadable media to TSF. + + + +### `setReportBrokenMedia(bool $reportBrokenMedia): self` + +Set whether to report undownloadable media to TSF. + + +Parameters: + +* `$reportBrokenMedia`: `bool` Whether to report undownloadable media to TSF + + + +### `getDownloadLink(): ?string` + +Get custom download link URL for CLI bots, used by `getDownloadLink`. + + + +### `setDownloadLink(?string $downloadLink): self` + +Only needed for CLI bots, not bots started via web. + +Sets custom download link URL for CLI bots, used by `getDownloadLink`. + +Can be null, in which case MadelineProto will automatically generate a download link. + + +Parameters: + +* `$downloadLink`: `?string` Custom download link URL for CLI bots, used by `getDownloadLink`. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Ipc.md b/docs/PHP/danog/MadelineProto/Settings/Ipc.md new file mode 100644 index 0000000000..d85ebb0427 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Ipc.md @@ -0,0 +1,37 @@ +--- +title: "danog\\MadelineProto\\Settings\\Ipc: IPC server settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Ipc` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +IPC server settings. + + + + +## Method list: +* [`__construct()`](#__construct) +* [`getSlow(): bool`](#getSlow) + +## Methods: +### `__construct()` + + + + + +### `getSlow(): bool` + +Get WARNING: this will cause slow startup if enabled. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Logger.md b/docs/PHP/danog/MadelineProto/Settings/Logger.md new file mode 100644 index 0000000000..e9a85d921e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Logger.md @@ -0,0 +1,126 @@ +--- +title: "danog\\MadelineProto\\Settings\\Logger: Logger settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Logger` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Logger settings. + + + + +## Method list: +* [`__construct()`](#__construct) +* [`getType(): MadelineProtoLogger::LOGGER_*`](#getType) +* [`setType(MadelineProtoLogger::LOGGER_* $type): self`](#setType) +* [`getExtra(): callable|string|null`](#getExtra) +* [`setExtra((null|callable|string) $extra): self`](#setExtra) +* [`getLevel(): MadelineProtoLogger::LEVEL_*`](#getLevel) +* [`setLevel(MadelineProtoLogger::LEVEL_* $level): self`](#setLevel) +* [`getMaxSize(): int`](#getMaxSize) +* [`setMaxSize(int $maxSize): self`](#setMaxSize) + +## Methods: +### `__construct()` + + + + + +### `getType(): MadelineProtoLogger::LOGGER_*` + +Get $type Logger type. + + +#### See also: +* `MadelineProtoLogger::LOGGER_*` + + + + +### `setType(MadelineProtoLogger::LOGGER_* $type): self` + +Set $type Logger type. + + +Parameters: + +* `$type`: `MadelineProtoLogger::LOGGER_*` $type Logger type. + + +#### See also: +* `MadelineProtoLogger::LOGGER_*` + + + + +### `getExtra(): callable|string|null` + +Get extra parameter for logger. + + + +### `setExtra((null|callable|string) $extra): self` + +Set extra parameter for logger. + + +Parameters: + +* `$extra`: `(null|callable|string)` Extra parameter for logger. + + + +### `getLevel(): MadelineProtoLogger::LEVEL_*` + +Get logging level. + + +#### See also: +* `MadelineProtoLogger::LEVEL_*` + + + + +### `setLevel(MadelineProtoLogger::LEVEL_* $level): self` + +Set logging level. + + +Parameters: + +* `$level`: `MadelineProtoLogger::LEVEL_*` Logging level. + + +#### See also: +* `MadelineProtoLogger::LEVEL_*` + + + + +### `getMaxSize(): int` + +Get maximum filesize for logger, in case of file logging. + + + +### `setMaxSize(int $maxSize): self` + +Set maximum filesize for logger, in case of file logging. + + +Parameters: + +* `$maxSize`: `int` Maximum filesize for logger, in case of file logging. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Peer.md b/docs/PHP/danog/MadelineProto/Settings/Peer.md new file mode 100644 index 0000000000..438e2a6c74 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Peer.md @@ -0,0 +1,80 @@ +--- +title: "danog\\MadelineProto\\Settings\\Peer: Peer database settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Peer` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Peer database settings. + + + + +## Method list: +* [`getFullInfoCacheTime(): int`](#getFullInfoCacheTime) +* [`setFullInfoCacheTime(int $fullInfoCacheTime): self`](#setFullInfoCacheTime) +* [`getFullFetch(): bool`](#getFullFetch) +* [`setFullFetch(bool $fullFetch): self`](#setFullFetch) +* [`getCacheAllPeersOnStartup(): bool`](#getCacheAllPeersOnStartup) +* [`setCacheAllPeersOnStartup(bool $cacheAllPeersOnStartup): self`](#setCacheAllPeersOnStartup) + +## Methods: +### `getFullInfoCacheTime(): int` + +Get cache time for full peer information (seconds). + + + +### `setFullInfoCacheTime(int $fullInfoCacheTime): self` + +Set cache time for full peer information (seconds). + + +Parameters: + +* `$fullInfoCacheTime`: `int` Cache time for full peer information (seconds). + + + +### `getFullFetch(): bool` + +Get should madeline fetch the full member list of every group it meets? + + + +### `setFullFetch(bool $fullFetch): self` + +Set should madeline fetch the full member list of every group it meets? + + +Parameters: + +* `$fullFetch`: `bool` Should madeline fetch the full member list of every group it meets? + + + +### `getCacheAllPeersOnStartup(): bool` + +Get whether to cache all peers on startup for userbots. + + + +### `setCacheAllPeersOnStartup(bool $cacheAllPeersOnStartup): self` + +Set whether to cache all peers on startup for userbots. + + +Parameters: + +* `$cacheAllPeersOnStartup`: `bool` Whether to cache all peers on startup for userbots. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Pwr.md b/docs/PHP/danog/MadelineProto/Settings/Pwr.md new file mode 100644 index 0000000000..f81f97f6ad --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Pwr.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\Settings\\Pwr: PWRTelegram settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Pwr` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +PWRTelegram settings. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/RPC.md b/docs/PHP/danog/MadelineProto/Settings/RPC.md new file mode 100644 index 0000000000..414b581de6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/RPC.md @@ -0,0 +1,101 @@ +--- +title: "danog\\MadelineProto\\Settings\\RPC: RPC settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\RPC` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +RPC settings. + + + + +## Method list: +* [`getRpcDropTimeout(): int`](#getRpcDropTimeout) +* [`setRpcDropTimeout(int $rpcDropTimeout): self`](#setRpcDropTimeout) +* [`getRpcResendTimeout(): int`](#getRpcResendTimeout) +* [`setRpcResendTimeout(int $rpcResendTimeout): self`](#setRpcResendTimeout) +* [`getFloodTimeout(): int`](#getFloodTimeout) +* [`setFloodTimeout(int $floodTimeout): self`](#setFloodTimeout) +* [`getGzipEncodeIfGt(): int`](#getGzipEncodeIfGt) +* [`setGzipEncodeIfGt(int $gzipEncodeIfGt): self`](#setGzipEncodeIfGt) + +## Methods: +### `getRpcDropTimeout(): int` + +Get RPC drop timeout. + + + +### `setRpcDropTimeout(int $rpcDropTimeout): self` + +Set RPC drop timeout. + + +Parameters: + +* `$rpcDropTimeout`: `int` RPC timeout + + + +### `getRpcResendTimeout(): int` + +Get RPC resend timeout. + + + +### `setRpcResendTimeout(int $rpcResendTimeout): self` + +Set RPC resend timeout. + + +Parameters: + +* `$rpcResendTimeout`: `int` RPC timeout. + + + +### `getFloodTimeout(): int` + +Get flood timeout: if FLOOD_WAIT_ time is bigger than this, throw exception instead of waiting asynchronously. + + + +### `setFloodTimeout(int $floodTimeout): self` + +Set flood timeout: if FLOOD_WAIT_ time is bigger than this, throw exception instead of waiting asynchronously. + +Must be bigger than 5. + + +Parameters: + +* `$floodTimeout`: `int` Flood timeout: if FLOOD_WAIT_ time is bigger than this, throw exception instead of waiting asynchronously + + + +### `getGzipEncodeIfGt(): int` + +Get encode payload with GZIP if bigger than. + + + +### `setGzipEncodeIfGt(int $gzipEncodeIfGt): self` + +Set encode payload with GZIP if bigger than. + + +Parameters: + +* `$gzipEncodeIfGt`: `int` Encode payload with GZIP if bigger than + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/SecretChats.md b/docs/PHP/danog/MadelineProto/Settings/SecretChats.md new file mode 100644 index 0000000000..70b3ee6e03 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/SecretChats.md @@ -0,0 +1,42 @@ +--- +title: "danog\\MadelineProto\\Settings\\SecretChats: Secret chat settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\SecretChats` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Secret chat settings. + + + + +## Method list: +* [`getAccept(): (bool|array)`](#getAccept) +* [`setAccept((bool|array) $accept): self`](#setAccept) + +## Methods: +### `getAccept(): (bool|array)` + +Get boolean or array of IDs. + + + +### `setAccept((bool|array) $accept): self` + +Set boolean or array of IDs. + + +Parameters: + +* `$accept`: `(bool|array)` Boolean or array of IDs + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Serialization.md b/docs/PHP/danog/MadelineProto/Settings/Serialization.md new file mode 100644 index 0000000000..441c7d1b0e --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Serialization.md @@ -0,0 +1,42 @@ +--- +title: "danog\\MadelineProto\\Settings\\Serialization: Serialization settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Serialization` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Serialization settings. + + + + +## Method list: +* [`getInterval(): int`](#getInterval) +* [`setInterval(int $interval): self`](#setInterval) + +## Methods: +### `getInterval(): int` + +Get serialization interval, in seconds. + + + +### `setInterval(int $interval): self` + +Set serialization interval, in seconds. + + +Parameters: + +* `$interval`: `int` Serialization interval, in seconds (minimum 10 seconds). + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/TLSchema.md b/docs/PHP/danog/MadelineProto/Settings/TLSchema.md new file mode 100644 index 0000000000..d0bf788ca5 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/TLSchema.md @@ -0,0 +1,151 @@ +--- +title: "danog\\MadelineProto\\Settings\\TLSchema: TL schema settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\TLSchema` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +TL schema settings. + + + + +## Method list: +* [`needsUpgrade(): bool`](#needsUpgrade) +* [`upgrade(): void`](#upgrade) +* [`getLayer(): int`](#getLayer) +* [`setLayer(int $layer): self`](#setLayer) +* [`getMTProtoSchema(): string`](#getMTProtoSchema) +* [`setMTProtoSchema(string $MTProtoSchema): self`](#setMTProtoSchema) +* [`getAPISchema(): string`](#getAPISchema) +* [`setAPISchema(string $APISchema): self`](#setAPISchema) +* [`getSecretSchema(): string`](#getSecretSchema) +* [`setSecretSchema(string $secretSchema): self`](#setSecretSchema) +* [`getOther(): array`](#getOther) +* [`setOther(array $other): self`](#setOther) +* [`getFuzzMode(): bool`](#getFuzzMode) +* [`setFuzzMode(bool $fuzz): self`](#setFuzzMode) + +## Methods: +### `needsUpgrade(): bool` + +Returns whether the TL parser should re-parse the TL schemes. + + + +### `upgrade(): void` + +Signal that scheme was re-parsed. + + + +### `getLayer(): int` + +Get TL layer version. + + + +### `setLayer(int $layer): self` + +Set TL layer version. + + +Parameters: + +* `$layer`: `int` TL layer version. + + + +### `getMTProtoSchema(): string` + +Get MTProto schema path. + + + +### `setMTProtoSchema(string $MTProtoSchema): self` + +Set MTProto schema path. + + +Parameters: + +* `$MTProtoSchema`: `string` MTProto schema path. + + + +### `getAPISchema(): string` + +Get API schema path. + + + +### `setAPISchema(string $APISchema): self` + +Set API schema path. + + +Parameters: + +* `$APISchema`: `string` API schema path. + + + +### `getSecretSchema(): string` + +Get secret schema path. + + + +### `setSecretSchema(string $secretSchema): self` + +Set secret schema path. + + +Parameters: + +* `$secretSchema`: `string` Secret schema path. + + + +### `getOther(): array` + +Get the value of other. + + + +### `setOther(array $other): self` + +Set the value of other. + + +Parameters: + +* `$other`: `array` + + + +### `getFuzzMode(): bool` + +Get the value of the fuzz mode. + + + +### `setFuzzMode(bool $fuzz): self` + +Set the value of the fuzz mode. + + +Parameters: + +* `$fuzz`: `bool` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/Templates.md b/docs/PHP/danog/MadelineProto/Settings/Templates.md new file mode 100644 index 0000000000..4019de089a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/Templates.md @@ -0,0 +1,42 @@ +--- +title: "danog\\MadelineProto\\Settings\\Templates: Web and CLI template settings for login." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\Templates` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Web and CLI template settings for login. + + + + +## Method list: +* [`getHtmlTemplate(): string`](#getHtmlTemplate) +* [`setHtmlTemplate(string $htmlTemplate): self`](#setHtmlTemplate) + +## Methods: +### `getHtmlTemplate(): string` + +Get web template used for querying app information. + + + +### `setHtmlTemplate(string $htmlTemplate): self` + +Set web template used for querying app information. + + +Parameters: + +* `$htmlTemplate`: `string` Web template used for querying app information. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Settings/VoIP.md b/docs/PHP/danog/MadelineProto/Settings/VoIP.md new file mode 100644 index 0000000000..65d50e14f1 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Settings/VoIP.md @@ -0,0 +1,19 @@ +--- +title: "danog\\MadelineProto\\Settings\\VoIP: VoIP settings." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Settings\VoIP` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +VoIP settings. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Shutdown.md b/docs/PHP/danog/MadelineProto/Shutdown.md new file mode 100644 index 0000000000..c66f3eeda6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Shutdown.md @@ -0,0 +1,59 @@ +--- +title: "danog\\MadelineProto\\Shutdown: Class that controls script shutdown." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Shutdown` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Class that controls script shutdown. + + + + +## Method list: +* [`init(): void`](#init) +* [`addCallback(callable $callback, (null|string) $id = NULL): (int|string)`](#addCallback) +* [`removeCallback((null|string|int) $id): bool`](#removeCallback) + +## Methods: +### `init(): void` + +Register shutdown function. + + + +### `addCallback(callable $callback, (null|string) $id = NULL): (int|string)` + +Add a callback for script shutdown. + + +Parameters: + +* `$callback`: `callable` The callback to set +* `$id`: `(null|string)` The optional callback ID + + +Return value: The callback ID + + +### `removeCallback((null|string|int) $id): bool` + +Remove a callback from the script shutdown callable list. + + +Parameters: + +* `$id`: `(null|string|int)` The optional callback ID + + +Return value: true if the callback was removed correctly, false otherwise + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/SimpleEventHandler.md b/docs/PHP/danog/MadelineProto/SimpleEventHandler.md new file mode 100644 index 0000000000..538c43a9f6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/SimpleEventHandler.md @@ -0,0 +1,3318 @@ +--- +title: "danog\\MadelineProto\\SimpleEventHandler: Simple event handler class: by extending this class, you can use filters, crons and the simplified event handler API." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\SimpleEventHandler` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Simple event handler class: by extending this class, you can use filters, crons and the simplified event handler API. + + + +## Properties +* `$auth`: `\danog\MadelineProto\Namespace\Auth` +* `$account`: `\danog\MadelineProto\Namespace\Account` +* `$users`: `\danog\MadelineProto\Namespace\Users` +* `$contacts`: `\danog\MadelineProto\Namespace\Contacts` +* `$messages`: `\danog\MadelineProto\Namespace\Messages` +* `$updates`: `\danog\MadelineProto\Namespace\Updates` +* `$photos`: `\danog\MadelineProto\Namespace\Photos` +* `$upload`: `\danog\MadelineProto\Namespace\Upload` +* `$help`: `\danog\MadelineProto\Namespace\Help` +* `$channels`: `\danog\MadelineProto\Namespace\Channels` +* `$bots`: `\danog\MadelineProto\Namespace\Bots` +* `$payments`: `\danog\MadelineProto\Namespace\Payments` +* `$stickers`: `\danog\MadelineProto\Namespace\Stickers` +* `$phone`: `\danog\MadelineProto\Namespace\Phone` +* `$langpack`: `\danog\MadelineProto\Namespace\Langpack` +* `$folders`: `\danog\MadelineProto\Namespace\Folders` +* `$stats`: `\danog\MadelineProto\Namespace\Stats` +* `$chatlists`: `\danog\MadelineProto\Namespace\Chatlists` +* `$stories`: `\danog\MadelineProto\Namespace\Stories` +* `$premium`: `\danog\MadelineProto\Namespace\Premium` +* `$smsjobs`: `\danog\MadelineProto\Namespace\Smsjobs` +* `$fragment`: `\danog\MadelineProto\Namespace\Fragment` + +## Method list: +* [`startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoop) +* [`startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void`](#startAndLoopBot) +* [`getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop`](#getPeriodicLoop) +* [`getPeriodicLoops(): array`](#getPeriodicLoops) +* [`getReportPeers(): (string|int|array<(string|int)>)`](#getReportPeers) +* [`getPluginPaths(): (non-empty-string|non-empty-list|null)`](#getPluginPaths) +* [`getPlugins(): array>`](#getPlugins) +* [`MTProtoToBotAPI(array $data): array`](#MTProtoToBotAPI) +* [`MTProtoToTd(mixed $params): array`](#MTProtoToTd) +* [`MTProtoToTdcli(mixed $params): array`](#MTProtoToTdcli) +* [`acceptCall(int $id): void`](#acceptCall) +* [`acceptSecretChat(array $params): void`](#acceptSecretChat) +* [`arr(mixed ...$params): array`](#arr) +* [`base64urlDecode(string $data): string`](#base64urlDecode) +* [`base64urlEncode(string $data): string`](#base64urlEncode) +* [`botAPIToMTProto(array $arguments): array`](#botAPIToMTProto) +* [`botLogin(string $token): ?array`](#botLogin) +* [`broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int`](#broadcastCustom) +* [`broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastForwardMessages) +* [`broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int`](#broadcastMessages) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null`](#callGetCurrent) +* [`callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void`](#callPlay) +* [`callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void`](#callPlayOnHold) +* [`callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void`](#callSetOutput) +* [`canConvertOgg(): bool`](#canConvertOgg) +* [`canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool`](#canUseFFmpeg) +* [`cancelBroadcast(integer $id): void`](#cancelBroadcast) +* [`closeConnection(string $message): void`](#closeConnection) +* [`complete2faLogin(string $password): array`](#complete2faLogin) +* [`completePhoneLogin(string $code): array`](#completePhoneLogin) +* [`completeSignup(string $first_name, string $last_name = ''): array`](#completeSignup) +* [`discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void`](#discardCall) +* [`discardSecretChat(int $chat): void`](#discardSecretChat) +* [`downloadServer(string $session): void`](#downloadServer) +* [`downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToBrowser) +* [`downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToCallable) +* [`downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToDir) +* [`downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string`](#downloadToFile) +* [`downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response`](#downloadToResponse) +* [`downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream`](#downloadToReturnedStream) +* [`downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void`](#downloadToStream) +* [`echo(string $string): void`](#echo) +* [`end(array $what): T`](#end) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`exportAuthorization(): array{0: (int|string), 1: string}`](#exportAuthorization) +* [`extractBotAPIFile(array $info): ?array`](#extractBotAPIFile) +* [`extractMessage(array $updates): array`](#extractMessage) +* [`extractMessageId(array $updates): int`](#extractMessageId) +* [`extractMessageUpdate(array $updates): array`](#extractMessageUpdate) +* [`extractUpdates(array $updates): array`](#extractUpdates) +* [`fileGetContents(string $url): string`](#fileGetContents) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`fullChatLastUpdated(mixed $id): int`](#fullChatLastUpdated) +* [`fullGetSelf(): array|false`](#fullGetSelf) +* [`genVectorHash(array $longs): string`](#genVectorHash) +* [`getAdminIds(): array`](#getAdminIds) +* [`getAllCalls(): array`](#getAllCalls) +* [`getAllMethods(): array`](#getAllMethods) +* [`getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)`](#getAuthorization) +* [`getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress`](#getBroadcastProgress) +* [`getCachedConfig(): array`](#getCachedConfig) +* [`getCall(int $id): ?\danog\MadelineProto\VoIP`](#getCall) +* [`getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP`](#getCallByPeer) +* [`getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState`](#getCallState) +* [`getCdnConfig(): void`](#getCdnConfig) +* [`getConfig(array $config = []): array`](#getConfig) +* [`getDNSClient(): \Amp\Dns\DnsResolver`](#getDNSClient) +* [`getDhConfig(): array`](#getDhConfig) +* [`getDialogIds(): list`](#getDialogIds) +* [`getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}`](#getDownloadInfo) +* [`getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string`](#getDownloadLink) +* [`getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)`](#getEventHandler) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getFileInfo(mixed $constructor): array`](#getFileInfo) +* [`getFullDialogs(): array`](#getFullDialogs) +* [`getFullInfo(mixed $id): array`](#getFullInfo) +* [`getHTTPClient(): \Amp\Http\Client\HttpClient`](#getHTTPClient) +* [`getHint(): string`](#getHint) +* [`getId(mixed $id): int`](#getId) +* [`getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))`](#getInfo) +* [`getLogger(): \danog\MadelineProto\Logger`](#getLogger) +* [`getMaps(): ?int`](#getMaps) +* [`getMaxMaps(): ?int`](#getMaxMaps) +* [`getMethodNamespaces(): array`](#getMethodNamespaces) +* [`getMethodsNamespaced(): array`](#getMethodsNamespaced) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null`](#getPlugin) +* [`getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo`](#getPropicInfo) +* [`getPsrLogger(): \Psr\Log\LoggerInterface`](#getPsrLogger) +* [`getPwrChat(mixed $id, bool $fullfetch = true): array`](#getPwrChat) +* [`getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat`](#getSecretChat) +* [`getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage`](#getSecretMessage) +* [`getSelf(): array|false`](#getSelf) +* [`getSessionName(): string`](#getSessionName) +* [`getSettings(): \danog\MadelineProto\Settings`](#getSettings) +* [`getSponsoredMessages((int|string|array) $peer): ?array`](#getSponsoredMessages) +* [`getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream`](#getStream) +* [`getStreamPipe(): \Amp\ByteStream\Pipe`](#getStreamPipe) +* [`getTL(): \danog\MadelineProto\TL\TLInterface`](#getTL) +* [`getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*`](#getType) +* [`getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list`](#getUpdates) +* [`getWebMessage(string $message): string`](#getWebMessage) +* [`getWebWarnings(): string`](#getWebWarnings) +* [`hasAdmins(): bool`](#hasAdmins) +* [`hasEventHandler(): bool`](#hasEventHandler) +* [`hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool`](#hasPlugin) +* [`hasReportPeers(): bool`](#hasReportPeers) +* [`hasSecretChat((array|int) $chat): bool`](#hasSecretChat) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`importAuthorization(array $authorization, int $mainDcID): array`](#importAuthorization) +* [`inflateStripped(string $stripped): string`](#inflateStripped) +* [`initSelfRestart(): void`](#initSelfRestart) +* [`isAltervista(): bool`](#isAltervista) +* [`isArrayOrAlike(mixed $var): bool`](#isArrayOrAlike) +* [`isBot(mixed $peer): bool`](#isBot) +* [`isForum(mixed $peer): bool`](#isForum) +* [`isIpc(): bool`](#isIpc) +* [`isIpcWorker(): bool`](#isIpcWorker) +* [`isPlayPaused(int $id): bool`](#isPlayPaused) +* [`isPremium(): bool`](#isPremium) +* [`isSelfBot(): bool`](#isSelfBot) +* [`isSelfUser(): bool`](#isSelfUser) +* [`isTestMode(): boolean`](#isTestMode) +* [`logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void`](#logger) +* [`logout(): void`](#logout) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string`](#openBuffered) +* [`openFileAppendOnly(string $path): \Amp\File\File`](#openFileAppendOnly) +* [`packDouble(float $value): string`](#packDouble) +* [`packSignedInt(integer $value): string`](#packSignedInt) +* [`packSignedLong(int $value): string`](#packSignedLong) +* [`packUnsignedInt(int $value): string`](#packUnsignedInt) +* [`pausePlay(int $id): void`](#pausePlay) +* [`peerIsset(mixed $id): bool`](#peerIsset) +* [`phoneLogin(string $number, integer $sms_type = 5): array`](#phoneLogin) +* [`posmod(int $a, int $b): int`](#posmod) +* [`processDownloadServerPing(string $path, string $payload): void`](#processDownloadServerPing) +* [`qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode`](#qrLogin) +* [`random(integer $length): string`](#random) +* [`randomInt(integer $modulus = 0): int`](#randomInt) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`refreshFullPeerCache(mixed $id): void`](#refreshFullPeerCache) +* [`refreshPeerCache(mixed ...$ids): void`](#refreshPeerCache) +* [`report(string $message, string $parseMode = ''): void`](#report) +* [`reportMemoryProfile(): void`](#reportMemoryProfile) +* [`requestCall(mixed $user): \danog\MadelineProto\VoIP`](#requestCall) +* [`requestSecretChat(mixed $user): int`](#requestSecretChat) +* [`resetUpdateState(): void`](#resetUpdateState) +* [`restart(): void`](#restart) +* [`resumePlay(int $id): void`](#resumePlay) +* [`rethrow(Throwable $e): void`](#rethrow) +* [`rleDecode(string $string): string`](#rleDecode) +* [`rleEncode(string $string): string`](#rleEncode) +* [`sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendAudio) +* [`sendCustomEvent(mixed $payload): void`](#sendCustomEvent) +* [`sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocument) +* [`sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendDocumentPhoto) +* [`sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendGif) +* [`sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendMessage) +* [`sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>`](#sendMessageToAdmins) +* [`sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendPhoto) +* [`sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendSticker) +* [`sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVideo) +* [`sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message`](#sendVoice) +* [`setNoop(): void`](#setNoop) +* [`setReportPeers((int|string|array<(int|string)>) $userOrId): void`](#setReportPeers) +* [`setWebhook(string $webhookUrl): void`](#setWebhook) +* [`skipPlay(int $id): void`](#skipPlay) +* [`sleep(float $time): void`](#sleep) +* [`start(): array`](#start) +* [`stop(): void`](#stop) +* [`stopPlay(int $id): void`](#stopPlay) +* [`stringToStream(string $str): \Amp\ByteStream\ReadableBuffer`](#stringToStream) +* [`subscribeToUpdates(mixed $channel): bool`](#subscribeToUpdates) +* [`tdToMTProto(array $params): array`](#tdToMTProto) +* [`tdToTdcli(mixed $params): array`](#tdToTdcli) +* [`tdcliToTd(mixed $params, array $key = NULL): array`](#tdcliToTd) +* [`testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}`](#testFibers) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`unpackDouble(string $value): float`](#unpackDouble) +* [`unpackFileId(string $fileId): array`](#unpackFileId) +* [`unpackSignedInt(string $value): int`](#unpackSignedInt) +* [`unpackSignedLong(string $value): int`](#unpackSignedLong) +* [`unpackSignedLongString((string|int|array) $value): string`](#unpackSignedLongString) +* [`unsetEventHandler(): void`](#unsetEventHandler) +* [`update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void`](#update2fa) +* [`updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void`](#updateSettings) +* [`upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#upload) +* [`uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadEncrypted) +* [`uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromCallable) +* [`uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromStream) +* [`uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromTgfile) +* [`uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array`](#uploadFromUrl) +* [`validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>`](#validateEventHandlerClass) +* [`viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool`](#viewSponsoredMessage) +* [`wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media`](#wrapMedia) +* [`wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage`](#wrapMessage) +* [`wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned`](#wrapPin) +* [`wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update`](#wrapUpdate) +* [`initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void`](#initDbProperties) +* [`saveDbProperties(): void`](#saveDbProperties) + +## Methods: +### `startAndLoop(string $session, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `startAndLoopBot(string $session, string $token, ?\danog\MadelineProto\SettingsAbstract $settings = NULL): void` + +Start MadelineProto as a bot and the event handler. + +Also initializes error reporting, catching and reporting all errors surfacing from the event loop. + + +Parameters: + +* `$session`: `string` Session name +* `$token`: `string` Bot token +* `$settings`: `?\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `getPeriodicLoop(string $name): ?\danog\Loop\PeriodicLoop` + +Obtain a PeriodicLoop instance created by the Cron attribute. + + +Parameters: + +* `$name`: `string` Method name + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getPeriodicLoops(): array` + +Obtain all PeriodicLoop instances created by the Cron attribute. + + +#### See also: +* `\danog\Loop\PeriodicLoop` + + + + +### `getReportPeers(): (string|int|array<(string|int)>)` + +Get peers where to send error reports. + + + +### `getPluginPaths(): (non-empty-string|non-empty-list|null)` + +Obtain a path or a list of paths that will be recursively searched for plugins. + +Plugin filenames end with Plugin.php, and will be included automatically. + + +#### See also: +* `non-empty-string` +* `non-empty-list` + + + + +### `getPlugins(): array>` + +Obtain a list of plugin event handlers to use, in addition with those found by getPluginPath. + + + +### `MTProtoToBotAPI(array $data): array` + +Convert MTProto parameters to bot API parameters. + + +Parameters: + +* `$data`: `array` Data + + + +### `MTProtoToTd(mixed $params): array` + +MTProto to TD params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `MTProtoToTdcli(mixed $params): array` + +MTProto to TDCLI params. + + +Parameters: + +* `$params`: `mixed` Params + + + +### `acceptCall(int $id): void` + +Accept call. + + +Parameters: + +* `$id`: `int` + + + +### `acceptSecretChat(array $params): void` + +Accept secret chat. + + +Parameters: + +* `$params`: `array` Secret chat ID + + + +### `arr(mixed ...$params): array` + +Create array. + + +Parameters: + +* `...$params`: `mixed` Params + + + +### `base64urlDecode(string $data): string` + +base64URL decode. + + +Parameters: + +* `$data`: `string` Data to decode + + + +### `base64urlEncode(string $data): string` + +Base64URL encode. + + +Parameters: + +* `$data`: `string` Data to encode + + + +### `botAPIToMTProto(array $arguments): array` + +Convert bot API parameters to MTProto parameters. + + +Parameters: + +* `$arguments`: `array` Arguments + + + +### `botLogin(string $token): ?array` + +Login as bot. + + +Parameters: + +* `$token`: `string` Bot token + + + +### `broadcastCustom(\danog\MadelineProto\Broadcast\Action $action, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, (float|null) $delay = NULL): int` + +Executes a custom broadcast action with all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$action`: `\danog\MadelineProto\Broadcast\Action` A custom, serializable Action class that will be called once for every peer. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Action`: Interface that represents a broadcast action.](../../danog/MadelineProto/Broadcast/Action.html) +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastForwardMessages(mixed $from_peer, list $message_ids, bool $drop_author = false, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Forwards a list of messages to all peers (users, chats, channels) of the bot. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$from_peer`: `mixed` Bot API ID or Update, from where to forward the messages. +* `$message_ids`: `list` IDs of the messages to forward. +* `$drop_author`: `bool` If true, will forward messages without quoting the original author. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `broadcastMessages(array $messages, ?\danog\MadelineProto\Broadcast\Filter $filter = NULL, bool $pin = false, (float|null) $delay = NULL): int` + +Sends a list of messages to all peers (users, chats, channels) of the bot. + +A simplified version of this method is also available: broadcastForwardMessages can work with pre-prepared messages. + +Will return an integer ID that can be used to: + +- Get the current broadcast progress with getBroadcastProgress +- Cancel the broadcast using cancelBroadcast + +Note that to avoid manually polling the progress, +MadelineProto will also periodically emit updateBroadcastProgress updates, +containing a Progress object for all broadcasts currently in-progress. + + +Parameters: + +* `$messages`: `array` The messages to send: an array of arrays, containing parameters to pass to messages.sendMessage. +* `$filter`: `?\danog\MadelineProto\Broadcast\Filter` +* `$pin`: `bool` Whether to also pin the last sent message. +* `$delay`: `(float|null)` Number of seconds to wait between each peer. + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Filter`: Broadcast filter.](../../danog/MadelineProto/Broadcast/Filter.html) + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `callGetCurrent(int $id): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null` + +Get the file that is currently being played. + +Will return a string with the object ID of the stream if we're currently playing a stream, otherwise returns the related LocalFile or RemoteUrl. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) + + + + +### `callPlay(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): void` + +Play file in call. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callPlayOnHold(int $id, \danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): void` + +Play files on hold in call. + + +Parameters: + +* `$id`: `int` +* `...$files`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `callSetOutput(int $id, \danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): void` + +Set output file or stream for incoming OPUS audio packets in a call. + +Will write an OGG OPUS stream to the specified file or stream. + + +Parameters: + +* `$id`: `int` +* `$file`: `\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* `\Amp\ByteStream\WritableStream` + + + + +### `canConvertOgg(): bool` + +Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot. + + + +### `canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool` + +Whether we can convert any audio/video file using ffmpeg. + + +Parameters: + +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `cancelBroadcast(integer $id): void` + +Cancel a running broadcast. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + + +### `closeConnection(string $message): void` + +Close connection with client, connected via web. + + +Parameters: + +* `$message`: `string` Message + + + +### `complete2faLogin(string $password): array` + +Complete 2FA login. + + +Parameters: + +* `$password`: `string` Password + + + +### `completePhoneLogin(string $code): array` + +Complet user login using login code. + + +Parameters: + +* `$code`: `string` Login code + + + +### `completeSignup(string $first_name, string $last_name = ''): array` + +Complete signup to Telegram. + + +Parameters: + +* `$first_name`: `string` First name +* `$last_name`: `string` Last name + + + +### `discardCall(int $id, \danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): void` + +Discard call. + + +Parameters: + +* `$id`: `int` +* `$reason`: `\danog\MadelineProto\VoIP\DiscardReason` +* `$rating`: `int<1, 5>` Call rating in stars +* `$comment`: `string` Additional comment on call quality. + + +#### See also: +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `discardSecretChat(int $chat): void` + +Discard secret chat. + + +Parameters: + +* `$chat`: `int` Secret chat ID + + + +### `downloadServer(string $session): void` + +Downloads a file to the browser using the specified session file. + + +Parameters: + +* `$session`: `string` + + + +### `downloadToBrowser((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, (null|callable) $cb = NULL, (null|int) $size = NULL, (null|string) $name = NULL, (null|string) $mime = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to browser. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$cb`: `(null|callable)` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Cancellation` + + + + +### `downloadToCallable(mixed $messageMedia, (callable|\danog\MadelineProto\FileCallbackInterface) $callable, callable $cb = NULL, bool $seekable = true, int $offset = 0, int $end = -1, int $part_size = NULL, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to callable. +The callable must accept two parameters: string $payload, int $offset +The callable will be called (possibly out of order, depending on the value of $seekable). + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$callable`: `(callable|\danog\MadelineProto\FileCallbackInterface)` Chunk callback +* `$cb`: `callable` Status callback +* `$seekable`: `bool` Whether the callable can be called out of order +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to stop downloading (inclusive) +* `$part_size`: `int` Size of each chunk +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `downloadToDir(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $dir, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file to directory. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$dir`: `(string|\danog\MadelineProto\FileCallbackInterface)` Directory where to download the file +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToFile(mixed $messageMedia, (string|\danog\MadelineProto\FileCallbackInterface) $file, callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): non-empty-string` + +Download file. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$file`: `(string|\danog\MadelineProto\FileCallbackInterface)` Downloaded file path +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: Downloaded file name + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` +* `non-empty-string` + + + + +### `downloadToResponse((array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message) $messageMedia, \Amp\Http\Server\Request $request, callable $cb = NULL, (null|int) $size = NULL, (null|string) $mime = NULL, (null|string) $name = NULL, ?\Amp\Cancellation $cancellation = NULL): \Amp\Http\Server\Response` + +Download file to amphp/http-server response. + +Supports HEAD requests and content-ranges for parallel and resumed downloads. + + +Parameters: + +* `$messageMedia`: `(array|string|\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\EventHandler\Message)` File to download +* `$request`: `\Amp\Http\Server\Request` Request +* `$cb`: `callable` Status callback (can also use FileCallback) +* `$size`: `(null|int)` Size of file to download, required for bot API file IDs. +* `$mime`: `(null|string)` MIME type of file to download, required for bot API file IDs. +* `$name`: `(null|string)` Name of file to download, required for bot API file IDs. +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* `\Amp\Http\Server\Request` +* `\Amp\Cancellation` +* `\Amp\Http\Server\Response` + + + + +### `downloadToReturnedStream(mixed $messageMedia, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): \Amp\ByteStream\ReadableStream` + +Download file to an amphp stream, returning it. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` +* `\Amp\ByteStream\ReadableStream` + + + + +### `downloadToStream(mixed $messageMedia, (mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream) $stream, callable $cb = NULL, int $offset = 0, int $end = -1, ?\Amp\Cancellation $cancellation = NULL): void` + +Download file to stream. + + +Parameters: + +* `$messageMedia`: `mixed` File to download +* `$stream`: `(mixed|\danog\MadelineProto\FileCallbackInterface|resource|\Amp\ByteStream\WritableStream)` Stream where to download file +* `$cb`: `callable` Callback +* `$offset`: `int` Offset where to start downloading +* `$end`: `int` Offset where to end download +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `resource` +* `\Amp\ByteStream\WritableStream` +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `end(array $what): T` + +Get final element of array. + + +Parameters: + +* `$what`: `array` Array + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `exportAuthorization(): array{0: (int|string), 1: string}` + +Export authorization. + + + +### `extractBotAPIFile(array $info): ?array` + +Extract file info from bot API message. + + +Parameters: + +* `$info`: `array` Bot API message object + + + +### `extractMessage(array $updates): array` + +Extract a message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageId(array $updates): int` + +Extract a message ID from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractMessageUpdate(array $updates): array` + +Extract an update message constructor from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `extractUpdates(array $updates): array` + +Extract Update constructors from an Updates constructor. + + +Parameters: + +* `$updates`: `array` + + + +### `fileGetContents(string $url): string` + +Get contents of remote file asynchronously. + + +Parameters: + +* `$url`: `string` URL + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `fullChatLastUpdated(mixed $id): int` + +When was full info for this chat last cached. + + +Parameters: + +* `$id`: `mixed` Chat ID + + + +### `fullGetSelf(): array|false` + +Get info about the logged-in user, not cached. + + + +### `genVectorHash(array $longs): string` + +Generate MTProto vector hash. + +Returns a vector hash. + + +Parameters: + +* `$longs`: `array` IDs + + + +### `getAdminIds(): array` + +Get admin IDs (equal to all user report peers). + + + +### `getAllCalls(): array` + +Get all pending and running calls, indexed by user ID. + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getAllMethods(): array` + +Get full list of MTProto and API methods. + + + +### `getAuthorization(): (\danog\MadelineProto\API::NOT_LOGGED_IN|\danog\MadelineProto\API::WAITING_CODE|\danog\MadelineProto\API::WAITING_SIGNUP|\danog\MadelineProto\API::WAITING_PASSWORD|\danog\MadelineProto\API::LOGGED_IN|API::LOGGED_OUT)` + +Get authorization info. + + +#### See also: +* `\danog\MadelineProto\API::NOT_LOGGED_IN` +* `\danog\MadelineProto\API::WAITING_CODE` +* `\danog\MadelineProto\API::WAITING_SIGNUP` +* `\danog\MadelineProto\API::WAITING_PASSWORD` +* `\danog\MadelineProto\API::LOGGED_IN` +* `API::LOGGED_OUT` + + + + +### `getBroadcastProgress(integer $id): ?\danog\MadelineProto\Broadcast\Progress` + +Get the progress of a currently running broadcast. + +Will return null if the broadcast doesn't exist, has already completed or was cancelled. + +Use updateBroadcastProgress updates to get real-time progress status without polling. + + +Parameters: + +* `$id`: `integer` Broadcast ID + + +#### See also: +* [`\danog\MadelineProto\Broadcast\Progress`: Broadcast progress.](../../danog/MadelineProto/Broadcast/Progress.html) + + + + +### `getCachedConfig(): array` + +Get cached server-side config. + + + +### `getCall(int $id): ?\danog\MadelineProto\VoIP` + +Get phone call information. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallByPeer(int $userId): ?\danog\MadelineProto\VoIP` + +Get the phone call with the specified user ID. + + +Parameters: + +* `$userId`: `int` + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `getCallState(int $id): ?\danog\MadelineProto\VoIP\CallState` + +Get call state. + + +Parameters: + +* `$id`: `int` + + +#### See also: +* [\danog\MadelineProto\VoIP\CallState](../../danog/MadelineProto/VoIP/CallState.html) + + + + +### `getCdnConfig(): void` + +Store RSA keys for CDN datacenters. + + + +### `getConfig(array $config = []): array` + +Get cached (or eventually re-fetch) server-side config. + + +Parameters: + +* `$config`: `array` Current config + + + +### `getDNSClient(): \Amp\Dns\DnsResolver` + +Get async DNS client. + + +#### See also: +* `\Amp\Dns\DnsResolver` + + + + +### `getDhConfig(): array` + +Get diffie-hellman configuration. + + + +### `getDialogIds(): list` + +Get dialog IDs. + + + +### `getDownloadInfo(mixed $messageMedia): array{ext: string, name: string, mime: string, size: int, InputFileLocation: array, key_fingerprint?: string, key?: string, iv?: string, thumb_size?: string}` + +Get download info of file +Returns an array with the following structure:. + +`$info['ext']` - The file extension +`$info['name']` - The file name, without the extension +`$info['mime']` - The file mime type +`$info['size']` - The file size + + +Parameters: + +* `$messageMedia`: `mixed` File ID + + + +### `getDownloadLink(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string $media, ?string $scriptUrl = NULL, ?int $size = NULL, ?string $name = NULL, ?string $mime = NULL): string` + +Get download link of media file. + + +Parameters: + +* `$media`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|array|string` +* `$scriptUrl`: `?string` +* `$size`: `?int` +* `$name`: `?string` +* `$mime`: `?string` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `getEventHandler((class-string|null) $class = NULL): (T|\danog\MadelineProto\Ipc\EventHandlerProxy|\__PHP_Incomplete_Class|null)` + +Get event handler (or plugin instance). + + +Parameters: + +* `$class`: `(class-string|null)` + + +#### See also: +* `\danog\MadelineProto\Ipc\EventHandlerProxy` +* `\__PHP_Incomplete_Class` + + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getFileInfo(mixed $constructor): array` + +Get info about file. + + +Parameters: + +* `$constructor`: `mixed` File ID + + + +### `getFullDialogs(): array` + +Get full info of all dialogs. + +Bots should use getDialogIds, instead. + + + +### `getFullInfo(mixed $id): array` + +Get full info about peer, returns an FullInfo object. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* [https://docs.madelineproto.xyz/FullInfo.html](https://docs.madelineproto.xyz/FullInfo.html) + + + + +### `getHTTPClient(): \Amp\Http\Client\HttpClient` + +Get async HTTP client. + + +#### See also: +* `\Amp\Http\Client\HttpClient` + + + + +### `getHint(): string` + +Get current password hint. + + + +### `getId(mixed $id): int` + +Get the bot API ID of a peer. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `getInfo(mixed $id, \danog\MadelineProto\API::INFO_TYPE_* $type = \danog\MadelineProto\API::INFO_TYPE_ALL): (\$type is \danog\MadelineProto\API::INFO_TYPE_ALL ? array{User?: array, Chat?: array, bot_api_id: int, user_id?: int, chat_id?: int, channel_id?: int, type: string} : ($type is API::INFO_TYPE_TYPE ? string : ($type is \danog\MadelineProto\API::INFO_TYPE_ID ? int : (array{_: string, user_id?: int, access_hash?: int, min?: bool, chat_id?: int, channel_id?: int} | array{_: string, user_id?: int, access_hash?: int, min?: bool} | array{_: string, channel_id: int, access_hash: int, min: bool}))))` + +Get info about peer, returns an Info object. + +If passed a secret chat ID, returns information about the user, not about the secret chat. +Use getSecretChat to return information about the secret chat. + + +Parameters: + +* `$id`: `mixed` Peer +* `$type`: `\danog\MadelineProto\API::INFO_TYPE_*` Whether to generate an Input*, an InputPeer or the full set of constructors + + +#### See also: +* [https://docs.madelineproto.xyz/Info.html](https://docs.madelineproto.xyz/Info.html) +* `\danog\MadelineProto\API::INFO_TYPE_*` + + + + +### `getLogger(): \danog\MadelineProto\Logger` + +Get logger. + + +#### See also: +* [`\danog\MadelineProto\Logger`: Logger class.](../../danog/MadelineProto/Logger.html) + + + + +### `getMaps(): ?int` + +Get current number of memory-mapped regions, UNIX only. + + + +### `getMaxMaps(): ?int` + +Get maximum number of memory-mapped regions, UNIX only. +Use testFibers to get the maximum number of fibers on any platform. + + + +### `getMethodNamespaces(): array` + +Get TL namespaces. + + + +### `getMethodsNamespaced(): array` + +Get namespaced methods (method => namespace). + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getPlugin(class-string $class): \danog\MadelineProto\PluginEventHandler|\danog\MadelineProto\Ipc\EventHandlerProxy|null` + +Obtain a certain event handler plugin instance. + + +Parameters: + +* `$class`: `class-string` + +return T|null + + +#### See also: +* [`\danog\MadelineProto\PluginEventHandler`: Plugin event handler class.](../../danog/MadelineProto/PluginEventHandler.html) +* `\danog\MadelineProto\Ipc\EventHandlerProxy` + + + + +### `getPropicInfo(mixed $data): ?\danog\MadelineProto\EventHandler\Media\Photo` + +Gets info of the propic of a user. + + +Parameters: + +* `$data`: `mixed` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media\Photo`: Represents a photo.](../../danog/MadelineProto/EventHandler/Media/Photo.html) + + + + +### `getPsrLogger(): \Psr\Log\LoggerInterface` + +Get PSR logger. + + +#### See also: +* `\Psr\Log\LoggerInterface` + + + + +### `getPwrChat(mixed $id, bool $fullfetch = true): array` + +Get full info about peer (including full list of channel members), returns a Chat object. + + +Parameters: + +* `$id`: `mixed` Peer +* `$fullfetch`: `bool` + + +#### See also: +* [https://docs.madelineproto.xyz/Chat.html](https://docs.madelineproto.xyz/Chat.html) + + + + +### `getSecretChat((array|int) $chat): \danog\MadelineProto\SecretChats\SecretChat` + +Get secret chat. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + +#### See also: +* [`\danog\MadelineProto\SecretChats\SecretChat`: Represents a secret chat.](../../danog/MadelineProto/SecretChats/SecretChat.html) + + + + +### `getSecretMessage(integer $chatId, integer $randomId): \danog\MadelineProto\EventHandler\Message\SecretMessage` + +Gets a secret chat message. + + +Parameters: + +* `$chatId`: `integer` Secret chat ID. +* `$randomId`: `integer` Secret chat message ID. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\SecretMessage`: Represents New encrypted message.](../../danog/MadelineProto/EventHandler/Message/SecretMessage.html) + + + + +### `getSelf(): array|false` + +Get info about the logged-in user, cached. + +Use fullGetSelf to bypass the cache. + + + +### `getSessionName(): string` + +Returns the session name. + + + +### `getSettings(): \danog\MadelineProto\Settings` + +Return current settings. + + +#### See also: +* [`\danog\MadelineProto\Settings`: Settings class used for configuring MadelineProto.](../../danog/MadelineProto/Settings.html) + + + + +### `getSponsoredMessages((int|string|array) $peer): ?array` + +Get sponsored messages for channel. +This method will return an array of [sponsored message objects](https://docs.madelineproto.xyz/API_docs/constructors/sponsoredMessage.html). + +See [the API documentation](https://core.telegram.org/api/sponsored-messages) for more info on how to handle sponsored messages. + + +Parameters: + +* `$peer`: `(int|string|array)` Channel ID, or Update, or Message, or Peer. + + + +### `getStream(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL, ?int $size = NULL): \Amp\ByteStream\ReadableStream` + +Provide a stream for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` +* `$size`: `?int` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `getStreamPipe(): \Amp\ByteStream\Pipe` + +Obtains a pipe that can be used to upload a file from a stream. + + +#### See also: +* `\Amp\ByteStream\Pipe` + + + + +### `getTL(): \danog\MadelineProto\TL\TLInterface` + +Get TL serializer. + + +#### See also: +* [\danog\MadelineProto\TL\TLInterface](../../danog/MadelineProto/TL/TLInterface.html) + + + + +### `getType(mixed $id): \danog\MadelineProto\API::PEER_TYPE_*` + +Get type of peer. + + +Parameters: + +* `$id`: `mixed` Peer + + +#### See also: +* `\danog\MadelineProto\API::PEER_TYPE_*` + + + + +### `getUpdates(array{offset?: int, limit?: int, timeout?: float} $params = []): list` + +Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**. + +`getUpdates` will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + + +Parameters: + +* `$params`: `array{offset?: int, limit?: int, timeout?: float}` Params + + + +### `getWebMessage(string $message): string` + +Get a message to show to the user when starting the bot. + + +Parameters: + +* `$message`: `string` + + + +### `getWebWarnings(): string` + +Get various warnings to show to the user in the web UI. + + + +### `hasAdmins(): bool` + +Check if has admins. + + + +### `hasEventHandler(): bool` + +Check if an event handler instance is present. + + + +### `hasPlugin(class-string<\danog\MadelineProto\EventHandler> $class): bool` + +Check if a certain event handler plugin is installed. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) + + + + +### `hasReportPeers(): bool` + +Check if has report peers. + + + +### `hasSecretChat((array|int) $chat): bool` + +Check whether secret chat exists. + + +Parameters: + +* `$chat`: `(array|int)` Secret chat ID + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `importAuthorization(array $authorization, int $mainDcID): array` + +Import authorization. + + +Parameters: + +* `$authorization`: `array` Authorization info +* `$mainDcID`: `int` Main DC ID + + + +### `inflateStripped(string $stripped): string` + +Inflate stripped photosize to full JPG payload. + + +Parameters: + +* `$stripped`: `string` Stripped photosize + + + +### `initSelfRestart(): void` + +Initialize self-restart hack. + + + +### `isAltervista(): bool` + +Whether this is altervista. + + + +### `isArrayOrAlike(mixed $var): bool` + +Check if is array or similar (traversable && countable && arrayAccess). + + +Parameters: + +* `$var`: `mixed` Value to check + + + +### `isBot(mixed $peer): bool` + +Check if the specified peer is a bot. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isForum(mixed $peer): bool` + +Check if the specified peer is a forum. + + +Parameters: + +* `$peer`: `mixed` + + + +### `isIpc(): bool` + +Whether we're an IPC client instance. + + + +### `isIpcWorker(): bool` + +Whether we're an IPC server process (as opposed to an event handler). + + + +### `isPlayPaused(int $id): bool` + +Whether the currently playing audio file is paused. + + +Parameters: + +* `$id`: `int` + + + +### `isPremium(): bool` + +Returns whether the current user is a premium user, cached. + + + +### `isSelfBot(): bool` + +Returns whether the current user is a bot. + + + +### `isSelfUser(): bool` + +Returns whether the current user is a user. + + + +### `isTestMode(): boolean` + +Whether we're currently connected to the test DCs. + + + +### `logger(mixed $param, int $level = \danog\MadelineProto\Logger::NOTICE, string $file = ''): void` + +Logger. + + +Parameters: + +* `$param`: `mixed` Parameter +* `$level`: `int` Logging level +* `$file`: `string` File where the message originated + + + +### `logout(): void` + +Logout the session. + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string` + +Provide a buffered reader for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `openFileAppendOnly(string $path): \Amp\File\File` + +Opens a file in append-only mode. + + +Parameters: + +* `$path`: `string` File path. + + +#### See also: +* `\Amp\File\File` + + + + +### `packDouble(float $value): string` + +Convert double to binary version. + + +Parameters: + +* `$value`: `float` Value to convert + + + +### `packSignedInt(integer $value): string` + +Convert integer to base256 signed int. + + +Parameters: + +* `$value`: `integer` Value to convert + + + +### `packSignedLong(int $value): string` + +Convert integer to base256 long. + + +Parameters: + +* `$value`: `int` Value to convert + + + +### `packUnsignedInt(int $value): string` + +Convert value to unsigned base256 int. + + +Parameters: + +* `$value`: `int` Value + + + +### `pausePlay(int $id): void` + +Pauses playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `peerIsset(mixed $id): bool` + +Check if peer is present in internal peer database. + + +Parameters: + +* `$id`: `mixed` Peer + + + +### `phoneLogin(string $number, integer $sms_type = 5): array` + +Login as user. + + +Parameters: + +* `$number`: `string` Phone number +* `$sms_type`: `integer` SMS type + + + +### `posmod(int $a, int $b): int` + +Positive modulo +Works just like the % (modulus) operator, only returns always a postive number. + + +Parameters: + +* `$a`: `int` A +* `$b`: `int` B + + + +### `processDownloadServerPing(string $path, string $payload): void` + +Internal endpoint used by the download server. + + +Parameters: + +* `$path`: `string` +* `$payload`: `string` + + + +### `qrLogin(): ?\danog\MadelineProto\TL\Types\LoginQrCode` + +Initiates QR code login. + +Returns a QR code login helper object, that can be used to render the QR code, display the link directly, wait for login, QR code expiration and much more. + +Returns null if we're already logged in, or if we're waiting for a password (use getAuthorization to distinguish between the two cases). + + +#### See also: +* [`\danog\MadelineProto\TL\Types\LoginQrCode`: Represents a login QR code.](../../danog/MadelineProto/TL/Types/LoginQrCode.html) + + + + +### `random(integer $length): string` + +Get secure random string of specified length. + + +Parameters: + +* `$length`: `integer` Length + + + +### `randomInt(integer $modulus = 0): int` + +Get random integer. + + +Parameters: + +* `$modulus`: `integer` Modulus + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `refreshFullPeerCache(mixed $id): void` + +Refresh full peer cache for a certain peer. + + +Parameters: + +* `$id`: `mixed` The peer to refresh + + + +### `refreshPeerCache(mixed ...$ids): void` + +Refresh peer cache for a certain peer. + + +Parameters: + +* `...$ids`: `mixed` + + + +### `report(string $message, string $parseMode = ''): void` + +Report an error to the previously set peer. + + +Parameters: + +* `$message`: `string` Error to report +* `$parseMode`: `string` Parse mode + + + +### `reportMemoryProfile(): void` + +Report memory profile with memprof. + + + +### `requestCall(mixed $user): \danog\MadelineProto\VoIP` + +Request VoIP call. + + +Parameters: + +* `$user`: `mixed` User + + +#### See also: +* [`\danog\MadelineProto\VoIP`: This update represents a VoIP Telegram call.](../../danog/MadelineProto/VoIP.html) + + + + +### `requestSecretChat(mixed $user): int` + +Request secret chat. + + +Parameters: + +* `$user`: `mixed` User to start secret chat with + + + +### `resetUpdateState(): void` + +Reset the update state and fetch all updates from the beginning. + + + +### `restart(): void` + +Restart update loop. + + + +### `resumePlay(int $id): void` + +Resumes playback of the current audio file in the call. + + +Parameters: + +* `$id`: `int` + + + +### `rethrow(Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `Throwable` + + +#### See also: +* `Throwable` + + + + +### `rleDecode(string $string): string` + +null-byte RLE decode. + + +Parameters: + +* `$string`: `string` Data to decode + + + +### `rleEncode(string $string): string` + +null-byte RLE encode. + + +Parameters: + +* `$string`: `string` Data to encode + + + +### `sendAudio((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, (integer|null) $duration = NULL, (string|null) $title = NULL, (string|null) $performer = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends an audio. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$duration`: `(integer|null)` Duration of the audio +* `$title`: `(string|null)` Title of the audio +* `$performer`: `(string|null)` Performer of the audio +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendCustomEvent(mixed $payload): void` + +Sends an updateCustomEvent update to the event handler. + + +Parameters: + +* `$payload`: `mixed` + + + +### `sendDocument((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?string $mimeType = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a document. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `?string` +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendDocumentPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendGif((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, boolean $spoiler = false, ?int $duration = NULL, ?int $width = NULL, ?int $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a gif. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$duration`: `?int` +* `$width`: `?int` +* `$height`: `?int` +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendMessage((integer|string) $peer, string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, boolean $updateStickersetsOrder = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a message. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$cancellation`: `?\Amp\Cancellation` Cancellation + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendMessageToAdmins(string $message, \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, (array|null) $replyMarkup = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $noWebpage = false, ?\Amp\Cancellation $cancellation = NULL): list<\danog\MadelineProto\EventHandler\Message>` + +Sends a message to all report peers (admins of the bot). + + +Parameters: + +* `$message`: `string` Message to send +* `$parseMode`: `\danog\MadelineProto\ParseMode` Parse mode +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$noWebpage`: `boolean` Set this flag to disable generation of the webpage preview +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) + + + + +### `sendPhoto((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, bool $spoiler = false, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, bool $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a photo. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$spoiler`: `bool` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `bool` +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendSticker((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $mimeType, string $emoji = '', array $stickerSet = [ '_' => 'inputStickerSetEmpty',], ?callable $callback = NULL, ?string $fileName = NULL, ?int $ttl = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $updateStickersetsOrder = false, boolean $forceResend = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a sticker. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$mimeType`: `string` +* `$emoji`: `string` +* `$stickerSet`: `array` +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `?int` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$updateStickersetsOrder`: `boolean` Whether to move used stickersets to top +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `sendVideo((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null) $thumb = NULL, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, string $mimeType = 'video/mp4', (integer|null) $ttl = NULL, boolean $spoiler = false, boolean $roundMessage = false, boolean $supportsStreaming = true, boolean $noSound = false, (integer|null) $duration = NULL, (integer|null) $width = NULL, (integer|null) $height = NULL, string $thumbSeek = '00:00:01.000', (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, bool $updateStickersetsOrder = false, \Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a video. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$thumb`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|null)` Optional: Thumbnail to upload +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$mimeType`: `string` +* `$ttl`: `(integer|null)` Time to live +* `$spoiler`: `boolean` Whether the message is a spoiler +* `$roundMessage`: `boolean` Whether the message should be round +* `$supportsStreaming`: `boolean` Whether the video supports streaming +* `$noSound`: `boolean` Whether the video has no sound +* `$duration`: `(integer|null)` Duration of the video +* `$width`: `(integer|null)` Width of the video +* `$height`: `(integer|null)` Height of the video +* `$thumbSeek`: `string` +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$updateStickersetsOrder`: `bool` +* `$cancellation`: `\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `sendVoice((integer|string) $peer, (\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream) $file, string $caption = '', \danog\MadelineProto\ParseMode $parseMode = \danog\MadelineProto\ParseMode::TEXT, ?callable $callback = NULL, ?string $fileName = NULL, (integer|null) $ttl = NULL, (integer|null) $duration = NULL, (array|null) $waveform = NULL, (integer|null) $replyToMsgId = NULL, (integer|null) $topMsgId = NULL, (array|null) $replyMarkup = NULL, (integer|string|null) $sendAs = NULL, (integer|null) $scheduleDate = NULL, boolean $silent = false, boolean $noForwards = false, boolean $background = false, boolean $clearDraft = false, boolean $forceResend = false, ?\Amp\Cancellation $cancellation = NULL): \danog\MadelineProto\EventHandler\Message` + +Sends a voice. + +Please use named arguments to call this method. + + +Parameters: + +* `$peer`: `(integer|string)` Destination peer or username. +* `$file`: `(\danog\MadelineProto\EventHandler\Message|\danog\MadelineProto\EventHandler\Media|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream)` File to upload: can be a message to reuse media present in a message. +* `$caption`: `string` Caption of document +* `$parseMode`: `\danog\MadelineProto\ParseMode` Text parse mode for the caption +* `$callback`: `?callable` +* `$fileName`: `?string` Optional file name, if absent will be extracted from the passed $file. +* `$ttl`: `(integer|null)` Time to live +* `$duration`: `(integer|null)` Duration of the voice +* `$waveform`: `(array|null)` Waveform of the voice +* `$replyToMsgId`: `(integer|null)` ID of message to reply to. +* `$topMsgId`: `(integer|null)` ID of thread where to send the message. +* `$replyMarkup`: `(array|null)` Keyboard information. +* `$sendAs`: `(integer|string|null)` Peer to send the message as. +* `$scheduleDate`: `(integer|null)` Schedule date. +* `$silent`: `boolean` Whether to send the message silently, without triggering notifications. +* `$noForwards`: `boolean` Whether to disable forwards for this message. +* `$background`: `boolean` Send this message as background message +* `$clearDraft`: `boolean` Clears the draft field +* `$forceResend`: `boolean` Whether to forcefully resend the file, even if its type and name are the same. +* `$cancellation`: `?\Amp\Cancellation` Cancellation. + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/Message.html) +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* [`\danog\MadelineProto\ParseMode`: Indicates a parsing mode for text.](../../danog/MadelineProto/ParseMode.html) +* `\Amp\Cancellation` + + + + +### `setNoop(): void` + +Set NOOP update handler, ignoring all updates. + + + +### `setReportPeers((int|string|array<(int|string)>) $userOrId): void` + +Set peer(s) where to send errors occurred in the event loop. + + +Parameters: + +* `$userOrId`: `(int|string|array<(int|string)>)` Username(s) or peer ID(s) + + + +### `setWebhook(string $webhookUrl): void` + +Set webhook update handler. + + +Parameters: + +* `$webhookUrl`: `string` Webhook URL + + + +### `skipPlay(int $id): void` + +When called, skips to the next file in the playlist. + + +Parameters: + +* `$id`: `int` + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `start(): array` + +Log in to telegram (via CLI or web). + + + +### `stop(): void` + +Stop update loop. + + + +### `stopPlay(int $id): void` + +Stops playing all files in the call, clears the main and the hold playlist. + + +Parameters: + +* `$id`: `int` + + + +### `stringToStream(string $str): \Amp\ByteStream\ReadableBuffer` + +Converts a string into an async amphp stream. + + +Parameters: + +* `$str`: `string` + + +#### See also: +* `\Amp\ByteStream\ReadableBuffer` + + + + +### `subscribeToUpdates(mixed $channel): bool` + +Subscribe to event handler updates for a channel/supergroup we're not a member of. + + +Parameters: + +* `$channel`: `mixed` Channel/supergroup to subscribe to + + +Return value: False if we were already subscribed + + +### `tdToMTProto(array $params): array` + +Convert TD to MTProto parameters. + + +Parameters: + +* `$params`: `array` Parameters + + + +### `tdToTdcli(mixed $params): array` + +Convert TD parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Parameters + + + +### `tdcliToTd(mixed $params, array $key = NULL): array` + +Convert tdcli parameters to tdcli. + + +Parameters: + +* `$params`: `mixed` Params +* `$key`: `array` Key + + + +### `testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}` + +Test fibers. + + +Parameters: + +* `$fiberCount`: `int` + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `unpackDouble(string $value): float` + +Unpack binary double. + + +Parameters: + +* `$value`: `string` Value to unpack + + + +### `unpackFileId(string $fileId): array` + +Unpack bot API file ID. + + +Parameters: + +* `$fileId`: `string` Bot API file ID + + +Return value: Unpacked file ID + + +### `unpackSignedInt(string $value): int` + +Unpack base256 signed int. + + +Parameters: + +* `$value`: `string` base256 int + + + +### `unpackSignedLong(string $value): int` + +Unpack base256 signed long. + + +Parameters: + +* `$value`: `string` base256 long + + + +### `unpackSignedLongString((string|int|array) $value): string` + +Unpack base256 signed long to string. + + +Parameters: + +* `$value`: `(string|int|array)` base256 long + + + +### `unsetEventHandler(): void` + +Unset event handler. + + + +### `update2fa(array{password?: string, new_password?: string, email?: string, hint?: string} $params): void` + +Update the 2FA password. + +The params array can contain password, new_password, email and hint params. + + +Parameters: + +* `$params`: `array{password?: string, new_password?: string, email?: string, hint?: string}` The params + + + +### `updateSettings(\danog\MadelineProto\SettingsAbstract $settings): void` + +Parse, update and store settings. + + +Parameters: + +* `$settings`: `\danog\MadelineProto\SettingsAbstract` Settings + + +#### See also: +* `\danog\MadelineProto\SettingsAbstract` + + + + +### `upload((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource) $file, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|\Amp\ByteStream\ReadableStream|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `\Amp\ByteStream\ReadableStream` +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadEncrypted((\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource) $file, string $fileName = '', callable $cb = NULL, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file to secret chat. + + +Parameters: + +* `$file`: `(\danog\MadelineProto\FileCallbackInterface|\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\danog\MadelineProto\BotApiFileId|string|array|resource)` File, URL or Telegram file to upload +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\BotApiFileId`: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](../../danog/MadelineProto/BotApiFileId.html) +* `resource` +* `\Amp\Cancellation` + + + + +### `uploadFromCallable(callable(int, int, ?Cancellation): strin) $callable, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable(float, float, float): voi) $cb = NULL, boolean $seekable = true, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from callable. + +The callable must accept two parameters: int $offset, int $size +The callable must return a string with the contest of the file at the specified offset and size. + + +Parameters: + +* `$callable`: `callable(int, int, ?Cancellation): strin)` Callable (offset, length) => data +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable(float, float, float): voi)` Status callback +* `$seekable`: `boolean` Whether chunks can be fetched out of order +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromStream(mixed $stream, integer $size = 0, string $mime = 'application/octet-stream', string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from stream. + + +Parameters: + +* `$stream`: `mixed` PHP resource or AMPHP async stream +* `$size`: `integer` File size +* `$mime`: `string` Mime type +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromTgfile(mixed $media, callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Reupload telegram file. + + +Parameters: + +* `$media`: `mixed` Telegram file +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* `\Amp\Cancellation` + + + + +### `uploadFromUrl((string|\danog\MadelineProto\FileCallbackInterface) $url, integer $size = 0, string $fileName = '', callable $cb = NULL, boolean $encrypted = false, ?\Amp\Cancellation $cancellation = NULL): array` + +Upload file from URL. + + +Parameters: + +* `$url`: `(string|\danog\MadelineProto\FileCallbackInterface)` URL of file +* `$size`: `integer` Size of file +* `$fileName`: `string` File name +* `$cb`: `callable` Callback +* `$encrypted`: `boolean` Whether to encrypt file for secret chats +* `$cancellation`: `?\Amp\Cancellation` + + +Return value: InputFile constructor + +#### See also: +* [`\danog\MadelineProto\FileCallbackInterface`: File callback interface.](../../danog/MadelineProto/FileCallbackInterface.html) +* `\Amp\Cancellation` + + + + +### `validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>` + +Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` Class name + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) +* [`\danog\MadelineProto\EventHandlerIssue`: Represents an event handler issue.](../../danog/MadelineProto/EventHandlerIssue.html) + + + + +### `viewSponsoredMessage((int|array) $peer, (string|array{random_id: string}) $message): bool` + +Mark sponsored message as read. + + +Parameters: + +* `$peer`: `(int|array)` Channel ID, or Update, or Message, or Peer. +* `$message`: `(string|array{random_id: string})` Random ID or sponsored message to mark as read. + + + +### `wrapMedia(array $media, bool $protected = false): ?\danog\MadelineProto\EventHandler\Media` + +Wrap a media constructor into an abstract Media object. + + +Parameters: + +* `$media`: `array` +* `$protected`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Media`: Represents a generic media.](../../danog/MadelineProto/EventHandler/Media.html) + + + + +### `wrapMessage(array $message, bool $scheduled = false): ?\danog\MadelineProto\EventHandler\AbstractMessage` + +Wrap a Message constructor into an abstract Message object. + + +Parameters: + +* `$message`: `array` +* `$scheduled`: `bool` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\AbstractMessage`: Represents an incoming or outgoing message.](../../danog/MadelineProto/EventHandler/AbstractMessage.html) + + + + +### `wrapPin(array $message): ?\danog\MadelineProto\EventHandler\Pinned` + +Wrap a Pin constructor into an abstract Pinned object. + + +Parameters: + +* `$message`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Pinned`: Indicates that some messages were pinned/unpinned.](../../danog/MadelineProto/EventHandler/Pinned.html) + + + + +### `wrapUpdate(array $update): ?\danog\MadelineProto\EventHandler\Update` + +Wrap an Update constructor into an abstract Update object. + + +Parameters: + +* `$update`: `array` + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Update`: Represents a generic update.](../../danog/MadelineProto/EventHandler/Update.html) + + + + +### `initDbProperties(\danog\AsyncOrm\Settings $settings, string $tablePrefix): void` + +Initialize database properties. + + +Parameters: + +* `$settings`: `\danog\AsyncOrm\Settings` +* `$tablePrefix`: `string` + + +#### See also: +* `\danog\AsyncOrm\Settings` + + + + +### `saveDbProperties(): void` + +Save all properties. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/StrTools.md b/docs/PHP/danog/MadelineProto/StrTools.md new file mode 100644 index 0000000000..dc3eb20816 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/StrTools.md @@ -0,0 +1,279 @@ +--- +title: "danog\\MadelineProto\\StrTools: Some tools." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\StrTools` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Some tools. + + + + +## Constants +* `danog\MadelineProto\StrTools::ALL_MIMES`: + + +## Method list: +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) + +## Methods: +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/Conversion/Exception.md b/docs/PHP/danog/MadelineProto/TL/Conversion/Exception.md new file mode 100644 index 0000000000..c7a8378e2c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/Conversion/Exception.md @@ -0,0 +1,136 @@ +--- +title: "danog\\MadelineProto\\TL\\Conversion\\Exception: TL conversion exception." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\Conversion\Exception` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +TL conversion exception. + + + +## Properties +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct(mixed $message, mixed $file = '')`](#__construct) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct(mixed $message, mixed $file = '')` + + + + +Parameters: + +* `$message`: `mixed` +* `$file`: `mixed` + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/Conversion/Extension.md b/docs/PHP/danog/MadelineProto/TL/Conversion/Extension.md new file mode 100644 index 0000000000..e31c0fb157 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/Conversion/Extension.md @@ -0,0 +1,89 @@ +--- +title: "danog\\MadelineProto\\TL\\Conversion\\Extension: Manages generation of extensions for files." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\Conversion\Extension` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Manages generation of extensions for files. + + + + +## Constants +* `danog\MadelineProto\TL\Conversion\Extension::ALL_MIMES`: + + +## Method list: +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) + +## Methods: +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/Exception.md b/docs/PHP/danog/MadelineProto/TL/Exception.md new file mode 100644 index 0000000000..61d447d8a2 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/Exception.md @@ -0,0 +1,136 @@ +--- +title: "danog\\MadelineProto\\TL\\Exception: TL deserialization exception." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\Exception` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +TL deserialization exception. + + + +## Properties +* `$tlTrace`: `string` TL trace. + +## Method list: +* [`__construct(mixed $message, mixed $file = '')`](#__construct) +* [`getMessage(): string`](#getMessage) +* [`getCode()`](#getCode) +* [`getFile(): string`](#getFile) +* [`getLine(): int`](#getLine) +* [`getTrace(): array`](#getTrace) +* [`getPrevious(): ?Throwable`](#getPrevious) +* [`getTraceAsString(): string`](#getTraceAsString) +* [`updateTLTrace(array $trace): void`](#updateTLTrace) +* [`getTLTrace(): string`](#getTLTrace) +* [`setTLTrace(string $tlTrace): void`](#setTLTrace) +* [`prettifyTL(string $init = '', array $trace = NULL): void`](#prettifyTL) + +## Methods: +### `__construct(mixed $message, mixed $file = '')` + + + + +Parameters: + +* `$message`: `mixed` +* `$file`: `mixed` + + + +### `getMessage(): string` + + + + + +### `getCode()` + + + + + +### `getFile(): string` + + + + + +### `getLine(): int` + + + + + +### `getTrace(): array` + + + + + +### `getPrevious(): ?Throwable` + + + + +#### See also: +* `Throwable` + + + + +### `getTraceAsString(): string` + + + + + +### `updateTLTrace(array $trace): void` + +Update TL trace. + + +Parameters: + +* `$trace`: `array` + + + +### `getTLTrace(): string` + +Get TL trace. + + + +### `setTLTrace(string $tlTrace): void` + +Set TL trace. + + +Parameters: + +* `$tlTrace`: `string` TL trace + + + +### `prettifyTL(string $init = '', array $trace = NULL): void` + +Generate async trace. + + +Parameters: + +* `$init`: `string` Method name +* `$trace`: `array` Async trace + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/TLInterface.md b/docs/PHP/danog/MadelineProto/TL/TLInterface.md new file mode 100644 index 0000000000..fdd11faafd --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/TLInterface.md @@ -0,0 +1,139 @@ +--- +title: "danog\\MadelineProto\\TL\\TLInterface: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\TLInterface` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Method list: +* [`getConstructors(): \danog\MadelineProto\TL\TLConstructors`](#getConstructors) +* [`getMethods(): \danog\MadelineProto\TL\TLMethods`](#getMethods) +* [`getDescriptions(): array`](#getDescriptions) +* [`getMethodNamespaces(): array`](#getMethodNamespaces) +* [`getMethodsNamespaced(): array`](#getMethodsNamespaced) +* [`serializeObject(array $type, mixed $object, string $ctx, integer $layer = -1)`](#serializeObject) +* [`serializeMethod(string $method, mixed $arguments)`](#serializeMethod) +* [`getLength((resource|string) $stream, array $type = [ 'type' => '',]): int`](#getLength) +* [`deserialize((string|resource) $stream, array $type)`](#deserialize) +* [`getSecretLayer(): int`](#getSecretLayer) + +## Methods: +### `getConstructors(): \danog\MadelineProto\TL\TLConstructors` + +Get constructors. + + +#### See also: +* `\danog\MadelineProto\TL\TLConstructors` + + + + +### `getMethods(): \danog\MadelineProto\TL\TLMethods` + +Get methods. + + +#### See also: +* `\danog\MadelineProto\TL\TLMethods` + + + + +### `getDescriptions(): array` + +Get descriptions. + + + +### `getMethodNamespaces(): array` + +Get TL namespaces. + + + +### `getMethodsNamespaced(): array` + +Get namespaced methods (method => namespace). + + + +### `serializeObject(array $type, mixed $object, string $ctx, integer $layer = -1)` + +Serialize TL object. + + +Parameters: + +* `$type`: `array` TL type definition +* `$object`: `mixed` Object to serialize +* `$ctx`: `string` Context +* `$layer`: `integer` Layer version + + + +### `serializeMethod(string $method, mixed $arguments)` + +Serialize method. + + +Parameters: + +* `$method`: `string` Method name +* `$arguments`: `mixed` Arguments + + + +### `getLength((resource|string) $stream, array $type = [ 'type' => '',]): int` + +Get length of TL payload. + + +Parameters: + +* `$stream`: `(resource|string)` Stream +* `$type`: `array` Type identifier + + +#### See also: +* `resource` + + + + +### `deserialize((string|resource) $stream, array $type)` + +Deserialize TL object. + + +Parameters: + +* `$stream`: `(string|resource)` Stream +* `$type`: `array` Type identifier + + +#### See also: +* `resource` + + + + +### `getSecretLayer(): int` + +Get secret chat layer version. + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/Types/Button.md b/docs/PHP/danog/MadelineProto/TL/Types/Button.md new file mode 100644 index 0000000000..cff1037df6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/Types/Button.md @@ -0,0 +1,93 @@ +--- +title: "danog\\MadelineProto\\TL\\Types\\Button: Clickable button." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\Types\Button` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Clickable button. + + + +## Properties +* `$label`: `string` Button label + +## Method list: +* [`click(boolean $donotwait = true)`](#click) +* [`jsonSerialize(): array`](#jsonSerialize) +* [`offsetSet(mixed $name, mixed $value): void`](#offsetSet) +* [`offsetGet(mixed $name): mixed`](#offsetGet) +* [`offsetUnset(mixed $name): void`](#offsetUnset) +* [`offsetExists(mixed $name): bool`](#offsetExists) + +## Methods: +### `click(boolean $donotwait = true)` + +Click on button. + + +Parameters: + +* `$donotwait`: `boolean` Whether to wait for the result of the method + + + +### `jsonSerialize(): array` + +Serialize button. + + + +### `offsetSet(mixed $name, mixed $value): void` + +Set button info. + + +Parameters: + +* `$name`: `mixed` Offset +* `$value`: `mixed` Value + + + +### `offsetGet(mixed $name): mixed` + +Get button info. + + +Parameters: + +* `$name`: `mixed` Field name + + + +### `offsetUnset(mixed $name): void` + +Unset button info. + + +Parameters: + +* `$name`: `mixed` Offset + + + +### `offsetExists(mixed $name): bool` + +Check if button field exists. + + +Parameters: + +* `$name`: `mixed` Offset + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/Types/Bytes.md b/docs/PHP/danog/MadelineProto/TL/Types/Bytes.md new file mode 100644 index 0000000000..ae626ea5ca --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/Types/Bytes.md @@ -0,0 +1,93 @@ +--- +title: "danog\\MadelineProto\\TL\\Types\\Bytes: Bytes wrapper." +description: "\nCast this object to a string ((string) $bytes) to obtain the inner bytes.\n" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\Types\Bytes` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Bytes wrapper. + + +Cast this object to a string ((string) $bytes) to obtain the inner bytes. + + + +## Method list: +* [`__construct(string $bytes)`](#__construct) +* [`jsonSerialize(): array`](#jsonSerialize) +* [`offsetSet((integer|null) $offset, string $value): void`](#offsetSet) +* [`offsetGet(integer $offset): string`](#offsetGet) +* [`offsetUnset(integer $offset): void`](#offsetUnset) +* [`offsetExists(integer $offset): bool`](#offsetExists) + +## Methods: +### `__construct(string $bytes)` + +Constructor function. + + +Parameters: + +* `$bytes`: `string` Contents + + + +### `jsonSerialize(): array` + +Obtain values for JSON-encoding. + + + +### `offsetSet((integer|null) $offset, string $value): void` + +Set char at offset. + + +Parameters: + +* `$offset`: `(integer|null)` Offset +* `$value`: `string` Char + + + +### `offsetGet(integer $offset): string` + +Get char at offset. + + +Parameters: + +* `$offset`: `integer` Name + + + +### `offsetUnset(integer $offset): void` + +Unset char at offset. + + +Parameters: + +* `$offset`: `integer` Offset + + + +### `offsetExists(integer $offset): bool` + +Check if char at offset exists. + + +Parameters: + +* `$offset`: `integer` Offset + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TL/Types/LoginQrCode.md b/docs/PHP/danog/MadelineProto/TL/Types/LoginQrCode.md new file mode 100644 index 0000000000..26e4701c2c --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TL/Types/LoginQrCode.md @@ -0,0 +1,122 @@ +--- +title: "danog\\MadelineProto\\TL\\Types\\LoginQrCode: Represents a login QR code." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TL\Types\LoginQrCode` +[Back to index](../../../../index.html) + +> Author: Daniil Gentili + + +Represents a login QR code. + + + +## Properties +* `$link`: `non-empty-string` The [QR code login link](https://core.telegram.org/api/links#qr-code-login-links) +* `$expiry`: `positive-int` The expiry date of the link + +## Method list: +* [`isExpired(): bool`](#isExpired) +* [`expiresIn(): non-negative-int`](#expiresIn) +* [`getExpirationCancellation(): \Amp\Cancellation`](#getExpirationCancellation) +* [`getLoginCancellation(): \Amp\Cancellation`](#getLoginCancellation) +* [`waitForLoginOrQrCodeExpiration((\Amp\Cancellation|null) $customCancellation = NULL): ?self`](#waitForLoginOrQrCodeExpiration) +* [`getQRSvg(int $size = 400, int $margin = 4): string`](#getQRSvg) +* [`getQRText(non-negative-int $margin = 2): string`](#getQRText) + +## Methods: +### `isExpired(): bool` + +Returns true if the QR code has expired and a new one should be fetched. + + + +### `expiresIn(): non-negative-int` + +Returns the number of seconds until the QR code expires. + + +#### See also: +* `non-negative-int` + + + + +### `getExpirationCancellation(): \Amp\Cancellation` + + + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getLoginCancellation(): \Amp\Cancellation` + + + + +#### See also: +* `\Amp\Cancellation` + + + + +### `waitForLoginOrQrCodeExpiration((\Amp\Cancellation|null) $customCancellation = NULL): ?self` + +Waits for the user to login or for the QR code to expire. + +If the user logins, null is returned. + +If the QR code expires, the new QR code is returned. + +If cancellation is requested externally through $cancellation, a CancelledException is thrown. + + +Parameters: + +* `$customCancellation`: `(\Amp\Cancellation|null)` Optional additional cancellation + + +#### See also: +* `\Amp\Cancellation` + + + + +### `getQRSvg(int $size = 400, int $margin = 4): string` + +Render and return SVG version of QR code. + + +Parameters: + +* `$size`: `int` +* `$margin`: `int` + + + +### `getQRText(non-negative-int $margin = 2): string` + +Render and return plain text version of QR code. + + +Parameters: + +* `$margin`: `non-negative-int` Text margin + + +#### See also: +* `non-negative-int` + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/TextEntities.md b/docs/PHP/danog/MadelineProto/TextEntities.md new file mode 100644 index 0000000000..9ffe22a69b --- /dev/null +++ b/docs/PHP/danog/MadelineProto/TextEntities.md @@ -0,0 +1,67 @@ +--- +title: "danog\\MadelineProto\\TextEntities: Class that converts HTML or markdown to a message + set of entities." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\TextEntities` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Class that converts HTML or markdown to a message + set of entities. + + + +## Properties +* `$message`: `string` Converted message +* `$entities`: `list` Converted entities. + +## Method list: +* [`__construct(string $message, array $entities)`](#__construct) +* [`fromMarkdown(string $markdown): self`](#fromMarkdown) +* [`fromHtml(string $html): self`](#fromHtml) + +## Methods: +### `__construct(string $message, array $entities)` + +Creates an Entities container using a message and a list of entities. + + +Parameters: + +* `$message`: `string` +* `$entities`: `array` + + + +### `fromMarkdown(string $markdown): self` + +Manually convert markdown to a message and a set of entities. + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + + +### `fromHtml(string $html): self` + +Manually convert HTML to a message and a set of entities. + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/Tools.md b/docs/PHP/danog/MadelineProto/Tools.md new file mode 100644 index 0000000000..b6b5182c63 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/Tools.md @@ -0,0 +1,779 @@ +--- +title: "danog\\MadelineProto\\Tools: Some tools." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\Tools` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +Some tools. + + + + +## Constants +* `danog\MadelineProto\Tools::ALL_MIMES`: + + +## Method list: +* [`testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}`](#testFibers) +* [`getMaps(): ?int`](#getMaps) +* [`getMaxMaps(): ?int`](#getMaxMaps) +* [`stringToStream(string $str): \Amp\ByteStream\ReadableBuffer`](#stringToStream) +* [`genVectorHash(array $longs): string`](#genVectorHash) +* [`randomInt(integer $modulus = 0): int`](#randomInt) +* [`random(integer $length): string`](#random) +* [`posmod(int $a, int $b): int`](#posmod) +* [`unpackSignedInt(string $value): int`](#unpackSignedInt) +* [`unpackSignedLong(string $value): int`](#unpackSignedLong) +* [`unpackSignedLongString((string|int|array) $value): string`](#unpackSignedLongString) +* [`packSignedInt(integer $value): string`](#packSignedInt) +* [`packSignedLong(int $value): string`](#packSignedLong) +* [`packUnsignedInt(int $value): string`](#packUnsignedInt) +* [`packDouble(float $value): string`](#packDouble) +* [`unpackDouble(string $value): float`](#unpackDouble) +* [`isArrayOrAlike(mixed $var): bool`](#isArrayOrAlike) +* [`arr(mixed ...$params): array`](#arr) +* [`base64urlDecode(string $data): string`](#base64urlDecode) +* [`base64urlEncode(string $data): string`](#base64urlEncode) +* [`rleDecode(string $string): string`](#rleDecode) +* [`rleEncode(string $string): string`](#rleEncode) +* [`inflateStripped(string $stripped): string`](#inflateStripped) +* [`closeConnection(string $message): void`](#closeConnection) +* [`end(array $what): T`](#end) +* [`isAltervista(): bool`](#isAltervista) +* [`openFileAppendOnly(string $path): \Amp\File\File`](#openFileAppendOnly) +* [`getStreamPipe(): \Amp\ByteStream\Pipe`](#getStreamPipe) +* [`openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string`](#openBuffered) +* [`validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>`](#validateEventHandlerClass) +* [`canConvertOgg(): bool`](#canConvertOgg) +* [`canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool`](#canUseFFmpeg) +* [`rethrow(\Throwable $e): void`](#rethrow) +* [`callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future`](#callFork) +* [`flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))`](#flock) +* [`sleep(float $time): void`](#sleep) +* [`readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string`](#readLine) +* [`echo(string $string): void`](#echo) +* [`mbStrlen(string $text): int`](#mbStrlen) +* [`mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string`](#mbSubstr) +* [`mbStrSplit(string $text, integer $length): array`](#mbStrSplit) +* [`htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities`](#htmlToMessageEntities) +* [`markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities`](#markdownToMessageEntities) +* [`entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string`](#entitiesToHtml) +* [`toCamelCase(string $input): string`](#toCamelCase) +* [`toSnakeCase(string $input): string`](#toSnakeCase) +* [`htmlEscape(string $what): string`](#htmlEscape) +* [`markdownEscape(string $what): string`](#markdownEscape) +* [`markdownCodeblockEscape(string $what): string`](#markdownCodeblockEscape) +* [`markdownCodeEscape(string $what): string`](#markdownCodeEscape) +* [`markdownUrlEscape(string $what): string`](#markdownUrlEscape) +* [`getMimeFromExtension(string $extension, string $default): string`](#getMimeFromExtension) +* [`getExtensionFromMime(string $mime): string`](#getExtensionFromMime) +* [`getExtensionFromLocation(mixed $location, string $default): string`](#getExtensionFromLocation) +* [`getMimeFromFile(string $file): string`](#getMimeFromFile) +* [`getMimeFromBuffer(string $buffer): string`](#getMimeFromBuffer) + +## Methods: +### `testFibers(int $fiberCount = 100000): array{maxFibers: int, realMemoryMb: int, maps: ?int, maxMaps: ?int}` + +Test fibers. + + +Parameters: + +* `$fiberCount`: `int` + + + +### `getMaps(): ?int` + +Get current number of memory-mapped regions, UNIX only. + + + +### `getMaxMaps(): ?int` + +Get maximum number of memory-mapped regions, UNIX only. +Use testFibers to get the maximum number of fibers on any platform. + + + +### `stringToStream(string $str): \Amp\ByteStream\ReadableBuffer` + +Converts a string into an async amphp stream. + + +Parameters: + +* `$str`: `string` + + +#### See also: +* `\Amp\ByteStream\ReadableBuffer` + + + + +### `genVectorHash(array $longs): string` + +Generate MTProto vector hash. + +Returns a vector hash. + + +Parameters: + +* `$longs`: `array` IDs + + + +### `randomInt(integer $modulus = 0): int` + +Get random integer. + + +Parameters: + +* `$modulus`: `integer` Modulus + + + +### `random(integer $length): string` + +Get secure random string of specified length. + + +Parameters: + +* `$length`: `integer` Length + + + +### `posmod(int $a, int $b): int` + +Positive modulo +Works just like the % (modulus) operator, only returns always a postive number. + + +Parameters: + +* `$a`: `int` A +* `$b`: `int` B + + + +### `unpackSignedInt(string $value): int` + +Unpack base256 signed int. + + +Parameters: + +* `$value`: `string` base256 int + + + +### `unpackSignedLong(string $value): int` + +Unpack base256 signed long. + + +Parameters: + +* `$value`: `string` base256 long + + + +### `unpackSignedLongString((string|int|array) $value): string` + +Unpack base256 signed long to string. + + +Parameters: + +* `$value`: `(string|int|array)` base256 long + + + +### `packSignedInt(integer $value): string` + +Convert integer to base256 signed int. + + +Parameters: + +* `$value`: `integer` Value to convert + + + +### `packSignedLong(int $value): string` + +Convert integer to base256 long. + + +Parameters: + +* `$value`: `int` Value to convert + + + +### `packUnsignedInt(int $value): string` + +Convert value to unsigned base256 int. + + +Parameters: + +* `$value`: `int` Value + + + +### `packDouble(float $value): string` + +Convert double to binary version. + + +Parameters: + +* `$value`: `float` Value to convert + + + +### `unpackDouble(string $value): float` + +Unpack binary double. + + +Parameters: + +* `$value`: `string` Value to unpack + + + +### `isArrayOrAlike(mixed $var): bool` + +Check if is array or similar (traversable && countable && arrayAccess). + + +Parameters: + +* `$var`: `mixed` Value to check + + + +### `arr(mixed ...$params): array` + +Create array. + + +Parameters: + +* `...$params`: `mixed` Params + + + +### `base64urlDecode(string $data): string` + +base64URL decode. + + +Parameters: + +* `$data`: `string` Data to decode + + + +### `base64urlEncode(string $data): string` + +Base64URL encode. + + +Parameters: + +* `$data`: `string` Data to encode + + + +### `rleDecode(string $string): string` + +null-byte RLE decode. + + +Parameters: + +* `$string`: `string` Data to decode + + + +### `rleEncode(string $string): string` + +null-byte RLE encode. + + +Parameters: + +* `$string`: `string` Data to encode + + + +### `inflateStripped(string $stripped): string` + +Inflate stripped photosize to full JPG payload. + + +Parameters: + +* `$stripped`: `string` Stripped photosize + + + +### `closeConnection(string $message): void` + +Close connection with client, connected via web. + + +Parameters: + +* `$message`: `string` Message + + + +### `end(array $what): T` + +Get final element of array. + + +Parameters: + +* `$what`: `array` Array + + + +### `isAltervista(): bool` + +Whether this is altervista. + + + +### `openFileAppendOnly(string $path): \Amp\File\File` + +Opens a file in append-only mode. + + +Parameters: + +* `$path`: `string` File path. + + +#### See also: +* `\Amp\File\File` + + + + +### `getStreamPipe(): \Amp\ByteStream\Pipe` + +Obtains a pipe that can be used to upload a file from a stream. + + +#### See also: +* `\Amp\ByteStream\Pipe` + + + + +### `openBuffered(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $stream, ?\Amp\Cancellation $cancellation = NULL): Closure(int): ?string` + +Provide a buffered reader for a file, URL or amp stream. + + +Parameters: + +* `$stream`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` +* `\Amp\Cancellation` + + + + +### `validateEventHandlerClass(class-string<\danog\MadelineProto\EventHandler> $class): list<\danog\MadelineProto\EventHandlerIssue>` + +Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements. + + +Parameters: + +* `$class`: `class-string<\danog\MadelineProto\EventHandler>` Class name + + +#### See also: +* [`\danog\MadelineProto\EventHandler`: Event handler.](../../danog/MadelineProto/EventHandler.html) +* [`\danog\MadelineProto\EventHandlerIssue`: Represents an event handler issue.](../../danog/MadelineProto/EventHandlerIssue.html) + + + + +### `canConvertOgg(): bool` + +Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot. + + + +### `canUseFFmpeg(?\Amp\Cancellation $cancellation = NULL): bool` + +Whether we can convert any audio/video file using ffmpeg. + + +Parameters: + +* `$cancellation`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `rethrow(\Throwable $e): void` + +Rethrow exception into event loop. + + +Parameters: + +* `$e`: `\Throwable` + + +#### See also: +* `\Throwable` + + + + +### `callFork(\Generator|\Amp\Future|callable $callable, mixed ...$args): \Amp\Future` + +Fork a new green thread and execute the passed function in the background. + + +Parameters: + +* `$callable`: `\Generator|\Amp\Future|callable` +* `...$args`: `mixed` Arguments forwarded to the function when forking the thread. + + +#### See also: +* `\Generator` +* `\Amp\Future` + + + + +### `flock(string $file, integer $operation, float $polling = 0.1, ?\Amp\Cancellation $token = NULL, ?\Closure $failureCb = NULL): ($token is null ? Closure(): void : (Closure(): void | null))` + +Asynchronously lock a file +Resolves with a callbable that MUST eventually be called in order to release the lock. + + +Parameters: + +* `$file`: `string` File to lock +* `$operation`: `integer` Locking mode +* `$polling`: `float` Polling interval +* `$token`: `?\Amp\Cancellation` Cancellation token +* `$failureCb`: `?\Closure` Failure callback, called only once if the first locking attempt fails. + + +#### See also: +* `\Amp\Cancellation` +* `\Closure` + + + + +### `sleep(float $time): void` + +Asynchronously sleep. + + +Parameters: + +* `$time`: `float` Number of seconds to sleep for + + + +### `readLine(string $prompt = '', ?\Amp\Cancellation $cancel = NULL): string` + +Asynchronously read line. + + +Parameters: + +* `$prompt`: `string` Prompt +* `$cancel`: `?\Amp\Cancellation` + + +#### See also: +* `\Amp\Cancellation` + + + + +### `echo(string $string): void` + +Asynchronously write to stdout/browser. + + +Parameters: + +* `$string`: `string` Message to echo + + + +### `mbStrlen(string $text): int` + +Get Telegram UTF-8 length of string. + + +Parameters: + +* `$text`: `string` Text + + + +### `mbSubstr(string $text, integer $offset, (null|int) $length = NULL): string` + +Telegram UTF-8 multibyte substring. + + +Parameters: + +* `$text`: `string` Text to substring +* `$offset`: `integer` Offset +* `$length`: `(null|int)` Length + + + +### `mbStrSplit(string $text, integer $length): array` + +Telegram UTF-8 multibyte split. + + +Parameters: + +* `$text`: `string` Text +* `$length`: `integer` Length + + + +### `htmlToMessageEntities(string $html): \danog\MadelineProto\TextEntities` + +Manually convert HTML to a message and a set of entities. + +NOTE: You don't have to use this method to send HTML messages. + +This method is already called automatically by using parse_mode: "HTML" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$html`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `markdownToMessageEntities(string $markdown): \danog\MadelineProto\TextEntities` + +Manually convert markdown to a message and a set of entities. + +NOTE: You don't have to use this method to send Markdown messages. + +This method is already called automatically by using parse_mode: "Markdown" in messages.sendMessage, messages.sendMedia, et cetera... + + +Parameters: + +* `$markdown`: `string` + + +Return value: Object containing message and entities + +#### See also: +* [https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMessage.html#usage-of-parse_mode) +* [`\danog\MadelineProto\TextEntities`: Class that converts HTML or markdown to a message + set of entities.](../../danog/MadelineProto/TextEntities.html) + + + + +### `entitiesToHtml(string $message, list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})> $entities, bool $allowTelegramTags = false): string` + +Convert a message and a set of entities to HTML. + + +Parameters: + +* `$message`: `string` +* `$entities`: `list<(\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity|array{_: string, offset: int, length: int})>` +* `$allowTelegramTags`: `bool` Whether to allow telegram-specific tags like tg-spoiler, tg-emoji, mention links and so on... + + +#### See also: +* [`\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity`: Master class for message entities.](../../danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) + + + + +### `toCamelCase(string $input): string` + +Convert to camelCase. + + +Parameters: + +* `$input`: `string` String + + + +### `toSnakeCase(string $input): string` + +Convert to snake_case. + + +Parameters: + +* `$input`: `string` String + + + +### `htmlEscape(string $what): string` + +Escape string for MadelineProto's HTML entity converter. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownEscape(string $what): string` + +Escape string for markdown. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeblockEscape(string $what): string` + +Escape string for markdown codeblock. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownCodeEscape(string $what): string` + +Escape string for markdown code section. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `markdownUrlEscape(string $what): string` + +Escape string for URL. + + +Parameters: + +* `$what`: `string` String to escape + + + +### `getMimeFromExtension(string $extension, string $default): string` + +Get mime type from file extension. + + +Parameters: + +* `$extension`: `string` File extension +* `$default`: `string` Default mime type + + + +### `getExtensionFromMime(string $mime): string` + +Get extension from mime type. + + +Parameters: + +* `$mime`: `string` MIME type + + + +### `getExtensionFromLocation(mixed $location, string $default): string` + +Get extension from file location. + + +Parameters: + +* `$location`: `mixed` File location +* `$default`: `string` Default extension + + + +### `getMimeFromFile(string $file): string` + +Get mime type of file. + + +Parameters: + +* `$file`: `string` File + + + +### `getMimeFromBuffer(string $buffer): string` + +Get mime type from buffer. + + +Parameters: + +* `$buffer`: `string` Buffer + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/VoIP.md b/docs/PHP/danog/MadelineProto/VoIP.md new file mode 100644 index 0000000000..484eff32d6 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/VoIP.md @@ -0,0 +1,200 @@ +--- +title: "danog\\MadelineProto\\VoIP: This update represents a VoIP Telegram call." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\VoIP` +[Back to index](../../index.html) + +> Author: Daniil Gentili + + +This update represents a VoIP Telegram call. + + + +## Properties +* `$callID`: `int` Phone call ID +* `$outgoing`: `bool` Whether the call is an outgoing call +* `$otherID`: `int` ID of the other user in the call +* `$date`: `int` When was the call created + +## Method list: +* [`accept(): self`](#accept) +* [`discard(\danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): self`](#discard) +* [`getVisualization(): ?list{string, string, string, string}`](#getVisualization) +* [`play(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): self`](#play) +* [`setOutput(\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): self`](#setOutput) +* [`then(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): self`](#then) +* [`skip(): self`](#skip) +* [`stop(): self`](#stop) +* [`pause(): self`](#pause) +* [`isPaused(): boolean`](#isPaused) +* [`resume(): self`](#resume) +* [`playOnHold(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): self`](#playOnHold) +* [`getCurrent(): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null`](#getCurrent) +* [`getCallState(): \danog\MadelineProto\VoIP\CallState`](#getCallState) + +## Methods: +### `accept(): self` + +Accept call. + + + +### `discard(\danog\MadelineProto\VoIP\DiscardReason $reason = \danog\MadelineProto\VoIP\DiscardReason::HANGUP, int<1, 5> $rating = NULL, string $comment = NULL): self` + +Discard call. + + +Parameters: + +* `$reason`: `\danog\MadelineProto\VoIP\DiscardReason` +* `$rating`: `int<1, 5>` Call rating in stars +* `$comment`: `string` Additional comment on call quality. + + +#### See also: +* [`\danog\MadelineProto\VoIP\DiscardReason`: Why was the call discarded?](../../danog/MadelineProto/VoIP/DiscardReason.html) + + + + +### `getVisualization(): ?list{string, string, string, string}` + +Get call emojis (will return null if the call is not inited yet). + + + +### `play(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): self` + +Play file. + + +Parameters: + +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `setOutput(\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream $file): self` + +Set output file or stream for incoming OPUS audio packets. + +Will write an OGG OPUS stream to the specified file or stream. + + +Parameters: + +* `$file`: `\danog\MadelineProto\LocalFile|\Amp\ByteStream\WritableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* `\Amp\ByteStream\WritableStream` + + + + +### `then(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream $file): self` + +Play file. + + +Parameters: + +* `$file`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `skip(): self` + +When called, skips to the next file in the playlist. + + + +### `stop(): self` + +Stops playing all files, clears the main and the hold playlist. + + + +### `pause(): self` + +Pauses the currently playing file. + + + +### `isPaused(): boolean` + +Whether the currently playing file is paused. + + + +### `resume(): self` + +Resumes the currently playing file. + + + +### `playOnHold(\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream ...$files): self` + +Files to play on hold. + + +Parameters: + +* `...$files`: `\danog\MadelineProto\LocalFile|\danog\MadelineProto\RemoteUrl|\Amp\ByteStream\ReadableStream` + + +#### See also: +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* `\Amp\ByteStream\ReadableStream` + + + + +### `getCurrent(): \danog\MadelineProto\RemoteUrl|\danog\MadelineProto\LocalFile|string|null` + +Get the file that is currently being played. + +Will return a string with the object ID of the stream if we're currently playing a stream, otherwise returns the related LocalFile or RemoteUrl. + + +#### See also: +* [`\danog\MadelineProto\RemoteUrl`: Indicates a remote URL to upload.](../../danog/MadelineProto/RemoteUrl.html) +* [`\danog\MadelineProto\LocalFile`: Indicates a local file to upload.](../../danog/MadelineProto/LocalFile.html) + + + + +### `getCallState(): \danog\MadelineProto\VoIP\CallState` + +Get call state. + + +#### See also: +* [\danog\MadelineProto\VoIP\CallState](../../danog/MadelineProto/VoIP/CallState.html) + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/VoIP/CallState.md b/docs/PHP/danog/MadelineProto/VoIP/CallState.md new file mode 100644 index 0000000000..e31ee029c8 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/VoIP/CallState.md @@ -0,0 +1,46 @@ +--- +title: "danog\\MadelineProto\\VoIP\\CallState: " +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\VoIP\CallState` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + + + + + + +## Constants +* `danog\MadelineProto\VoIP\CallState::REQUESTED`: The call was requested + +* `danog\MadelineProto\VoIP\CallState::INCOMING`: An incoming call + +* `danog\MadelineProto\VoIP\CallState::ACCEPTED`: The call was accepted + +* `danog\MadelineProto\VoIP\CallState::CONFIRMED`: The call was confirmed + +* `danog\MadelineProto\VoIP\CallState::RUNNING`: The call is ongoing + +* `danog\MadelineProto\VoIP\CallState::ENDED`: The call has ended + +## Properties +* `$name`: `string` + +## Method list: +* [`cases(): array`](#cases) + +## Methods: +### `cases(): array` + + + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/VoIP/DiscardReason.md b/docs/PHP/danog/MadelineProto/VoIP/DiscardReason.md new file mode 100644 index 0000000000..e1d2c3397a --- /dev/null +++ b/docs/PHP/danog/MadelineProto/VoIP/DiscardReason.md @@ -0,0 +1,67 @@ +--- +title: "danog\\MadelineProto\\VoIP\\DiscardReason: Why was the call discarded?" +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\VoIP\DiscardReason` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +Why was the call discarded? + + + + +## Constants +* `danog\MadelineProto\VoIP\DiscardReason::MISSED`: We missed the call + +* `danog\MadelineProto\VoIP\DiscardReason::DISCONNECTED`: The phone call was disconnected + +* `danog\MadelineProto\VoIP\DiscardReason::HANGUP`: The phone call ended normally + +* `danog\MadelineProto\VoIP\DiscardReason::BUSY`: The phone call was discarded because the user is busy in another call + +## Properties +* `$name`: `string` +* `$value`: `string` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/danog/MadelineProto/VoIP/VoIPState.md b/docs/PHP/danog/MadelineProto/VoIP/VoIPState.md new file mode 100644 index 0000000000..781a9efbb7 --- /dev/null +++ b/docs/PHP/danog/MadelineProto/VoIP/VoIPState.md @@ -0,0 +1,71 @@ +--- +title: "danog\\MadelineProto\\VoIP\\VoIPState: VoIP protcol state." +description: "" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +parent: "MadelineProto API" + +--- +# `danog\MadelineProto\VoIP\VoIPState` +[Back to index](../../../index.html) + +> Author: Daniil Gentili + + +VoIP protcol state. + + + + +## Constants +* `danog\MadelineProto\VoIP\VoIPState::CREATED`: + +* `danog\MadelineProto\VoIP\VoIPState::WAIT_INIT`: + +* `danog\MadelineProto\VoIP\VoIPState::WAIT_INIT_ACK`: + +* `danog\MadelineProto\VoIP\VoIPState::WAIT_PONG`: + +* `danog\MadelineProto\VoIP\VoIPState::WAIT_STREAM_INIT`: + +* `danog\MadelineProto\VoIP\VoIPState::ESTABLISHED`: + +## Properties +* `$name`: `string` +* `$value`: `int` + +## Method list: +* [`cases(): array`](#cases) +* [`from(string|int $value): static`](#from) +* [`tryFrom(string|int $value): ?static`](#tryFrom) + +## Methods: +### `cases(): array` + + + + + +### `from(string|int $value): static` + + + + +Parameters: + +* `$value`: `string|int` + + + +### `tryFrom(string|int $value): ?static` + + + + +Parameters: + +* `$value`: `string|int` + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it) diff --git a/docs/PHP/index.md b/docs/PHP/index.md new file mode 100644 index 0000000000..d0d53ea7d3 --- /dev/null +++ b/docs/PHP/index.md @@ -0,0 +1,372 @@ +--- +description: "MadelineProto PHP API reference" +title: "MadelineProto API" +image: "https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png" +has_children: "true" +has_toc: "false" +nav_order: "2" + +--- +# `danog/madelineproto` + +PHP implementation of telegram's MTProto protocol. + + +## Interfaces +* [\danog\MadelineProto\EventHandler\SimpleFilter\Ended: Represents an ended call](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Ended.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin: Allows messages from the bot admin](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdmin.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\FromAdminOrOutgoing: Allows messages from the bot admin or outgoing messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdminOrOutgoing.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasAudio: Allows only audio messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasAudio.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasDocument: Allows only documents](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocument.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasDocumentPhoto: Allows only document photos](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocumentPhoto.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasGif: Allows only GIFs](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasGif.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasMedia: Allows only media messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMedia.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasMultiplePoll: Allows only messages that contain a multiple poll](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMultiplePoll.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasNoMedia: Allows only messages with no media](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasNoMedia.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasPhoto: Allows only photos](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPhoto.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasPoll: Allows only messages that contain a poll](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPoll.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasQuizPoll: Allows only messages that contain a quiz poll](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasQuizPoll.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasRoundVideo: Allows only round videos](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasRoundVideo.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasSinglePoll: Allows only messages that contain a single poll](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSinglePoll.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasSticker: Allows only stickers](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSticker.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasTopic: Allow only messages coming from groups that has topics (Supergroups only).](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasTopic.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasVideo: Allows only videos](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVideo.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\HasVoice: Allows only voice messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVoice.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\Incoming: Represents an incoming message](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Incoming.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\IsEdited: Allows messages that were edited.](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsEdited.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\IsForwarded: Allows only forwarded messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsForwarded.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\IsNotEdited: Allows messages that weren't edited.](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsNotEdited.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\IsReply: Allows only messages that reply to other messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReply.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\IsReplyToSelf: Allows only messages that reply to one of our messages](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReplyToSelf.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\Outgoing: Represents an outgoing message](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Outgoing.html) +* [\danog\MadelineProto\EventHandler\SimpleFilter\Running: Allow only currently running calls](/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Running.html) + +## Abstract classes +* [\danog\MadelineProto\AsyncTools: Async tools.](/PHP/danog/MadelineProto/AsyncTools.html) +* [\danog\MadelineProto\EventHandler: Event handler.](/PHP/danog/MadelineProto/EventHandler.html) +* [\danog\MadelineProto\FileCallbackInterface: File callback interface.](/PHP/danog/MadelineProto/FileCallbackInterface.html) +* [\danog\MadelineProto\PluginEventHandler: Plugin event handler class.](/PHP/danog/MadelineProto/PluginEventHandler.html) +* [\danog\MadelineProto\SimpleEventHandler: Simple event handler class: by extending this class, you can use filters, crons and the simplified event handler API.](/PHP/danog/MadelineProto/SimpleEventHandler.html) +* [\danog\MadelineProto\StrTools: Some tools.](/PHP/danog/MadelineProto/StrTools.html) +* [\danog\MadelineProto\Tools: Some tools.](/PHP/danog/MadelineProto/Tools.html) +* [\danog\MadelineProto\Broadcast\Action: Interface that represents a broadcast action.](/PHP/danog/MadelineProto/Broadcast/Action.html) +* [\danog\MadelineProto\EventHandler\AbstractMessage: Represents an incoming or outgoing message.](/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html) +* [\danog\MadelineProto\EventHandler\AbstractPoll: Poll](/PHP/danog/MadelineProto/EventHandler/AbstractPoll.html) +* [\danog\MadelineProto\EventHandler\AbstractPrivateMessage: Represents a private or secret chat message.](/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html) +* [\danog\MadelineProto\EventHandler\AbstractStory: Represents a Telegram Story.](/PHP/danog/MadelineProto/EventHandler/AbstractStory.html) +* [\danog\MadelineProto\EventHandler\Action: In-progress actions.](/PHP/danog/MadelineProto/EventHandler/Action.html) +* [\danog\MadelineProto\EventHandler\CallbackQuery: Represents a query sent by the user by clicking on a button.](/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html) +* [\danog\MadelineProto\EventHandler\ChatInvite: Chat invite link that was used by the user to send the [join request »](https://core.telegram.org/api/invites#join-requests).](/PHP/danog/MadelineProto/EventHandler/ChatInvite.html) +* [\danog\MadelineProto\EventHandler\ChatInviteRequester: Indicates someone has requested to join a chat or channel.](/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html) +* [\danog\MadelineProto\EventHandler\Delete: Indicates that some messages were deleted.](/PHP/danog/MadelineProto/EventHandler/Delete.html) +* [\danog\MadelineProto\EventHandler\Keyboard: Represents an inline or reply keyboard.](/PHP/danog/MadelineProto/EventHandler/Keyboard.html) +* [\danog\MadelineProto\EventHandler\Media: Represents a generic media.](/PHP/danog/MadelineProto/EventHandler/Media.html) +* [\danog\MadelineProto\EventHandler\Message: Represents an incoming or outgoing message.](/PHP/danog/MadelineProto/EventHandler/Message.html) +* [\danog\MadelineProto\EventHandler\Participant: Info about a channel participant.](/PHP/danog/MadelineProto/EventHandler/Participant.html) +* [\danog\MadelineProto\EventHandler\Pinned: Indicates that some messages were pinned/unpinned.](/PHP/danog/MadelineProto/EventHandler/Pinned.html) +* [\danog\MadelineProto\EventHandler\Typing: A user is typing.](/PHP/danog/MadelineProto/EventHandler/Typing.html) +* [\danog\MadelineProto\EventHandler\Update: Represents a generic update.](/PHP/danog/MadelineProto/EventHandler/Update.html) +* [\danog\MadelineProto\EventHandler\Filter\Filter](/PHP/danog/MadelineProto/EventHandler/Filter/Filter.html) +* [\danog\MadelineProto\EventHandler\Media\AbstractAudio: Represents a generic audio file.](/PHP/danog/MadelineProto/EventHandler/Media/AbstractAudio.html) +* [\danog\MadelineProto\EventHandler\Media\AbstractSticker: Represents a generic sticker.](/PHP/danog/MadelineProto/EventHandler/Media/AbstractSticker.html) +* [\danog\MadelineProto\EventHandler\Media\AbstractVideo: Represents a generic video.](/PHP/danog/MadelineProto/EventHandler/Media/AbstractVideo.html) +* [\danog\MadelineProto\EventHandler\Media\MediaStory: Represents a forwarded story.](/PHP/danog/MadelineProto/EventHandler/Media/MediaStory.html) +* [\danog\MadelineProto\EventHandler\Media\Sticker: Represents a sticker.](/PHP/danog/MadelineProto/EventHandler/Media/Sticker.html) +* [\danog\MadelineProto\EventHandler\Message\ServiceMessage: Represents info about a service message.](/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\MessageEntity: Master class for message entities.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/MessageEntity.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall: Represents a service message about a group call.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html) +* [\danog\MadelineProto\EventHandler\Participant\Rights](/PHP/danog/MadelineProto/EventHandler/Participant/Rights.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination: To whom does a privacy rule apply?](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination.html) +* [\danog\MadelineProto\EventHandler\Query\ButtonQuery: Represents a query sent by the user by clicking on a button.](/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html) +* [\danog\MadelineProto\EventHandler\Query\GameQuery: Represents a query sent by the user by clicking on a "Play game" button.](/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html) +* [\danog\MadelineProto\EventHandler\User\Status: Contains a status update.](/PHP/danog/MadelineProto/EventHandler/User/Status.html) +* [\danog\MadelineProto\Settings\DatabaseAbstract: Base class for storage backends.](/PHP/danog/MadelineProto/Settings/DatabaseAbstract.html) +* [\danog\MadelineProto\Settings\Database\DriverDatabaseAbstract: Base class for database backends.](/PHP/danog/MadelineProto/Settings/Database/DriverDatabaseAbstract.html) +* [\danog\MadelineProto\Settings\Database\SqlAbstract: Generic db backend settings.](/PHP/danog/MadelineProto/Settings/Database/SqlAbstract.html) +* [\danog\MadelineProto\TL\TLInterface](/PHP/danog/MadelineProto/TL/TLInterface.html) +* [\danog\MadelineProto\TL\Conversion\Extension: Manages generation of extensions for files.](/PHP/danog/MadelineProto/TL/Conversion/Extension.html) + +## Classes +* [\danog\MadelineProto\API: Main API wrapper for MadelineProto.](/PHP/danog/MadelineProto/API.html) +* [\danog\MadelineProto\BotApiFileId: Indicates a bot API file ID to upload using sendDocument, sendPhoto etc...](/PHP/danog/MadelineProto/BotApiFileId.html) +* [\danog\MadelineProto\Conversion](/PHP/danog/MadelineProto/Conversion.html) +* [\danog\MadelineProto\EventHandlerIssue: Represents an event handler issue.](/PHP/danog/MadelineProto/EventHandlerIssue.html) +* [\danog\MadelineProto\Exception: Basic exception.](/PHP/danog/MadelineProto/Exception.html) +* [\danog\MadelineProto\FileCallback: File callback interface.](/PHP/danog/MadelineProto/FileCallback.html) +* [\danog\MadelineProto\LocalFile: Indicates a local file to upload.](/PHP/danog/MadelineProto/LocalFile.html) +* [\danog\MadelineProto\Logger: Logger class.](/PHP/danog/MadelineProto/Logger.html) +* [\danog\MadelineProto\MyTelegramOrgWrapper: Wrapper for my.telegram.org.](/PHP/danog/MadelineProto/MyTelegramOrgWrapper.html) +* [\danog\MadelineProto\Ogg: Async OGG stream reader and writer.](/PHP/danog/MadelineProto/Ogg.html) +* [\danog\MadelineProto\OggWriter: Async OGG stream writer.](/PHP/danog/MadelineProto/OggWriter.html) +* [\danog\MadelineProto\PTSException: Internal error indicating a problem with Telegram's servers.](/PHP/danog/MadelineProto/PTSException.html) +* [\danog\MadelineProto\ParseMode: Indicates a parsing mode for text.](/PHP/danog/MadelineProto/ParseMode.html) +* [\danog\MadelineProto\PeerNotInDbException: Indicates that a specified peer (user, chat, channel) was not found in the internal MadelineProto peer database.](/PHP/danog/MadelineProto/PeerNotInDbException.html) +* [\danog\MadelineProto\PsrLogger: PSR-3 wrapper for MadelineProto's Logger.](/PHP/danog/MadelineProto/PsrLogger.html) +* [\danog\MadelineProto\RPCErrorException: Indicates an error returned by Telegram's API.](/PHP/danog/MadelineProto/RPCErrorException.html) +* [\danog\MadelineProto\RemoteUrl: Indicates a remote URL to upload.](/PHP/danog/MadelineProto/RemoteUrl.html) +* [\danog\MadelineProto\ResponseException: Indicates an error thrown when an unexpected response is received from telegram's servers.](/PHP/danog/MadelineProto/ResponseException.html) +* [\danog\MadelineProto\SecretPeerNotInDbException: Indicates that the specified secret chat wasn't found.](/PHP/danog/MadelineProto/SecretPeerNotInDbException.html) +* [\danog\MadelineProto\SecurityException: Indicates a security error.](/PHP/danog/MadelineProto/SecurityException.html) +* [\danog\MadelineProto\Settings: Settings class used for configuring MadelineProto.](/PHP/danog/MadelineProto/Settings.html) +* [\danog\MadelineProto\Shutdown: Class that controls script shutdown.](/PHP/danog/MadelineProto/Shutdown.html) +* [\danog\MadelineProto\TextEntities: Class that converts HTML or markdown to a message + set of entities.](/PHP/danog/MadelineProto/TextEntities.html) +* [\danog\MadelineProto\VoIP: This update represents a VoIP Telegram call.](/PHP/danog/MadelineProto/VoIP.html) +* [\danog\MadelineProto\Broadcast\Filter: Broadcast filter.](/PHP/danog/MadelineProto/Broadcast/Filter.html) +* [\danog\MadelineProto\Broadcast\Progress: Broadcast progress.](/PHP/danog/MadelineProto/Broadcast/Progress.html) +* [\danog\MadelineProto\Broadcast\Status: Broadcast status.](/PHP/danog/MadelineProto/Broadcast/Status.html) +* [\danog\MadelineProto\EventHandler\BotApp: Represents information about a [named bot web app](https://core.telegram.org/api/bots/webapps#named-bot-web-apps).](/PHP/danog/MadelineProto/EventHandler/BotApp.html) +* [\danog\MadelineProto\EventHandler\BotCommands: The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed.](/PHP/danog/MadelineProto/EventHandler/BotCommands.html) +* [\danog\MadelineProto\EventHandler\Command: Represents a bot command that can be used in a chat.](/PHP/danog/MadelineProto/EventHandler/Command.html) +* [\danog\MadelineProto\EventHandler\CommandType](/PHP/danog/MadelineProto/EventHandler/CommandType.html) +* [\danog\MadelineProto\EventHandler\ForwardedInfo: Info about a forwarded message.](/PHP/danog/MadelineProto/EventHandler/ForwardedInfo.html) +* [\danog\MadelineProto\EventHandler\InlineQuery: An incoming inline query.](/PHP/danog/MadelineProto/EventHandler/InlineQuery.html) +* [\danog\MadelineProto\EventHandler\Privacy: Indicates some privacy rules for a user or set of users.](/PHP/danog/MadelineProto/EventHandler/Privacy.html) +* [\danog\MadelineProto\EventHandler\Wallpaper: Represents a [wallpaper](https://core.telegram.org/api/wallpapers).](/PHP/danog/MadelineProto/EventHandler/Wallpaper.html) +* [\danog\MadelineProto\EventHandler\Action\Cancel: Invalidate all previous action updates. E.g. when user deletes entered text or aborts a video upload.](/PHP/danog/MadelineProto/EventHandler/Action/Cancel.html) +* [\danog\MadelineProto\EventHandler\Action\ChooseContact: User is selecting a contact to share.](/PHP/danog/MadelineProto/EventHandler/Action/ChooseContact.html) +* [\danog\MadelineProto\EventHandler\Action\ChooseSticker: User is choosing a sticker.](/PHP/danog/MadelineProto/EventHandler/Action/ChooseSticker.html) +* [\danog\MadelineProto\EventHandler\Action\EmojiSeen: User is watching an animated emoji reaction triggered by another user, [click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions).](/PHP/danog/MadelineProto/EventHandler/Action/EmojiSeen.html) +* [\danog\MadelineProto\EventHandler\Action\EmojiTap: User has clicked on an animated emoji triggering a [reaction, click here for more info »](https://core.telegram.org/api/animated-emojis#emoji-reactions).](/PHP/danog/MadelineProto/EventHandler/Action/EmojiTap.html) +* [\danog\MadelineProto\EventHandler\Action\GamePlay: User is playing a game.](/PHP/danog/MadelineProto/EventHandler/Action/GamePlay.html) +* [\danog\MadelineProto\EventHandler\Action\GeoLocation: User is selecting a location to share.](/PHP/danog/MadelineProto/EventHandler/Action/GeoLocation.html) +* [\danog\MadelineProto\EventHandler\Action\GroupCallSpeaking: User is currently speaking in the group call.](/PHP/danog/MadelineProto/EventHandler/Action/GroupCallSpeaking.html) +* [\danog\MadelineProto\EventHandler\Action\HistoryImport: Chat history is being imported.](/PHP/danog/MadelineProto/EventHandler/Action/HistoryImport.html) +* [\danog\MadelineProto\EventHandler\Action\RecordAudio: User is recording a voice message.](/PHP/danog/MadelineProto/EventHandler/Action/RecordAudio.html) +* [\danog\MadelineProto\EventHandler\Action\RecordRound: User is recording a round video to share.](/PHP/danog/MadelineProto/EventHandler/Action/RecordRound.html) +* [\danog\MadelineProto\EventHandler\Action\RecordVideo: User is recording a video.](/PHP/danog/MadelineProto/EventHandler/Action/RecordVideo.html) +* [\danog\MadelineProto\EventHandler\Action\Typing: User is typing.](/PHP/danog/MadelineProto/EventHandler/Action/Typing.html) +* [\danog\MadelineProto\EventHandler\Action\UploadAudio: User is uploading a voice message.](/PHP/danog/MadelineProto/EventHandler/Action/UploadAudio.html) +* [\danog\MadelineProto\EventHandler\Action\UploadDocument: User is uploading a file.](/PHP/danog/MadelineProto/EventHandler/Action/UploadDocument.html) +* [\danog\MadelineProto\EventHandler\Action\UploadPhoto: User is uploading a photo.](/PHP/danog/MadelineProto/EventHandler/Action/UploadPhoto.html) +* [\danog\MadelineProto\EventHandler\Action\UploadRound: User is uploading a round video.](/PHP/danog/MadelineProto/EventHandler/Action/UploadRound.html) +* [\danog\MadelineProto\EventHandler\Action\UploadVideo: User is uploading a video.](/PHP/danog/MadelineProto/EventHandler/Action/UploadVideo.html) +* [\danog\MadelineProto\EventHandler\Attributes\Cron: Attribute that enables periodic execution of a certain method.](/PHP/danog/MadelineProto/EventHandler/Attributes/Cron.html) +* [\danog\MadelineProto\EventHandler\Attributes\Handler: Attribute that marks a handler method.](/PHP/danog/MadelineProto/EventHandler/Attributes/Handler.html) +* [\danog\MadelineProto\EventHandler\Channel\ChannelParticipant: A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel).](/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html) +* [\danog\MadelineProto\EventHandler\Channel\MessageForwards: Indicates that the forward counter of a message in a channel has changed.](/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html) +* [\danog\MadelineProto\EventHandler\Channel\MessageViewsChanged: Indicates that the view counter of a message in a channel has changed.](/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html) +* [\danog\MadelineProto\EventHandler\Channel\UpdateChannel: A new channel is available, or info about an existing channel was changed.](/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html) +* [\danog\MadelineProto\EventHandler\ChatInvite\ChatInviteExported: Represents an exported chat invite.](/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInviteExported.html) +* [\danog\MadelineProto\EventHandler\ChatInvite\ChatInvitePublicJoin: Used in updates and in the channel log to indicate when a user is requesting to join or has joined a [discussion group](https://core.telegram.org/api/discussion#requiring-users-to-join-the-group).](/PHP/danog/MadelineProto/EventHandler/ChatInvite/ChatInvitePublicJoin.html) +* [\danog\MadelineProto\EventHandler\ChatInviteRequester\BotChatInviteRequest: Indicates someone has requested to join a chat or channel (bots only).](/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html) +* [\danog\MadelineProto\EventHandler\ChatInviteRequester\PendingJoinRequests: Someone has requested to join a chat or channel.](/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html) +* [\danog\MadelineProto\EventHandler\Delete\DeleteChannelMessages: Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted.](/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html) +* [\danog\MadelineProto\EventHandler\Delete\DeleteMessages: Some messages were deleted in a private chat or simple group.](/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html) +* [\danog\MadelineProto\EventHandler\Delete\DeleteScheduledMessages: Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat.](/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterAllowAll: Allow all updates.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterAllowAll.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterButtonQueryData: Filters based on the content of a button query.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterButtonQueryData.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterChannel: Allow only updates coming from channels.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterChannel.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterCommand: Allow only messages containing the specified command.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommand.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterCommandCaseInsensitive: Allow only messages containing the specified case-insensitive command.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommandCaseInsensitive.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterEdited: Allows messages that were edited.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterEdited.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterEnded: Allow only ended calls.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterEnded.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterForwarded: Allow only forwarded messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwarded.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterForwardedFrom: Allow only forwarded messages from a certain sender.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwardedFrom.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterFromAdmin: Allow only messages coming from the admin (defined as the peers returned by getReportPeers).](/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromAdmin.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterFromBot: Allow only messages coming from bots.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromBot.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterFromSender: Allow incoming or outgoing group messages made by a certain sender.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSender.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterFromSenders: Allow incoming or outgoing group messages made by a certain list of senders.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSenders.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterGroup: Allow only updates coming from groups.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterGroup.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterIncoming: Allow only incoming messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterIncoming.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterMedia: Allow any media messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterMedia.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterMessage: Allow any non-service message.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterMessage.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterNoMedia: Allow any messages except media messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterNoMedia.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterNotEdited: Allows messages that weren't edited.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterNotEdited.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterOutgoing: Allow only outgoing messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterOutgoing.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterPeer: Allow messages coming from or sent to a certain peer.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterPeer.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterPoll: Allow only messages that contain a poll.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterPoll.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterPrivate: Allow only updates coming from private chats.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterPrivate.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterRegex: Allow only messages or button queries matching the specified regex.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegex.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterRegexMatchAll: Allow only messages or button queries matching the specified regex.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegexMatchAll.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterReply: Allow messages that reply to other messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterReply.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterReplyToSelf: Allow messages that reply to one of our messages.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterReplyToSelf.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterRunning: Allow only running calls.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterRunning.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterSecret: Allow only updates coming from secret chats.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterSecret.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterSender: Allow incoming or outgoing group messages made by a certain sender.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterSender.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterSenders: Allow incoming or outgoing group messages made by a certain list of senders.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterSenders.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterService: Allow only service messages of any type.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterService.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterText: Allow only messages with a specific content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterText.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextCaseInsensitive: Allow only messages with a specific case-insensitive content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextCaseInsensitive.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextContains: Allow only messages that contain a specific content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContains.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextContainsCaseInsensitive: Allow only messages that contain a specific case-insensitive content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContainsCaseInsensitive.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextEnds: Allow only messages that ends with a specific content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEnds.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextEndsCaseInsensitive: Allow only messages that ends with a specific case-insensitive content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEndsCaseInsensitive.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextStarts: Allow only messages that start with a specific content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStarts.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTextStartsCaseInsensitive: Allow only messages that start with a specific case-insensitive content.](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStartsCaseInsensitive.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTopic: Allow only messages coming from groups that has topics (Supergroups only).](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopic.html) +* [\danog\MadelineProto\EventHandler\Filter\FilterTopicId: Allow only messages with a specific topic id (Supergroups only).](/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopicId.html) +* [\danog\MadelineProto\EventHandler\Filter\Combinator\FilterNot: NOTs a filter.](/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FilterNot.html) +* [\danog\MadelineProto\EventHandler\Filter\Combinator\FiltersAnd: ANDs multiple filters.](/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersAnd.html) +* [\danog\MadelineProto\EventHandler\Filter\Combinator\FiltersOr: ORs multiple filters.](/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersOr.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterAudio: Allow only audio files.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterAudio.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterDocument: Allow only documents.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocument.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterDocumentPhoto: Allow only documents containing an image.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocumentPhoto.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterGif: Allow only GIFs.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterGif.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterPhoto: Allow only photos.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterPhoto.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterRoundVideo: Allow only round videos.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterRoundVideo.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterSticker: Allow only stickers.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterSticker.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterVideo: Allow only videos.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVideo.html) +* [\danog\MadelineProto\EventHandler\Filter\Media\FilterVoice: Allow only voice messages.](/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVoice.html) +* [\danog\MadelineProto\EventHandler\Filter\Poll\FilterMultiplePoll: Allow only messages that contain a multiple poll.](/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterMultiplePoll.html) +* [\danog\MadelineProto\EventHandler\Filter\Poll\FilterQuizPoll: Allow only messages that contain a quiz poll.](/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterQuizPoll.html) +* [\danog\MadelineProto\EventHandler\Filter\Poll\FilterSinglePoll: Allow only messages that contain a single poll.](/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterSinglePoll.html) +* [\danog\MadelineProto\EventHandler\Keyboard\InlineKeyboard: Represents an inline keyboard.](/PHP/danog/MadelineProto/EventHandler/Keyboard/InlineKeyboard.html) +* [\danog\MadelineProto\EventHandler\Keyboard\ReplyKeyboard: Represents a reply keyboard.](/PHP/danog/MadelineProto/EventHandler/Keyboard/ReplyKeyboard.html) +* [\danog\MadelineProto\EventHandler\Media\AnimatedSticker: Represents an animated sticker.](/PHP/danog/MadelineProto/EventHandler/Media/AnimatedSticker.html) +* [\danog\MadelineProto\EventHandler\Media\Audio: Represents an audio file.](/PHP/danog/MadelineProto/EventHandler/Media/Audio.html) +* [\danog\MadelineProto\EventHandler\Media\CustomEmoji: Represents a custom emoji sticker.](/PHP/danog/MadelineProto/EventHandler/Media/CustomEmoji.html) +* [\danog\MadelineProto\EventHandler\Media\Document: Represents a document.](/PHP/danog/MadelineProto/EventHandler/Media/Document.html) +* [\danog\MadelineProto\EventHandler\Media\DocumentPhoto: Represents a photo uploaded as a document.](/PHP/danog/MadelineProto/EventHandler/Media/DocumentPhoto.html) +* [\danog\MadelineProto\EventHandler\Media\GeoPoint](/PHP/danog/MadelineProto/EventHandler/Media/GeoPoint.html) +* [\danog\MadelineProto\EventHandler\Media\Gif: Represents a GIF (or an MPEG4 file without sound).](/PHP/danog/MadelineProto/EventHandler/Media/Gif.html) +* [\danog\MadelineProto\EventHandler\Media\MaskPosition: Position of the mask](/PHP/danog/MadelineProto/EventHandler/Media/MaskPosition.html) +* [\danog\MadelineProto\EventHandler\Media\MaskSticker: Represents a mask sticker.](/PHP/danog/MadelineProto/EventHandler/Media/MaskSticker.html) +* [\danog\MadelineProto\EventHandler\Media\Photo: Represents a photo.](/PHP/danog/MadelineProto/EventHandler/Media/Photo.html) +* [\danog\MadelineProto\EventHandler\Media\RoundVideo: Represents a round video.](/PHP/danog/MadelineProto/EventHandler/Media/RoundVideo.html) +* [\danog\MadelineProto\EventHandler\Media\StaticSticker: Represents a static sticker.](/PHP/danog/MadelineProto/EventHandler/Media/StaticSticker.html) +* [\danog\MadelineProto\EventHandler\Media\Video: Represents a video.](/PHP/danog/MadelineProto/EventHandler/Media/Video.html) +* [\danog\MadelineProto\EventHandler\Media\VideoSticker: Represents a video sticker.](/PHP/danog/MadelineProto/EventHandler/Media/VideoSticker.html) +* [\danog\MadelineProto\EventHandler\Media\Voice: Represents a voice message.](/PHP/danog/MadelineProto/EventHandler/Media/Voice.html) +* [\danog\MadelineProto\EventHandler\Message\ChannelMessage: Represents an incoming or outgoing channel message.](/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html) +* [\danog\MadelineProto\EventHandler\Message\GroupMessage: Represents an incoming or outgoing group message.](/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html) +* [\danog\MadelineProto\EventHandler\Message\PrivateMessage: Represents an incoming or outgoing private message.](/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html) +* [\danog\MadelineProto\EventHandler\Message\ReportReason](/PHP/danog/MadelineProto/EventHandler/Message/ReportReason.html) +* [\danog\MadelineProto\EventHandler\Message\SecretMessage: Represents New encrypted message.](/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\BankCard: Indicates a credit card number.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/BankCard.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Blockquote: Message entity representing a block quote.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Blockquote.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Bold: Message entity representing bold text.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Bold.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\BotCommand: Message entity representing a bot /command.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/BotCommand.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Cashtag: Message entity representing a $cashtag.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Cashtag.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Code: Message entity representing a codeblock.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Code.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\CustomEmoji: Represents a custom emoji.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/CustomEmoji.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Email: Message entity representing an email@example.com.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Email.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Hashtag: #hashtag message entity.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Hashtag.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\InputMentionName: Message entity representing a [user mention](https://core.telegram.org/api/mentions) created by the user, not returned by the API.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/InputMentionName.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Italic: Message entity representing italic text.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Italic.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Mention: Message entity mentioning the current user.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Mention.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\MentionName: Message entity representing a [user mention](https://core.telegram.org/api/mentions).](/PHP/danog/MadelineProto/EventHandler/Message/Entities/MentionName.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Phone: Message entity representing a phone number.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Phone.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Pre: Message entity representing a preformatted codeblock, allowing the user to specify a programming language for the codeblock.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Pre.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Spoiler: Message entity representing a spoiler.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Spoiler.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Strike: Message entity representing strikethrough text.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Strike.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\TextUrl: Message entity representing a text url: for in-text urls like https://google.com use Url.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/TextUrl.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Underline: Message entity representing underlined text.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Underline.html) +* [\danog\MadelineProto\EventHandler\Message\Entities\Url: Message entity representing an in-text url: https://google.com; for text urls, use TextUrl.](/PHP/danog/MadelineProto/EventHandler/Message/Entities/Url.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogBotAllowed: We have given the bot permission to send us direct messages.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogChannelCreated: The channel was created.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogChannelMigrateFrom: Indicates the channel was [migrated](https://core.telegram.org/api/channel) from the specified chat.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogChatJoinedByLink: A user joined the chat via an invite link.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogChatMigrateTo: Indicates the chat was [migrated](https://core.telegram.org/api/channel) to the specified supergroup.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogContactSignUp: A contact just signed up to telegram.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogCreated: A chat or channel was created.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogDeleteMessages: Deleted messages.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGameScore: Someone scored in a game.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGeoProximityReached: A user of the chat is now in proximity of another user.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGiftPremium: Info about a gifted Telegram Premium subscription.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogHistoryCleared: Chat history was cleared.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogMemberJoinedByRequest: A user was accepted into the group by an admin.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogMemberLeft: A member left the chat or channel.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogMembersJoined: Some members joined the chat or channel.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogMessagePinned: A message was pinned in a chat.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogPeerRequested: Contains info about a peer that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) button.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogPhoneCall: A phone call.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogPhotoChanged: The photo of the dialog was changed or deleted.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogReadMessages: Messages marked as read.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken: A screenshot of the chat was taken.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogSetChatTheme: The chat theme was changed.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogSetChatWallPaper: The [wallpaper](https://core.telegram.org/api/wallpapers) of the current chat was changed.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL: The Time-To-Live of messages in this chat was changed.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogSuggestProfilePhoto: A new profile picture was suggested using [photos.uploadContactProfilePhoto](https://docs.madelineproto.xyz/API_docs/methods/photos.uploadContactProfilePhoto.html).](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogTitleChanged: The title of a channel or group has changed.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated: A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited: [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogWebView: Data from an opened [reply keyboard bot web app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user & bot side service message).](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCall: The group call has started or ended.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallInvited: A set of users was invited to the group call.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html) +* [\danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallScheduled: A group call was scheduled.](/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html) +* [\danog\MadelineProto\EventHandler\Participant\Admin: Admin.](/PHP/danog/MadelineProto/EventHandler/Participant/Admin.html) +* [\danog\MadelineProto\EventHandler\Participant\Banned: Banned/kicked user.](/PHP/danog/MadelineProto/EventHandler/Participant/Banned.html) +* [\danog\MadelineProto\EventHandler\Participant\Creator: Channel/supergroup creator.](/PHP/danog/MadelineProto/EventHandler/Participant/Creator.html) +* [\danog\MadelineProto\EventHandler\Participant\Left: A participant that left the channel/supergroup.](/PHP/danog/MadelineProto/EventHandler/Participant/Left.html) +* [\danog\MadelineProto\EventHandler\Participant\Member: Channel/supergroup participant.](/PHP/danog/MadelineProto/EventHandler/Participant/Member.html) +* [\danog\MadelineProto\EventHandler\Participant\MySelf: Myself.](/PHP/danog/MadelineProto/EventHandler/Participant/MySelf.html) +* [\danog\MadelineProto\EventHandler\Participant\Rights\Admin: Represents the rights of an admin in a [channel/supergroup](https://core.telegram.org/api/channel).](/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Admin.html) +* [\danog\MadelineProto\EventHandler\Participant\Rights\Banned: Represents the rights of a normal user in a [supergroup/channel/chat](https://core.telegram.org/api/channel). In this case, the flags are inverted: if set, a flag does not allow a user to do X.](/PHP/danog/MadelineProto/EventHandler/Participant/Rights/Banned.html) +* [\danog\MadelineProto\EventHandler\Pinned\PinnedChannelMessages: Represents messages that were pinned/unpinned in a [channel](https://core.telegram.org/api/channel).](/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html) +* [\danog\MadelineProto\EventHandler\Pinned\PinnedGroupMessages: Represents messages that were pinned/unpinned in a [chat/supergroup](https://core.telegram.org/api/channel).](/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html) +* [\danog\MadelineProto\EventHandler\Pinned\PinnedPrivateMessages: Some messages were pinned in a private chat.](/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html) +* [\danog\MadelineProto\EventHandler\Plugin\RestartPlugin: Plugin that offers a /restart command to admins that can be used to restart the bot, applying changes.](/PHP/danog/MadelineProto/EventHandler/Plugin/RestartPlugin.html) +* [\danog\MadelineProto\EventHandler\Poll\MultiplePoll: Represents a poll with multiple options can be chosen as answer](/PHP/danog/MadelineProto/EventHandler/Poll/MultiplePoll.html) +* [\danog\MadelineProto\EventHandler\Poll\PollAnswer: Represents a possible answer of a poll](/PHP/danog/MadelineProto/EventHandler/Poll/PollAnswer.html) +* [\danog\MadelineProto\EventHandler\Poll\QuizPoll: Represents a quiz (with wrong and correct answers, results shown in the return type) poll](/PHP/danog/MadelineProto/EventHandler/Poll/QuizPoll.html) +* [\danog\MadelineProto\EventHandler\Poll\SinglePoll: Represents a poll with a option can be chosen as answer](/PHP/danog/MadelineProto/EventHandler/Poll/SinglePoll.html) +* [\danog\MadelineProto\EventHandler\Privacy\Rule: Represents a privacy rule.](/PHP/danog/MadelineProto/EventHandler/Privacy/Rule.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowAll: Allow all users.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowAll.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowChatParticipants: Allow all participants of certain chats.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowChatParticipants.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowCloseFriends](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowCloseFriends.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowContacts: Allow all contacts.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowContacts.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\AllowUsers: Allow only certain user.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/AllowUsers.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowAll: Disallow all users.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowAll.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowChatParticipants: Disallow only participants of certain chats.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowChatParticipants.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowContacts: Disallow only contacts.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowContacts.html) +* [\danog\MadelineProto\EventHandler\Privacy\RuleDestination\DisallowUsers: Disallow only certain users.](/PHP/danog/MadelineProto/EventHandler/Privacy/RuleDestination/DisallowUsers.html) +* [\danog\MadelineProto\EventHandler\Query\ChatButtonQuery: Represents a query sent by the user by clicking on a button in a chat.](/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html) +* [\danog\MadelineProto\EventHandler\Query\ChatGameQuery: Represents a query sent by the user by clicking on a "Play game" button in a chat.](/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html) +* [\danog\MadelineProto\EventHandler\Query\InlineButtonQuery: Represents a query sent by the user by clicking on a button in an inline message.](/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html) +* [\danog\MadelineProto\EventHandler\Query\InlineGameQuery: Represents a query sent by the user by clicking on a "Play game" button in an inline message.](/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html) +* [\danog\MadelineProto\EventHandler\Story\Story: Represents a Telegram story.](/PHP/danog/MadelineProto/EventHandler/Story/Story.html) +* [\danog\MadelineProto\EventHandler\Story\StoryDeleted: Represents a deleted story.](/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html) +* [\danog\MadelineProto\EventHandler\Story\StoryReaction: Represents a reaction to a story.](/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html) +* [\danog\MadelineProto\EventHandler\Topic\IconColor: Specifies the color of the fallback topic icon (RGB) if no custom emoji icon is specified.](/PHP/danog/MadelineProto/EventHandler/Topic/IconColor.html) +* [\danog\MadelineProto\EventHandler\Typing\ChatUserTyping: The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing.](/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html) +* [\danog\MadelineProto\EventHandler\Typing\SecretUserTyping: The user is preparing a message in a secret chat; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing.](/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html) +* [\danog\MadelineProto\EventHandler\Typing\SupergroupUserTyping: A user is typing in a [supergroup](https://core.telegram.org/api/channel).](/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html) +* [\danog\MadelineProto\EventHandler\Typing\UserTyping: The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing.](/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html) +* [\danog\MadelineProto\EventHandler\User\Blocked: A peer was blocked.](/PHP/danog/MadelineProto/EventHandler/User/Blocked.html) +* [\danog\MadelineProto\EventHandler\User\BotStopped: A bot was stopped or re-started.](/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html) +* [\danog\MadelineProto\EventHandler\User\Phone: A user’s phone number was changed.](/PHP/danog/MadelineProto/EventHandler/User/Phone.html) +* [\danog\MadelineProto\EventHandler\User\Username: Changes were made to the user’s first name, last name or username.](/PHP/danog/MadelineProto/EventHandler/User/Username.html) +* [\danog\MadelineProto\EventHandler\User\UsernameInfo: Represents an username.](/PHP/danog/MadelineProto/EventHandler/User/UsernameInfo.html) +* [\danog\MadelineProto\EventHandler\User\Status\Emoji: The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed or was removed.](/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html) +* [\danog\MadelineProto\EventHandler\User\Status\EmptyStatus: User status has not been set yet.](/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html) +* [\danog\MadelineProto\EventHandler\User\Status\LastMonth: Online status: last seen last month.](/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html) +* [\danog\MadelineProto\EventHandler\User\Status\LastWeek: Online status: last seen last week.](/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html) +* [\danog\MadelineProto\EventHandler\User\Status\Offline: The user’s offline status.](/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html) +* [\danog\MadelineProto\EventHandler\User\Status\Online: Online status of the user.](/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html) +* [\danog\MadelineProto\EventHandler\User\Status\Recently: Online status: last seen recently.](/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html) +* [\danog\MadelineProto\EventHandler\Wallpaper\WallpaperSettings: Info on how to generate a wallpaper, according to [these instructions »](https://core.telegram.org/api/wallpapers).](/PHP/danog/MadelineProto/EventHandler/Wallpaper/WallpaperSettings.html) +* [\danog\MadelineProto\MTProtoTools\DialogId: Represents the type of a bot API dialog ID.](/PHP/danog/MadelineProto/MTProtoTools/DialogId.html) +* [\danog\MadelineProto\RPCError\FloodWaitError: Represents a FLOOD_WAIT_ RPC error returned by telegram.](/PHP/danog/MadelineProto/RPCError/FloodWaitError.html) +* [\danog\MadelineProto\SecretChats\SecretChat: Represents a secret chat.](/PHP/danog/MadelineProto/SecretChats/SecretChat.html) +* [\danog\MadelineProto\Settings\AppInfo: App information.](/PHP/danog/MadelineProto/Settings/AppInfo.html) +* [\danog\MadelineProto\Settings\Auth: Cryptography settings.](/PHP/danog/MadelineProto/Settings/Auth.html) +* [\danog\MadelineProto\Settings\Connection: Connection settings.](/PHP/danog/MadelineProto/Settings/Connection.html) +* [\danog\MadelineProto\Settings\Files: File management settings.](/PHP/danog/MadelineProto/Settings/Files.html) +* [\danog\MadelineProto\Settings\Ipc: IPC server settings.](/PHP/danog/MadelineProto/Settings/Ipc.html) +* [\danog\MadelineProto\Settings\Logger: Logger settings.](/PHP/danog/MadelineProto/Settings/Logger.html) +* [\danog\MadelineProto\Settings\Peer: Peer database settings.](/PHP/danog/MadelineProto/Settings/Peer.html) +* [\danog\MadelineProto\Settings\Pwr: PWRTelegram settings.](/PHP/danog/MadelineProto/Settings/Pwr.html) +* [\danog\MadelineProto\Settings\RPC: RPC settings.](/PHP/danog/MadelineProto/Settings/RPC.html) +* [\danog\MadelineProto\Settings\SecretChats: Secret chat settings.](/PHP/danog/MadelineProto/Settings/SecretChats.html) +* [\danog\MadelineProto\Settings\Serialization: Serialization settings.](/PHP/danog/MadelineProto/Settings/Serialization.html) +* [\danog\MadelineProto\Settings\TLSchema: TL schema settings.](/PHP/danog/MadelineProto/Settings/TLSchema.html) +* [\danog\MadelineProto\Settings\Templates: Web and CLI template settings for login.](/PHP/danog/MadelineProto/Settings/Templates.html) +* [\danog\MadelineProto\Settings\VoIP: VoIP settings.](/PHP/danog/MadelineProto/Settings/VoIP.html) +* [\danog\MadelineProto\Settings\Database\Memory: Memory backend settings.](/PHP/danog/MadelineProto/Settings/Database/Memory.html) +* [\danog\MadelineProto\Settings\Database\Mysql: MySQL backend settings.](/PHP/danog/MadelineProto/Settings/Database/Mysql.html) +* [\danog\MadelineProto\Settings\Database\Postgres: Postgres backend settings.](/PHP/danog/MadelineProto/Settings/Database/Postgres.html) +* [\danog\MadelineProto\Settings\Database\Redis: Redis backend settings.](/PHP/danog/MadelineProto/Settings/Database/Redis.html) +* [\danog\MadelineProto\Settings\Database\SerializerType](/PHP/danog/MadelineProto/Settings/Database/SerializerType.html) +* [\danog\MadelineProto\TL\Exception: TL deserialization exception.](/PHP/danog/MadelineProto/TL/Exception.html) +* [\danog\MadelineProto\TL\Conversion\Exception: TL conversion exception.](/PHP/danog/MadelineProto/TL/Conversion/Exception.html) +* [\danog\MadelineProto\TL\Types\Button: Clickable button.](/PHP/danog/MadelineProto/TL/Types/Button.html) +* [\danog\MadelineProto\TL\Types\Bytes: Bytes wrapper.](/PHP/danog/MadelineProto/TL/Types/Bytes.html) +* [\danog\MadelineProto\TL\Types\LoginQrCode: Represents a login QR code.](/PHP/danog/MadelineProto/TL/Types/LoginQrCode.html) +* [\danog\MadelineProto\VoIP\CallState](/PHP/danog/MadelineProto/VoIP/CallState.html) +* [\danog\MadelineProto\VoIP\DiscardReason: Why was the call discarded?](/PHP/danog/MadelineProto/VoIP/DiscardReason.html) +* [\danog\MadelineProto\VoIP\VoIPState: VoIP protcol state.](/PHP/danog/MadelineProto/VoIP/VoIPState.html) + + + +--- +Generated by [danog/phpdoc](https://phpdoc.daniil.it). \ No newline at end of file diff --git a/docs/Participant.md b/docs/Participant.md new file mode 100644 index 0000000000..2d0b044fa6 --- /dev/null +++ b/docs/Participant.md @@ -0,0 +1,24 @@ +--- +title: Participant +description: PWRTelegram participant attributes, type and example +nav_exclude: true +--- +## Constructor: PWRTelegram chat participant + + + +### Attributes: + +| Name | Type | Required | Description| +|----------|---------------|----------|------------| +|user|[Chat](Chat.html) | Yes| The participant| +|inviter|[Chat](Chat.html) | Optional|The user that invited this participant| +|promoted_by|[Chat](Chat.html) | Optional|The user that promoted this participant| +|kicked_by|[Chat](Chat.html) | Optional|The user that kicked this participant| +|date|[int](API_docs/types/int.html) | Yes|When was the user invited| +|role|[string](API_docs/types/string.html) | Yes|user, admin, creator, banned| +|rank|[string](API_docs/types/string.html) | Optional|A custom rank string for admins and creators| +|can_edit|[Bool](API_docs/types/Bool.html) | Optional|Can the user edit messages in the channel| +|left|[Bool](API_docs/types/Bool.html) | Optional|Has this user left| +|admin_rights|[ChatAdminRights](API_docs/types/ChatAdminRights.html) | Optional|Admin rights| +|banned_rights|[ChatBannedRights](API_docs/types/ChatBannedRights.html) | Optional|Banned rights| diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 0000000000..142d1310f6 --- /dev/null +++ b/docs/README.md @@ -0,0 +1,3 @@ +# Documentation for MadelineProto + +This is the documentation repo for [MadelineProto](https://github.com/danog/MadelineProto). diff --git a/docs/_config.yml b/docs/_config.yml new file mode 100644 index 0000000000..f88f868320 --- /dev/null +++ b/docs/_config.yml @@ -0,0 +1,38 @@ +color_scheme: dark + +plugins: + - jekyll-sitemap + - jekyll-redirect-from + - jekyll-seo-tag + - jekyll-default-layout + +url: https://docs.madelineproto.xyz +logo: logo.png + +twitter: + username: DaniilGentili + card: summary + +author: + twitter: DaniilGentili + +include: [".well-known"] +repository: danog/madelineproto + +aux_links_new_tab: true + +gh_edit_link: true # show or hide edit this page link +gh_edit_link_text: "Edit this page on GitHub" +gh_edit_repository: "https://github.com/danog/MadelineProtoDocs" # the github URL for your repo +gh_edit_branch: "master" # the branch that your docs is served from +gh_edit_source: docs # the source that your files originate from +gh_edit_view_mode: "edit" # "tree" or "edit" if you want the user to jump into the editor immediately + + +compress_html: + clippings: all + comments: all + endings: all + startings: [] + blanklines: false + profile: false \ No newline at end of file diff --git a/docs/_includes/fix_linenos.html b/docs/_includes/fix_linenos.html new file mode 100644 index 0000000000..6243fb093e --- /dev/null +++ b/docs/_includes/fix_linenos.html @@ -0,0 +1,65 @@ +{%- comment -%} +This file can be used to fix the HTML produced by Jekyll for highlighted +code with line numbers. + +It works with `{% highlight some_language linenos %}...{% endhighlight %}` +and with the Kramdown option to add line numbers to fenced code. + +The implementation was derived from the workaround provided by +Dmitry Hrabrov (DeXP) at +https://github.com/penibelst/jekyll-compress-html/issues/71#issuecomment-188144901 + +EXPLANATION + +The HTML produced by Rouge highlighting with lie numbers is of the form +`code table`. Jekyll (<= 4.1.1) always wraps the highlighted HTML +with `pre`. This wrapping is not only unnecessary, but also transforms +the conforming HTML produced by Rouge to non-conforming HTML, which +results in HTML validation error reports. + +The fix removes the outer `pre` tags whenever they contain the pattern +``. + +Apart from avoiding HTML validation errors, the fix allows the use of +the [Jekyll layout for compressing HTML](http://jch.penibelst.de), +which relies on `pre` tags not being nested, according to +https://github.com/penibelst/jekyll-compress-html/issues/71#issuecomment-172069842 + +USAGE + +(Any names can be used for `some_var` and `some_language`.) + +{% capture some_var %} +{% highlight some_language linenos %} +Some code +{% endhighlight %} +{% endcapture %} +{% include fix_linenos.html code=some_var %} + +For code fences: + +{% capture some_var %} +```some_language +Some code +``` +{% endcapture %} +{% assign some_var = some_var | markdownify %} +{% include fix_linenos.html code=some_var %} + +CAVEATS + +The above does not work when `Some code` happens to contain the matched string +`
`. + +The use of this file overwrites the variable `fix_linenos_code` with `nil`. + +{%- endcomment -%} + +{% assign fix_linenos_code = include.code %} +{% if fix_linenos_code contains '
' %} + {% assign fix_linenos_code = fix_linenos_code | replace: '
', '
' %}
+  {% assign fix_linenos_code = fix_linenos_code | replace: "
", "" %} +{% endif %} +{{ fix_linenos_code }} +{% assign fix_linenos_code = nil %} diff --git a/docs/_includes/footer_custom.html b/docs/_includes/footer_custom.html new file mode 100644 index 0000000000..64e08c290f --- /dev/null +++ b/docs/_includes/footer_custom.html @@ -0,0 +1,3 @@ +{%- if site.footer_content -%} +

{{ site.footer_content }}

+{%- endif -%} diff --git a/docs/_includes/head.html b/docs/_includes/head.html new file mode 100644 index 0000000000..d50b2a59ad --- /dev/null +++ b/docs/_includes/head.html @@ -0,0 +1,33 @@ + + + + + {{ page.title }} + + + + + + + + + + + + + + + + + {% seo %} + + {% include head_custom.html %} + + + + + diff --git a/docs/_includes/head_custom.html b/docs/_includes/head_custom.html new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/_includes/header_custom.html b/docs/_includes/header_custom.html new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/_includes/nav.html b/docs/_includes/nav.html new file mode 100644 index 0000000000..8b6a3550db --- /dev/null +++ b/docs/_includes/nav.html @@ -0,0 +1,101 @@ + diff --git a/docs/_includes/title.html b/docs/_includes/title.html new file mode 100644 index 0000000000..8bd3fa83da --- /dev/null +++ b/docs/_includes/title.html @@ -0,0 +1,5 @@ +{% if site.logo %} + +{% else %} + {{ site.title }} +{% endif %} diff --git a/docs/_includes/vendor/anchor_headings.html b/docs/_includes/vendor/anchor_headings.html new file mode 100755 index 0000000000..8b12751559 --- /dev/null +++ b/docs/_includes/vendor/anchor_headings.html @@ -0,0 +1,175 @@ +{% capture headingsWorkspace %} + {% comment %} + Copyright (c) 2018 Vladimir "allejo" Jimenez + + Permission is hereby granted, free of charge, to any person + obtaining a copy of this software and associated documentation + files (the "Software"), to deal in the Software without + restriction, including without limitation the rights to use, + copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the + Software is furnished to do so, subject to the following + conditions: + + The above copyright notice and this permission notice shall be + included in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES + OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT + HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR + OTHER DEALINGS IN THE SOFTWARE. + {% endcomment %} + {% comment %} + Version 1.0.13 + https://github.com/allejo/jekyll-anchor-headings + + "Be the pull request you wish to see in the world." ~Ben Balter + + Usage: + {% include anchor_headings.html html=content anchorBody="#" %} + + Parameters: + * html (string) - the HTML of compiled markdown generated by kramdown in Jekyll + + Optional Parameters: + * beforeHeading (bool) : false - Set to true if the anchor should be placed _before_ the heading's content + * headerAttrs (string) : '' - Any custom HTML attributes that will be added to the heading tag; you may NOT use `id`; + the `%heading%` and `%html_id%` placeholders are available + * anchorAttrs (string) : '' - Any custom HTML attributes that will be added to the `` tag; you may NOT use `href`, `class` or `title`; + the `%heading%` and `%html_id%` placeholders are available + * anchorBody (string) : '' - The content that will be placed inside the anchor; the `%heading%` placeholder is available + * anchorClass (string) : '' - The class(es) that will be used for each anchor. Separate multiple classes with a space + * anchorTitle (string) : '' - The `title` attribute that will be used for anchors + * h_min (int) : 1 - The minimum header level to build an anchor for; any header lower than this value will be ignored + * h_max (int) : 6 - The maximum header level to build an anchor for; any header greater than this value will be ignored + * bodyPrefix (string) : '' - Anything that should be inserted inside of the heading tag _before_ its anchor and content + * bodySuffix (string) : '' - Anything that should be inserted inside of the heading tag _after_ its anchor and content + * generateId (true) : false - Set to true if a header without id should generate an id to use. + + Output: + The original HTML with the addition of anchors inside of all of the h1-h6 headings. + {% endcomment %} + + {% assign minHeader = include.h_min | default: 1 %} + {% assign maxHeader = include.h_max | default: 6 %} + {% assign beforeHeading = include.beforeHeading %} + {% assign headerAttrs = include.headerAttrs %} + {% assign nodes = include.html | split: ' + {% if headerLevel != "1" and headerLevel != "2" and headerLevel != "3" and headerLevel != "4" and headerLevel != "5" and headerLevel != "6" %} + + {% assign firstChunk = node | split: '>' | first %} + + + {% unless firstChunk contains '<' %} + {% capture node %}{% endcapture %} + {% assign _workspace = node | split: _closingTag %} + {% capture _hAttrToStrip %}{{ _workspace[0] | split: '>' | first }}>{% endcapture %} + {% assign header = _workspace[0] | replace: _hAttrToStrip, '' %} + {% assign escaped_header = header | strip_html | strip %} + + {% assign _classWorkspace = _workspace[0] | split: 'class="' %} + {% assign _classWorkspace = _classWorkspace[1] | split: '"' %} + {% assign _html_class = _classWorkspace[0] %} + + {% if _html_class contains "no_anchor" %} + {% assign skip_anchor = true %} + {% else %} + {% assign skip_anchor = false %} + {% endif %} + + {% assign _idWorkspace = _workspace[0] | split: 'id="' %} + {% if _idWorkspace[1] %} + {% assign _idWorkspace = _idWorkspace[1] | split: '"' %} + {% assign html_id = _idWorkspace[0] %} + {% assign h_attrs = headerAttrs %} + {% elsif include.generateId %} + + {% assign html_id = escaped_header | slugify %} + {% if html_id == "" %} + {% assign html_id = false %} + {% endif %} + + {% capture h_attrs %}{{ headerAttrs }} id="%html_id%"{% endcapture %} + {% endif %} + + + {% capture anchor %}{% endcapture %} + + {% if skip_anchor == false and html_id and headerLevel >= minHeader and headerLevel <= maxHeader %} + {% if h_attrs %} + {% capture _hAttrToStrip %}{{ _hAttrToStrip | split: '>' | first }} {{ h_attrs | strip | replace: '%heading%', escaped_header | replace: '%html_id%', html_id }}>{% endcapture %} + {% endif %} + + {% capture anchor %}href="#{{ html_id }}"{% endcapture %} + + {% if include.anchorClass %} + {% capture anchor %}{{ anchor }} class="{{ include.anchorClass }}"{% endcapture %} + {% endif %} + + {% if include.anchorTitle %} + {% capture anchor %}{{ anchor }} title="{{ include.anchorTitle | replace: '%heading%', escaped_header }}"{% endcapture %} + {% endif %} + + {% if include.anchorAttrs %} + {% capture anchor %}{{ anchor }} {{ include.anchorAttrs | replace: '%heading%', escaped_header | replace: '%html_id%', html_id }}{% endcapture %} + {% endif %} + + {% capture anchor %}{{ include.anchorBody | replace: '%heading%', escaped_header | default: '' }}{% endcapture %} + + + {% if beforeHeading %} + {% capture anchor %}{{ anchor }} {% endcapture %} + {% else %} + {% capture anchor %} {{ anchor }}{% endcapture %} + {% endif %} + {% endif %} + + {% capture new_heading %} + + {% endcapture %} + + + {% assign chunkCount = _workspace | size %} + {% if chunkCount > 1 %} + {% capture new_heading %}{{ new_heading }}{{ _workspace | last }}{% endcapture %} + {% endif %} + + {% capture edited_headings %}{{ edited_headings }}{{ new_heading }}{% endcapture %} + {% endfor %} +{% endcapture %}{% assign headingsWorkspace = '' %}{{ edited_headings | strip }} diff --git a/docs/_layouts/about.html b/docs/_layouts/about.html new file mode 100644 index 0000000000..5e7112684a --- /dev/null +++ b/docs/_layouts/about.html @@ -0,0 +1,5 @@ +--- +layout: default +--- + +{{ content }} diff --git a/docs/_layouts/default.html b/docs/_layouts/default.html new file mode 100644 index 0000000000..4b31def537 --- /dev/null +++ b/docs/_layouts/default.html @@ -0,0 +1,195 @@ +--- +layout: table_wrappers +--- + + + + +{% include head.html %} + + + + Link + + + + + + Search + + + + + + Menu + + + + + + Expand + + + + + + Document + + + + + + + +
+
+ + {% include header_custom.html %} + {% if site.aux_links %} + + {% endif %} +
+
+ {% unless page.url == "/" %} + {% if page.parent %} + {%- for node in pages_list -%} + {%- if node.parent == nil -%} + {%- if page.parent == node.title or page.grand_parent == node.title -%} + {%- assign first_level_url = node.url | absolute_url -%} + {%- endif -%} + {%- if node.has_children -%} + {%- assign children_list = pages_list | where: "parent", node.title -%} + {%- for child in children_list -%} + {%- if page.url == child.url or page.parent == child.title -%} + {%- assign second_level_url = child.url | absolute_url -%} + {%- endif -%} + {%- endfor -%} + {%- endif -%} + {%- endif -%} + {%- endfor -%} + + {% endif %} + {% endunless %} +
+ {% include vendor/anchor_headings.html html=content beforeHeading="true" anchorBody='' anchorClass="anchor-heading" anchorAttrs='aria-labelledby="%html_id%"' %} + + {% if page.has_children == true and page.has_toc != false %} +
+

Table of contents

+
    + {%- assign children_list = pages_list | where: "parent", page.title | where: "grand_parent", page.parent -%} + {% for child in children_list %} +
  • + {{ child.title }}{% if child.summary %} - {{ child.summary }}{% endif %} +
  • + {% endfor %} +
+ {% endif %} + + {% capture footer_custom %} + {%- include footer_custom.html -%} + {% endcapture %} + {% if footer_custom != "" or site.last_edit_timestamp or site.gh_edit_link %} +
+
+ {% if site.back_to_top %} +

{{ site.back_to_top_text }}

+ {% endif %} + + {{ footer_custom }} + + {% if site.last_edit_timestamp or site.gh_edit_link %} +
+ {% if site.last_edit_timestamp and site.last_edit_time_format and page.last_modified_date %} +

+ Page last modified: {{ page.last_modified_date | date: site.last_edit_time_format }}. +

+ {% endif %} + {% if + site.gh_edit_link and + site.gh_edit_link_text and + site.gh_edit_repository and + site.gh_edit_branch and + site.gh_edit_view_mode + %} +

+ {{ site.gh_edit_link_text }} +

+ {% endif %} +
+ {% endif %} +
+ {% endif %} + +
+
+ + + + + +
+
+ + diff --git a/docs/_layouts/empty.html b/docs/_layouts/empty.html new file mode 100644 index 0000000000..7f63ffdeb6 --- /dev/null +++ b/docs/_layouts/empty.html @@ -0,0 +1,3 @@ +--- +--- +{{ content }} \ No newline at end of file diff --git a/docs/_layouts/home.html b/docs/_layouts/home.html new file mode 100644 index 0000000000..5e7112684a --- /dev/null +++ b/docs/_layouts/home.html @@ -0,0 +1,5 @@ +--- +layout: default +--- + +{{ content }} diff --git a/docs/_layouts/page.html b/docs/_layouts/page.html new file mode 100644 index 0000000000..5e7112684a --- /dev/null +++ b/docs/_layouts/page.html @@ -0,0 +1,5 @@ +--- +layout: default +--- + +{{ content }} diff --git a/docs/_layouts/post.html b/docs/_layouts/post.html new file mode 100644 index 0000000000..5e7112684a --- /dev/null +++ b/docs/_layouts/post.html @@ -0,0 +1,5 @@ +--- +layout: default +--- + +{{ content }} diff --git a/docs/_layouts/table_wrappers.html b/docs/_layouts/table_wrappers.html new file mode 100644 index 0000000000..3f8f226a12 --- /dev/null +++ b/docs/_layouts/table_wrappers.html @@ -0,0 +1,7 @@ +--- +layout: vendor/compress +--- + +{% assign content_ = content | replace: '', '
' %} +{{ content_ }} diff --git a/docs/_layouts/vendor/compress.html b/docs/_layouts/vendor/compress.html new file mode 100644 index 0000000000..bb34487d2a --- /dev/null +++ b/docs/_layouts/vendor/compress.html @@ -0,0 +1,10 @@ +--- +# Jekyll layout that compresses HTML +# v3.1.0 +# http://jch.penibelst.de/ +# © 2014–2015 Anatol Broder +# MIT License +--- + +{% capture _LINE_FEED %} +{% endcapture %}{% if site.compress_html.ignore.envs contains jekyll.environment or site.compress_html.ignore.envs == "all" %}{{ content }}{% else %}{% capture _content %}{{ content }}{% endcapture %}{% assign _profile = site.compress_html.profile %}{% if site.compress_html.endings == "all" %}{% assign _endings = "html head body li dt dd optgroup option colgroup caption thead tbody tfoot tr td th" | split: " " %}{% else %}{% assign _endings = site.compress_html.endings %}{% endif %}{% for _element in _endings %}{% capture _end %}{% endcapture %}{% assign _content = _content | remove: _end %}{% endfor %}{% if _profile and _endings %}{% assign _profile_endings = _content | size | plus: 1 %}{% endif %}{% for _element in site.compress_html.startings %}{% capture _start %}<{{ _element }}>{% endcapture %}{% assign _content = _content | remove: _start %}{% endfor %}{% if _profile and site.compress_html.startings %}{% assign _profile_startings = _content | size | plus: 1 %}{% endif %}{% if site.compress_html.comments == "all" %}{% assign _comments = "" | split: " " %}{% else %}{% assign _comments = site.compress_html.comments %}{% endif %}{% if _comments.size == 2 %}{% capture _comment_befores %}.{{ _content }}{% endcapture %}{% assign _comment_befores = _comment_befores | split: _comments.first %}{% for _comment_before in _comment_befores %}{% if forloop.first %}{% continue %}{% endif %}{% capture _comment_outside %}{% if _carry %}{{ _comments.first }}{% endif %}{{ _comment_before }}{% endcapture %}{% capture _comment %}{% unless _carry %}{{ _comments.first }}{% endunless %}{{ _comment_outside | split: _comments.last | first }}{% if _comment_outside contains _comments.last %}{{ _comments.last }}{% assign _carry = false %}{% else %}{% assign _carry = true %}{% endif %}{% endcapture %}{% assign _content = _content | remove_first: _comment %}{% endfor %}{% if _profile %}{% assign _profile_comments = _content | size | plus: 1 %}{% endif %}{% endif %}{% assign _pre_befores = _content | split: "" %}{% assign _pres_after = "" %}{% if _pres.size != 0 %}{% if site.compress_html.blanklines %}{% assign _lines = _pres.last | split: _LINE_FEED %}{% capture _pres_after %}{% for _line in _lines %}{% assign _trimmed = _line | split: " " | join: " " %}{% if _trimmed != empty or forloop.last %}{% unless forloop.first %}{{ _LINE_FEED }}{% endunless %}{{ _line }}{% endif %}{% endfor %}{% endcapture %}{% else %}{% assign _pres_after = _pres.last | split: " " | join: " " %}{% endif %}{% endif %}{% capture _content %}{{ _content }}{% if _pre_before contains "
" %}{% endif %}{% unless _pre_before contains "
" and _pres.size == 1 %}{{ _pres_after }}{% endunless %}{% endcapture %}{% endfor %}{% if _profile %}{% assign _profile_collapse = _content | size | plus: 1 %}{% endif %}{% if site.compress_html.clippings == "all" %}{% assign _clippings = "html head title base link meta style body article section nav aside h1 h2 h3 h4 h5 h6 hgroup header footer address p hr blockquote ol ul li dl dt dd figure figcaption main div table caption colgroup col tbody thead tfoot tr td th" | split: " " %}{% else %}{% assign _clippings = site.compress_html.clippings %}{% endif %}{% for _element in _clippings %}{% assign _edges = " ;; ;" | replace: "e", _element | split: ";" %}{% assign _content = _content | replace: _edges[0], _edges[1] | replace: _edges[2], _edges[3] | replace: _edges[4], _edges[5] %}{% endfor %}{% if _profile and _clippings %}{% assign _profile_clippings = _content | size | plus: 1 %}{% endif %}{{ _content }}{% if _profile %}
Step Bytes
raw {{ content | size }}{% if _profile_endings %}
endings {{ _profile_endings }}{% endif %}{% if _profile_startings %}
startings {{ _profile_startings }}{% endif %}{% if _profile_comments %}
comments {{ _profile_comments }}{% endif %}{% if _profile_collapse %}
collapse {{ _profile_collapse }}{% endif %}{% if _profile_clippings %}
clippings {{ _profile_clippings }}{% endif %}
{% endif %}{% endif %} diff --git a/docs/_sass/base.scss b/docs/_sass/base.scss new file mode 100644 index 0000000000..c3b6698722 --- /dev/null +++ b/docs/_sass/base.scss @@ -0,0 +1,108 @@ +// +// Base element style overrides +// +// stylelint-disable selector-no-type, selector-max-type + +* { + box-sizing: border-box; +} + +::selection { + color: $white; + background: $link-color; +} + +html { + @include fs-4; + scroll-behavior: smooth; +} + +body { + font-family: $body-font-family; + font-size: inherit; + line-height: $body-line-height; + color: $body-text-color; + background-color: $body-background-color; +} + +ol, +ul, +dl, +pre, +address, +blockquote, +table, +div, +hr, +form, +fieldset, +noscript .table-wrapper { + margin-top: 0; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + margin-top: 0; + margin-bottom: 1em; + font-weight: 500; + line-height: $body-heading-line-height; + color: $body-heading-color; +} + +p { + margin-top: 1em; + margin-bottom: 1em; +} + +a { + color: $link-color; + text-decoration: none; +} + +a:not([class]) { + text-decoration: none; + background-image: linear-gradient($border-color 0%, $border-color 100%); + background-repeat: repeat-x; + background-position: 0 100%; + background-size: 1px 1px; + + &:hover { + background-image: linear-gradient( + rgba($link-color, 0.45) 0%, + rgba($link-color, 0.45) 100% + ); + background-size: 1px 1px; + } +} + +code { + font-family: $mono-font-family; + font-size: 0.75em; + line-height: $body-line-height; +} + +figure, +pre { + margin: 0; +} + +li { + margin: 0.25em 0; +} + +img { + max-width: 100%; + height: auto; +} + +hr { + height: 1px; + padding: 0; + margin: $sp-6 0; + background-color: $border-color; + border: 0; +} diff --git a/docs/_sass/buttons.scss b/docs/_sass/buttons.scss new file mode 100644 index 0000000000..4a1b2d6a3b --- /dev/null +++ b/docs/_sass/buttons.scss @@ -0,0 +1,119 @@ +// +// Buttons and things that look like buttons +// +// stylelint-disable color-named + +.btn { + display: inline-block; + box-sizing: border-box; + padding-top: 0.3em; + padding-right: 1em; + padding-bottom: 0.3em; + padding-left: 1em; + margin: 0; + margin-right: 0.15em; + font-family: inherit; + font-size: inherit; + font-weight: 500; + line-height: 1.5; + color: $link-color; + text-decoration: none; + vertical-align: baseline; + cursor: pointer; + background-color: $base-button-color; + border-width: 0; + border-radius: $border-radius; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + appearance: none; + + &:focus { + text-decoration: none; + outline: none; + box-shadow: 0 0 0 3px rgba(blue, 0.25); + } + + &:focus:hover, + &.selected:focus { + box-shadow: 0 0 0 3px rgba(blue, 0.25); + } + + &:hover, + &.zeroclipboard-is-hover { + color: darken($link-color, 2%); + } + + &:hover, + &:active, + &.zeroclipboard-is-hover, + &.zeroclipboard-is-active { + text-decoration: none; + background-color: darken($base-button-color, 1%); + } + + &:active, + &.selected, + &.zeroclipboard-is-active { + background-color: darken($base-button-color, 3%); + background-image: none; + box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15); + } + + &.selected:hover { + background-color: darken(#dcdcdc, 5%); + } + + &:disabled, + &.disabled { + &, + &:hover { + color: rgba(102, 102, 102, 0.5); + cursor: default; + background-color: rgba(229, 229, 229, 0.5); + background-image: none; + box-shadow: none; + } + } +} + +.btn-outline { + color: $link-color; + background: transparent; + box-shadow: inset 0 0 0 2px $grey-lt-300; + + &:hover, + &:active, + &.zeroclipboard-is-hover, + &.zeroclipboard-is-active { + color: darken($link-color, 4%); + text-decoration: none; + background-color: transparent; + box-shadow: inset 0 0 0 3px $grey-lt-300; + } + + &:focus { + text-decoration: none; + outline: none; + box-shadow: inset 0 0 0 2px $grey-dk-100, 0 0 0 3px rgba(blue, 0.25); + } + + &:focus:hover, + &.selected:focus { + box-shadow: inset 0 0 0 2px $grey-dk-100; + } +} + +.btn-primary { + @include btn-color($white, $btn-primary-color); +} + +.btn-purple { + @include btn-color($white, $purple-100); +} + +.btn-blue { + @include btn-color($white, $blue-000); +} + +.btn-green { + @include btn-color($white, $green-100); +} diff --git a/docs/_sass/code.scss b/docs/_sass/code.scss new file mode 100644 index 0000000000..f038912909 --- /dev/null +++ b/docs/_sass/code.scss @@ -0,0 +1,340 @@ +// +// Code and syntax highlighting +// +// stylelint-disable selector-no-qualifying-type, declaration-block-semicolon-newline-after,declaration-block-single-line-max-declarations, selector-no-type, selector-max-type + +code { + padding: 0.2em 0.15em; + font-weight: 400; + background-color: $code-background-color; + border: $border $border-color; + border-radius: $border-radius; +} + +// Avoid appearance of dark border around visited code links in Safari +a:visited code { + border-color: $border-color; +} + +// Content structure for highlighted code blocks using fences or Liquid +// +// ```[LANG]...```, no kramdown line_numbers: +// div.[language-LANG.]highlighter-rouge > div.highlight > pre.highlight > code +// +// ```[LANG]...```, kramdown line_numbers = true: +// div.[language-LANG.]highlighter-rouge > div.highlight > pre.highlight > code +// > div.table-wrapper > table.rouge-table > tbody > tr +// > td.rouge-gutter.gl > pre.lineno +// | td.rouge-code > pre +// +// {% highlight LANG %}...{% endhighlight %}: +// figure.highlight > pre > code.language-LANG +// +// {% highlight LANG linenos %}...{% endhighlight %}: +// figure.highlight > pre > code.language-LANG +// > div.table-wrapper > table.rouge-table > tbody > tr +// > td.gutter.gl > pre.lineno +// | td.code > pre +// +// fix_linenos removes the outermost pre when it encloses table.rouge-table +// +// See docs/index-test.md for some tests. +// +// No kramdown line_numbers: fences and Liquid highlighting look the same. +// Kramdown line_numbers = true: fences have a wider gutter than with Liquid? + +// ```[LANG]...``` +div.highlighter-rouge { + padding: $sp-3; + margin-top: 0; + margin-bottom: $sp-3; + overflow-x: auto; + background-color: $code-background-color; + border-radius: $border-radius; + box-shadow: none; + -webkit-overflow-scrolling: touch; + + div.highlight, + pre.highlight, + code { + padding: 0; + margin: 0; + border: 0; + } +} + +// {% highlight LANG %}...{% endhighlight %}, +// {% highlight LANG linenos %}...{% endhighlight %}: +figure.highlight { + padding: $sp-3; + margin-top: 0; + margin-bottom: $sp-3; + background-color: $code-background-color; + border-radius: $border-radius; + box-shadow: none; + -webkit-overflow-scrolling: touch; + + pre, + code { + padding: 0; + margin: 0; + border: 0; + } +} + +// ```[LANG]...```, kramdown line_numbers = true, +// {% highlight LANG linenos %}...{% endhighlight %}: +.highlight .table-wrapper { + padding: 0; + margin: 0; + border: 0; + box-shadow: none; + + td, + pre { + @include fs-2; + min-width: 0; + padding: 0; + background-color: $code-background-color; + border: 0; + } + + td.gl { + padding-right: $sp-3; + } + + pre { + margin: 0; + line-height: 2; + } +} + +.highlight .c { + color: #586e75; +} // comment // +.highlight .err { + color: #93a1a1; +} // error // +.highlight .g { + color: #93a1a1; +} // generic // +.highlight .k { + color: #859900; +} // keyword // +.highlight .l { + color: #93a1a1; +} // literal // +.highlight .n { + color: #93a1a1; +} // name // +.highlight .o { + color: #859900; +} // operator // +.highlight .x { + color: #cb4b16; +} // other // +.highlight .p { + color: #93a1a1; +} // punctuation // +.highlight .cm { + color: #586e75; +} // comment.multiline // +.highlight .cp { + color: #859900; +} // comment.preproc // +.highlight .c1 { + color: #586e75; +} // comment.single // +.highlight .cs { + color: #859900; +} // comment.special // +.highlight .gd { + color: #2aa198; +} // generic.deleted // +.highlight .ge { + font-style: italic; + color: #93a1a1; +} // generic.emph // +.highlight .gr { + color: #dc322f; +} // generic.error // +.highlight .gh { + color: #cb4b16; +} // generic.heading // +.highlight .gi { + color: #859900; +} // generic.inserted // +.highlight .go { + color: #93a1a1; +} // generic.output // +.highlight .gp { + color: #93a1a1; +} // generic.prompt // +.highlight .gs { + font-weight: bold; + color: #93a1a1; +} // generic.strong // +.highlight .gu { + color: #cb4b16; +} // generic.subheading // +.highlight .gt { + color: #93a1a1; +} // generic.traceback // +.highlight .kc { + color: #cb4b16; +} // keyword.constant // +.highlight .kd { + color: #268bd2; +} // keyword.declaration // +.highlight .kn { + color: #859900; +} // keyword.namespace // +.highlight .kp { + color: #859900; +} // keyword.pseudo // +.highlight .kr { + color: #268bd2; +} // keyword.reserved // +.highlight .kt { + color: #dc322f; +} // keyword.type // +.highlight .ld { + color: #93a1a1; +} // literal.date // +.highlight .m { + color: #2aa198; +} // literal.number // +.highlight .s { + color: #2aa198; +} // literal.string // +.highlight .na { + color: #555; +} // name.attribute // +.highlight .nb { + color: #b58900; +} // name.builtin // +.highlight .nc { + color: #268bd2; +} // name.class // +.highlight .no { + color: #cb4b16; +} // name.constant // +.highlight .nd { + color: #268bd2; +} // name.decorator // +.highlight .ni { + color: #cb4b16; +} // name.entity // +.highlight .ne { + color: #cb4b16; +} // name.exception // +.highlight .nf { + color: #268bd2; +} // name.function // +.highlight .nl { + color: #555; +} // name.label // +.highlight .nn { + color: #93a1a1; +} // name.namespace // +.highlight .nx { + color: #555; +} // name.other // +.highlight .py { + color: #93a1a1; +} // name.property // +.highlight .nt { + color: #268bd2; +} // name.tag // +.highlight .nv { + color: #268bd2; +} // name.variable // +.highlight .ow { + color: #859900; +} // operator.word // +.highlight .w { + color: #93a1a1; +} // text.whitespace // +.highlight .mf { + color: #2aa198; +} // literal.number.float // +.highlight .mh { + color: #2aa198; +} // literal.number.hex // +.highlight .mi { + color: #2aa198; +} // literal.number.integer // +.highlight .mo { + color: #2aa198; +} // literal.number.oct // +.highlight .sb { + color: #586e75; +} // literal.string.backtick // +.highlight .sc { + color: #2aa198; +} // literal.string.char // +.highlight .sd { + color: #93a1a1; +} // literal.string.doc // +.highlight .s2 { + color: #2aa198; +} // literal.string.double // +.highlight .se { + color: #cb4b16; +} // literal.string.escape // +.highlight .sh { + color: #93a1a1; +} // literal.string.heredoc // +.highlight .si { + color: #2aa198; +} // literal.string.interpol // +.highlight .sx { + color: #2aa198; +} // literal.string.other // +.highlight .sr { + color: #dc322f; +} // literal.string.regex // +.highlight .s1 { + color: #2aa198; +} // literal.string.single // +.highlight .ss { + color: #2aa198; +} // literal.string.symbol // +.highlight .bp { + color: #268bd2; +} // name.builtin.pseudo // +.highlight .vc { + color: #268bd2; +} // name.variable.class // +.highlight .vg { + color: #268bd2; +} // name.variable.global // +.highlight .vi { + color: #268bd2; +} // name.variable.instance // +.highlight .il { + color: #2aa198; +} // literal.number.integer.long // + +// +// Code examples (rendered) +// + +.code-example { + padding: $sp-3; + margin-bottom: $sp-3; + overflow: auto; + border: 1px solid $border-color; + border-radius: $border-radius; + + + .highlighter-rouge, + + figure.highlight { + position: relative; + margin-top: -$sp-4; + border-right: 1px solid $border-color; + border-bottom: 1px solid $border-color; + border-left: 1px solid $border-color; + border-top-left-radius: 0; + border-top-right-radius: 0; + } +} diff --git a/docs/_sass/color_schemes/dark.scss b/docs/_sass/color_schemes/dark.scss new file mode 100644 index 0000000000..4d0dc98216 --- /dev/null +++ b/docs/_sass/color_schemes/dark.scss @@ -0,0 +1,21 @@ +$body-background-color: $grey-dk-300; +$sidebar-color: $grey-dk-300; +$border-color: $grey-dk-200; + +$body-text-color: $grey-lt-300; +$body-heading-color: $grey-lt-000; +$nav-child-link-color: $grey-dk-000; +$search-result-preview-color: $grey-dk-000; + +$link-color: $blue-000; +$btn-primary-color: $blue-200; +$base-button-color: $grey-dk-250; + +$code-background-color: $grey-dk-250; +$search-background-color: $grey-dk-250; +$table-background-color: $grey-dk-250; +$feedback-color: darken($sidebar-color, 3%); + +.theme-dark-button { + display: none !important; +} \ No newline at end of file diff --git a/docs/_sass/color_schemes/light.scss b/docs/_sass/color_schemes/light.scss new file mode 100644 index 0000000000..b16e2a8f38 --- /dev/null +++ b/docs/_sass/color_schemes/light.scss @@ -0,0 +1,3 @@ +.theme-light-button { + display: none !important; +} \ No newline at end of file diff --git a/docs/_sass/content.scss b/docs/_sass/content.scss new file mode 100644 index 0000000000..c83c917c52 --- /dev/null +++ b/docs/_sass/content.scss @@ -0,0 +1,231 @@ +@charset "UTF-8"; + +// +// Styles for rendered markdown in the .main-content container +// +// stylelint-disable selector-no-type, max-nesting-depth, selector-max-compound-selectors, selector-max-type + +.main-content { + line-height: $content-line-height; + + ol, + ul, + dl, + pre, + address, + blockquote, + .table-wrapper { + margin-top: 0.5em; + } + + a { + overflow: hidden; + text-overflow: ellipsis; + //white-space: nowrap; + } + + ul, + ol { + padding-left: 1.5em; + } + + li { + .highlight { + margin-top: $sp-1; + } + } + + ol { + list-style-type: none; + counter-reset: step-counter; + + > li { + position: relative; + + &::before { + position: absolute; + top: 0.2em; + left: -1.6em; + color: $grey-dk-000; + content: counter(step-counter); + counter-increment: step-counter; + @include fs-3; + + @include mq(sm) { + top: 0.11em; + } + } + + ol { + counter-reset: sub-counter; + + li { + &::before { + content: counter(sub-counter, lower-alpha); + counter-increment: sub-counter; + } + } + } + } + } + + ul { + list-style: none; + + > li { + &::before { + position: absolute; + margin-left: -1.4em; + color: $grey-dk-000; + content: "•"; + } + } + } + + .task-list { + padding-left: 0; + } + + .task-list-item { + display: flex; + align-items: center; + + &::before { + content: ""; + } + } + + .task-list-item-checkbox { + margin-right: 0.6em; + } + + hr + * { + margin-top: 0; + } + + h1:first-of-type { + margin-top: 0.5em; + } + + dl { + display: grid; + grid-template: auto / 10em 1fr; + } + + dt, + dd { + margin: 0.25em 0; + } + + dt { + grid-column: 1; + font-weight: 500; + text-align: right; + &::after { + content: ":"; + } + } + + dd { + grid-column: 2; + margin-bottom: 0; + margin-left: 1em; + blockquote, + div, + dl, + dt, + h1, + h2, + h3, + h4, + h5, + h6, + li, + ol, + p, + pre, + table, + ul, + .table-wrapper { + &:first-child { + margin-top: 0; + } + } + } + + dd, + ol, + ul { + dl:first-child { + dt:first-child, + dd:nth-child(2) { + margin-top: 0; + } + } + } + + .anchor-heading { + position: absolute; + right: -$sp-4; + width: $sp-5; + height: 100%; + padding-right: $sp-1; + padding-left: $sp-1; + overflow: visible; + + @include mq(md) { + right: auto; + left: -$sp-5; + } + + svg { + display: inline-block; + width: 100%; + height: 100%; + color: $link-color; + visibility: hidden; + } + } + + .anchor-heading:hover, + h1:hover > .anchor-heading, + h2:hover > .anchor-heading, + h3:hover > .anchor-heading, + h4:hover > .anchor-heading, + h5:hover > .anchor-heading, + h6:hover > .anchor-heading { + svg { + visibility: visible; + } + } + + summary { + cursor: pointer; + } + + h1, + h2, + h3, + h4, + h5, + h6 { + position: relative; + margin-top: 1.5em; + margin-bottom: 0.25em; + + &:first-child { + margin-top: $sp-2; + } + + + table, + + .table-wrapper, + + .code-example, + + .highlighter-rouge { + margin-top: 1em; + } + + + p { + margin-top: 0; + } + } +} diff --git a/docs/_sass/custom/custom.scss b/docs/_sass/custom/custom.scss new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/_sass/labels.scss b/docs/_sass/labels.scss new file mode 100644 index 0000000000..e08ae80dec --- /dev/null +++ b/docs/_sass/labels.scss @@ -0,0 +1,37 @@ +// +// Labels (not the form kind) +// + +.label, +.label-blue { + display: inline-block; + padding-top: 0.16em; + padding-right: 0.56em; + padding-bottom: 0.16em; + padding-left: 0.56em; + margin-right: $sp-2; + margin-left: $sp-2; + color: $white; + text-transform: uppercase; + vertical-align: middle; + background-color: $blue-100; + @include fs-2; + border-radius: 12px; +} + +.label-green { + background-color: $green-200; +} + +.label-purple { + background-color: $purple-100; +} + +.label-red { + background-color: $red-200; +} + +.label-yellow { + color: $grey-dk-200; + background-color: $yellow-200; +} diff --git a/docs/_sass/layout.scss b/docs/_sass/layout.scss new file mode 100644 index 0000000000..2197faf924 --- /dev/null +++ b/docs/_sass/layout.scss @@ -0,0 +1,208 @@ +// +// The basic two column layout +// + +.side-bar { + z-index: 0; + display: flex; + flex-wrap: wrap; + background-color: $sidebar-color; + + @include mq(md) { + flex-wrap: nowrap; + position: fixed; + width: $nav-width-md; + height: 100%; + flex-direction: column; + border-right: $border $border-color; + align-items: flex-end; + } + + /*@include mq(lg) { + width: calc((100% - #{$nav-width + $content-width}) / 2 + #{$nav-width}); + min-width: $nav-width; + }*/ +} + +.main { + @include mq(md) { + position: relative; + //max-width: $content-width; + margin-left: $nav-width-md; + } + + /*@include mq(lg) { + margin-left: calc( + (100% - #{$nav-width + $content-width}) / 2 + #{$nav-width} + ); + }*/ +} + +.main-content-wrap { + @include container; + padding-top: $gutter-spacing-sm; + padding-bottom: $gutter-spacing-sm; + + @include mq(md) { + padding-top: $gutter-spacing; + padding-bottom: $gutter-spacing; + } +} + +.main-header { + z-index: 0; + display: none; + background-color: $sidebar-color; + + @include mq(md) { + display: flex; + justify-content: space-between; + height: $header-height; + background-color: $body-background-color; + border-bottom: $border $border-color; + } + + &.nav-open { + display: block; + + @include mq(md) { + display: flex; + } + } +} + +.site-nav, +.site-header, +.site-footer { + width: 100%; + + @include mq(lg) { + width: $nav-width; + } +} + +.site-nav { + display: none; + + &.nav-open { + display: block; + } + + @include mq(md) { + display: block; + //padding-top: $sp-8; + padding-bottom: $gutter-spacing-sm; + overflow-y: auto; + flex: 1 1 auto; + } +} + +.site-header { + display: flex; + min-height: $header-height; + align-items: center; + + @include mq(md) { + height: $header-height; + max-height: $header-height; + border-bottom: $border $border-color; + } +} + +.site-title { + @include container; + flex-grow: 1; + display: flex; + height: 100%; + align-items: center; + padding-left: $sp-4 !important; + padding-right: 0rem !important; + padding-top: $sp-3; + padding-bottom: $sp-3; + color: $body-heading-color; + @include fs-6; + + @include mq(md) { + padding-top: $sp-2; + padding-bottom: $sp-2; + } +} + +@if variable-exists(logo) { + .site-logo { + width: 100%; + height: 100%; + background-image: url($logo); + background-repeat: no-repeat; + background-position: left center; + background-size: contain; + } +} + +.site-button { + display: flex; + height: 100%; + padding: $gutter-spacing-sm; + align-items: center; +} + +@include mq(md) { + .site-header .site-button { + display: none; + } +} + +.site-title:hover { + background-image: linear-gradient( + -90deg, + rgba($feedback-color, 1) 0%, + rgba($feedback-color, 0.8) 80%, + rgba($feedback-color, 0) 100% + ); +} + +.site-button:hover { + background-image: linear-gradient( + -90deg, + rgba($feedback-color, 1) 0%, + rgba($feedback-color, 0.8) 100% + ); +} + +// stylelint-disable selector-max-type + +body { + position: relative; + padding-bottom: $sp-10; + overflow-y: scroll; + overflow-wrap: break-word; + + @include mq(md) { + position: static; + padding-bottom: 0; + } +} + +// stylelint-enable selector-max-type + +.site-footer { + @include container; + position: absolute; + bottom: 0; + left: 0; + padding-top: $sp-4; + padding-bottom: $sp-4; + color: $grey-dk-000; + @include fs-2; + + @include mq(md) { + position: static; + justify-self: end; + } +} + +.icon { + width: $sp-5; + height: $sp-5; + color: $link-color; +} diff --git a/docs/_sass/modules.scss b/docs/_sass/modules.scss new file mode 100644 index 0000000000..d82591b75a --- /dev/null +++ b/docs/_sass/modules.scss @@ -0,0 +1,20 @@ +// +// Import external dependencies +// +@import "./vendor/normalize.scss/normalize.scss"; + +// +// Modules +// +@import "./base"; +@import "./layout"; +@import "./content"; +@import "./navigation"; +@import "./typography"; +@import "./labels"; +@import "./buttons"; +@import "./search"; +@import "./tables"; +@import "./code"; +@import "./utilities/utilities"; +@import "./print"; diff --git a/docs/_sass/navigation.scss b/docs/_sass/navigation.scss new file mode 100644 index 0000000000..c6743b2869 --- /dev/null +++ b/docs/_sass/navigation.scss @@ -0,0 +1,226 @@ +// +// Main nav, breadcrumb, etc... +// +// stylelint-disable selector-no-type, max-nesting-depth, selector-max-compound-selectors, selector-max-type, selector-max-specificity + +.nav-list { + padding: 0; + margin-top: 0; + margin-bottom: 0; + list-style: none; + + .nav-list-item { + @include fs-4; + position: relative; + margin: 0; + + @include mq(md) { + @include fs-3; + } + + .nav-list-github { + line-height: #{($nav-list-item-height-sm - 2 * $sp-1) * 2} !important; + @include mq(md) { + line-height: #{($nav-list-item-height - 2 * $sp-1) * 2} !important; + } + } + + .nav-list-link { + display: block; + min-height: $nav-list-item-height-sm; + padding-top: $sp-1; + padding-bottom: $sp-1; + line-height: #{$nav-list-item-height-sm - 2 * $sp-1}; + @if $nav-list-expander-right { + padding-right: $nav-list-item-height-sm; + padding-left: $gutter-spacing-sm; + } @else { + padding-right: $gutter-spacing-sm; + padding-left: $nav-list-item-height-sm; + } + + @include mq(md) { + min-height: $nav-list-item-height; + line-height: #{$nav-list-item-height - 2 * $sp-1}; + @if $nav-list-expander-right { + padding-right: $nav-list-item-height; + padding-left: $gutter-spacing; + } @else { + padding-right: $gutter-spacing; + padding-left: $nav-list-item-height; + } + } + + &.active { + font-weight: 600; + text-decoration: none; + } + + &:hover, + &.active { + background-image: linear-gradient( + -90deg, + rgba($feedback-color, 1) 0%, + rgba($feedback-color, 0.8) 80%, + rgba($feedback-color, 0) 100% + ); + } + } + + .nav-list-expander { + position: absolute; + @if $nav-list-expander-right { + right: 0; + } + width: $nav-list-item-height-sm; + height: $nav-list-item-height-sm; + padding-top: #{$nav-list-item-height-sm / 4}; + padding-right: #{$nav-list-item-height-sm / 4}; + padding-bottom: #{$nav-list-item-height-sm / 4}; + padding-left: #{$nav-list-item-height-sm / 4}; + color: $link-color; + + @include mq(md) { + width: $nav-list-item-height; + height: $nav-list-item-height; + padding-top: #{$nav-list-item-height / 4}; + padding-right: #{$nav-list-item-height / 4}; + padding-bottom: #{$nav-list-item-height / 4}; + padding-left: #{$nav-list-item-height / 4}; + } + + &:hover { + background-image: linear-gradient( + -90deg, + rgba($feedback-color, 1) 0%, + rgba($feedback-color, 0.8) 100% + ); + } + + @if $nav-list-expander-right { + svg { + transform: rotate(90deg); + } + } + } + + > .nav-list { + display: none; + padding-left: $sp-3; + list-style: none; + + .nav-list-item { + position: relative; + + .nav-list-link { + color: $nav-child-link-color; + } + + .nav-list-expander { + color: $nav-child-link-color; + } + } + } + + &.active { + > .nav-list-expander svg { + @if $nav-list-expander-right { + transform: rotate(-90deg); + } @else { + transform: rotate(90deg); + } + } + + > .nav-list { + display: block; + } + } + } +} + +.nav-category { + padding-top: $sp-2; + padding-right: $gutter-spacing-sm; + padding-bottom: $sp-2; + padding-left: $gutter-spacing-sm; + font-weight: 600; + text-align: end; + text-transform: uppercase; + border-bottom: $border $border-color; + @include fs-2; + + @include mq(md) { + padding-right: $gutter-spacing; + padding-left: $gutter-spacing; + margin-top: $gutter-spacing-sm; + text-align: start; + + &:first-child { + margin-top: 0; + } + } +} + +// Aux nav + +.aux-nav { + height: 100%; + overflow-x: auto; + @include fs-2; + + .aux-nav-list { + display: flex; + height: 100%; + padding: 0; + margin: 0; + list-style: none; + } + + .aux-nav-list-item { + display: inline-block; + height: 100%; + padding: 0; + margin: 0; + } + + @include mq(md) { + padding-right: $gutter-spacing-sm; + } +} + +// Breadcrumb nav + +.breadcrumb-nav { + @include mq(md) { + margin-top: -$sp-4; + } +} + +.breadcrumb-nav-list { + padding-left: 0; + margin-bottom: $sp-3; + list-style: none; +} + +.breadcrumb-nav-list-item { + display: table-cell; + @include fs-2; + + &::before { + display: none; + } + + &::after { + display: inline-block; + margin-right: $sp-2; + margin-left: $sp-2; + color: $grey-dk-000; + content: "/"; + } + + &:last-child { + &::after { + content: ""; + } + } +} diff --git a/docs/_sass/print.scss b/docs/_sass/print.scss new file mode 100644 index 0000000000..6e6de3734c --- /dev/null +++ b/docs/_sass/print.scss @@ -0,0 +1,40 @@ +// stylelint-disable selector-max-specificity, selector-max-id, selector-max-type, selector-no-qualifying-type, primer/no-override, + +@media print { + .site-footer, + .site-button, + #edit-this-page, + #back-to-top, + .site-nav, + .main-header { + display: none !important; + } + + .side-bar { + width: 100%; + height: auto; + border-right: 0 !important; + } + + .site-header { + border-bottom: 1px solid $border-color; + } + + .site-title { + font-size: $root-font-size !important; + font-weight: 700 !important; + } + + .text-small { + font-size: 8pt !important; + } + + pre.highlight { + border: 1px solid $border-color; + } + + .main { + max-width: none; + margin-left: 0; + } +} diff --git a/docs/_sass/search.scss b/docs/_sass/search.scss new file mode 100644 index 0000000000..efd176630b --- /dev/null +++ b/docs/_sass/search.scss @@ -0,0 +1,324 @@ +// +// Search input and autocomplete +// + +.search { + position: relative; + z-index: 2; + flex-grow: 1; + height: $sp-10; + padding: $sp-2; + transition: padding linear #{$transition-duration / 2}; + + @include mq(md) { + position: relative !important; + width: auto !important; + height: 100% !important; + padding: 0; + transition: none; + } +} + +.search-input-wrap { + position: relative; + z-index: 1; + height: $sp-8; + overflow: hidden; + border-radius: $border-radius; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + transition: height linear #{$transition-duration / 2}; + + @include mq(md) { + position: absolute; + width: 100%; + max-width: $search-results-width; + height: 100% !important; + border-radius: 0; + box-shadow: none; + transition: width ease $transition-duration; + } +} + +.search-input { + position: absolute; + width: 100%; + height: 100%; + padding-top: $sp-2; + padding-right: $gutter-spacing-sm; + padding-bottom: $sp-2; + padding-left: #{$gutter-spacing-sm + $sp-5}; + font-size: 16px; + background-color: $search-background-color; + color: $body-text-color; + border-top: 0; + border-right: 0; + border-bottom: 0; + border-left: 0; + border-radius: 0; + + @include mq(md) { + padding-top: $gutter-spacing-sm; + padding-bottom: $gutter-spacing-sm; + padding-left: #{$gutter-spacing + $sp-5}; + font-size: 14px; + background-color: $body-background-color; + transition: padding-left linear #{$transition-duration / 2}; + } + + &:focus { + outline: 0; + + + .search-label .search-icon { + color: $link-color; + } + } +} + +.search-label { + position: absolute; + display: flex; + height: 100%; + padding-left: $gutter-spacing-sm; + + @include mq(md) { + padding-left: $gutter-spacing; + transition: padding-left linear #{$transition-duration / 2}; + } + + .search-icon { + width: #{$sp-4 * 1.2}; + height: #{$sp-4 * 1.2}; + align-self: center; + color: $grey-dk-000; + } +} + +.search-results { + position: absolute; + left: 0; + display: none; + width: 100%; + max-height: calc(100% - #{$sp-10}); + overflow-y: auto; + background-color: $search-background-color; + border-bottom-right-radius: $border-radius; + border-bottom-left-radius: $border-radius; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + + @include mq(md) { + top: 100%; + width: $search-results-width; + max-height: calc(100vh - 200%) !important; + } +} + +.search-results-list { + padding-left: 0; + margin-bottom: $sp-1; + list-style: none; + @include fs-4; + + @include mq(md) { + @include fs-3; + } +} + +.search-results-list-item { + padding: 0; + margin: 0; +} + +.search-result { + display: block; + padding-top: $sp-1; + padding-right: $sp-3; + padding-bottom: $sp-1; + padding-left: $sp-3; + + &:hover, + &.active { + background-color: $feedback-color; + } +} + +.search-result-title { + display: block; + padding-top: $sp-2; + padding-bottom: $sp-2; + + @include mq(sm) { + display: inline-block; + width: 40%; + padding-right: $sp-2; + vertical-align: top; + } +} + +.search-result-doc { + display: flex; + align-items: center; + word-wrap: break-word; + + &.search-result-doc-parent { + opacity: 0.5; + @include fs-3; + + @include mq(md) { + @include fs-2; + } + } + + .search-result-icon { + width: $sp-4; + height: $sp-4; + margin-right: $sp-2; + color: $link-color; + flex-shrink: 0; + } + + .search-result-doc-title { + overflow: auto; + } +} + +.search-result-section { + margin-left: #{$sp-4 + $sp-2}; + word-wrap: break-word; +} + +.search-result-rel-url { + display: block; + margin-left: #{$sp-4 + $sp-2}; + overflow: hidden; + color: $search-result-preview-color; + text-overflow: ellipsis; + white-space: nowrap; + @include fs-1; +} + +.search-result-previews { + display: block; + padding-top: $sp-2; + padding-bottom: $sp-2; + padding-left: $sp-4; + margin-left: $sp-2; + color: $search-result-preview-color; + word-wrap: break-word; + border-left: $border; + border-left-color: $border-color; + @include fs-2; + + @include mq(sm) { + display: inline-block; + width: 60%; + padding-left: $sp-2; + margin-left: 0; + vertical-align: top; + } +} + +.search-result-preview + .search-result-preview { + margin-top: $sp-1; +} + +.search-result-highlight { + font-weight: bold; +} + +.search-no-result { + padding-top: $sp-2; + padding-right: $sp-3; + padding-bottom: $sp-2; + padding-left: $sp-3; + @include fs-3; +} + +.search-button { + position: fixed; + right: $sp-4; + bottom: $sp-4; + display: flex; + width: $sp-9; + height: $sp-9; + background-color: $search-background-color; + border: 1px solid rgba($link-color, 0.3); + border-radius: #{$sp-9 / 2}; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + align-items: center; + justify-content: center; +} + +.search-overlay { + position: fixed; + top: 0; + left: 0; + z-index: 1; + width: 0; + height: 0; + background-color: rgba(0, 0, 0, 0.3); + opacity: 0; + transition: opacity ease $transition-duration, width 0s $transition-duration, + height 0s $transition-duration; +} + +.search-active { + .search { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + padding: 0; + } + + .search-input-wrap { + height: $sp-10; + border-radius: 0; + + @include mq(md) { + width: $search-results-width; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + } + } + + .search-input { + background-color: $search-background-color; + + @include mq(md) { + padding-left: 2.3rem; + } + } + + .search-label { + @include mq(md) { + padding-left: 0.6rem; + } + } + + .search-results { + display: block; + } + + .search-overlay { + width: 100%; + height: 100%; + opacity: 1; + transition: opacity ease $transition-duration, width 0s, height 0s; + } + + @include mq(md) { + .main { + position: fixed; + right: 0; + left: 0; + } + } + + .main-header { + padding-top: $sp-10; + + @include mq(md) { + padding-top: 0; + } + } +} diff --git a/docs/_sass/support/_functions.scss b/docs/_sass/support/_functions.scss new file mode 100644 index 0000000000..992a84d56e --- /dev/null +++ b/docs/_sass/support/_functions.scss @@ -0,0 +1,9 @@ +@function remCustom($size, $unit: "") { + $remSize: $size / $root-font-size; + + @if ($unit == false) { + @return #{$remSize}; + } @else { + @return #{$remSize}rem; + } +} diff --git a/docs/_sass/support/_variables.scss b/docs/_sass/support/_variables.scss new file mode 100644 index 0000000000..3ab3f05e14 --- /dev/null +++ b/docs/_sass/support/_variables.scss @@ -0,0 +1,153 @@ +// +// Typography +// + +$body-font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", + Roboto, "Helvetica Neue", Arial, sans-serif !default; +$mono-font-family: "SFMono-Regular", Menlo, Consolas, Monospace !default; +$root-font-size: 16px !default; // Base font-size for rems +$body-line-height: 1.4 !default; +$content-line-height: 1.6 !default; +$body-heading-line-height: 1.25 !default; + +// +// Font size +// `-sm` suffix is the size at the small (and above) media query +// + +$font-size-1: 9px !default; +$font-size-1-sm: 10px !default; +$font-size-2: 11px !default; //h4 - uppercased!, h6 not uppercased, text-small +$font-size-3: 12px !default; //h5 +$font-size-4: 14px !default; +$font-size-5: 16px !default; //h3 +$font-size-6: 18px !default; //h2 +$font-size-7: 24px !default; +$font-size-8: 32px !default; //h1 +$font-size-9: 36px !default; +$font-size-10: 42px !default; +$font-size-10-sm: 48px !default; + +// +// Colors +// + +$white: #fff !default; + +$grey-dk-000: #959396 !default; +$grey-dk-100: #5c5962 !default; +$grey-dk-200: #44434d !default; +$grey-dk-250: #302d36 !default; +$grey-dk-300: #27262b !default; + +$grey-lt-000: #f5f6fa !default; +$grey-lt-100: #eeebee !default; +$grey-lt-200: #ecebed !default; +$grey-lt-300: #e6e1e8 !default; + +$purple-000: #7253ed !default; +$purple-100: #5e41d0 !default; +$purple-200: #4e26af !default; +$purple-300: #381885 !default; + +$blue-000: #2c84fa !default; +$blue-100: #2869e6 !default; +$blue-200: #264caf !default; +$blue-300: #183385 !default; + +$green-000: #41d693 !default; +$green-100: #11b584 !default; +$green-200: #009c7b !default; +$green-300: #026e57 !default; + +$yellow-000: #ffeb82 !default; +$yellow-100: #fadf50 !default; +$yellow-200: #f7d12e !default; +$yellow-300: #e7af06 !default; + +$red-000: #f77e7e !default; +$red-100: #f96e65 !default; +$red-200: #e94c4c !default; +$red-300: #dd2e2e !default; + +$body-background-color: $white !default; +$sidebar-color: $grey-lt-000 !default; +$search-background-color: $white !default; +$table-background-color: $white !default; +$code-background-color: $grey-lt-000 !default; +$feedback-color: darken($sidebar-color, 3%) !default; + +$body-text-color: $grey-dk-100 !default; +$body-heading-color: $grey-dk-300 !default; +$search-result-preview-color: $grey-dk-000 !default; +$nav-child-link-color: $grey-dk-100 !default; +$link-color: $purple-000 !default; +$btn-primary-color: $purple-100 !default; +$base-button-color: #f7f7f7 !default; + +// +// Spacing +// + +$spacing-unit: 1rem; // 1rem == 16px + +$spacers: ( + sp-0: 0, + sp-1: $spacing-unit * 0.25, + sp-2: $spacing-unit * 0.5, + sp-3: $spacing-unit * 0.75, + sp-4: $spacing-unit, + sp-5: $spacing-unit * 1.5, + sp-6: $spacing-unit * 2, + sp-7: $spacing-unit * 2.5, + sp-8: $spacing-unit * 3, + sp-9: $spacing-unit * 3.5, + sp-10: $spacing-unit * 4, +) !default; + +$sp-1: map-get($spacers, sp-1) !default; // 0.25 rem == 4px +$sp-2: map-get($spacers, sp-2) !default; // 0.5 rem == 8px +$sp-3: map-get($spacers, sp-3) !default; // 0.75 rem == 12px +$sp-4: map-get($spacers, sp-4) !default; // 1 rem == 16px +$sp-5: map-get($spacers, sp-5) !default; // 1.5 rem == 24px +$sp-6: map-get($spacers, sp-6) !default; // 2 rem == 32px +$sp-7: map-get($spacers, sp-7) !default; // 2.5 rem == 40px +$sp-8: map-get($spacers, sp-8) !default; // 3 rem == 48px +$sp-9: map-get($spacers, sp-9) !default; // 3.5 rem == 56px +$sp-10: map-get($spacers, sp-10) !default; // 4 rem == 64px + +// +// Borders +// + +$border: 1px solid !default; +$border-radius: 4px !default; +$border-color: $grey-lt-100 !default; + +// +// Grid system +// + +$gutter-spacing: $sp-6 !default; +$gutter-spacing-sm: $sp-4 !default; +$nav-width: 264px !default; +$nav-width-md: 248px !default; +$nav-list-item-height: $sp-6 !default; +$nav-list-item-height-sm: $sp-8 !default; +$nav-list-expander-right: true; +$content-width: 800px !default; +$header-height: 60px !default; +$search-results-width: $content-width - $nav-width !default; +$transition-duration: 400ms; + +// +// Media queries in pixels +// + +$media-queries: ( + xs: 320px, + sm: 500px, + md: $content-width, + lg: $content-width + $nav-width, + xl: 1400px, +) !default; diff --git a/docs/_sass/support/mixins/_buttons.scss b/docs/_sass/support/mixins/_buttons.scss new file mode 100644 index 0000000000..e3e6c4fbca --- /dev/null +++ b/docs/_sass/support/mixins/_buttons.scss @@ -0,0 +1,27 @@ +// Colored button + +@mixin btn-color($fg, $bg) { + color: $fg; + background-color: darken($bg, 2%); + background-image: linear-gradient(lighten($bg, 5%), darken($bg, 2%)); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25), 0 4px 10px rgba(0, 0, 0, 0.12); + + &:hover, + &.zeroclipboard-is-hover { + color: $fg; + background-color: darken($bg, 4%); + background-image: linear-gradient((lighten($bg, 2%), darken($bg, 4%))); + } + + &:active, + &.selected, + &.zeroclipboard-is-active { + background-color: darken($bg, 5%); + background-image: none; + box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15); + } + + &.selected:hover { + background-color: darken($bg, 10%); + } +} diff --git a/docs/_sass/support/mixins/_layout.scss b/docs/_sass/support/mixins/_layout.scss new file mode 100644 index 0000000000..df2b3d0448 --- /dev/null +++ b/docs/_sass/support/mixins/_layout.scss @@ -0,0 +1,34 @@ +// Media query + +// Media query mixin +// Usage: +// @include mq(md) { +// ..medium and up styles +// } +@mixin mq($name) { + // Retrieves the value from the key + $value: map-get($media-queries, $name); + + // If the key exists in the map + @if $value != null { + // Prints a media query based on the value + @media (min-width: remCustom($value)) { + @content; + } + } @else { + @warn "No value could be retrieved from `#{$media-query}`. " + + "Please make sure it is defined in `$media-queries` map."; + } +} + +// Responsive container + +@mixin container { + padding-right: $gutter-spacing-sm; + padding-left: $gutter-spacing-sm; + + @include mq(md) { + padding-right: $gutter-spacing; + padding-left: $gutter-spacing; + } +} diff --git a/docs/_sass/support/mixins/_typography.scss b/docs/_sass/support/mixins/_typography.scss new file mode 100644 index 0000000000..5207fcd13a --- /dev/null +++ b/docs/_sass/support/mixins/_typography.scss @@ -0,0 +1,84 @@ +@mixin fs-1 { + font-size: $font-size-1 !important; + + @include mq(sm) { + font-size: $font-size-1-sm !important; + } +} + +@mixin fs-2 { + font-size: $font-size-2 !important; + + @include mq(sm) { + font-size: $font-size-3 !important; + } +} + +@mixin fs-3 { + font-size: $font-size-3 !important; + + @include mq(sm) { + font-size: $font-size-4 !important; + } +} + +@mixin fs-4 { + font-size: $font-size-4 !important; + + @include mq(sm) { + font-size: $font-size-5 !important; + } +} + +@mixin fs-5 { + font-size: $font-size-5 !important; + + @include mq(sm) { + font-size: $font-size-6 !important; + } +} + +@mixin fs-6 { + font-size: $font-size-6 !important; + + @include mq(sm) { + font-size: $font-size-7 !important; + line-height: $body-heading-line-height; + } +} + +@mixin fs-7 { + font-size: $font-size-7 !important; + line-height: $body-heading-line-height; + + @include mq(sm) { + font-size: $font-size-8 !important; + } +} + +@mixin fs-8 { + font-size: $font-size-8 !important; + line-height: $body-heading-line-height; + + @include mq(sm) { + font-size: $font-size-9 !important; + } +} + +@mixin fs-9 { + font-size: $font-size-9 !important; + line-height: $body-heading-line-height; + + @include mq(sm) { + font-size: $font-size-10 !important; + } +} + +@mixin fs-10 { + font-size: $font-size-10 !important; + line-height: $body-heading-line-height; + + @include mq(sm) { + font-size: $font-size-10-sm !important; + } +} diff --git a/docs/_sass/support/mixins/mixins.scss b/docs/_sass/support/mixins/mixins.scss new file mode 100644 index 0000000000..0506fbf5ff --- /dev/null +++ b/docs/_sass/support/mixins/mixins.scss @@ -0,0 +1,3 @@ +@import "./layout"; +@import "./buttons"; +@import "./typography"; diff --git a/docs/_sass/support/support.scss b/docs/_sass/support/support.scss new file mode 100644 index 0000000000..8131a3201a --- /dev/null +++ b/docs/_sass/support/support.scss @@ -0,0 +1,3 @@ +@import "./variables"; +@import "./functions"; +@import "./mixins/mixins"; diff --git a/docs/_sass/tables.scss b/docs/_sass/tables.scss new file mode 100644 index 0000000000..b2ac7cdb8f --- /dev/null +++ b/docs/_sass/tables.scss @@ -0,0 +1,58 @@ +// +// Tables +// +// stylelint-disable max-nesting-depth, selector-no-type, selector-max-type + +.table-wrapper { + display: block; + width: 100%; + max-width: 100%; + margin-bottom: $sp-5; + overflow-x: auto; + border-radius: $border-radius; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); +} + +table { + display: table; + min-width: 100%; + border-collapse: separate; +} + +th, +td { + @include fs-3; + min-width: 120px; + padding-top: $sp-2; + padding-right: $sp-3; + padding-bottom: $sp-2; + padding-left: $sp-3; + background-color: $table-background-color; + border-bottom: $border rgba($border-color, 0.5); + border-left: $border $border-color; + + &:first-of-type { + border-left: 0; + } +} + +tbody { + tr { + &:last-of-type { + th, + td { + border-bottom: 0; + } + + td { + padding-bottom: $sp-3; + } + } + } +} + +thead { + th { + border-bottom: $border $border-color; + } +} diff --git a/docs/_sass/typography.scss b/docs/_sass/typography.scss new file mode 100644 index 0000000000..cadee362dc --- /dev/null +++ b/docs/_sass/typography.scss @@ -0,0 +1,64 @@ +// +// Typography +// +// stylelint-disable primer/selector-no-utility, primer/no-override, selector-no-type, selector-max-type + +h1, +.text-alpha { + @include fs-8; + font-weight: 300; +} + +h2, +.text-beta { + @include fs-6; +} + +h3, +.text-gamma { + @include fs-5; +} + +h4, +.text-delta { + @include fs-2; + font-weight: 400; + text-transform: uppercase; + letter-spacing: 0.1em; +} + +h4 code { + text-transform: none; +} + +h5, +.text-epsilon { + @include fs-3; + color: $grey-dk-200; +} + +h6, +.text-zeta { + @include fs-2; + color: $grey-dk-200; +} + +.text-small { + @include fs-2; +} + +.text-mono { + font-family: $mono-font-family !important; +} + +.text-left { + text-align: left !important; +} + +.text-center { + text-align: center !important; +} + +.text-right { + text-align: right !important; +} diff --git a/docs/_sass/utilities/_colors.scss b/docs/_sass/utilities/_colors.scss new file mode 100644 index 0000000000..f3607ab895 --- /dev/null +++ b/docs/_sass/utilities/_colors.scss @@ -0,0 +1,239 @@ +// +// Utility classes for colors +// + +// Text colors + +.text-grey-dk-000 { + color: $grey-dk-000 !important; +} + +.text-grey-dk-100 { + color: $grey-dk-100 !important; +} + +.text-grey-dk-200 { + color: $grey-dk-200 !important; +} + +.text-grey-dk-250 { + color: $grey-dk-250 !important; +} + +.text-grey-dk-300 { + color: $grey-dk-300 !important; +} + +.text-grey-lt-000 { + color: $grey-lt-000 !important; +} + +.text-grey-lt-100 { + color: $grey-lt-100 !important; +} + +.text-grey-lt-200 { + color: $grey-lt-200 !important; +} + +.text-grey-lt-300 { + color: $grey-lt-300 !important; +} + +.text-blue-000 { + color: $blue-000 !important; +} + +.text-blue-100 { + color: $blue-100 !important; +} + +.text-blue-200 { + color: $blue-200 !important; +} + +.text-blue-300 { + color: $blue-300 !important; +} + +.text-green-000 { + color: $green-000 !important; +} + +.text-green-100 { + color: $green-100 !important; +} + +.text-green-200 { + color: $green-200 !important; +} + +.text-green-300 { + color: $green-300 !important; +} + +.text-purple-000 { + color: $purple-000 !important; +} + +.text-purple-100 { + color: $purple-100 !important; +} + +.text-purple-200 { + color: $purple-200 !important; +} + +.text-purple-300 { + color: $purple-300 !important; +} + +.text-yellow-000 { + color: $yellow-000 !important; +} + +.text-yellow-100 { + color: $yellow-100 !important; +} + +.text-yellow-200 { + color: $yellow-200 !important; +} + +.text-yellow-300 { + color: $yellow-300 !important; +} + +.text-red-000 { + color: $red-000 !important; +} + +.text-red-100 { + color: $red-100 !important; +} + +.text-red-200 { + color: $red-200 !important; +} + +.text-red-300 { + color: $red-300 !important; +} + +// Background colors + +.bg-grey-dk-000 { + background-color: $grey-dk-000 !important; +} + +.bg-grey-dk-100 { + background-color: $grey-dk-100 !important; +} + +.bg-grey-dk-200 { + background-color: $grey-dk-200 !important; +} + +.bg-grey-dk-250 { + background-color: $grey-dk-250 !important; +} + +.bg-grey-dk-300 { + background-color: $grey-dk-300 !important; +} + +.bg-grey-lt-000 { + background-color: $grey-lt-000 !important; +} + +.bg-grey-lt-100 { + background-color: $grey-lt-100 !important; +} + +.bg-grey-lt-200 { + background-color: $grey-lt-200 !important; +} + +.bg-grey-lt-300 { + background-color: $grey-lt-300 !important; +} + +.bg-blue-000 { + background-color: $blue-000 !important; +} + +.bg-blue-100 { + background-color: $blue-100 !important; +} + +.bg-blue-200 { + background-color: $blue-200 !important; +} + +.bg-blue-300 { + background-color: $blue-300 !important; +} + +.bg-green-000 { + background-color: $green-000 !important; +} + +.bg-green-100 { + background-color: $green-100 !important; +} + +.bg-green-200 { + background-color: $green-200 !important; +} + +.bg-green-300 { + background-color: $green-300 !important; +} + +.bg-purple-000 { + background-color: $purple-000 !important; +} + +.bg-purple-100 { + background-color: $purple-100 !important; +} + +.bg-purple-200 { + background-color: $purple-200 !important; +} + +.bg-purple-300 { + background-color: $purple-300 !important; +} + +.bg-yellow-000 { + background-color: $yellow-000 !important; +} + +.bg-yellow-100 { + background-color: $yellow-100 !important; +} + +.bg-yellow-200 { + background-color: $yellow-200 !important; +} + +.bg-yellow-300 { + background-color: $yellow-300 !important; +} + +.bg-red-000 { + background-color: $red-000 !important; +} + +.bg-red-100 { + background-color: $red-100 !important; +} + +.bg-red-200 { + background-color: $red-200 !important; +} + +.bg-red-300 { + background-color: $red-300 !important; +} diff --git a/docs/_sass/utilities/_layout.scss b/docs/_sass/utilities/_layout.scss new file mode 100644 index 0000000000..37ebe42142 --- /dev/null +++ b/docs/_sass/utilities/_layout.scss @@ -0,0 +1,95 @@ +// stylelint-disable primer/selector-no-utility, primer/no-override +// +// Utility classes for layout +// + +// Display + +.d-block { + display: block !important; +} +.d-flex { + display: flex !important; +} +.d-inline { + display: inline !important; +} +.d-inline-block { + display: inline-block !important; +} +.d-none { + display: none !important; +} + +@each $media-query in map-keys($media-queries) { + @for $i from 1 through length($spacers) { + @include mq($media-query) { + $size: #{map-get($spacers, sp-#{$i - 1})}; + $scale: #{$i - 1}; + + // .d-sm-block, .d-md-none, .d-lg-inline + .d-#{$media-query}-block { + display: block !important; + } + .d-#{$media-query}-flex { + display: flex !important; + } + .d-#{$media-query}-inline { + display: inline !important; + } + .d-#{$media-query}-inline-block { + display: inline-block !important; + } + .d-#{$media-query}-none { + display: none !important; + } + } + } +} + +// Horizontal alignment + +.float-left { + float: left !important; +} + +.float-right { + float: right !important; +} + +.flex-justify-start { + justify-content: flex-start !important; +} + +.flex-justify-end { + justify-content: flex-end !important; +} + +.flex-justify-between { + justify-content: space-between !important; +} + +.flex-justify-around { + justify-content: space-around !important; +} + +// Vertical alignment + +.v-align-baseline { + vertical-align: baseline !important; +} +.v-align-bottom { + vertical-align: bottom !important; +} +.v-align-middle { + vertical-align: middle !important; +} +.v-align-text-bottom { + vertical-align: text-bottom !important; +} +.v-align-text-top { + vertical-align: text-top !important; +} +.v-align-top { + vertical-align: top !important; +} diff --git a/docs/_sass/utilities/_lists.scss b/docs/_sass/utilities/_lists.scss new file mode 100644 index 0000000000..c7b2293d0f --- /dev/null +++ b/docs/_sass/utilities/_lists.scss @@ -0,0 +1,17 @@ +// +// Utility classes for lists +// + +// stylelint-disable primer/selector-no-utility, primer/no-override, selector-max-type + +.list-style-none { + padding: 0 !important; + margin: 0 !important; + list-style: none !important; + + li { + &::before { + display: none !important; + } + } +} diff --git a/docs/_sass/utilities/_spacing.scss b/docs/_sass/utilities/_spacing.scss new file mode 100644 index 0000000000..162f8017a3 --- /dev/null +++ b/docs/_sass/utilities/_spacing.scss @@ -0,0 +1,165 @@ +// +// Utility classes for margins and padding +// + +// scss-lint:disable SpaceAfterPropertyName +// stylelint-disable block-opening-brace-space-after, block-opening-brace-space-before, primer/selector-no-utility, primer/no-override + +// Margin spacer utilities + +.mx-auto { + margin-right: auto !important; + margin-left: auto !important; +} + +@for $i from 1 through length($spacers) { + $size: #{map-get($spacers, sp-#{$i - 1})}; + $scale: #{$i - 1}; + + // .m-0, .m-1, .m-2... + .m-#{$scale} { + margin: #{$size} !important; + } + .mt-#{$scale} { + margin-top: #{$size} !important; + } + .mr-#{$scale} { + margin-right: #{$size} !important; + } + .mb-#{$scale} { + margin-bottom: #{$size} !important; + } + .ml-#{$scale} { + margin-left: #{$size} !important; + } + + .mx-#{$scale} { + margin-right: #{$size} !important; + margin-left: #{$size} !important; + } + + .my-#{$scale} { + margin-top: #{$size} !important; + margin-bottom: #{$size} !important; + } + + .mxn-#{$scale} { + margin-right: -#{$size} !important; + margin-left: -#{$size} !important; + } + .mx-#{$scale}-auto { + margin-right: auto !important; + margin-left: auto !important; + } +} + +@each $media-query in map-keys($media-queries) { + @for $i from 1 through length($spacers) { + @include mq($media-query) { + $size: #{map-get($spacers, sp-#{$i - 1})}; + $scale: #{$i - 1}; + + // .m-sm-0, .m-md-1, .m-lg-2... + .m-#{$media-query}-#{$scale} { + margin: #{$size} !important; + } + .mt-#{$media-query}-#{$scale} { + margin-top: #{$size} !important; + } + .mr-#{$media-query}-#{$scale} { + margin-right: #{$size} !important; + } + .mb-#{$media-query}-#{$scale} { + margin-bottom: #{$size} !important; + } + .ml-#{$media-query}-#{$scale} { + margin-left: #{$size} !important; + } + + .mx-#{$media-query}-#{$scale} { + margin-right: #{$size} !important; + margin-left: #{$size} !important; + } + + .my-#{$media-query}-#{$scale} { + margin-top: #{$size} !important; + margin-bottom: #{$size} !important; + } + + .mxn-#{$media-query}-#{$scale} { + margin-right: -#{$size} !important; + margin-left: -#{$size} !important; + } + } + } +} + +// Padding spacer utilities + +@for $i from 1 through length($spacers) { + $size: #{map-get($spacers, sp-#{$i - 1})}; + $scale: #{$i - 1}; + + // .p-0, .p-1, .p-2... + .p-#{$scale} { + padding: #{$size} !important; + } + .pt-#{$scale} { + padding-top: #{$size} !important; + } + .pr-#{$scale} { + padding-right: #{$size} !important; + } + .pb-#{$scale} { + padding-bottom: #{$size} !important; + } + .pl-#{$scale} { + padding-left: #{$size} !important; + } + + .px-#{$scale} { + padding-right: #{$size} !important; + padding-left: #{$size} !important; + } + + .py-#{$scale} { + padding-top: #{$size} !important; + padding-bottom: #{$size} !important; + } +} + +@each $media-query in map-keys($media-queries) { + @include mq($media-query) { + @for $i from 1 through length($spacers) { + $size: #{map-get($spacers, sp-#{$i - 1})}; + $scale: #{$i - 1}; + + // .p-sm-0, .p-md-1, .p-lg-2... + .p-#{$media-query}-#{$scale} { + padding: #{$size} !important; + } + .pt-#{$media-query}-#{$scale} { + padding-top: #{$size} !important; + } + .pr-#{$media-query}-#{$scale} { + padding-right: #{$size} !important; + } + .pb-#{$media-query}-#{$scale} { + padding-bottom: #{$size} !important; + } + .pl-#{$media-query}-#{$scale} { + padding-left: #{$size} !important; + } + + .px-#{$media-query}-#{$scale} { + padding-right: #{$size} !important; + padding-left: #{$size} !important; + } + + .py-#{$media-query}-#{$scale} { + padding-top: #{$size} !important; + padding-bottom: #{$size} !important; + } + } + } +} diff --git a/docs/_sass/utilities/_typography.scss b/docs/_sass/utilities/_typography.scss new file mode 100644 index 0000000000..2397acbc08 --- /dev/null +++ b/docs/_sass/utilities/_typography.scss @@ -0,0 +1,91 @@ +// +// Utility classes for typography +// + +// stylelint-disable primer/selector-no-utility, primer/no-override + +.fs-1 { + @include fs-1; +} + +.fs-2 { + @include fs-2; +} + +.fs-3 { + @include fs-3; +} + +.fs-4 { + @include fs-4; +} + +.fs-5 { + @include fs-5; +} + +.fs-6 { + @include fs-6; +} + +.fs-7 { + @include fs-7; +} + +.fs-8 { + @include fs-8; +} + +.fs-9 { + @include fs-9; +} + +.fs-10 { + @include fs-10; +} + +.fw-300 { + font-weight: 300 !important; +} + +.fw-400 { + font-weight: 400 !important; +} + +.fw-500 { + font-weight: 500 !important; +} + +.fw-700 { + font-weight: 700 !important; +} + +.lh-0 { + line-height: 0 !important; +} + +.lh-default { + line-height: $body-line-height; +} + +.lh-tight { + line-height: $body-heading-line-height; +} + +.ls-5 { + letter-spacing: 0.05em !important; +} + +.ls-10 { + letter-spacing: 0.1em !important; +} + +.ls-0 { + letter-spacing: 0 !important; +} + +.text-uppercase { + text-transform: uppercase !important; +} + +// stylelint-enable primer/selector-no-utility diff --git a/docs/_sass/utilities/utilities.scss b/docs/_sass/utilities/utilities.scss new file mode 100644 index 0000000000..6c25bdfa7a --- /dev/null +++ b/docs/_sass/utilities/utilities.scss @@ -0,0 +1,5 @@ +@import "./colors"; +@import "./layout"; +@import "./typography"; +@import "./lists"; +@import "./spacing"; diff --git a/docs/_sass/vendor/normalize.scss/README.md b/docs/_sass/vendor/normalize.scss/README.md new file mode 100644 index 0000000000..7af1714a9f --- /dev/null +++ b/docs/_sass/vendor/normalize.scss/README.md @@ -0,0 +1,7 @@ +# normalize.scss + +Normalize.scss is an SCSS copy of [normalize.css](http://necolas.github.io/normalize.css), a customisable CSS file that makes browsers render all elements more consistently and in line with modern standards. + +The [normalize.scss fork](https://github.com/guerrero/normalize.scss) of [normalize.css](http://necolas.github.io/normalize.css) was archived in 2014, and has not been updated since v0.1.0. + +[View the normalize.css test file](http://necolas.github.io/normalize.css/latest/test.html) diff --git a/docs/_sass/vendor/normalize.scss/normalize.scss b/docs/_sass/vendor/normalize.scss/normalize.scss new file mode 100644 index 0000000000..192eb9ce43 --- /dev/null +++ b/docs/_sass/vendor/normalize.scss/normalize.scss @@ -0,0 +1,349 @@ +/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */ + +/* Document + ========================================================================== */ + +/** + * 1. Correct the line height in all browsers. + * 2. Prevent adjustments of font size after orientation changes in iOS. + */ + +html { + line-height: 1.15; /* 1 */ + -webkit-text-size-adjust: 100%; /* 2 */ +} + +/* Sections + ========================================================================== */ + +/** + * Remove the margin in all browsers. + */ + +body { + margin: 0; +} + +/** + * Render the `main` element consistently in IE. + */ + +main { + display: block; +} + +/** + * Correct the font size and margin on `h1` elements within `section` and + * `article` contexts in Chrome, Firefox, and Safari. + */ + +h1 { + font-size: 2em; + margin: 0.67em 0; +} + +/* Grouping content + ========================================================================== */ + +/** + * 1. Add the correct box sizing in Firefox. + * 2. Show the overflow in Edge and IE. + */ + +hr { + box-sizing: content-box; /* 1 */ + height: 0; /* 1 */ + overflow: visible; /* 2 */ +} + +/** + * 1. Correct the inheritance and scaling of font size in all browsers. + * 2. Correct the odd `em` font sizing in all browsers. + */ + +pre { + font-family: monospace, monospace; /* 1 */ + font-size: 1em; /* 2 */ +} + +/* Text-level semantics + ========================================================================== */ + +/** + * Remove the gray background on active links in IE 10. + */ + +a { + background-color: transparent; +} + +/** + * 1. Remove the bottom border in Chrome 57- + * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari. + */ + +abbr[title] { + border-bottom: none; /* 1 */ + text-decoration: underline; /* 2 */ + text-decoration: underline dotted; /* 2 */ +} + +/** + * Add the correct font weight in Chrome, Edge, and Safari. + */ + +b, +strong { + font-weight: bolder; +} + +/** + * 1. Correct the inheritance and scaling of font size in all browsers. + * 2. Correct the odd `em` font sizing in all browsers. + */ + +code, +kbd, +samp { + font-family: monospace, monospace; /* 1 */ + font-size: 1em; /* 2 */ +} + +/** + * Add the correct font size in all browsers. + */ + +small { + font-size: 80%; +} + +/** + * Prevent `sub` and `sup` elements from affecting the line height in + * all browsers. + */ + +sub, +sup { + font-size: 75%; + line-height: 0; + position: relative; + vertical-align: baseline; +} + +sub { + bottom: -0.25em; +} + +sup { + top: -0.5em; +} + +/* Embedded content + ========================================================================== */ + +/** + * Remove the border on images inside links in IE 10. + */ + +img { + border-style: none; +} + +/* Forms + ========================================================================== */ + +/** + * 1. Change the font styles in all browsers. + * 2. Remove the margin in Firefox and Safari. + */ + +button, +input, +optgroup, +select, +textarea { + font-family: inherit; /* 1 */ + font-size: 100%; /* 1 */ + line-height: 1.15; /* 1 */ + margin: 0; /* 2 */ +} + +/** + * Show the overflow in IE. + * 1. Show the overflow in Edge. + */ + +button, +input { /* 1 */ + overflow: visible; +} + +/** + * Remove the inheritance of text transform in Edge, Firefox, and IE. + * 1. Remove the inheritance of text transform in Firefox. + */ + +button, +select { /* 1 */ + text-transform: none; +} + +/** + * Correct the inability to style clickable types in iOS and Safari. + */ + +button, +[type="button"], +[type="reset"], +[type="submit"] { + -webkit-appearance: button; +} + +/** + * Remove the inner border and padding in Firefox. + */ + +button::-moz-focus-inner, +[type="button"]::-moz-focus-inner, +[type="reset"]::-moz-focus-inner, +[type="submit"]::-moz-focus-inner { + border-style: none; + padding: 0; +} + +/** + * Restore the focus styles unset by the previous rule. + */ + +button:-moz-focusring, +[type="button"]:-moz-focusring, +[type="reset"]:-moz-focusring, +[type="submit"]:-moz-focusring { + outline: 1px dotted ButtonText; +} + +/** + * Correct the padding in Firefox. + */ + +fieldset { + padding: 0.35em 0.75em 0.625em; +} + +/** + * 1. Correct the text wrapping in Edge and IE. + * 2. Correct the color inheritance from `fieldset` elements in IE. + * 3. Remove the padding so developers are not caught out when they zero out + * `fieldset` elements in all browsers. + */ + +legend { + box-sizing: border-box; /* 1 */ + color: inherit; /* 2 */ + display: table; /* 1 */ + max-width: 100%; /* 1 */ + padding: 0; /* 3 */ + white-space: normal; /* 1 */ +} + +/** + * Add the correct vertical alignment in Chrome, Firefox, and Opera. + */ + +progress { + vertical-align: baseline; +} + +/** + * Remove the default vertical scrollbar in IE 10+. + */ + +textarea { + overflow: auto; +} + +/** + * 1. Add the correct box sizing in IE 10. + * 2. Remove the padding in IE 10. + */ + +[type="checkbox"], +[type="radio"] { + box-sizing: border-box; /* 1 */ + padding: 0; /* 2 */ +} + +/** + * Correct the cursor style of increment and decrement buttons in Chrome. + */ + +[type="number"]::-webkit-inner-spin-button, +[type="number"]::-webkit-outer-spin-button { + height: auto; +} + +/** + * 1. Correct the odd appearance in Chrome and Safari. + * 2. Correct the outline style in Safari. + */ + +[type="search"] { + -webkit-appearance: textfield; /* 1 */ + outline-offset: -2px; /* 2 */ +} + +/** + * Remove the inner padding in Chrome and Safari on macOS. + */ + +[type="search"]::-webkit-search-decoration { + -webkit-appearance: none; +} + +/** + * 1. Correct the inability to style clickable types in iOS and Safari. + * 2. Change font properties to `inherit` in Safari. + */ + +::-webkit-file-upload-button { + -webkit-appearance: button; /* 1 */ + font: inherit; /* 2 */ +} + +/* Interactive + ========================================================================== */ + +/* + * Add the correct display in Edge, IE 10+, and Firefox. + */ + +details { + display: block; +} + +/* + * Add the correct display in all browsers. + */ + +summary { + display: list-item; +} + +/* Misc + ========================================================================== */ + +/** + * Add the correct display in IE 10+. + */ + +template { + display: none; +} + +/** + * Add the correct display in IE 10. + */ + +[hidden] { + display: none; +} diff --git a/docs/apikey.pub b/docs/apikey.pub new file mode 120000 index 0000000000..47a9d01186 --- /dev/null +++ b/docs/apikey.pub @@ -0,0 +1 @@ +.well-known/amphtml/apikey.pub \ No newline at end of file diff --git a/docs/assets/css/just-the-docs-dark.scss b/docs/assets/css/just-the-docs-dark.scss new file mode 100644 index 0000000000..7310755231 --- /dev/null +++ b/docs/assets/css/just-the-docs-dark.scss @@ -0,0 +1,8 @@ +--- +layout: empty +--- +$logo: "https://docs.madelineproto.xyz/logo.png"; +@import "./support/support"; +@import "./color_schemes/dark"; +@import "./modules"; +@import "./custom/custom"; diff --git a/docs/assets/css/just-the-docs-light.scss b/docs/assets/css/just-the-docs-light.scss new file mode 100644 index 0000000000..2cd1c233c1 --- /dev/null +++ b/docs/assets/css/just-the-docs-light.scss @@ -0,0 +1,8 @@ +--- +layout: empty +--- +$logo: "https://docs.madelineproto.xyz/logo.png"; +@import "./support/support"; +@import "./color_schemes/light"; +@import "./modules"; +@import "./custom/custom"; diff --git a/docs/assets/images/just-the-docs.png b/docs/assets/images/just-the-docs.png new file mode 100644 index 0000000000..81c33065f2 Binary files /dev/null and b/docs/assets/images/just-the-docs.png differ diff --git a/docs/assets/images/search.svg b/docs/assets/images/search.svg new file mode 100644 index 0000000000..421ca4df01 --- /dev/null +++ b/docs/assets/images/search.svg @@ -0,0 +1 @@ +Search diff --git a/docs/assets/js/just-the-docs.js b/docs/assets/js/just-the-docs.js new file mode 100644 index 0000000000..a10f4ee737 --- /dev/null +++ b/docs/assets/js/just-the-docs.js @@ -0,0 +1,488 @@ +--- +layout: empty +--- +(function (jtd, undefined) { + +// Switch theme + +jtd.setTheme = function(theme) { + if (!theme || theme === 'null') theme = 'dark'; + window.localStorage.setItem('theme', theme); + var cssFile = document.querySelector('[rel="stylesheet"]'); + cssFile.setAttribute('href', '/assets/css/just-the-docs-' + theme + '.css'); +} + +// Event handling + +jtd.addEvent = function(el, type, handler) { + if (el.attachEvent) el.attachEvent('on'+type, handler); else el.addEventListener(type, handler); +} +jtd.removeEvent = function(el, type, handler) { + if (el.detachEvent) el.detachEvent('on'+type, handler); else el.removeEventListener(type, handler); +} +jtd.onReady = function(ready) { + // in case the document is already rendered + if (document.readyState!='loading') ready(); + // modern browsers + else if (document.addEventListener) document.addEventListener('DOMContentLoaded', ready); + // IE <= 8 + else document.attachEvent('onreadystatechange', function(){ + if (document.readyState=='complete') ready(); + }); +} + +// Show/hide mobile menu + +function initNav() { + jtd.addEvent(document, 'click', function(e){ + var target = e.target; + while (target && !(target.classList && target.classList.contains('nav-list-expander'))) { + target = target.parentNode; + } + if (target) { + e.preventDefault(); + target.parentNode.classList.toggle('active'); + } + }); + + for (const btn of document.getElementsByClassName('theme-dark-button')) { + btn.addEventListener('click', () => jtd.setTheme('dark')); + } + for (const btn of document.getElementsByClassName('theme-light-button')) { + btn.addEventListener('click', () => jtd.setTheme('light')); + } + + const oReq = new XMLHttpRequest(); + oReq.addEventListener("load", function () { + const stargazers = parseFloat(JSON.parse(this.responseText).stargazers_count); + document.getElementById('star-button').innerHTML = "⭐️ "+Math.floor(stargazers/100)/10+"k"; + }); + oReq.open("GET", "https://api.github.com/repos/danog/madelineproto"); + oReq.send(); + + const siteNav = document.getElementById('site-nav'); + const mainHeader = document.getElementById('main-header'); + const menuButton = document.getElementById('menu-button'); + + jtd.addEvent(menuButton, 'click', function(e){ + e.preventDefault(); + + if (menuButton.classList.toggle('nav-open')) { + siteNav.classList.add('nav-open'); + mainHeader.classList.add('nav-open'); + } else { + siteNav.classList.remove('nav-open'); + mainHeader.classList.remove('nav-open'); + } + }); + + const searchInput = document.getElementById('search-input'); + const searchButton = document.getElementById('search-button'); + + jtd.addEvent(searchButton, 'click', function(e){ + e.preventDefault(); + + mainHeader.classList.add('nav-open'); + searchInput.focus(); + }); + + jtd.addEvent(searchInput, 'focus', function(){ + initSearch(function () { + setTimeout(update, 0); + }); + }); + + jtd.addEvent(searchInput, 'keyup', function(e){ + initSearch(function () { + switch (e.keyCode) { + case 27: // When esc key is pressed, hide the results and clear the field + searchInput.value = ''; + break; + case 38: // arrow up + case 40: // arrow down + case 13: // enter + e.preventDefault(); + return; + } + update(); + }); + }); + + jtd.addEvent(searchInput, 'keydown', function(e){ + initSearch(function () { + switch (e.keyCode) { + case 38: // arrow up + e.preventDefault(); + var active = document.querySelector('.search-result.active'); + if (active) { + active.classList.remove('active'); + if (active.parentElement.previousSibling) { + var previous = active.parentElement.previousSibling.querySelector('.search-result'); + previous.classList.add('active'); + } + } + return; + case 40: // arrow down + e.preventDefault(); + var active = document.querySelector('.search-result.active'); + if (active) { + if (active.parentElement.nextSibling) { + var next = active.parentElement.nextSibling.querySelector('.search-result'); + active.classList.remove('active'); + next.classList.add('active'); + } + } else { + var next = document.querySelector('.search-result'); + if (next) { + next.classList.add('active'); + } + } + return; + case 13: // enter + e.preventDefault(); + var active = document.querySelector('.search-result.active'); + if (active) { + active.click(); + } else { + var first = document.querySelector('.search-result'); + if (first) { + first.click(); + } + } + return; + } + }); + }); + + jtd.addEvent(document, 'click', function(e){ + if (e.target != searchInput) { + hideSearch(); + } + }); +} + +// Site search + +function initSearch(cb) { + if (window.searchDbLoaded) { + cb(); + return; + } + var request = new XMLHttpRequest(); + request.open('GET', '/assets/js/search-data.json', true); + + request.onload = function(){ + if (request.status >= 200 && request.status < 400) { + var docs = JSON.parse(request.responseText); + + lunr.tokenizer.separator = {{ site.search.tokenizer_separator | default: site.search_tokenizer_separator | default: "/[\s\-/]+/" }} + + var index = lunr(function(){ + this.ref('id'); + this.field('title', { boost: 200 }); + this.field('content', { boost: 2 }); + {%- if site.search.rel_url != false %} + this.field('relUrl'); + {%- endif %} + this.metadataWhitelist = ['position'] + + for (var i in docs) { + this.add({ + id: i, + title: docs[i].title, + content: docs[i].content, + {%- if site.search.rel_url != false %} + relUrl: docs[i].relUrl + {%- endif %} + }); + } + }); + + window.index = index; + window.docs = docs; + window.searchDbLoaded = true; + cb(); + } else { + console.log('Error loading ajax request. Request status:' + request.status); + } + }; + + request.onerror = function(){ + console.log('There was a connection error'); + }; + + request.send(); +} + +var searchInput = document.getElementById('search-input'); +var searchResults = document.getElementById('search-results'); +var mainHeader = document.getElementById('main-header'); +var currentInput; +var currentSearchIndex = 0; + +function showSearch() { + document.documentElement.classList.add('search-active'); +} + +function hideSearch() { + document.documentElement.classList.remove('search-active'); +} + +function update() { + currentSearchIndex++; + + var input = searchInput.value; + if (input === '') { + hideSearch(); + } else { + showSearch(); + // scroll search input into view, workaround for iOS Safari + window.scroll(0, -1); + setTimeout(function(){ window.scroll(0, 0); }, 0); + } + if (input === currentInput) { + return; + } + currentInput = input; + searchResults.innerHTML = ''; + if (input === '') { + return; + } + + var results = window.index.query(function (query) { + var tokens = lunr.tokenizer(input) + query.term(tokens, { + boost: 10 + }); + query.term(tokens, { + wildcard: lunr.Query.wildcard.TRAILING + }); + }); + + if ((results.length == 0) && (input.length > 2)) { + var tokens = lunr.tokenizer(input).filter(function(token, i) { + return token.str.length < 20; + }) + if (tokens.length > 0) { + results = window.index.query(function (query) { + query.term(tokens, { + editDistance: Math.round(Math.sqrt(input.length / 2 - 1)) + }); + }); + } + } + + if (results.length == 0) { + var noResultsDiv = document.createElement('div'); + noResultsDiv.classList.add('search-no-result'); + noResultsDiv.innerText = 'No results found'; + searchResults.appendChild(noResultsDiv); + + } else { + var resultsList = document.createElement('ul'); + resultsList.classList.add('search-results-list'); + searchResults.appendChild(resultsList); + + addResults(resultsList, results, 0, 10, 100, currentSearchIndex); + } + + function addResults(resultsList, results, start, batchSize, batchMillis, searchIndex) { + if (searchIndex != currentSearchIndex) { + return; + } + for (var i = start; i < (start + batchSize); i++) { + if (i == results.length) { + return; + } + addResult(resultsList, results[i]); + } + setTimeout(function() { + addResults(resultsList, results, start + batchSize, batchSize, batchMillis, searchIndex); + }, batchMillis); + } + + function addResult(resultsList, result) { + var doc = window.docs[result.ref]; + + var resultsListItem = document.createElement('li'); + resultsListItem.classList.add('search-results-list-item'); + resultsList.appendChild(resultsListItem); + + var resultLink = document.createElement('a'); + resultLink.classList.add('search-result'); + resultLink.setAttribute('href', doc.url); + resultsListItem.appendChild(resultLink); + + var resultTitle = document.createElement('div'); + resultTitle.classList.add('search-result-title'); + resultLink.appendChild(resultTitle); + + var resultDoc = document.createElement('div'); + resultDoc.classList.add('search-result-doc'); + resultDoc.innerHTML = ''; + resultTitle.appendChild(resultDoc); + + var resultDocTitle = document.createElement('div'); + resultDocTitle.classList.add('search-result-doc-title'); + resultDocTitle.innerHTML = doc.doc; + resultDoc.appendChild(resultDocTitle); + var resultDocOrSection = resultDocTitle; + + if (doc.doc != doc.title) { + resultDoc.classList.add('search-result-doc-parent'); + var resultSection = document.createElement('div'); + resultSection.classList.add('search-result-section'); + resultSection.innerHTML = doc.title; + resultTitle.appendChild(resultSection); + resultDocOrSection = resultSection; + } + + var metadata = result.matchData.metadata; + var titlePositions = []; + var contentPositions = []; + for (var j in metadata) { + var meta = metadata[j]; + if (meta.title) { + var positions = meta.title.position; + for (var k in positions) { + titlePositions.push(positions[k]); + } + } + if (meta.content) { + var positions = meta.content.position; + for (var k in positions) { + var position = positions[k]; + var previewStart = position[0]; + var previewEnd = position[0] + position[1]; + var ellipsesBefore = true; + var ellipsesAfter = true; + for (var k = 0; k < {{ site.search.preview_words_before | default: 5 }}; k++) { + var nextSpace = doc.content.lastIndexOf(' ', previewStart - 2); + var nextDot = doc.content.lastIndexOf('. ', previewStart - 2); + if ((nextDot >= 0) && (nextDot > nextSpace)) { + previewStart = nextDot + 1; + ellipsesBefore = false; + break; + } + if (nextSpace < 0) { + previewStart = 0; + ellipsesBefore = false; + break; + } + previewStart = nextSpace + 1; + } + for (var k = 0; k < {{ site.search.preview_words_after | default: 10 }}; k++) { + var nextSpace = doc.content.indexOf(' ', previewEnd + 1); + var nextDot = doc.content.indexOf('. ', previewEnd + 1); + if ((nextDot >= 0) && (nextDot < nextSpace)) { + previewEnd = nextDot; + ellipsesAfter = false; + break; + } + if (nextSpace < 0) { + previewEnd = doc.content.length; + ellipsesAfter = false; + break; + } + previewEnd = nextSpace; + } + contentPositions.push({ + highlight: position, + previewStart: previewStart, previewEnd: previewEnd, + ellipsesBefore: ellipsesBefore, ellipsesAfter: ellipsesAfter + }); + } + } + } + + if (titlePositions.length > 0) { + titlePositions.sort(function(p1, p2){ return p1[0] - p2[0] }); + resultDocOrSection.innerHTML = ''; + addHighlightedText(resultDocOrSection, doc.title, 0, doc.title.length, titlePositions); + } + + if (contentPositions.length > 0) { + contentPositions.sort(function(p1, p2){ return p1.highlight[0] - p2.highlight[0] }); + var contentPosition = contentPositions[0]; + var previewPosition = { + highlight: [contentPosition.highlight], + previewStart: contentPosition.previewStart, previewEnd: contentPosition.previewEnd, + ellipsesBefore: contentPosition.ellipsesBefore, ellipsesAfter: contentPosition.ellipsesAfter + }; + var previewPositions = [previewPosition]; + for (var j = 1; j < contentPositions.length; j++) { + contentPosition = contentPositions[j]; + if (previewPosition.previewEnd < contentPosition.previewStart) { + previewPosition = { + highlight: [contentPosition.highlight], + previewStart: contentPosition.previewStart, previewEnd: contentPosition.previewEnd, + ellipsesBefore: contentPosition.ellipsesBefore, ellipsesAfter: contentPosition.ellipsesAfter + } + previewPositions.push(previewPosition); + } else { + previewPosition.highlight.push(contentPosition.highlight); + previewPosition.previewEnd = contentPosition.previewEnd; + previewPosition.ellipsesAfter = contentPosition.ellipsesAfter; + } + } + + var resultPreviews = document.createElement('div'); + resultPreviews.classList.add('search-result-previews'); + resultLink.appendChild(resultPreviews); + + var content = doc.content; + for (var j = 0; j < Math.min(previewPositions.length, {{ site.search.previews | default: 3 }}); j++) { + var position = previewPositions[j]; + + var resultPreview = document.createElement('div'); + resultPreview.classList.add('search-result-preview'); + resultPreviews.appendChild(resultPreview); + + if (position.ellipsesBefore) { + resultPreview.appendChild(document.createTextNode('... ')); + } + addHighlightedText(resultPreview, content, position.previewStart, position.previewEnd, position.highlight); + if (position.ellipsesAfter) { + resultPreview.appendChild(document.createTextNode(' ...')); + } + } + } + + {%- if site.search.rel_url != false %} + var resultRelUrl = document.createElement('span'); + resultRelUrl.classList.add('search-result-rel-url'); + resultRelUrl.innerText = doc.relUrl; + resultTitle.appendChild(resultRelUrl); + {%- endif %} + } + + function addHighlightedText(parent, text, start, end, positions) { + var index = start; + for (var i in positions) { + var position = positions[i]; + var span = document.createElement('span'); + span.innerHTML = text.substring(index, position[0]); + parent.appendChild(span); + index = position[0] + position[1]; + var highlight = document.createElement('span'); + highlight.classList.add('search-result-highlight'); + highlight.innerHTML = text.substring(position[0], index); + parent.appendChild(highlight); + } + var span = document.createElement('span'); + span.innerHTML = text.substring(index, end); + parent.appendChild(span); + } +} +// Document ready + +jtd.onReady(function(){ + initNav(); + if (window.location.hash) { + setTimeout(function () { + document.getElementById(window.location.hash.slice(1)).scrollIntoView(); + }, 50); + } +}); + +})(window.jtd = window.jtd || {}); diff --git a/docs/assets/js/vendor/lunr.min.js b/docs/assets/js/vendor/lunr.min.js new file mode 100644 index 0000000000..cdc94cd390 --- /dev/null +++ b/docs/assets/js/vendor/lunr.min.js @@ -0,0 +1,6 @@ +/** + * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9 + * Copyright (C) 2020 Oliver Nightingale + * @license MIT + */ +!function(){var e=function(t){var r=new e.Builder;return r.pipeline.add(e.trimmer,e.stopWordFilter,e.stemmer),r.searchPipeline.add(e.stemmer),t.call(r,r),r.build()};e.version="2.3.9",e.utils={},e.utils.warn=function(e){return function(t){e.console&&console.warn&&console.warn(t)}}(this),e.utils.asString=function(e){return void 0===e||null===e?"":e.toString()},e.utils.clone=function(e){if(null===e||void 0===e)return e;for(var t=Object.create(null),r=Object.keys(e),i=0;i0){var c=e.utils.clone(r)||{};c.position=[a,l],c.index=s.length,s.push(new e.Token(i.slice(a,o),c))}a=o+1}}return s},e.tokenizer.separator=/[\s\-]+/,e.Pipeline=function(){this._stack=[]},e.Pipeline.registeredFunctions=Object.create(null),e.Pipeline.registerFunction=function(t,r){r in this.registeredFunctions&&e.utils.warn("Overwriting existing registered function: "+r),t.label=r,e.Pipeline.registeredFunctions[t.label]=t},e.Pipeline.warnIfFunctionNotRegistered=function(t){var r=t.label&&t.label in this.registeredFunctions;r||e.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\n",t)},e.Pipeline.load=function(t){var r=new e.Pipeline;return t.forEach(function(t){var i=e.Pipeline.registeredFunctions[t];if(!i)throw new Error("Cannot load unregistered function: "+t);r.add(i)}),r},e.Pipeline.prototype.add=function(){var t=Array.prototype.slice.call(arguments);t.forEach(function(t){e.Pipeline.warnIfFunctionNotRegistered(t),this._stack.push(t)},this)},e.Pipeline.prototype.after=function(t,r){e.Pipeline.warnIfFunctionNotRegistered(r);var i=this._stack.indexOf(t);if(i==-1)throw new Error("Cannot find existingFn");i+=1,this._stack.splice(i,0,r)},e.Pipeline.prototype.before=function(t,r){e.Pipeline.warnIfFunctionNotRegistered(r);var i=this._stack.indexOf(t);if(i==-1)throw new Error("Cannot find existingFn");this._stack.splice(i,0,r)},e.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);t!=-1&&this._stack.splice(t,1)},e.Pipeline.prototype.run=function(e){for(var t=this._stack.length,r=0;r1&&(se&&(r=n),s!=e);)i=r-t,n=t+Math.floor(i/2),s=this.elements[2*n];return s==e?2*n:s>e?2*n:sa?l+=2:o==a&&(t+=r[u+1]*i[l+1],u+=2,l+=2);return t},e.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},e.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,r=0;t0){var o,a=s.str.charAt(0);a in s.node.edges?o=s.node.edges[a]:(o=new e.TokenSet,s.node.edges[a]=o),1==s.str.length&&(o["final"]=!0),n.push({node:o,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(0!=s.editsRemaining){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new e.TokenSet;s.node.edges["*"]=u}if(0==s.str.length&&(u["final"]=!0),n.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&n.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),1==s.str.length&&(s.node["final"]=!0),s.str.length>=1){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new e.TokenSet;s.node.edges["*"]=l}1==s.str.length&&(l["final"]=!0),n.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var c,h=s.str.charAt(0),d=s.str.charAt(1);d in s.node.edges?c=s.node.edges[d]:(c=new e.TokenSet,s.node.edges[d]=c),1==s.str.length&&(c["final"]=!0),n.push({node:c,editsRemaining:s.editsRemaining-1,str:h+s.str.slice(2)})}}}return i},e.TokenSet.fromString=function(t){for(var r=new e.TokenSet,i=r,n=0,s=t.length;n=e;t--){var r=this.uncheckedNodes[t],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r["char"]]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}},e.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},e.Index.prototype.search=function(t){return this.query(function(r){var i=new e.QueryParser(t,r);i.parse()})},e.Index.prototype.query=function(t){for(var r=new e.Query(this.fields),i=Object.create(null),n=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),u=0;u1?this._b=1:this._b=e},e.Builder.prototype.k1=function(e){this._k1=e},e.Builder.prototype.add=function(t,r){var i=t[this._ref],n=Object.keys(this._fields);this._documents[i]=r||{},this.documentCount+=1;for(var s=0;s=this.length)return e.QueryLexer.EOS;var t=this.str.charAt(this.pos);return this.pos+=1,t},e.QueryLexer.prototype.width=function(){return this.pos-this.start},e.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},e.QueryLexer.prototype.backup=function(){this.pos-=1},e.QueryLexer.prototype.acceptDigitRun=function(){var t,r;do t=this.next(),r=t.charCodeAt(0);while(r>47&&r<58);t!=e.QueryLexer.EOS&&this.backup()},e.QueryLexer.prototype.more=function(){return this.pos1&&(t.backup(),t.emit(e.QueryLexer.TERM)),t.ignore(),t.more())return e.QueryLexer.lexText},e.QueryLexer.lexEditDistance=function(t){return t.ignore(),t.acceptDigitRun(),t.emit(e.QueryLexer.EDIT_DISTANCE),e.QueryLexer.lexText},e.QueryLexer.lexBoost=function(t){return t.ignore(),t.acceptDigitRun(),t.emit(e.QueryLexer.BOOST),e.QueryLexer.lexText},e.QueryLexer.lexEOS=function(t){t.width()>0&&t.emit(e.QueryLexer.TERM)},e.QueryLexer.termSeparator=e.tokenizer.separator,e.QueryLexer.lexText=function(t){for(;;){var r=t.next();if(r==e.QueryLexer.EOS)return e.QueryLexer.lexEOS;if(92!=r.charCodeAt(0)){if(":"==r)return e.QueryLexer.lexField;if("~"==r)return t.backup(),t.width()>0&&t.emit(e.QueryLexer.TERM),e.QueryLexer.lexEditDistance;if("^"==r)return t.backup(),t.width()>0&&t.emit(e.QueryLexer.TERM),e.QueryLexer.lexBoost;if("+"==r&&1===t.width())return t.emit(e.QueryLexer.PRESENCE),e.QueryLexer.lexText;if("-"==r&&1===t.width())return t.emit(e.QueryLexer.PRESENCE),e.QueryLexer.lexText;if(r.match(e.QueryLexer.termSeparator))return e.QueryLexer.lexTerm}else t.escapeCharacter()}},e.QueryParser=function(t,r){this.lexer=new e.QueryLexer(t),this.query=r,this.currentClause={},this.lexemeIdx=0},e.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var t=e.QueryParser.parseClause;t;)t=t(this);return this.query},e.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},e.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},e.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},e.QueryParser.parseClause=function(t){var r=t.peekLexeme();if(void 0!=r)switch(r.type){case e.QueryLexer.PRESENCE:return e.QueryParser.parsePresence;case e.QueryLexer.FIELD:return e.QueryParser.parseField;case e.QueryLexer.TERM:return e.QueryParser.parseTerm;default:var i="expected either a field or a term, found "+r.type;throw r.str.length>=1&&(i+=" with value '"+r.str+"'"),new e.QueryParseError(i,r.start,r.end)}},e.QueryParser.parsePresence=function(t){var r=t.consumeLexeme();if(void 0!=r){switch(r.str){case"-":t.currentClause.presence=e.Query.presence.PROHIBITED;break;case"+":t.currentClause.presence=e.Query.presence.REQUIRED;break;default:var i="unrecognised presence operator'"+r.str+"'";throw new e.QueryParseError(i,r.start,r.end)}var n=t.peekLexeme();if(void 0==n){var i="expecting term or field, found nothing";throw new e.QueryParseError(i,r.start,r.end)}switch(n.type){case e.QueryLexer.FIELD:return e.QueryParser.parseField;case e.QueryLexer.TERM:return e.QueryParser.parseTerm;default:var i="expecting term or field, found '"+n.type+"'";throw new e.QueryParseError(i,n.start,n.end)}}},e.QueryParser.parseField=function(t){var r=t.consumeLexeme();if(void 0!=r){if(t.query.allFields.indexOf(r.str)==-1){var i=t.query.allFields.map(function(e){return"'"+e+"'"}).join(", "),n="unrecognised field '"+r.str+"', possible fields: "+i;throw new e.QueryParseError(n,r.start,r.end)}t.currentClause.fields=[r.str];var s=t.peekLexeme();if(void 0==s){var n="expecting term, found nothing";throw new e.QueryParseError(n,r.start,r.end)}switch(s.type){case e.QueryLexer.TERM:return e.QueryParser.parseTerm;default:var n="expecting term, found '"+s.type+"'";throw new e.QueryParseError(n,s.start,s.end)}}},e.QueryParser.parseTerm=function(t){var r=t.consumeLexeme();if(void 0!=r){t.currentClause.term=r.str.toLowerCase(),r.str.indexOf("*")!=-1&&(t.currentClause.usePipeline=!1);var i=t.peekLexeme();if(void 0==i)return void t.nextClause();switch(i.type){case e.QueryLexer.TERM:return t.nextClause(),e.QueryParser.parseTerm;case e.QueryLexer.FIELD:return t.nextClause(),e.QueryParser.parseField;case e.QueryLexer.EDIT_DISTANCE:return e.QueryParser.parseEditDistance;case e.QueryLexer.BOOST:return e.QueryParser.parseBoost;case e.QueryLexer.PRESENCE:return t.nextClause(),e.QueryParser.parsePresence;default:var n="Unexpected lexeme type '"+i.type+"'";throw new e.QueryParseError(n,i.start,i.end)}}},e.QueryParser.parseEditDistance=function(t){var r=t.consumeLexeme();if(void 0!=r){var i=parseInt(r.str,10);if(isNaN(i)){var n="edit distance must be numeric";throw new e.QueryParseError(n,r.start,r.end)}t.currentClause.editDistance=i;var s=t.peekLexeme();if(void 0==s)return void t.nextClause();switch(s.type){case e.QueryLexer.TERM:return t.nextClause(),e.QueryParser.parseTerm;case e.QueryLexer.FIELD:return t.nextClause(),e.QueryParser.parseField;case e.QueryLexer.EDIT_DISTANCE:return e.QueryParser.parseEditDistance;case e.QueryLexer.BOOST:return e.QueryParser.parseBoost;case e.QueryLexer.PRESENCE:return t.nextClause(),e.QueryParser.parsePresence;default:var n="Unexpected lexeme type '"+s.type+"'";throw new e.QueryParseError(n,s.start,s.end)}}},e.QueryParser.parseBoost=function(t){var r=t.consumeLexeme();if(void 0!=r){var i=parseInt(r.str,10);if(isNaN(i)){var n="boost must be numeric";throw new e.QueryParseError(n,r.start,r.end)}t.currentClause.boost=i;var s=t.peekLexeme();if(void 0==s)return void t.nextClause();switch(s.type){case e.QueryLexer.TERM:return t.nextClause(),e.QueryParser.parseTerm;case e.QueryLexer.FIELD:return t.nextClause(),e.QueryParser.parseField;case e.QueryLexer.EDIT_DISTANCE:return e.QueryParser.parseEditDistance;case e.QueryLexer.BOOST:return e.QueryParser.parseBoost;case e.QueryLexer.PRESENCE:return t.nextClause(),e.QueryParser.parsePresence;default:var n="Unexpected lexeme type '"+s.type+"'";throw new e.QueryParseError(n,s.start,s.end)}}},function(e,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():e.lunr=t()}(this,function(){return e})}(); diff --git a/docs/assets/js/zzzz-search-data.json b/docs/assets/js/zzzz-search-data.json new file mode 100644 index 0000000000..3ab58b6b74 --- /dev/null +++ b/docs/assets/js/zzzz-search-data.json @@ -0,0 +1,73 @@ +--- +permalink: /assets/js/search-data.json +layout: empty +--- +{ +{%- assign i = 0 -%} +{%- assign pages_array = '' | split: '' -%} +{%- assign pages_array = pages_array | push: site.html_pages -%} +{%- if site.just_the_docs.collections -%} + {%- for collection_entry in site.just_the_docs.collections -%} + {%- assign collection_key = collection_entry[0] -%} + {%- assign collection_value = collection_entry[1] -%} + {%- assign collection = site[collection_key] -%} + {%- if collection_value.search_exclude != true -%} + {%- assign pages_array = pages_array | push: collection -%} + {%- endif -%} + {%- endfor -%} +{%- endif -%} +{%- for pages in pages_array -%} + {%- for page in pages -%} + {%- if page.title and page.search_exclude != true -%} + {%- assign page_content = page.content -%} + {%- assign heading_level = site.search.heading_level | default: 2 -%} + {%- for j in (2..heading_level) -%} + {%- assign tag = '' -%} + {%- assign title = titleAndContent[0] | replace_first: '>', '

' | split: '

' -%} + {%- assign title = title[1] | strip_html -%} + {%- assign content = titleAndContent[1] -%} + {%- assign url = page.url -%} + {%- if title == page.title and parts[0] == '' -%} + {%- assign title_found = true -%} + {%- else -%} + {%- assign id = titleAndContent[0] -%} + {%- assign id = id | split: 'id="' -%} + {%- if id.size == 2 -%} + {%- assign id = id[1] -%} + {%- assign id = id | split: '"' -%} + {%- assign id = id[0] -%} + {%- capture url -%}{{ url | append: '#' | append: id }}{%- endcapture -%} + {%- endif -%} + {%- endif -%} + {%- unless i == 0 -%},{%- endunless -%} + "{{ i }}": { + "doc": {{ page.title | jsonify }}, + "title": {{ title | jsonify }}, + "content": {{ content | replace: 'botLogin($token); +``` diff --git a/docs/complete2FALogin.md b/docs/complete2FALogin.md new file mode 100644 index 0000000000..eb04b29088 --- /dev/null +++ b/docs/complete2FALogin.md @@ -0,0 +1,37 @@ +--- +title: complete2falogin +description: complete2falogin parameters, return type and example +grand_parent: "Telegram RPC API" +parent: "Methods" +redirect_from: /complete_2fa_login.html +redirect_from: /complete2falogin.html +redirect_from: /complete2FAlogin.html +--- +## Method: complete2falogin + + +### Parameters: + +| Name | Type | +|----------|---------------| +|password| A string with the password| + +### Return type: [auth.Authorization](API_docs/types/auth.Authorization.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$MadelineProto->phoneLogin(readline('Enter your phone number: ')); +$authorization = $MadelineProto->completePhoneLogin(readline('Enter the code you received: ')); +if ($authorization['_'] === 'account.noPassword') { + throw new \danog\MadelineProto\Exception('2FA is enabled but no password is set!'); +} +if ($authorization['_'] === 'account.password') { + $authorization = $MadelineProto->complete2falogin(readline('Please enter your password (hint '.$authorization['hint'].'): ')); +} +if ($authorization['_'] === 'account.needSignup') { + $authorization = $MadelineProto->completeSignup(readline('Please enter your first name: '), readline('Please enter your last name (can be empty): ')); +} + +``` diff --git a/docs/completePhoneLogin.md b/docs/completePhoneLogin.md new file mode 100644 index 0000000000..53b5af1e96 --- /dev/null +++ b/docs/completePhoneLogin.md @@ -0,0 +1,37 @@ +--- +title: completePhoneLogin +description: completePhoneLogin parameters, return type and example +redirect_from: /complete_phone_login.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: complete\_phone\_login + + +### Parameters: + +| Name | Type | +|----------|---------------| +|code| A string with the phone code| + +### Return type: [auth.Authorization](API_docs/types/auth.Authorization.html) or [account.Password](http://docs.madelineproto.xyz/API_docs/types/account_Password.html) or `['_' => 'account.needSignup']` + +You must then use [complete2falogin](complete2FALogin.html) or [completeSignup](completeSignup.html) to login or signup, or simply start using `$MadelineProto` if the result is a `auth.Authorization` object. + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$MadelineProto->phoneLogin(readline('Enter your phone number: ')); +$authorization = $MadelineProto->completePhoneLogin(readline('Enter the code you received: ')); +if ($authorization['_'] === 'account.noPassword') { + throw new \danog\MadelineProto\Exception('2FA is enabled but no password is set!'); +} +if ($authorization['_'] === 'account.password') { + $authorization = $MadelineProto->complete2falogin(readline('Please enter your password (hint '.$authorization['hint'].'): ')); +} +if ($authorization['_'] === 'account.needSignup') { + $authorization = $MadelineProto->completeSignup(readline('Please enter your first name: '), readline('Please enter your last name (can be empty): ')); +} + +``` diff --git a/docs/completeSignup.md b/docs/completeSignup.md new file mode 100644 index 0000000000..4432532563 --- /dev/null +++ b/docs/completeSignup.md @@ -0,0 +1,37 @@ +--- +title: completeSignup +description: completeSignup parameters, return type and example +redirect_from: /complete_signup.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: completeSignup + + +### Parameters: + +| Name | Type | +|----------|---------------| +|first_name| A string with the first name| +|last_name| Optional, string with the last name| + +### Return type: [auth.Authorization](API_docs/types/auth.Authorization.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$MadelineProto->phoneLogin(readline('Enter your phone number: ')); +$authorization = $MadelineProto->completePhoneLogin(readline('Enter the code you received: ')); +if ($authorization['_'] === 'account.noPassword') { + throw new \danog\MadelineProto\Exception('2FA is enabled but no password is set!'); +} +if ($authorization['_'] === 'account.password') { + $authorization = $MadelineProto->complete2falogin(readline('Please enter your password (hint '.$authorization['hint'].'): ')); +} +if ($authorization['_'] === 'account.needSignup') { + $authorization = $MadelineProto->completeSignup(readline('Please enter your first name: '), readline('Please enter your last name (can be empty): ')); +} + + +``` diff --git a/docs/docs/ASYNC.md b/docs/docs/ASYNC.md new file mode 100644 index 0000000000..6e5fda997f --- /dev/null +++ b/docs/docs/ASYNC.md @@ -0,0 +1,244 @@ +--- +title: "Async" +description: "MadelineProto now features async, for incredible speed improvements, and parallel processing, all powered by amphp." +nav_order: 27 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Async + +MadelineProto now features async, for **incredible speed improvements**, and parallel processing, all powered by [amphp](https://amphp.org). + +* [Usage](#usage) + * [Async in event handler](#async-in-event-handler) + * [Multiple async](#multiple-async) + * [Ignored async](#ignored-async) + * [Combining async operations](#combining-async-operations) + * [MadelineProto and AMPHP async APIs](#madelineproto-and-amphp-async-apis) + * [Helper methods](#helper-methods) + * [Async sleep](#async-sleep-does-not-block-the-main-thread) + * [Async readline](#async-readline-does-not-block-the-main-thread) + * [Async echo](#async-echo-does-not-block-the-main-thread) + * [MadelineProto HTTP client](#madelineproto-http-client) + * [Async forking](#async-forking-does-async-green-thread-forking) + * [Async flock](#async-flock) + * [MadelineProto async loop APIs](#async-loop-apis) + +## Usage + +What exactly __is__ **async**, you may ask, and how is it better than **threading** or **multiprocessing**? +Async is a relatively new programming pattern that allows you to easily write **non-blocking** code **as if you were using standard** blocking functions, all **without** the need for complex message exchange systems and synchronization handling for threaded programs, that only add overhead and complexity to your programs, making everything slower and error-prone. + +That's very cool and all, you might think, but how exactly does this __async__ stuff work? Well, as it turns out, it's very easy. + +Instead of writing code like this: +```php +$file = $MadelineProto->downloadToDir($bigfile, '/tmp/'); +``` + +Write it like **this**: +```php +$file = $MadelineProto->downloadToDir($bigfile, '/tmp/'); +``` + +But isn't that's the same code? + +**Exactly**. + +Starting from [amphp v3](https://amphp.org) and MadelineProto 8, [native PHP fibers](https://www.php.net/manual/en/language.fibers.php) allow concurrent async execution of code without any special `await` or `yield` keywords. + +### That's it. + +It's really **that** easy. + +This means that you can handle multiple updates, download/upload multiple files all together in one process, as if you were writing normal synchronous code + making everything a lot faster. + +**WARNING**: MadelineProto async is not compatible with pthreads or pcntl, so please uninstall pthreads and do not use `pcntl_fork` in your bot. + +### Async in [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html#event-driven): + +```php +class EventHandler extends \danog\MadelineProto\EventHandler +{ + public function onAny($update) + { + if (isset($update['message']['out']) && $update['message']['out']) { + return; + } + if (isset($update['message']['media']) && $update['message']['media']['_'] !== 'messageMediaGame') { + $this->downloadToDir($update, '/tmp'); + $this->messages->sendMedia(['peer' => $update, 'message' => $update['message']['message'], 'media' => $update]); + } + + $res = json_encode($update, JSON_PRETTY_PRINT); + + $this->sleep(3); + + try { + $this->sm($update, "$res\nAsynchronously, after 3 seconds"); + } catch (\danog\MadelineProto\RPCErrorException $e) { + \danog\MadelineProto\Logger::log((string) $e, \danog\MadelineProto\Logger::FATAL_ERROR); + } catch (\danog\MadelineProto\Exception $e) { + \danog\MadelineProto\Logger::log((string) $e, \danog\MadelineProto\Logger::FATAL_ERROR); + } + } + public function sm($peer, $message) + { + $this->messages->sendMessage(peer: $peer, message: $message, reply_to_msg_id: isset($update['message']['id']) ? $update['message']['id'] : null, parse_mode: 'HTML'); + } +} +``` + +### Ignored async + +```php +\Revolt\EventLoop::queue(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'a')); +\Revolt\EventLoop::queue(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'b')); +``` + +You can use the above syntax if don't want the request to block, and you don't need the result of the function. +Note that the order of execution of the function calls will not be guaranteed. +See [async forking](#async-forking-does-async-green-thread-forking). + +### Combining async operations + +There are AMPHP methods can be used to execute multiple async operations simultaneously and wait for the result of all of them, see the [amphp docs](https://amphp.org/amp#combinators) for more info. + +## MadelineProto and AMPHP async APIs + +MadelineProto and AMPHP (through Revolt) both provide a lot of async functions: all of MadelineProto's functions are async, for example; and AMPHP provides [multiple packages](https://amphp.org/packages) to work asynchronously with HTTP requests, websockets, databases (HTTP, MySQL, redis, postgres, DNS, sockets and [much more](https://github.com/amphp/))! + +Also, you should read the [AMPHP docs](https://amphp.org/amp): AMPHP provides multiple helper methods for executing actions repeatedly every N seconds in a non-blocking manner, or to defer execution of certain actions (aka async cron). + +You can also use [danog/loop](https://daniil.it/loop) for that. + +### Helper methods + +MadelineProto also provides a few generic async helper methods. + +#### Async sleep (does not block the main thread) +```php +$MadelineProto->sleep(3); +``` + +#### Async readline (does not block the main thread) +```php +$res = $MadelineProto->readLine('Optional prompt'); +``` + +#### Async echo (does not block the main thread) +```php +$MadelineProto->echo('Hello'.PHP_EOL); +``` + +#### MadelineProto HTTP client + +When using amphp's [http-client](https://amphp.org/http-client) to make high-speed asynchronous HTTP requests (downloading files, etc.), use MadelineProto's modified http-client client, instead. +It automatically supports the socks/HTTP proxies specified in MadelineProto's settings (will use proxies only if the file can't be downloaded normally), and DoH for greater security. + +To use MadelineProto's http-client client, instead of creating an http-client instance: +```php +$client = \Amp\Http\Client\HttpClientBuilder::buildDefault(); +``` + +Simply get MadelineProto's HTTP client: +```php +$client = $MadelineProto->getHTTPClient(); +``` + +From here it's like in the [http-client docs](https://amphp.org/http-client). + +MadelineProto also provides a simplified async version of `file_get_contents`: +```php +$result = $MadelineProto->fileGetContents('https://myurl'); +``` + +#### Async forking (does async green-thread forking) + +Useful if you need to start a process in the background. + +```php +\Revolt\EventLoop::queue(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'test')); +``` + +If the method throws an exception, it will surface out of the event loop, unless it's intercepted by the configured Revolt exception handler ([startAndLoop](https://docs.madelineproto.xyz/docs/UPDATES.html) automatically sets up an exception handler that reports exception to the userbot's admin). +Also, the method result can't be used: this is usually not good practice, so it's best to use `\Amp\async` instead, which returns a future that will resolve or fail according to the result of the function. + +```php +$future = \Amp\async(fn () => $MadelineProto->messages->sendMessage(peer: 'danogentili', message: 'test')); +// Use $future to register a callback with catch, use it with combinator functions, and much more... +``` + +#### Multiple async + +Multiple concurrent requests can be started [using `\Amp\async`](#async-forking-does-async-green-thread-forking), this will queue bundle all requests in a single container for higher efficiency, if there are no method calls inbetween the `async` calls. + +```php +$res1 = async(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 1')); +$res2 = async(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 2')); +$res3 = async(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 3')); + +// The await will send all 3 methods in a single container: ['hi 1', 'hi 2', 'hi 3'] +[$res1, $res2, $res3] = await([$res1, $res2, $res3]); + +$res1 = async(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 1')); + +// This non-async call will send request hi 1 and hi 2 direct in a single container: ['hi 1', 'hi 2 direct'] +$MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 2 direct'); + +$res2 = async(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 2')); +$res3 = async(fn () => $MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'hi 3')); + +// The await will send the remaining 2 calls in two container: ['hi 2', 'hi 3'] +[$res1, $res2, $res3] = await([$res1, $res2, $res3]); +``` + +This is the preferred way of combining multiple method calls: this way, the MadelineProto async WriteLoop will combine all method calls in one container, making everything WAY faster. + +Note that the execution order of method calls is not guaranteed in this case, unless a `queueId` argument is also provided, in which case it will be guaranteed to be equal to the queueing order (each method call is queued by the `async` call). + +#### Cancellation + +All MadelineProto and amphp methods allow cancelling an in-progress operation, by passing an `\Amp\Cancellation` object to the last parameter of any method, see the [amphp](https://amphp.org/amp#cancellation) documentation for more info. + +Example: + +```php +use danog\MadelineProto\RemoteUrl; + + +$deferredCancellation = new \Amp\DeferredCancellation(); +$res1 = async( + $MadelineProto->sendDocument(...), + peer: '@danogentili', + file: new RemoteUrl($url), + cancellation: $deferredCancellation->getCancellation() +); + + +// Sometime later, if the user decides to /cancel... +$deferredCancellation->cancel(); +``` + +#### Async flock + +```php +$unlock = $MadelineProto->flock($filePath, LOCK_SH); +try { + // ... +} finally { + $unlock(); +} +``` + +This will asynchronously wait for a lock on `$filePath` (creating it if it doesn't exist). +The locking mode can be `LOCK_SH` (shared locks), `LOCK_EX` (exclusive locks), as with the PHP `flock` function. +A third optional parameter can be set, to specify a polling interval in seconds (0.1 by default). + +### Async loop APIs + +MadelineProto provides a very useful async loop APIs, for executing operations periodically or on demand. +It's a more flexible and powerful alternative to AMPHP's [repeat](https://amphp.org/amp/event-loop/api#repeat), allowing dynamically changeable repeat periods, resumes and signaling. + +See [the documentation](https://daniil.it/loop) for more info! + +Next section \ No newline at end of file diff --git a/docs/docs/BROADCAST.md b/docs/docs/BROADCAST.md new file mode 100644 index 0000000000..eecd8d12af --- /dev/null +++ b/docs/docs/BROADCAST.md @@ -0,0 +1,276 @@ +--- +title: "Broadcasting messages to all users" +description: "MadelineProto can be used to broadcast messages to all users, chats and channels of a bot or userbot." +nav_order: 10 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Broadcasting messages to all users + +MadelineProto can be used to broadcast messages to all users, chats and channels of a bot or userbot. + +Note that unlike the bot API, MadelineProto can be used to fetch the full list of users, chats and channels of a **normal bot, simply using its bot token**. + +**All** users, chats and channels of the bot will be fetched, **regardless** of their last activity date: for example, if you just logged in with a bot token in MadelineProto 5 minutes ago, MadelineProto will fetch **all** users, chats and channels, even if their last activity is 5+ years ago! + +>Note: if you just want to fetch the member list, you can use [getDialogIds](https://docs.madelineproto.xyz/docs/DIALOGS.html#getdialogids). +>Be aware that getDialogIds **can't be used when running via web**, due to timeouts. +>Instead, use the [broadcast API »](#broadcast-api) to run via web. + +## Broadcast API + +MadelineProto offers a simple broadcast API, that can be used to asynchronously broadcast messages to all users of a bot or userbot in the background, without incurring in timeouts or other issues. + +See [here »](https://github.com/danog/MadelineProto/blob/v8/examples/bot.php) for a full example of the broadcast API. + +### Forward messages + +Use `broadcastForwardMessages` to forward a list of messages to all peers (users, chats, channels) of the bot. + +This method will automatically handle rate limits, waiting to ensure all messages are sent correctly. + +This method starts the broadcast process **in the background**. +It immediately returns an integer ID that can be used to: + +- Get the current broadcast progress with [getBroadcastProgress](#get-progress) +- Cancel the broadcast using [cancelBroadcast](#cancel-a-broadcast) + +Note that to avoid manually polling the progress, MadelineProto will also periodically emit [updateBroadcastProgress updates](#get-progress), containing a Progress object for all broadcasts currently in-progress. +Note that the process may take even hours to start, so be patient. + +```php +start(); + +// Or, instead of start() you can use botLogin (bots only) +//$MadelineProto->botLogin('1234:token'); + +// Let's forward two messages from the @MadelineProto channel! +// Channel ID: @MadelineProto +// Message ID 1: 614 +// Message ID 2: 613 +// Link 1: https://t.me/MadelineProto/613 +// Link 2: https://t.me/MadelineProto/614 + +$from_peer = '@MadelineProto'; // Can also be a numeric bot API ID +$message_ids = [613, 614]; + +// Send messages, showing the "Forwarded from" header +$id = $MadelineProto->broadcastForwardMessages( + from_peer: $from_peer, + message_ids: $message_ids, + drop_author: false, + pin: false, +); + +// Send messages WITHOUT showing the "Forwarded from" header +$id = $MadelineProto->broadcastForwardMessages( + from_peer: $from_peer, + message_ids: $message_ids, + drop_author: true, + pin: false, +); +``` + +You can specify `pin: true` to automatically pin the last sent message. + +An optional `filter` parameter can also be used, specifying a [peer filter](#filtering). + +### Send messages + +Use `broadcastMessages` to broadcast a list of messages to all peers (users, chats, channels) of the bot. + +This method will automatically handle rate limits, waiting to ensure all messages are sent correctly. + +A simplified version of this method is also available: [broadcastForwardMessages](#forward-messages) can work with pre-prepared messages. + +This method starts the broadcast process **in the background**. +It immediately returns an integer ID that can be used to: + +- Get the current broadcast progress with [getBroadcastProgress](#get-progress) +- Cancel the broadcast using [cancelBroadcast](#cancel-a-broadcast) + +Note that to avoid manually polling the progress, MadelineProto will also periodically emit [updateBroadcastProgress updates](#get-progress), containing a Progress object for all broadcasts currently in-progress. +Note that the process may take even hours to start, so be patient. + +```php +start(); + +// Or, instead of start() you can use botLogin (bots only) +//$MadelineProto->botLogin('1234:token'); + +$id = $MadelineProto->broadcastMessages( + messages: [ + ['message' => 'This broadcast is powered by @MadelineProto!'], + ['message' => 'This media broadcast is powered by @MadelineProto!', 'media' => [ + '_' => 'inputMediaUploadedPhoto', + 'file' => 'https://docs.madelineproto.xyz/logo-hover.png' + ]], + ], + pin: false, +); +``` + +You can specify `pin: true` to automatically pin the last sent message. + +An optional `filter` parameter can also be used, specifying a [peer filter](#filtering). + +### Custom action + +Use `broadcastCustom` to execute a custom broadcast action with all peers (users, chats, channels) of the bot. + +This method will **NOT** automatically handle rate limits. +To handle rate limits and errors automatically, a simplified version of this method is available, [broadcastForwardMessages »](#forward-messages) and [broadcastMessages »](#send-messages). + +This method starts the broadcast process **in the background**. +It immediately returns an integer ID that can be used to: + +- Get the current broadcast progress with [getBroadcastProgress](#get-progress) +- Cancel the broadcast using [cancelBroadcast](#cancel-a-broadcast) + +Note that to avoid manually polling the progress, MadelineProto will also periodically emit [updateBroadcastProgress updates](#get-progress), containing a Progress object for all broadcasts currently in-progress. + +An optional `filter` parameter can also be used, specifying a [peer filter](#filtering). +Note that the process may take even hours to start, so be patient. + +```php +isRequested()) { + return; + } + $this->API->messages->sendMessage( + peer: $peer, + message: $this->message, + ); + } catch (RPCErrorException $e) { + if ($e->rpc === 'INPUT_USER_DEACTIVATED') { + return; + } + if ($e->rpc === 'USER_IS_BOT') { + return; + } + if ($e->rpc === 'CHAT_WRITE_FORBIDDEN') { + return; + } + if ($e->rpc === 'USER_IS_BLOCKED') { + return; + } + if ($e->rpc === 'PEER_ID_INVALID') { + return; + } + throw $e; + } + } +} + +// In some other file... +$id = $MadelineProto->broadcastCustom(new CustomBroadcastAction($MadelineProto, 'This broadcast is powered by @MadelineProto!')); +``` + +### Filtering + +All broadcast methods allow specifying a custom peer filter: + +```php +start(); + +// Or, instead of start() you can use botLogin (bots only) +//$MadelineProto->botLogin('1234:token'); + +// Send messages, showing the "Forwarded from" header +$id = $MadelineProto->broadcastForwardMessages( + from_peer: 101374607, + message_ids: [1, 2, 3, 4], + drop_author: false, + filter: new Filter( + allowUsers: true, + allowBots: false, + allowGroups: true, + allowChannels: false, + blacklist: [], // Optional + whitelist: null // Optional array, if null all IDs are allowed (equivalent to *) + ) +); +``` + +### Cancel a broadcast + +Use `cancelBroadcast` to a cancel an in-progress broadcast. + +```php +$MadelineProto->cancelBroadcast(123); +``` + +### Get progress + +```php +use danog\MadelineProto\Broadcast\Progress; +use danog\MadelineProto\Broadcast\Status; + +$progress = $MadelineProto->getBroadcastProgress(123); + +if ($progress !== null) { + assert($progress instanceof Progress); + + $progressStr = (string) $progress; + echo "Human-readable progress: $progressStr".PHP_EOL; + + // 123 + $broadcastId = $progress->broadcastId; + + // One of Status::GATHERING_PEERS, Status::BROADCASTING, Status::FINISHED, Status::CANCELLED + $status = $progress->status; + + $pendingCount = $progress->pendingCount; + $sucessCount = $progress->successCount; + $sucessCount = $progress->failCount; +} +``` + +You can use `getBroadcastProgress` to get the progress of a currently running broadcast. +The method returns null if the broadcast doesn't exist, has already completed or was cancelled. + +Use updateBroadcastProgress updates to get real-time progress status without polling, [here's a full example »](https://github.com/danog/MadelineProto/blob/v8/examples/bot.php). + +Next section \ No newline at end of file diff --git a/docs/docs/CALLS.md b/docs/docs/CALLS.md new file mode 100644 index 0000000000..529630b40a --- /dev/null +++ b/docs/docs/CALLS.md @@ -0,0 +1,195 @@ +--- +title: "Telegram VoIP phone calls" +description: "MadelineProto provides an easy wrapper to work with phone calls." +nav_order: 20 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Telegram VoIP phone calls + +MadelineProto provides an easy wrapper to work with phone calls. + +[Full webradio example](https://github.com/danog/magnaluna) + +* Please read the whole [VoIP API documentation](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) before proceeding. +* [Requesting a call](#requesting-a-call) +* [Playing audio files](#playing-audio-files) + * [Webhost support!](#webhost-support) +* [Accepting calls](#accepting-calls) + + +## Requesting a call +```php +start(); + +$call = $MadelineProto->requestCall('@danogentili'); +``` + +The [requestCall](https://docs.madelineproto.xyz/requestCall.html) function accepts one parameter with the ID/username/Peer/User/InputPeer of the person to call, and returns a VoIP object that can be used to play audio files, set the hold files, change the configuration and set the output file (see the [VoIP API documentation](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) for more info). + +You can play audio files of any format as follows: + +## Playing audio files + +You can play audio files of any format: + +```php +start(); + +$call = $MadelineProto->requestCall('@danogentili'); +$call->play(new LocalFile("audio.mp3")) + ->then(new LocalFile("audio.flac")) + ->then(new LocalFile("audio.wav")) + ->then(new LocalFile("audio_with_video.mp4")); +``` + +You can also play remote streams (or simple remote files) by URL: + +```php +start(); + +$call = $MadelineProto->requestCall('@danogentili'); +$call->play(new RemoteUrl("http://icestreaming.rai.it/1.mp3")); +``` + +You can also play Telegram files, using AMP streams! + + +## Webhost support + +Starting from MadelineProto 8, VoIP now works on webhosts, too, thanks to a pure PHP implementation of libtgvoip and a pure PHP OGG demuxer! + +The only limitation when running on webhosts is that audio files must be preconverted using by sending them to [@libtgvoip_bot](https://t.me/libtgvoip_bot) ([source code](https://github.com/danog/MadelineProto/blob/v8/examples/libtgvoipbot.php)), or by using the following script on your PC: + +```php +start(); + +$call = $MadelineProto->requestCall('@danogentili'); +$call->play(new LocalFile("out.ogg")); +``` + +## Accepting calls + +Accepting calls is just as easy: + +```php +accept()->play(new RemoteUrl('http://icestreaming.rai.it/1.mp3')); + } +} + +PonyHandler::startAndLoop('session.madeline'); +``` + +## Recording calls + +To record the incoming audio stream in a call, simply use `setOutput`: + +```php +accept(); + $call->play(new RemoteUrl('http://icestreaming.rai.it/1.mp3')); + + $call->setOutput(new LocalFile('output.ogg')); + + // $stream can also be a WritableStream. + // Can be used to pipe OGG OPUS audio data to ffmpeg, asterisk via amphp/process, amphp/socket, etc... + // + //$call->setOutput($stream); + } +} + +PonyHandler::startAndLoop('session.madeline'); +``` + +Next section \ No newline at end of file diff --git a/docs/docs/CHAT_INFO.md b/docs/docs/CHAT_INFO.md new file mode 100644 index 0000000000..d0ef5e21c7 --- /dev/null +++ b/docs/docs/CHAT_INFO.md @@ -0,0 +1,63 @@ +--- +title: "Getting info about chats" +description: "There are various methods that can be used to fetch info about chats, based on bot API id, tg-cli ID, Peer, User, Chat objects." +nav_order: 22 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Getting info about chats + +There are various methods that can be used to fetch info about chats, based on bot API id, tg-cli ID, Peer, User, Chat objects. + +* [Full chat info with full list of participants](#getPwrChat) +* [Full chat info](#getFullInfo) +* [Reduced chat info (very fast)](#getInfo) +* [Just the chat ID (extremely fast)](#getId) + +## getPwrChat +```php +$pwr_chat = $MadelineProto->getPwrChat(-100214891824); +foreach ($pwr_chat['participants'] as $participant) { + \danog\MadelineProto\Logger::log($participant); +} +``` + +Use `getPwrChat` to get full chat info, including the full list of members, see [here for the parameters and the result](https://docs.madelineproto.xyz/getPwrChat.html). + +Please avoid using this method if possible, use [getInfo](#getinfo) or at least [getFullInfo](#getfullinfo) to avoid flood waits. + +* Speed: slow +* Caching: partial + +## getFullInfo +```php +$full_chat = $MadelineProto->getFullInfo(-10028941842); +``` + +You can use `getFullInfo` to get full chat info, without the full list of members, see [here for the parameters and the result](https://docs.madelineproto.xyz/getFullInfo.html). + +Please avoid using this method if possible, use [getInfo](#getinfo) to avoid flood waits. + +* Speed: medium-fast +* Caching: partial, and an initial RPC query is always made, so please use [getInfo](#getinfo) if possible to avoid flood waits. + +## getInfo +```php +$chat = $MadelineProto->getInfo(-10028941842); +``` + +You can use `getInfo` to get chat info, see [here for the parameters and the result](https://docs.madelineproto.xyz/getInfo.html) + +* Speed: fast +* Caching: full, 0 RPC queries are made unless an unknown username is passed. + +## getId +```php +$id = $MadelineProto->getID($update); +``` + +You can also use `getId` to get chat ID from updates, messages and other objects. + +* Speed: very fast +* Caching: full, 0 RPC queries are made unless an unknown username is passed. + +Next section \ No newline at end of file diff --git a/docs/docs/CONTRIB.md b/docs/docs/CONTRIB.md new file mode 100644 index 0000000000..b0099a44be --- /dev/null +++ b/docs/docs/CONTRIB.md @@ -0,0 +1,89 @@ +--- +title: "Contributing" +description: "You can contribute in various ways." +nav_order: 31 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Contributing + +You can contribute in various ways. + +* [Translation](#translation) +* [Contribution guide](#contribution-guide) +* [Credits](#credits) + +## Translation + +You can help by translating MadelineProto in your language. + +To do this, head over to [weblate.madelineproto.xyz »](https://weblate.madelineproto.xyz/projects/madelineproto/madelineproto/). + +## Contribution guide + +[Here](https://github.com/danog/MadelineProto/projects/1) you can find this project's roadmap. + +You can use this scheme of the structure of this project to help yourself: + +``` +build_docs.php - Builds API docs from TL scheme file +src/ + MTProtoTools/ + AckHandler - Handles acknowledgement of incoming and outgoing mtproto messages + AuthKeyHandler - Handles generation of the temporary and permanent authorization keys + CallHandler - Handles synchronous calls to mtproto methods or objects, also basic response management (waits until the socket receives a response) + Crypt - Handles ige and aes encryption + MessageHandler - Handles sending and receiving of mtproto messages (packs TL serialized data with message id, auth key id and encrypts it with Crypt if needed, adds them to the arrays of incoming and outgoing messages) + MsgIdHandler - Handles message ids (checks if they are valid, adds them to the arrays of incoming and outgoing messages) + ResponseHandler - Handles the content of responses received, service messages, rpc results, errors, and stores them into the response section of the outgoing messages array) + SaltHandler - Handles server salts + SeqNoHandler - Handles sequence numbers (checks validity) + PeerHandler - Manages peers + UpdateHandler - Handles updates + TL/ + Exception - Handles exceptions in the TL namespace + TL - Handles TL serialization and deserialization + TLConstructor - Stores TL constructors + TLMethod - Stores TL methods + TLParams - Parses params + Wrappers/ + Login - Handles logging in as a bot or a user, logging out + PeerHandler - Eases getting of input peer objects using usernames or bot API chat ids + SettingsManager - Eases updating settings + API - Wrapper class that instantiates the MTProto class, sets the error handler, provides a wrapper for calling mtproto methods directly as class submethods, and uses the simplified wrappers from Wrappers/ + APIFactory - Provides a wrapper for calling namespaced mtproto methods directly as class submethods + Connection - Handles tcp/udp/http connections and wrapping payloads generated by MTProtoTools/MessageHandler into the right message according to the protocol, stores authorization keys, session id and sequence number + DataCenter - Handles mtproto datacenters (is a wrapper for Connection classes) + DebugTools - Various debugging tools + Exception - Handles exceptions and PHP errors + RPCErrorException - Handles RPC errors + MTProto - Handles initial connection, generation of authorization keys, instantiation of classes, writing of client info + Logger - Static logging class + prime.py and getpq.py - prime module (python) for p and q generation + PrimeModule.php - prime module (php) for p and q generation by wrapping the python module, using wolfram alpha or a built in PHP engine + RSA - Handles RSA public keys and signatures + Tools - Various tools (positive modulus, string2bin, python-like range) +``` + +Check out our Contribution Guide on GitHub before contributing. + +## Credits + +Created by [Daniil Gentili](https://daniil.it), licensed under AGPLv3, based on [telepy](https://github.com/griganton/telepy_old). + +While writing this client, I looked at many projects for inspiration and help. Here's the full list: + +[tdesktop](github.com/telegramdesktop/tdesktop/) + +[td](https://github.com/tdlib/td) + +[tgl](https://github.com/vysheng/tgl) + +[Kotlogram](https://github.com/badoualy/kotlogram) + +[Webogram](https://github.com/zhukov/webogram) + +Thanks to the devs that contributed to these projects, and to MadelineProto itself, MadelineProto is now an easy, well-written and complete MTProto client. + +Thank you for using MadelineProto <3 + +Next section \ No newline at end of file diff --git a/docs/docs/CREATING_A_CLIENT.md b/docs/docs/CREATING_A_CLIENT.md new file mode 100644 index 0000000000..4f65a4386d --- /dev/null +++ b/docs/docs/CREATING_A_CLIENT.md @@ -0,0 +1,25 @@ +--- +title: "Creating a client" +description: "This page explains how to create a MadelineProto instance." +nav_order: 4 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Creating a client + +This page explains how to create a MadelineProto instance. + +To create the session and set the serialization destination file, do the following: + +```php +$MadelineProto = new \danog\MadelineProto\API('session.madeline', $settings); // The session will be serialized to session.madeline +``` + +Do the same to load a serialized session: + +```php +$MadelineProto = new \danog\MadelineProto\API('session.madeline', $settings); // The session will be loaded from session.madeline +``` + +MadelineProto can also be configured to run on ephemeral filesystems (i.e. docker containers with no volumes, storing all data on MySQL/Postgres/Redis) by setting a table prefix manually in the settings, as specified [here »](https://docs.madelineproto.xyz/docs/DATABASE.html). + +Next section \ No newline at end of file diff --git a/docs/docs/DATABASE.md b/docs/docs/DATABASE.md new file mode 100644 index 0000000000..2074235bcd --- /dev/null +++ b/docs/docs/DATABASE.md @@ -0,0 +1,97 @@ +--- +title: "Database" +description: "MadelineProto optionally can keep some of its internal data in a database, such as mysql, mariadb, postgres or redis (you can also add your own!), reducing RAM usage." +nav_order: 14 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Database + +MadelineProto *optionally* can keep some of its internal data in a database, such as mysql, mariadb, postgres or redis (you can also [add your own](https://github.com/danog/MadelineProto/tree/v8/src/Db)!), reducing RAM usage. + +MadelineProto uses the [danog/AsyncOrm](https://github.com/danog/AsyncOrm) library to store all data to the chosen database backend: this library can also be used standalone, without MadelineProto. + +On first start after switching type all data will be migrated from the previous backend to the new one. +Database to memory migration is also supported. + +Databases and tables will be created automatically. + +You can also directly connect the [event handler](/docs/UPDATES.html#built-in-orm) using the same async MySQL/Postgres/Redis ORM used by MadelineProto internally. + +Related settings: + +* [\danog\MadelineProto\Settings\Database\Memory: Memory backend settings.](../PHP/danog/MadelineProto/Settings/Database/Memory.html) +* [\danog\MadelineProto\Settings\Database\Mysql: MySQL backend settings.](../PHP/danog/MadelineProto/Settings/Database/Mysql.html) MariaDb 10.2+ or Mysql 5.6+ required. +* [\danog\MadelineProto\Settings\Database\Postgres: Postgres backend settings.](../PHP/danog/MadelineProto/Settings/Database/Postgres.html) +* [\danog\MadelineProto\Settings\Database\Redis: Redis backend settings.](../PHP/danog/MadelineProto/Settings/Database/Redis.html) + +See [the settings documentation for more info](SETTINGS.html). + +### Mysql example (low memory usage): + +```php +$settings = (new \danog\MadelineProto\Settings\Database\Mysql) + ->setUri('tcp://localhost') + ->setPassword('pass'); + +$API = new \danog\MadelineProto\API('session.madeline', $settings); +``` + +**WARNING**: Make sure to run `SET GLOBAL max_connections = 100000;` as root in the mysql/mariadb console, **regardless of the limit you set in the MadelineProto settings**. +Make sure to run the command **after every system restart**, or modify the database configuration file to set the maximum connection limit to `100000`. + +MadelineProto can also be configured to run on ephemeral filesystems (i.e. docker containers with no volumes, storing all data on MySQL) by setting a table prefix manually in the settings, as specified [here »](#ephemeral-filesystems). + + +### Postgres example (low memory usage): + +```php +$settings = (new \danog\MadelineProto\Settings\Database\Postgres) + ->setUri('tcp://localhost') + ->setPassword('pass'); +``` + +MadelineProto can also be configured to run on ephemeral filesystems (i.e. docker containers with no volumes, storing all data on Postgres) by setting a table prefix manually in the settings, as specified [here »](#ephemeral-filesystems). + +### Redis example (medium memory usage, faster access): + +```php +$settings = (new \danog\MadelineProto\Settings\Database\Redis) + ->setUri('redis://127.0.0.1') + ->setPassword('pass'); +``` + +MadelineProto can also be configured to run on ephemeral filesystems (i.e. docker containers with no volumes, storing all data on Redis) by setting a table prefix manually in the settings, as specified [here »](#ephemeral-filesystems). + +### Memory example (medium-high memory usage, fastest access): + +```php +$settings = new \danog\MadelineProto\Settings\Database\Memory; +``` + +This mode, unlike [mysql](#mysql-example-low-memory-usage), [postgres](#postgres-example-low-memory-usage) and [redis](#redis-example-medium-memory-usage-faster-access) does not support [ephemeral filesystems](#ephemeral-filesystems), thus a persistent filesystem must be used for the session folder. + +### Ephemeral filesystems + +MadelineProto can also be configured to run on ephemeral filesystems (i.e. docker containers with no volumes, storing all data on [MySQL](#mysql-example-low-memory-usage)/[Postgres](#postgres-example-low-memory-usage)/[Redis](#redis-example-medium-memory-usage-faster-access)) by setting a table prefix manually in the settings: + +```php +$settings = (new \danog\MadelineProto\Settings\Database\Mysql) + ->setUri('tcp://localhost') + ->setPassword('pass') + ->setEphemeralFilesystemPrefix('session_1'); + +$API = new \danog\MadelineProto\API('session.madeline', $settings); +``` + +The `setEphemeralFilesystemPrefix` setting indicates that the filesystem is ephemeral, and thus session files will not be used to store persistent data. + +The prefix must contain a unique string, used as prefix for database tables, different for every session. +The prefix may be the same if different databases are used. + +This is useful when running MadelineProto inside docker containers without volumes, using just a database. + +Note that the session folder must still NEVER be deleted *if* MadelineProto is running, or else the session will be dropped from the database due to `AUTH_KEY_DUPLICATED` errors. + +Stopping the container gracefully and then deleting the session folder (i.e. by deleting or recreating the container itself) is 100% OK though. + +Next section \ No newline at end of file diff --git a/docs/docs/DIALOGS.md b/docs/docs/DIALOGS.md new file mode 100644 index 0000000000..ad8b3d7751 --- /dev/null +++ b/docs/docs/DIALOGS.md @@ -0,0 +1,37 @@ +--- +title: "Getting all chats (dialogs)" +description: "There are two ways to get a list of all chats, depending if you logged in as a user, or as a bot." +nav_order: 23 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Getting all chats (dialogs) + +There are two ways to get a list of all chats, depending if you logged in as a user, or as a bot. + +* [Dialog ID list](#getDialogIds) +* [Full dialog info](#getFullDialogs) + +## getDialogIds +```php +$dialogs = $MadelineProto->getDialogIds(); +foreach ($dialogs as $peer) { + $MadelineProto->messages->sendMessage(peer: $peer, message: 'Hi! Testing MadelineProto broadcasting!'); +} +``` + +`getDialogIds` will return a full list of the bot API IDs of all users/chats/channels known by the bot, see [here for the parameters and the result](https://docs.madelineproto.xyz/getDialogIds.html). + +**Note**: this method will take a **very long time** to return the first time when used with bots: to avoid incurring in timeouts, run the method via CLI (**not web**) OR use the [async background broadcast API](https://docs.madelineproto.xyz/docs/BROADCAST.html), instead. +After the first broadcast with the broadcast API (i.e. `$id = $MadelineProto->broadcastMessages(...)`) is completed in the background (i.e. `$MadelineProto->getBroadcastProgress($id) === null`), the result of `getDialogIds` will be cached and will be returned immediately. + +## getFullDialogs +```php +$dialogs = $MadelineProto->getFullDialogs(); +foreach ($dialogs as $dialog) { + $MadelineProto->logger($dialog); +} +``` + +`getFullDialogs` will return a full list of all chats you're member of, including dialog info (such as the pinned/last message ID, unread count, tag count, notification settings and message drafts) see [here for the parameters and the result](https://docs.madelineproto.xyz/getFullDialogs.html) + +Next section \ No newline at end of file diff --git a/docs/docs/DOCKER.md b/docs/docs/DOCKER.md new file mode 100644 index 0000000000..d29f62e70b --- /dev/null +++ b/docs/docs/DOCKER.md @@ -0,0 +1,230 @@ +--- +title: "MadelineProto on Docker" +description: "MadelineProto offers an official MadelineProto docker image for the linux/amd64, linux/arm64 and linux/riscv64 platforms @ hub.madelineproto.xyz/danog/madelineproto." +nav_order: 8 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# MadelineProto on Docker + +MadelineProto offers an official MadelineProto docker image for the `linux/amd64`, `linux/arm64` and `linux/riscv64` platforms @ `hub.madelineproto.xyz/danog/madelineproto`. + +The image comes with all dependencies pre-configured. +Both opcache and JIT are enabled by default, for maximum performance. + +* [Getting started](#getting-started) + * [CLI bot (recommended)](#cli-bot-recommended) + * [Databases on docker](#databases-on-docker) + * [Web docker](#web-docker) + * [Custom extensions](#custom-extensions) + +## Getting started + +To get started, install `docker`: + +```bash +curl -fsSL https://get.docker.com | sudo sh +``` + +Then increase the `max_map_count` sysctl configuration to avoid "Fiber stack allocate failed" and "Fiber stack protect failed" errors, since the PHP engine mmaps two memory regions per fiber. + +```bash +echo 262144 | sudo tee /proc/sys/vm/max_map_count +echo vm.max_map_count=262144 | sudo tee /etc/sysctl.d/40-madelineproto.conf +``` + +Finally, follow one or more of the following guides, according to your needs: + +### CLI bot (recommended) + +Create the following `docker-compose.yml` file, with the following contents: + +```yml +services: + bot: + image: hub.madelineproto.xyz/danog/madelineproto + restart: always + #depends_on: + #- mariadb + #- postgres + #- redis + tty: true + volumes: + - ./app:/app + command: php /app/bot.php +``` + +Then, create an `app` folder, and an `app/bot.php` file with your code. + +**Mac OS note**: If you encounter issues on Mac OS, make sure to enable ephemeral filesystem support with a database [as described here »](https://docs.madelineproto.xyz/docs/DATABASE.html#ephemeral-filesystems), and change the session path in `bot.php` to point to a unique path in `/tmp`, not in `/app`. + +Then, run this command to log into the bot: + +```bash +docker run --rm -it --init -v $PWD/app:/app hub.madelineproto.xyz/danog/madelineproto php /app/bot.php +``` + +**After logging in, press ctrl-c to close the temporary container.** + +**After logging in for the first time**, you can specify some custom settings to connect to a database, as described [here »](#databases-on-docker). + +Finally, simply run this command to start the bot in the background. + +```bash +docker compose up --pull always -d +``` + +Use `docker compose logs` to view MadelineProto logs and `docker compose ps` to view the status of your bot. + +Run `docker compose restart bot` to restart the bot. + +### Databases on docker + +Specifying additional containers with mariadb, postgres or redis is really easy, just add the following sections to the `docker-compose.yml` file you created in the [previous step](#cli-bot-recommended): + +```yml +services: + # Your bot or php-fpm services created in previous steps + + #mariadb: + # image: mariadb:latest + # restart: always + # environment: + # - MARIADB_ROOT_PASSWORD=replace_me_with_a_secure_password + # volumes: + # - ./mysql:/var/lib/mysql + + #postgres: + # image: postgres:latest + # restart: always + # environment: + # POSTGRES_USER: admin + # POSTGRES_PASSWORD: replace_me_with_a_secure_password + # healthcheck: + # test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"] + # volumes: + # - ./postgres:/var/lib/postgresql/data + + #redis: + # image: redis:latest + # restart: always + # volumes: + # - ./redis:/data + # command: redis-server --save 60 1 --loglevel warning + +``` + +If you want to use the mysql backend for lower memory usage, uncomment all `mariadb` sections and use [these MadelineProto settings to connect »](https://docs.madelineproto.xyz/docs/DATABASE.html#mysql-example-low-memory-usage). + +If you want to use the postgres backend for lower memory usage, uncomment all `postgres` sections and use [these MadelineProto settings to connect »](https://docs.madelineproto.xyz/docs/DATABASE.html#postgres-example-low-memory-usage). + +If you want to use the redis backend, uncomment all `redis` sections and use these [MadelineProto settings to connect](https://docs.madelineproto.xyz/docs/DATABASE.html#redis-example-medium-memory-usage-faster-access). + +**NOTE**: MadelineProto can also be configured to run on ephemeral filesystems (i.e. docker containers with no volumes, storing all data on MySQL/Postgres/Redis) by setting a table prefix manually in the settings, as specified [here »](https://docs.madelineproto.xyz/docs/DATABASE.html#ephemeral-filesystems). + +### Web docker + +Running in [CLI mode](#cli-bot-recommended) is heavily recommended, but if web access is required, the official MadelineProto image can also function as a `php-fpm` server. +Note that the image has opcache and JIT enabled by default, so you should restart your container with `docker compose restart php-fpm` to apply changes to your code. + +Here's an example `docker-compose.yml` file for a caddy+php-fpm combo: + +```yml +services: + php-fpm: + image: hub.madelineproto.xyz/danog/madelineproto + restart: always + #depends_on: + #- mariadb + #- postgres + #- redis + volumes: + - ./app:/app + command: php-fpm + + caddy: + image: caddy:alpine + restart: always + depends_on: + - php-fpm + ports: + - 80:80/tcp + - 443:443/tcp + - 443:443/udp + volumes: + - ./app:/app + - ./Caddyfile:/etc/caddy/Caddyfile + - ./caddy_data:/data + - ./caddy_config:/config +``` + +Create the following `Caddyfile` in the same folder: + +``` +{ + email daniil@daniil.it +} + +example.com { + root * /app + php_fastcgi php-fpm:9000 + file_server + log { + format console + } +} +``` + +Caddy will automatically configure a TLS certificate for `example.com`. + +Create an `app` folder, and put your code in that folder. + +Finally, simply run this command to start the webserver in the background. + +```bash +docker compose up --pull always -d +``` + +You can now access your PHP code @ `https://example.com`. + +You can also add containers for mariadb, postgres or redis as [described here »](#databases-on-docker). + +Use `docker compose logs` to view webserver logs and `docker compose ps` to view the status of your webserver. + +Run `docker compose restart php-fpm` every time you change your code to reload changes. + +If you want to test locally without obtaining a certificate for a domain, replace `example.com` with `http://localhost:80` in the Caddyfile. + +### Custom extensions + +Optionally, you may also add custom extensions by creating a custom docker image with the following `Dockerfile`, for example to install the `gd` and `bcmath` extensions: + +``` +FROM hub.madelineproto.xyz/danog/madelineproto:latest + +ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ + +RUN chmod +x /usr/local/bin/install-php-extensions && \ + install-php-extensions gd bcmath && \ + rm /usr/local/bin/install-php-extensions +``` + +And use the following `docker-compose.yml` file: + +```yml +services: + bot: + build: + context: . + dockerfile: Dockerfile + restart: always + #depends_on: + #- mariadb + #- postgres + #- redis + tty: true + volumes: + - .:/app + command: php /app/bot.php +``` + +Next section \ No newline at end of file diff --git a/docs/docs/EXCEPTIONS.md b/docs/docs/EXCEPTIONS.md new file mode 100644 index 0000000000..215a2efa05 --- /dev/null +++ b/docs/docs/EXCEPTIONS.md @@ -0,0 +1,116 @@ +--- +title: "Exceptions" +description: "MadelineProto can throw lots of different exceptions." +nav_order: 17 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Exceptions + +MadelineProto can throw lots of different exceptions. + +```php +try { + $MadelineProto->someMethod(); +} catch (\danog\MadelineProto\RPCErrorException $e) { + if ($e->rpc === 'BOT_METHOD_INVALID') { + \danog\MadelineProto\Logger::log("Bots can't execute this method!"); + } else { + $MadelineProto->messages->sendMessage(['peer' => '@danogentili', 'message' => 'An error occurred while calling someMethod: '.$e]); + } +} +``` + +* [List of exception types](#list-of-exception-types) +* [Pretty TL trace](#pretty-tl-trace) +* [Getting the TL trace](#getting-the-tl-trace) + + +## List of exception types + +* `\danog\MadelineProto\Exception` - Default exception, thrown when a php error occures and in a lot of other cases + +* `\danog\MadelineProto\RPCErrorException` - Thrown when an RPC error occurres (an error received via the MTProto API): **note** that the error message of this exception is localized in English, and may vary: to fetch the original API error message use `$e->rpc`. + +* `\danog\MadelineProto\TL\Exception` - Thrown on TL serialization/deserialization errors + +* `\danog\MadelineProto\ResponseException` - Thrown when an unexpected message is received through the socket + +* `\danog\MadelineProto\NothingInTheSocketException` - Thrown if no data can be read/written on the TCP socket + +* `\danog\MadelineProto\PTSException` - Thrown if the PTS is unrecoverably corrupted + +* `\danog\MadelineProto\SecurityException` - Thrown on security problems (invalid params during generation of auth key or similar) + +* `\danog\MadelineProto\TL\Conversion\Exception` - Thrown if some param/object can't be converted to/from bot API/TD/TD-CLI format (this includes markdown/html parsing) + + +## Pretty TL trace +Every exception features a custom stack trace called `pretty TL trace`, that makes finding bugs **really** easy: + +```text +php > $MadelineProto->messages->sendMessage(peer: '@dd', message: 'hi'); + +Uncaught \danog\MadelineProto\Exception: This peer is not present in the internal peer database in /home/pwrtelegram/cleanMadeline/src/MTProtoTools/PeerHandler.php:330 +Revision: 63823fc3cc5070bd8a1ebe91e60e1fd583a2f37f + +TL Trace (YOU ABSOLUTELY MUST READ THE TEXT BELOW): + +PeerHandler.php(327): getInfo("dd",false) +TL.php(339): getInfo("dd")['peer'] +While serializing: messages.sendMessage +CallHandler.php(79): serializeMethod("messages.sendMessage",{"peer":"@dd","message":"hi"}) +APIFactory.php(142): methodCall("messages.sendMessage",{"peer":"@dd","message":"hi"},{"datacenter":4}) +php shell code(1): __call("sendMessage",[{"peer":"@dd","message":"hi"}]) + thrown in /home/pwrtelegram/cleanMadeline/src/MTProtoTools/PeerHandler.php on line 330 +php > +``` + +Explanation: + +`Uncaught \danog\MadelineProto\Exception`: an exception of type \danog\MadelineProto\Exception was thrown and not caught using a `catch` block, like showed in the first example of this page. + +`This peer is not present in the internal peer database`: this error means you have tried sending a message to a peer that does not exist or is not present in MadelineProto's internal peer database: in fact, `@dd` is not a valid telegram username. + +`in /home/pwrtelegram/cleanMadeline/src/MTProtoTools/PeerHandler.php:330`: this indicates the line where this error was thrown + +`Revision: 63823fc3cc5070bd8a1ebe91e60e1fd583a2f37f`: this indicates the MadelineProto version: **always** include this code when opening github issues or reporting errors in the group. + +```text +PeerHandler.php(327): getInfo("dd",false) +TL.php(339): getInfo("dd") +['peer'] +While serializing: messages.sendMessage +CallHandler.php(79): serializeMethod("messages.sendMessage",{"peer":"@dd","message":"hi"}) +APIFactory.php(142): methodCall("messages.sendMessage",{"peer":"@dd","message":"hi"},{"datacenter":4}) +php shell code(1): __call("sendMessage",[{"peer":"@dd","message":"hi"}]) +``` + +This part is supposed to be read from bottom to top, the most important parts are: + +`While serializing: messages.sendMessage`: this means the error was thrown while serializing the method call for messages->sendMessage + +`['peer']`: this means the error was thrown while trying to serialize the `peer` parameter, so **you should fix that part of your code**: +```php +$MadelineProto->messages->sendMessage(['peer' => '@danogentili', 'message' => 'hi']); +``` + +## Getting the TL trace + +To get the whole TL trace as string, cast the exception object to string: + +**NOTE**: Due to the async nature of MadelineProto 4.0, sometimes the exception that is thrown and logged may not be the actual exception that caused the crash of the script. +To let me properly debug the issue, when reporting issues you also have to provide [**full logs**](LOGGING.html). + + +```php +try { + // stuff +} catch (\danog\MadelineProto\Exception $e) { + $estring = (string) $e; + $estring2 = 'This also works: '.$e; + $estring3 = "So does this: $e"; + // use $estring to report the error using sendMessage or log +} +``` + +Next section \ No newline at end of file diff --git a/docs/docs/FAQ.md b/docs/docs/FAQ.md new file mode 100644 index 0000000000..997e725316 --- /dev/null +++ b/docs/docs/FAQ.md @@ -0,0 +1,196 @@ +--- +title: "FAQ" +description: "Here's a list of common MadelineProto questions and answers." +nav_order: 28 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# FAQ + +Here's a list of common MadelineProto questions and answers. + +## How do I solve "Fiber stack allocate failed" and "Fiber stack protect failed" errors? + +The PHP engine mmap's two memory regions for each forked green thread: one for the stack, and one for the final guard page. + +MadelineProto can use hundreds or even thousands of concurrent, low-overhead green threads to handle updates with the maximum performance. + +This error is emitted when the maximum number of configured mmap'ed regions is reached: you must increase the vm.max_map_count kernel config to 262144 to fix. + +To fix, run the following command as root: + +```bash +echo 262144 | sudo tee /proc/sys/vm/max_map_count +``` + +To persist the change across reboots: + +```bash +echo vm.max_map_count=262144 | sudo tee /etc/sysctl.d/40-madelineproto.conf +``` + +On Windows and WSL, increasing the size of the pagefile might help; please switch to native Linux if the issue persists. + +## How do I get the chat ID and/or sender ID of a message in the event handler? + +Use this code: + +```php +// Chat ID +$id = $this->getId($update); + +// Sender ID, not always present +from_id = isset($update['message']['from_id']) + ? $this->getId($update['message']['from_id']) + : null; +``` + +## How do I extract the ID of a message sent using sendMessage/sendMedia/etc...? + +Use this code: + +```php +$id = $MadelineProto->extractMessageId( + $MadelineProto->messages->sendMessage(peer: 'danogentili', message: 'test') +); +``` + +## How do I execute a function periodically (like cron)? + +Use this code: + +```php +use danog\MadelineProto\EventHandler; +use danog\MadelineProto\Settings; +use danog\Loop\GenericLoop; + +class MyEventHandler extends EventHandler +{ + private PeriodicLoop $cron1; + + public function onStart(): void + { + // Execute every 1.0 seconds + $this->cron1 = new PeriodicLoop($this->cron1(...), "Cron 1", 1.0); + $this->cron1->start(); + } + + /** + * Cron function 1. + * Executed every second. + */ + private function cron1(): bool + { + $this->echo("Current time: ".time().PHP_EOL); + + // The loop can be stopped from the outside by calling $this->cron1->stop(); + + // You can also return true here to stop the loop from the inside. + return false; + } +} + +$settings = new Settings; + +MyEventHandler::startAndLoop('bot.madeline', $settings); +``` + +See the [danog/loop](https://daniil.it/loop) documentation for more info. + +## Do I need cron to run MadelineProto? + +Generally, you don't. + +To keep your MadelineProto bot online forever: + +- If running via CLI, use [docker »](https://docs.madelineproto.xyz/docs/DOCKER.html) or a `screen while :; php bot.php;done` session. +- If running via web: MadelineProto will self-restart automatically: however, please note that this self-restart logic may fail in case of a physical server reboot or web server/php-fpm restart, so it’s always a better idea to run via CLI, or use a cron to periodically ping the bot’s URL. + +## How do I use a database in MadelineProto? + +First of all, **never use PDO**. + +If you only want to reduce RAM usage of your bot, use this code: + +```php +$settings = (new \danog\MadelineProto\Settings\Database\Mysql) + ->setUri('tcp://localhost') + ->setPassword('pass'); + +MyEventHandler::startAndLoop('bot.madeline', $settings); +``` + +You can also use Postgresql or Redis, see the [database docs for more info »](https://docs.madelineproto.xyz/docs/DATABASE.html). + +If you also want to store data of your bot in a database, use this code: + +```php + +use danog\MadelineProto\EventHandler; + +class MyEventHandler extends EventHandler +{ + private int $messageCounter = 0; + + /** Which properties to save in the database */ + public function __sleep(): array + { + return ['messageCounter']; + } + + public function onUpdateNewMessage(array $update) { + $this->messageCounter++; + } +} + +$settings = (new \danog\MadelineProto\Settings\Database\Mysql) + ->setUri('tcp://localhost') + ->setPassword('pass'); + +MyEventHandler::startAndLoop('bot.madeline', $settings); +``` + +This will automatically store the `$messageCounter` property in the MySQL/postgres/redis database. + +The property can have any type (`array`, `object`, `string`, etc): there are no limits. + +If you actually want to interact with a real database using SQL queries, use the [amphp/mysql](https://github.com/amphp/mysql) library. + +## How do I use threads in MadelineProto? + +You can fork a new green thread using this code: + +```php +\danog\MadelineProto\Tools::callFork(function() { + // Code to execute in forked thread +}); +// Code to execute in original thread +``` + +Make sure to never use blocking functions in the forked thread (NO `file_get_contents`, `PDO`), only use [async amphp libraries](https://amphp.org) (i.e. [amphp/file](https://amphp.org/file), [amphp/mysql](https://amphp.org/mysql), and [so on...](https://amphp.org/installation)). + +See the [async docs »](https://docs.madelineproto.xyz/docs/ASYNC.html) for more info. + +## What is the "MadelineProto worker" process, can I kill it? + +No, you must never kill it. + +The MadelineProto worker process is like apache2: it keeps running in the background, waiting for incoming requests from MadelineProto. + +Don't kill it, or else MadelineProto will take 30+ seconds to start, every time you make a request. + +You don't kill your apache2/nginx webserver just because there are no incoming requests, and the same goes for the MadelineProto worker process. + +When there are no incoming requests, CPU usage is extremely low (`~0%`), and RAM usage can be reduced by using the [database](#how-do-i-use-a-database-in-madelineproto) (don't forget to use `updateSettings` to update the settings). + +## What is the "This peer is not present in the internal peer database" error (also known as PeerNotInDbException)? + +This error indicates that a specified peer (user, chat, channel) was not found in the internal MadelineProto peer database. + +This can be because the user(bot) has never seen the peer before in the dialog list or in a chat. + +This error can also be caused by an invalid ID, extracted manually from an update, instead of using the correct `$this->getID($update)` function. + +This error can also be caused by referring to a user/chat/channel by its bot API ID, *only if the (user)bot has never seen the peer before*. +In this case, resolving a user/chat/channel `@username` with [getInfo](https://docs.madelineproto.xyz/getInfo.html) or importing an invite link with [messages.importChatInvite](https://docs.madelineproto.xyz/API_docs/methods/messages.importChatInvite.html), or (for users) enabling the [setCacheAllPeersOnStartup setting](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Peer.html#setcacheallpeersonstartup-bool-cacheallpeersonstartup-self) will automatically cache the peer into the database, allowing you to use the bot API ID again. + +Next section \ No newline at end of file diff --git a/docs/docs/FEATURES.md b/docs/docs/FEATURES.md new file mode 100644 index 0000000000..973bbabb9b --- /dev/null +++ b/docs/docs/FEATURES.md @@ -0,0 +1,53 @@ +--- +title: "Features" +description: "MadelineProto can do everything official clients can do, and more!" +nav_order: 6 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Features + +MadelineProto can do everything official clients can do, and more! + +* It allows you to do everything official clients can do, programmatically! + +* It is [fully async](https://docs.madelineproto.xyz/docs/ASYNC.html)! + +* *It can make phone calls!* [See here for instructions](https://docs.madelineproto.xyz/docs/CALLS.html) + +* It can be proxied (MTProxy, HTTP, socks5 and more)! + +* It is very fast! + +* It can be easily serialized! + +* It featured update handling with callbacks or long polling! + +* Easy to use wrappers to upload/download files and call mtproto methods + +* Documentation for EVERY mtproto method! + +* Internal peer management: you can provide a simple bot API chat id or a username to send a message or to call other mtproto methods! + +* You can easily login as a user (2FA is supported) or as a bot! + +* Simple error handling! + +* It is highly customizable with a lot of different settings! + +* Bot API file id/object support (even for users)! + +* A Lua binding + +* A lua wrapper for td-cli scripts + +* Secret chats + +* MTProto 2.0 + +* PFS + +* PFS in secret chats + +* [Clickable inline buttons](https://docs.madelineproto.xyz/docs/INLINE_BUTTONS.html)! + +Next section \ No newline at end of file diff --git a/docs/docs/FILES.md b/docs/docs/FILES.md new file mode 100644 index 0000000000..d832f3343b --- /dev/null +++ b/docs/docs/FILES.md @@ -0,0 +1,784 @@ +--- +title: "Uploading and downloading files" +description: "MadelineProto provides fully parallelized wrapper methods to upload and download files that support bot API file ids, direct upload by URL and file renaming." +nav_order: 21 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Uploading and downloading files + +MadelineProto provides **fully parallelized** wrapper methods to upload and download files that support bot API file ids, direct upload by URL and file renaming. + +Maximum file size is of 4 GB. + +Example bot: [`downloadRenameBot.php`](https://github.com/danog/downloadRenameBot/blob/main/bot.php) - download files by URL and rename Telegram files using this async parallelized bot! + + +* [Bot API file IDs](#bot-api-file-ids) +* [Uploading & sending files](#sending-files) + * [Security notice](#security-notice) + * [Photos](#photos) + * [Photos as documents](#photos-as-documents) + * [Documents](#documents) + * [GIFs](#gifs) + * [Videos](#videos) + * [Music](#music) + * [Voice](#voice) + * [Stickers](#stickers) +* [Uploading files](#uploading-files) +* [Reusing uploaded files](#reusing-uploaded-files) +* [Renaming files](#renaming-files) +* [Downloading files](#downloading-files) + * [Extracting download info](#extracting-download-info) + * [Getting a download link](#getting-a-download-link) + * [Downloading profile pictures](#downloading-profile-pictures) + * [Download to directory](#download-to-directory) + * [Download to file](#download-to-file) + * [Download to stream](#download-to-stream) + * [Download to callback](#download-to-callback) + * [Download to http-server](#download-to-http-server) + * [Download to browser](#download-to-browser) +* [Getting progress](#getting-progress) + +## Sending files + +To send photos and documents to someone, use the [$MadelineProto->messages->sendMedia](https://docs.madelineproto.xyz/API_docs/methods/messages.sendMedia.html) method, click on the link for more info. + +All files will be uploaded **asynchronously and in parallel**, 20 chunks at a time for maximum performance (this value can be tweaked in the [settings](https://docs.madelineproto.xyz/docs/SETTINGS.html)). + +The required `message` parameter is the caption: it can contain URLs, mentions, bold and italic text, thanks to the `parse_mode` parameter, that enables markdown or HTML parsing. + +The `media` parameter contains the file path and other info about the file. + +It can contain [lots of various objects](https://docs.madelineproto.xyz/API_docs/types/InputMedia.html), here are the most important: + +### Security notice + +Be careful when calling methods with user-provided parameters: the upload function may be used to access and send any file. +To disable automatic uploads by file name (disabled by default), [use the appropriate setting](../PHP/danog/MadelineProto/Settings/Files.html#setallowautomaticuploadbool-allowautomaticupload-self) OR upload files [manually](#reusing-uploaded-files). + + +### Photos +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('faust.jpg'); + +// $file = new RemoteUrl('https://example.com/img.jpg'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendPhoto( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendPhoto) to see the full list of arguments to set set the self-destruction period of the photo, and many more parameters. + +### Photos as documents +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('faust.jpg'); + +// $file = new RemoteUrl('https://example.com/img.jpg'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendDocumentPhoto( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendDocumentPhoto) to see the full list of arguments to set set the self-destruction period of the photo, and many more parameters. + +### Documents + +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('faust.txt'); + +// $file = new RemoteUrl('https://example.com/file.txt'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendDocument( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendDocument) to see the full list of arguments to set set the self-destruction period of the document, and many more parameters. + +To rename files, provide a Message or another already-uploaded Telegram file object to the `file` field. + +### GIFs +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('gif.mp4'); + +// $file = new RemoteUrl('https://example.com/gif.mp4'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendGif( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendGif) to see the full list of arguments to set set the self-destruction period of the document, and many more parameters. + +MadelineProto will **automatically** extract the video's thumbnail, duration, width and height using ffmpeg, if installed. + +### Videos + +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('video.mp4'); + +// $file = new RemoteUrl('https://example.com/video.mp4'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendVideo( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendVideo) to see the full list of arguments to set set the self-destruction period of the document, send round videos, and many more parameters. + +MadelineProto will **automatically** extract the video's thumbnail, duration, width and height using ffmpeg, if installed. + +### Music + +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('song.mp3'); + +// $file = new RemoteUrl('https://example.com/song.mp3'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendAudio( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendAudio) to see the full list of arguments to set set the self-destruction period of the document, and many more parameters. + +MadelineProto will **automatically** extract the music's thumbnail and duration using ffmpeg, if installed. + + +### Voice + +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('voice.ogg'); + +// $file = new RemoteUrl('https://example.com/voice.ogg'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendVoice( + peer: '@danogentili', + file: $file, + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendVoice) to see the full list of arguments to set set the self-destruction period of the document, and many more parameters. + +MadelineProto will **automatically** extract the voice message's duration using ffmpeg, if installed. + +### Stickers + +```php +use danog\MadelineProto\LocalFile; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\BotApiFileId; + +use danog\MadelineProto\ParseMode; + +$file = new LocalFile('sticker.webp'); + +// $file = new RemoteUrl('https://example.com/sticker.webp'); +// ... +// $file can also be a Message, Media, BotApiFileId, ReadableStream object. + +$sentMessage = $MadelineProto->sendSticker( + peer: '@danogentili', + file: $file, + mimeType: 'image/webp', + caption: '[This is the caption](https://t.me/MadelineProto)', + parseMode: ParseMode::MARKDOWN +); +``` + +Click [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendSticker) to see the full list of arguments to set set the self-destruction period of the document, and many more parameters. + +## Uploading files + +```php +$MessageMedia = $MadelineProto->messages->uploadMedia([ + 'media' => [ + '_' => 'inputMediaUploadedPhoto', + 'file' => 'faust.jpg' + ], +]); +``` + +The `file` can be a file name, a URL, or a file uploaded by someone else (can be used to rename files). + +You can also only upload a file, without actually sending it to anyone, storing only the file ID for later usage. + +All files will be uploaded **asynchronously and in parallel**, 20 chunks at a time for maximum performance (this value can be tweaked in the [settings](https://docs.madelineproto.xyz/docs/SETTINGS.html)). + +The [$MadelineProto->messages->uploadMedia](https://docs.madelineproto.xyz/API_docs/methods/messages_uploadMedia.html) function is a reduced version of the [$MadelineProto->messages->sendMedia](https://docs.madelineproto.xyz/API_docs/methods/messages_sendMedia.html), that requires only a `media` parameter, with the media to upload (on normal users, the `peer` field should be populated with `@me` or another value). + +The returned [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object can then be reused to resend the document using sendMedia. + +```php +$sentMessage = $MadelineProto->messages->sendMedia([ + 'peer' => '@danogentili', + 'media' => $MessageMedia, + 'message' => '[This is the caption](https://t.me/MadelineProto)', + 'parse_mode' => 'Markdown' +]); +``` + +`$MessageMedia` can also be a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html) (the media contained in the message will be sent), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html) (the media contained in the message contained in the update will be sent). + +## Reusing uploaded files + +`$MadelineProto->messages->uploadMedia` and bot API file IDs do not allow you to modify the type of the file to send: however, MadelineProto provides methods that can generate a file object that can be resent with multiple file types. + +```php +$inputFile = $MadelineProto->upload('filename.mp4'); +``` + +The file name can also be a URL. +More optional parameters are available, check the PHPDOC of the method in your IDE. +You can also upload a file from a stream (this is especially useful, for example, when downloading YouTube videos using `youtube-dl` with `ffmpeg` and [async AMPHP CLI streams](https://github.com/amphp/process)): + +```php +$inputFile = $MadelineProto->uploadFromStream($stream); +``` + +`$stream` - PHP resource or [async AMPHP stream](https://github.com/amphp/byte-stream). + +More optional parameters are available, check the PHPDOC of the method in your IDE. +You can also upload files from a callable: + +```php +$inputFile = $MadelineProto->uploadFromCallable($callable, $size, $mime); +``` + +`$callable`: +The callable must accept two parameters: `int $offset, int $size` +The callable must return a string with the contest of the file at the specified offset and size. + +More optional parameters are available, check the PHPDOC of the method in your IDE. + +You can also re-use a media received in a message or update, for example in the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html): + +```php +$inputFile = $update; +$inputFile = $message; +``` + +--- + +The generated `$inputFile` can later be reused thusly: + +```php +$sentMessage = $MadelineProto->messages->sendMedia([ + 'peer' => '@danogentili', + 'media' => [ + '_' => 'inputMediaUploadedDocument', + 'file' => $inputFile, + 'attributes' => [ + ['_' => 'documentAttributeFilename', 'file_name' => 'video.mp4'] + ] + ], + 'message' => '[This is the caption](https://t.me/MadelineProto)', + 'parse_mode' => 'Markdown' +]); +$sentMessageVideo = $MadelineProto->messages->sendMedia([ + 'peer' => '@danogentili', + 'media' => [ + '_' => 'inputMediaUploadedDocument', + 'file' => $inputFile, + 'attributes' => [ + ['_' => 'documentAttributeVideo', 'round_message' => false, 'supports_streaming' => true] + ] + ], + 'message' => '[This is the caption](https://t.me/MadelineProto)', + 'parse_mode' => 'Markdown' +]); +``` + +In this case, we're reusing the same InputFile to send both a document and a video, without uploading the file twice. + +The concept is easy: where you would usually provide a file path, simply provide `$inputFile`. + +## Renaming files + +Files can be renamed by simply providing the `$Update` with the file to the sendMedia method thusly: + +```php +$sentMessage = $MadelineProto->messages->sendMedia([ + 'peer' => '@danogentili', + 'media' => [ + '_' => 'inputMediaUploadedDocument', + 'file' => $Update, + 'attributes' => [ + ['_' => 'documentAttributeFilename', 'file_name' => $newName] + ] + ], + 'message' => '[This is the caption](https://t.me/MadelineProto)', + 'parse_mode' => 'Markdown' +]); +``` + +## Downloading files + +There are multiple download methods that allow you to download a file to a directory, to a file or to a stream. + +### Extracting download info +```php +$info = $MadelineProto->getDownloadInfo($MessageMedia); +``` + +`$MessageMedia` can be a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object or a bot API file ID. + +You can also use [getDownloadLink](#getting-a-download-link) to obtain a direct download link for any file up to 4GB. + +* `$info['ext']` - The file extension +* `$info['name']` - The file name, without the extension +* `$info['mime']` - The file mime type +* `$info['size']` - The file size + +### Getting a download link + +To obtain a direct download link for any Telegram file up to 4GB, simply use `getDownloadLink`, for example: + +```php +botLogin('token'); + +// For users +//$MadelineProto->start(); + +$botApiFileId = '...'; +$fileName = '...'; +$fileSize = 123..; +$mimeType = '...'; + + +$link = $MadelineProto->getDownloadLink($botApiFileId, size: $fileSize, name: $fileName, mime: $mimeType); +``` + +Event handler example with [bound methods](https://docs.madelineproto.xyz/docs/UPDATES.html#bound-methods): + +```php +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\EventHandler\Filter\FilterCommand; +use danog\MadelineProto\EventHandler\Message; +use danog\MadelineProto\EventHandler\SimpleFilter\Incoming; + +class MyEventHandler extends SimpleEventHandler +{ + /** + * Gets a download link for any file up to 4GB! + */ + #[FilterCommand('dl')] + public function downloadLink(Incoming&Message $message): void + { + $reply = $message->getReply(Message::class); + if (!$reply?->media) { + $message->reply("This command must reply to a media message!"); + return; + } + $reply->reply("Download link: ".$reply->media->getDownloadLink()); + } +} + +MyEventHandler::startAndLoop('bot.madeline') +``` + +`$botApiFileId` can be a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object or a **bot API file ID** (files up to 4GB are supported!). + +This method will work automatically only when running via web (apache/php-fpm). + +The generated download `$link` will point to your own server, and the link will stream files directly to the browser (**no temporary files will be created**, **0** disk space will be used). + +#### Getting a download link (CLI bots) + +**Only if running via CLI** (or if URL rewriting is enabled on web), a second parameter must be provided with a URL to a download script hosted on a php-fpm/apache instance on the same machine: + +```php +botLogin('token'); + +// For users +//$MadelineProto->start(); + +$botApiFileId = '...'; +$fileName = '...'; +$fileSize = 123..; +$mimeType = '...'; + + +$link = $MadelineProto->getDownloadLink($botApiFileId, 'https://yourhost.com/dl.php', size: $fileSize, name: $fileName, mime: $mimeType); +``` + +Event handler example with [bound methods](https://docs.madelineproto.xyz/docs/UPDATES.html#bound-methods): + +```php +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\EventHandler\Filter\FilterCommand; +use danog\MadelineProto\EventHandler\Message; +use danog\MadelineProto\EventHandler\SimpleFilter\Incoming; + +class MyEventHandler extends SimpleEventHandler +{ + /** + * Gets a download link for any file up to 4GB! + */ + #[FilterCommand('dl')] + public function downloadLink(Incoming&Message $message): void + { + $reply = $message->getReply(Message::class); + if (!$reply?->media) { + $message->reply("This command must reply to a media message!"); + return; + } + $reply->reply("Download link: ".$reply->media->getDownloadLink('https://yourhost.com/dl.php')); + } +} + +MyEventHandler::startAndLoop('bot.madeline') +``` + +You can also pass your custom download link in the [Files settings, instead](https://docs.madelineproto.xyz/docs/FILES.html). + +The dl.php script must have the following content: + +```php +getPropicInfo($Update); +``` + +`$Update` can be a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html) object, an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), or any value supported by [getInfo](https://docs.madelineproto.xyz/getInfo.html). +The result will be a [Photo](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Media/Photo.html) object. + +### Download to directory +```php +$output_file_name = $MadelineProto->downloadToDir($MessageMedia, '/tmp/'); +``` + +This downloads the given file to `/tmp`, and returns the full generated file path. + +**Note**: if downloading files that will be re-downloaded by the user, use [downloadToBrowser](#download-to-browser), instead: [downloadToBrowser](#download-to-browser) will avoid the creation of temporary files, streaming the file directly to the user. + +You can also use [getDownloadLink](#getting-a-download-link) to obtain a direct download link for any file up to 4GB. + +`$MessageMedia` can be either a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object, or a bot API file ID. + +### Download to file +```php +$output_file_name = $MadelineProto->downloadToFile($MessageMedia, '/tmp/myname.mp4'); +``` + +**Note**: if downloading files that will be re-downloaded by the user, use [downloadToBrowser](#download-to-browser), instead: [downloadToBrowser](#download-to-browser) will avoid the creation of temporary files, streaming the file directly to the user. + +You can also use [getDownloadLink](#getting-a-download-link) to obtain a direct download link for any file up to 4GB. + +This downloads the given file to `/tmp/myname.mp4`, and returns the full file path. + +`$MessageMedia`can be either a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object, or a bot API file ID. + +### Download to stream +```php +$MadelineProto->downloadToStream($MessageMedia, $stream); +``` + +This downloads the given file to the given resource or [async AMPHP stream](https://github.com/amphp/byte-stream), the latter is especially useful for building an async HTTP file server with [http-server](https://github.com/amphp/http-server). + +`$MessageMedia`can be either a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object, or a bot API file ID. + + +You can also use `downloadToReturnedStream`, which returns an amphp `ReadableStream`, instead: + +```php +$stream = $MadelineProto->downloadToReturnedStream($MessageMedia); +``` + +### Download to callback +```php +$MadelineProto->downloadToCallable($MessageMedia, $callable); +``` + +This downloads the given file to the callable. +The callable must accept two parameters: `string $payload, int $offset` +The callable will be called (possibly out of order, depending on the value of the `$seekable` (see PHPDOC)). +The callable should return the number of written bytes. + +`$MessageMedia`can be either a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object, or a bot API file ID. + + +### Download to http-server +```php +$MadelineProto->downloadToResponse($MessageMedia, $request, $cb); +``` + +This downloads the given file, replying to the specified [async http-server](https://amphp.org/http-server) request. +Automatically supports HEAD requests and content-ranges for parallel and resumed downloads. + +`$MessageMedia` can be either a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object, or a bot API file ID. + +`$request` is the [Request](https://amphp.org/http-server/classes/request) object returned by [http-server](https://amphp.org/http-server). + +`$cb` is an optional parameter can be a callback for download progress, but it shouldn't be used, the new [FileCallback](#getting-progress) should be used instead + + + +### Download to browser +```php +$MadelineProto->downloadToBrowser($MessageMedia, $cb); +``` + +You can also use [getDownloadLink](#getting-a-download-link) to obtain a direct download link for any file up to 4GB. + +This downloads the given file to the browser, sending also information about the file's type and size. +Automatically supports HEAD requests and content-ranges for parallel and resumed downloads. + +`$MessageMedia` can be either a [Message](https://docs.madelineproto.xyz/API_docs/types/Message.html), an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html), a [MessageMedia](https://docs.madelineproto.xyz/API_docs/types/MessageMedia.html) object, or a bot API file ID. + +`$cb` is an optional parameter can be a callback for download progress, but it shouldn't be used, the new [FileCallback](#getting-progress) should be used instead + + +## Getting progress + +To get the upload/download progress in real-time, use the `\danog\MadelineProto\FileCallback` class: + +```php +$peer = '@danogentili'; +$sentMessage = $MadelineProto->messages->sendMedia([ + 'peer' => $peer, + 'media' => [ + '_' => 'inputMediaUploadedDocument', + 'file' => new \danog\MadelineProto\FileCallback( + 'video.mp4', + function ($progress, $speed, $time) use ($MadelineProto, $peer) { + try { + $MadelineProto->messages->sendMessage(['peer' => $peer, 'message' => "Upload progress: $progress%\nSpeed: $speed mbps\nTime elapsed since start: $time"]); + } catch (\Throwable $e) {} + } + ), + 'attributes' => [ + ['_' => 'documentAttributeVideo', 'round_message' => false, 'supports_streaming' => true] + ] + ], + 'message' => '[This is the caption](https://t.me/MadelineProto)', + 'parse_mode' => 'Markdown' +]); + +$output_file_name = $MadelineProto->downloadToFile( + $sentMessage, + new \danog\MadelineProto\FileCallback( + '/tmp/myname.mp4', + function ($progress, $speed, $time) use ($MadelineProto, $peer) { + try { + $MadelineProto->messages->sendMessage(['peer' => $peer, 'message' => "Download progress: $progress%\nSpeed: $speed mbps\nTime elapsed since start: $time"]); + } catch (\Throwable $e) {} + } + ) +); +``` + +This will send the file `video.mp4` to [@danogentili](https://t.me/danogentili): while uploading, he will receive progress messages `Upload progress: 24%` until the upload is complete; while downloading, he will receive progress messages `Download progress: 34%` until the download is complete. + +You can also add two more parameters `$speed, $time` to the signature of the method to get a partial upload speed in mbps, along with the time elapsed since the start of the download. + +A FileCallback object can be provided to `uploadMedia`, `sendMedia`, `uploadProfilePicture`, `upload`, `upload_encrypted`, `download_to_*`: the first parameter to its constructor must be the file path/object that is usually accepted by the function, the second must be a callable function or object. + +You can also write your own callback class, just implement `\danog\MadelineProto\FileCallbackInterface`: +```php +class MyCallback implements \danog\MadelineProto\FileCallbackInterface +{ + private $file; + private $peer; + private $MadelineProto; + public function __construct($file, $peer, $MadelineProto) + { + $this->file = $file; + $this->peer = $peer; + $this->MadelineProto = $MadelineProto; + } + public function getFile() + { + return $this->file; + } + public function __invoke($progress, $speed, $time) + { + $this->MadelineProto->messages->sendMessage(['peer' => $this->peer, 'message' => 'Progress: '.$progress.'%']); + } +} +$peer = '@danogentili'; +$sentMessage = $MadelineProto->messages->sendMedia([ + 'peer' => $peer, + 'media' => [ + '_' => 'inputMediaUploadedDocument', + 'file' => new MyCallback('video.mp4', $peer, $MadelineProto), + 'attributes' => [ + ['_' => 'documentAttributeVideo', 'round_message' => false, 'supports_streaming' => true] + ] + ], + 'message' => '[This is the caption](https://t.me/MadelineProto)', + 'parse_mode' => 'Markdown' +]); + +$output_file_name = $MadelineProto->downloadToFile( + $sentMessage, + new MyCallback('/tmp/myname.mp4', $peer, $MadelineProto) +); +``` + + +## Bot API file IDs + +`$MessageMedia` can even be a bot API file ID, generated by the bot API, or by MadelineProto: + +Actual MessageMedia objects can also be converted to bot API file IDs like this: + +```php +$botAPI_file = $MadelineProto->MTProtoToBotAPI($MessageMedia); +``` + +`$botAPI_file` now contains a [bot API message](https://core.telegram.org/bots/api#message), to extract the file ID from it use the following code: + +```php +foreach (['audio', 'document', 'photo', 'sticker', 'video', 'voice', 'video_note'] as $type) { + if (isset($botAPI_file[$type]) && is_array($botAPI_file[$type])) { + $method = $type; + } +} +$result['file_type'] = $method; +if ($result['file_type'] == 'photo') { + $result['file_size'] = $botAPI_file[$method][0]['file_size']; + if (isset($botAPI_file[$method][0]['file_name'])) { + $result['file_name'] = $botAPI_file[$method][0]['file_name']; + $result['file_id'] = $botAPI_file[$method][0]['file_id']; + } +} else { + if (isset($botAPI_file[$method]['file_name'])) { + $result['file_name'] = $botAPI_file[$method]['file_name']; + } + if (isset($botAPI_file[$method]['file_size'])) { + $result['file_size'] = $botAPI_file[$method]['file_size']; + } + if (isset($botAPI_file[$method]['mime_type'])) { + $result['mime_type'] = $botAPI_file[$method]['mime_type']; + } + $result['file_id'] = $botAPI_file[$method]['file_id']; +} +if (!isset($result['mime_type'])) { + $result['mime_type'] = 'application/octet-stream'; +} +if (!isset($result['file_name'])) { + $result['file_name'] = $result['file_id'].($method === 'sticker' ? '.webp' : ''); +} +``` + +* `$result['file_id']` - Bot API file ID +* `$result['mime_type']` - Mime type +* `$result['file_type']` - File type: voice, video, video_note (round video), music, video, photo, sticker or document +* `$result['file_size']` - File size +* `$result['file_name']` - File name + +Next section \ No newline at end of file diff --git a/docs/docs/FILTERS.md b/docs/docs/FILTERS.md new file mode 100644 index 0000000000..401b393483 --- /dev/null +++ b/docs/docs/FILTERS.md @@ -0,0 +1,942 @@ +--- +title: "Filters" +description: "MadelineProto offers a very simple and intuitive message filtering system, based on PHP's type system and attributes." +nav_order: 12 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Filters + +MadelineProto offers a very simple and intuitive message filtering system, based on PHP's type system and attributes. + +There are two filter types: + +* [Simple filters](#simple-filters) +* [Attribute filters](#attribute-filters) + * [Creating custom attribute filters](#creating-custom-attribute-filters) +* [MTProto filters](#mtproto-filters) + +## Simple filters + +Simple filters are implemented using simple PHP types, for example: + +```php +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\EventHandler\Attributes\Handler; +use danog\MadelineProto\EventHandler\Message; +use danog\MadelineProto\EventHandler\Message\PrivateMessage; +use danog\MadelineProto\EventHandler\Message\GroupMessage; +use danog\MadelineProto\EventHandler\Message\ChannelMessage; +use danog\MadelineProto\EventHandler\SimpleFilter\Incoming; +use danog\MadelineProto\EventHandler\SimpleFilter\Outgoing; +use danog\MadelineProto\EventHandler\SimpleFilter\HasMedia; + +class MyEventHandler extends SimpleEventHandler +{ + #[Handler] + public function h1(Incoming & Message $message): void + { + // Handle all incoming messages (private+groups+channels). + } + + #[Handler] + public function h2(Outgoing & PrivateMessage $message): void + { + // Handle all outgoing messages (private). + } + + #[Handler] + public function h3((Incoming & GroupMessage & HasMedia) | (Incoming & ChannelMessage & HasMedia) $message): void + { + // Handle all incoming messages with media attached (groups+channels). + } +} +``` + +MadelineProto will send updates about new messages to all methods marked with the `Handler` attribute, appropriately filtering them first according to the typehint. + +A filter typehint is composed of: + +* A single concrete type: `A` + * Concrete types are objects with useful bound methods and properties containing the fields of the message. +* A single concrete type intersected with one or more filter interfaces: `A&B&C` (used to AND filters) + * Filter interfaces are PHP interfaces that are automatically parsed using reflection. + Unlike concrete types, they cannot be used for type assertions outside of a method marked by `#[Handler]` or `#[Filter...]` attributes. +* A union of concrete types: `A|B|C` (used to OR filters) +* A union of concrete types or intersections: `(A&B)|C|(D&F)` (used to OR filters in DNF form) + +Single concrete type examples: + +* `Message` - Handle all incoming and outgoing messages (private or groups or channels). +* `ChannelMessage` - Handle all incoming and outgoing messages (channels). +* `GroupMessage` - Handle all incoming and outgoing messages (groups). +* `PrivateMessage` - Handle all incoming and outgoing messages (private). +* `ServiceMessage` - Handle all incoming and outgoing service messages (private or groups or channels). +* `AbstractMessage` - Handle all incoming and outgoing service+normal messages (private or groups or channels). + +Intersection examples: + +* `Incoming & Message` - Handle all incoming messages (private or groups or channels). +* `Incoming & GroupMessage & HasMedia` - Handle all incoming media messages (groups). + +Union/DNF examples: + +* `GroupMessage|ChannelMessage` - Handle all incoming and outgoing messages (groups or channels). +* `(Incoming&GroupMessage)|(Incoming&ChannelMessage)` - Handle all incoming messages (groups or channels). +* `ServiceMessage|(ChannelMessage&HasMedia)` - Handle all service messages or incoming and outgoing media channel messages. + +Simple filters can optionally be combined with [attribute filters](#attribute-filters), in which case they will be AND-ed together. + +Here's the full list of all concrete types: + + + +* [danog\MadelineProto\Broadcast\Progress »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html) - Broadcast progress. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html#method-list) +* [danog\MadelineProto\EventHandler\AbstractMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html) - Represents an incoming or outgoing message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html#method-list) +* [danog\MadelineProto\EventHandler\AbstractPrivateMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html) - Represents a private or secret chat message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html#method-list) +* [danog\MadelineProto\EventHandler\AbstractStory »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractStory.html) - Represents a Telegram Story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractStory.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractStory.html#method-list) +* [danog\MadelineProto\EventHandler\BotCommands »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html) - The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html#method-list) +* [danog\MadelineProto\EventHandler\CallbackQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html) - Represents a query sent by the user by clicking on a button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\ChannelParticipant »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html) - A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\MessageForwards »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html) - Indicates that the forward counter of a message in a channel has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\MessageViewsChanged »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html) - Indicates that the view counter of a message in a channel has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\UpdateChannel »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html) - A new channel is available, or info about an existing channel was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html#method-list) +* [danog\MadelineProto\EventHandler\ChatInviteRequester »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html) - Indicates someone has requested to join a chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html#method-list) +* [danog\MadelineProto\EventHandler\ChatInviteRequester\BotChatInviteRequest »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html) - Indicates someone has requested to join a chat or channel (bots only). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html#method-list) +* [danog\MadelineProto\EventHandler\ChatInviteRequester\PendingJoinRequests »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html) - Someone has requested to join a chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html#method-list) +* [danog\MadelineProto\EventHandler\Delete »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete.html) - Indicates that some messages were deleted. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete.html#method-list) +* [danog\MadelineProto\EventHandler\Delete\DeleteChannelMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html) - Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Delete\DeleteMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html) - Some messages were deleted in a private chat or simple group. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Delete\DeleteScheduledMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html) - Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html#method-list) +* [danog\MadelineProto\EventHandler\InlineQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/InlineQuery.html) - An incoming inline query. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/InlineQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/InlineQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Message »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message.html) - Represents an incoming or outgoing message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message.html#method-list) +* [danog\MadelineProto\EventHandler\Message\ChannelMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html) - Represents an incoming or outgoing channel message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\GroupMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html) - Represents an incoming or outgoing group message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\PrivateMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html) - Represents an incoming or outgoing private message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\SecretMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html) - Represents New encrypted message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\ServiceMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html) - Represents info about a service message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\ServiceMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html) - Represents info about a service message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogBotAllowed »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html) - We have given the bot permission to send us direct messages. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChannelCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html) - The channel was created. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChannelMigrateFrom »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html) - Indicates the channel was [migrated](https://core.telegram.org/api/channel) from the specified chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChatJoinedByLink »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html) - A user joined the chat via an invite link. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChatMigrateTo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html) - Indicates the chat was [migrated](https://core.telegram.org/api/channel) to the specified supergroup. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogContactSignUp »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html) - A contact just signed up to telegram. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html) - A chat or channel was created. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogDeleteMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html) - Deleted messages. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGameScore »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html) - Someone scored in a game. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGeoProximityReached »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html) - A user of the chat is now in proximity of another user. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGiftPremium »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html) - Info about a gifted Telegram Premium subscription. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html) - Represents a service message about a group call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCall »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html) - The group call has started or ended. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallInvited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html) - A set of users was invited to the group call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallScheduled »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html) - A group call was scheduled. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogHistoryCleared »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html) - Chat history was cleared. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMemberJoinedByRequest »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html) - A user was accepted into the group by an admin. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMemberLeft »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html) - A member left the chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMembersJoined »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html) - Some members joined the chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMessagePinned »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html) - A message was pinned in a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogPeerRequested »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html) - Contains info about a peer that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogPhoneCall »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html) - A phone call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogPhotoChanged »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html) - The photo of the dialog was changed or deleted. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogReadMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html) - Messages marked as read. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html) - A screenshot of the chat was taken. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSetChatTheme »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html) - The chat theme was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSetChatWallPaper »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html) - The [wallpaper](https://core.telegram.org/api/wallpapers) of the current chat was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) - The Time-To-Live of messages in this chat was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSuggestProfilePhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html) - A new profile picture was suggested using [photos.uploadContactProfilePhoto](https://docs.madelineproto.xyz/API_docs/methods/photos.uploadContactProfilePhoto.html). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogTitleChanged »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html) - The title of a channel or group has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html) - A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) - [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogWebView »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html) - Data from an opened [reply keyboard bot web app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user & bot side service message). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned.html) - Indicates that some messages were pinned/unpinned. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned\PinnedChannelMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html) - Represents messages that were pinned/unpinned in a [channel](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned\PinnedGroupMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html) - Represents messages that were pinned/unpinned in a [chat/supergroup](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned\PinnedPrivateMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html) - Some messages were pinned in a private chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Privacy »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Privacy.html) - Indicates some privacy rules for a user or set of users. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Privacy.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Privacy.html#method-list) +* [danog\MadelineProto\EventHandler\Query\ButtonQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html) - Represents a query sent by the user by clicking on a button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\ChatButtonQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html) - Represents a query sent by the user by clicking on a button in a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\ChatGameQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html) - Represents a query sent by the user by clicking on a "Play game" button in a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\GameQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html) - Represents a query sent by the user by clicking on a "Play game" button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\InlineButtonQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html) - Represents a query sent by the user by clicking on a button in an inline message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\InlineGameQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html) - Represents a query sent by the user by clicking on a "Play game" button in an inline message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Story\Story »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/Story.html) - Represents a Telegram story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/Story.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/Story.html#method-list) +* [danog\MadelineProto\EventHandler\Story\StoryDeleted »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html) - Represents a deleted story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html#method-list) +* [danog\MadelineProto\EventHandler\Story\StoryReaction »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html) - Represents a reaction to a story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html#method-list) +* [danog\MadelineProto\EventHandler\Typing »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing.html) - A user is typing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\ChatUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html) - The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\SecretUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html) - The user is preparing a message in a secret chat; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\SupergroupUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html) - A user is typing in a [supergroup](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\UserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html) - The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\User\Blocked »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Blocked.html) - A peer was blocked. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Blocked.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Blocked.html#method-list) +* [danog\MadelineProto\EventHandler\User\BotStopped »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html) - A bot was stopped or re-started. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html#method-list) +* [danog\MadelineProto\EventHandler\User\Phone »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Phone.html) - A user’s phone number was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Phone.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Phone.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status.html) - Contains a status update. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Emoji »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html) - The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed or was removed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\EmptyStatus »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html) - User status has not been set yet. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\LastMonth »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html) - Online status: last seen last month. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\LastWeek »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html) - Online status: last seen last week. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Offline »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html) - The user’s offline status. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Online »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html) - Online status of the user. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Recently »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html) - Online status: last seen recently. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html#method-list) +* [danog\MadelineProto\EventHandler\User\Username »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Username.html) - Changes were made to the user’s first name, last name or username. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Username.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Username.html#method-list) +* [danog\MadelineProto\VoIP »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) - This update represents a VoIP Telegram call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html#method-list) + + + + +Here's the full list of simple filter interfaces (see [attribute filters](#attribute-filters) for more advanced filters like commands, regexes, and much more!): + + + +* [danog\MadelineProto\EventHandler\SimpleFilter\Ended »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Ended.html) - Represents an ended call +* [danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdmin.html) - Allows messages from the bot admin +* [danog\MadelineProto\EventHandler\SimpleFilter\FromAdminOrOutgoing »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/FromAdminOrOutgoing.html) - Allows messages from the bot admin or outgoing messages +* [danog\MadelineProto\EventHandler\SimpleFilter\HasAudio »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasAudio.html) - Allows only audio messages +* [danog\MadelineProto\EventHandler\SimpleFilter\HasDocument »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocument.html) - Allows only documents +* [danog\MadelineProto\EventHandler\SimpleFilter\HasDocumentPhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasDocumentPhoto.html) - Allows only document photos +* [danog\MadelineProto\EventHandler\SimpleFilter\HasGif »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasGif.html) - Allows only GIFs +* [danog\MadelineProto\EventHandler\SimpleFilter\HasMedia »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMedia.html) - Allows only media messages +* [danog\MadelineProto\EventHandler\SimpleFilter\HasMultiplePoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasMultiplePoll.html) - Allows only messages that contain a multiple poll +* [danog\MadelineProto\EventHandler\SimpleFilter\HasNoMedia »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasNoMedia.html) - Allows only messages with no media +* [danog\MadelineProto\EventHandler\SimpleFilter\HasPhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPhoto.html) - Allows only photos +* [danog\MadelineProto\EventHandler\SimpleFilter\HasPoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasPoll.html) - Allows only messages that contain a poll +* [danog\MadelineProto\EventHandler\SimpleFilter\HasQuizPoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasQuizPoll.html) - Allows only messages that contain a quiz poll +* [danog\MadelineProto\EventHandler\SimpleFilter\HasRoundVideo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasRoundVideo.html) - Allows only round videos +* [danog\MadelineProto\EventHandler\SimpleFilter\HasSinglePoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSinglePoll.html) - Allows only messages that contain a single poll +* [danog\MadelineProto\EventHandler\SimpleFilter\HasSticker »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasSticker.html) - Allows only stickers +* [danog\MadelineProto\EventHandler\SimpleFilter\HasTopic »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasTopic.html) - Allow only messages coming from groups that has topics (Supergroups only). +* [danog\MadelineProto\EventHandler\SimpleFilter\HasVideo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVideo.html) - Allows only videos +* [danog\MadelineProto\EventHandler\SimpleFilter\HasVoice »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/HasVoice.html) - Allows only voice messages +* [danog\MadelineProto\EventHandler\SimpleFilter\Incoming »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Incoming.html) - Represents an incoming message +* [danog\MadelineProto\EventHandler\SimpleFilter\IsEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsEdited.html) - Allows messages that were edited. +* [danog\MadelineProto\EventHandler\SimpleFilter\IsForwarded »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsForwarded.html) - Allows only forwarded messages +* [danog\MadelineProto\EventHandler\SimpleFilter\IsNotEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsNotEdited.html) - Allows messages that weren't edited. +* [danog\MadelineProto\EventHandler\SimpleFilter\IsReply »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReply.html) - Allows only messages that reply to other messages +* [danog\MadelineProto\EventHandler\SimpleFilter\IsReplyToSelf »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/IsReplyToSelf.html) - Allows only messages that reply to one of our messages +* [danog\MadelineProto\EventHandler\SimpleFilter\Outgoing »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Outgoing.html) - Represents an outgoing message +* [danog\MadelineProto\EventHandler\SimpleFilter\Running »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/SimpleFilter/Running.html) - Allow only currently running calls + + + + +## Attribute filters + +Attribute filters are implemented using PHP attributes, for example: + +```php +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\EventHandler\Attributes\Handler; +use danog\MadelineProto\EventHandler\Message; +use danog\MadelineProto\EventHandler\Message\PrivateMessage; +use danog\MadelineProto\EventHandler\Message\GroupMessage; +use danog\MadelineProto\EventHandler\Message\ChannelMessage; +use danog\MadelineProto\EventHandler\Filter\FilterIncoming; + +class MyEventHandler extends SimpleEventHandler +{ + #[FilterIncoming] + public function h1(Message $message): void + { + // Handle all incoming messages (private+groups+channels). + } + + #[FilterAnd(new FilterOutgoing, new FilterPrivate)] + public function h2(Message $message): void + { + // Handle all outgoing messages (private). + } + + #[FilterAnd(new FilterIncoming, new FilterOr(new FilterGroup, new FilterChannel), new FilterMedia)] + public function h3(Message $message): void + { + // Handle all incoming messages with media attached (groups+channels). + } + + #[FilterOr(new FilterGroup, new FilterChannel)] + public function h4(Incoming&Message&HasMedia $message): void + { + // Same as h3, but combining simple filters with attribute filters. + } +} +``` + +Attribute filters are usual combined with [simple filters](#simple-filters). +Attribute filters are ANDed with simple filters defined on the same method, for example this: + +```php +#[FilterOr(new FilterGroup, new FilterChannel)] +public function h4(Incoming&Message&HasMedia $message) +``` + +Is exactly the same as this: + +```php +#[FilterAnd(new FilterIncoming, new FilterMessage, new FilterMedia, new FilterOr(new FilterGroup, new FilterChannel))] +public function h3($message): void +``` + +Which can also be written using only [simple filters](#simple-filters): + +```php +#[Handler] +public function h3((Incoming & GroupMessage & HasMedia) | (Incoming & ChannelMessage & HasMedia) $message): void +``` + + +Here's the full list of filter attributes (see the [MTProto filters »](#mtproto-filters) for even more low-level filters): + + + +* [danog\MadelineProto\EventHandler\Filter\FilterAllowAll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterAllowAll.html) - Allow all updates. +* [danog\MadelineProto\EventHandler\Filter\FilterButtonQueryData(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterButtonQueryData.html) - Filters based on the content of a button query. +* [danog\MadelineProto\EventHandler\Filter\FilterChannel »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterChannel.html) - Allow only updates coming from channels. +* [danog\MadelineProto\EventHandler\Filter\FilterCommand(string $command, list $types = [ 0 => \danog\MadelineProto\EventHandler\CommandType::BANG, 1 => \danog\MadelineProto\EventHandler\CommandType::DOT, 2 => \danog\MadelineProto\EventHandler\CommandType::SLASH,]) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommand.html) - Allow only messages containing the specified command. +* [danog\MadelineProto\EventHandler\Filter\FilterCommandCaseInsensitive(string $command, list $types = [ 0 => \danog\MadelineProto\EventHandler\CommandType::BANG, 1 => \danog\MadelineProto\EventHandler\CommandType::DOT, 2 => \danog\MadelineProto\EventHandler\CommandType::SLASH,]) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterCommandCaseInsensitive.html) - Allow only messages containing the specified case-insensitive command. +* [danog\MadelineProto\EventHandler\Filter\FilterEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterEdited.html) - Allows messages that were edited. +* [danog\MadelineProto\EventHandler\Filter\FilterEnded »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterEnded.html) - Allow only ended calls. +* [danog\MadelineProto\EventHandler\Filter\FilterForwarded »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwarded.html) - Allow only forwarded messages. +* [danog\MadelineProto\EventHandler\Filter\FilterForwardedFrom(string|int $peer) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterForwardedFrom.html) - Allow only forwarded messages from a certain sender. +* [danog\MadelineProto\EventHandler\Filter\FilterFromAdmin »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromAdmin.html) - Allow only messages coming from the admin (defined as the peers returned by getReportPeers). +* [danog\MadelineProto\EventHandler\Filter\FilterFromBot »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromBot.html) - Allow only messages coming from bots. +* [danog\MadelineProto\EventHandler\Filter\FilterFromSender(string|int $peer) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSender.html) - Allow incoming or outgoing group messages made by a certain sender. +* [danog\MadelineProto\EventHandler\Filter\FilterFromSenders(string|int ...$idOrUsername) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterFromSenders.html) - Allow incoming or outgoing group messages made by a certain list of senders. +* [danog\MadelineProto\EventHandler\Filter\FilterGroup »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterGroup.html) - Allow only updates coming from groups. +* [danog\MadelineProto\EventHandler\Filter\FilterIncoming »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterIncoming.html) - Allow only incoming messages. +* [danog\MadelineProto\EventHandler\Filter\FilterMedia »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterMedia.html) - Allow any media messages. +* [danog\MadelineProto\EventHandler\Filter\FilterMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterMessage.html) - Allow any non-service message. +* [danog\MadelineProto\EventHandler\Filter\FilterNoMedia »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterNoMedia.html) - Allow any messages except media messages. +* [danog\MadelineProto\EventHandler\Filter\FilterNotEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterNotEdited.html) - Allows messages that weren't edited. +* [danog\MadelineProto\EventHandler\Filter\FilterOutgoing »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterOutgoing.html) - Allow only outgoing messages. +* [danog\MadelineProto\EventHandler\Filter\FilterPeer(string|int $peer) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterPeer.html) - Allow messages coming from or sent to a certain peer. +* [danog\MadelineProto\EventHandler\Filter\FilterPoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterPoll.html) - Allow only messages that contain a poll. +* [danog\MadelineProto\EventHandler\Filter\FilterPrivate »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterPrivate.html) - Allow only updates coming from private chats. +* [danog\MadelineProto\EventHandler\Filter\FilterRegex(non-empty-string $regex, int-mask<0, 256, 512> $flags = 0, int $offset = 0) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegex.html) - Allow only messages or button queries matching the specified regex. +* [danog\MadelineProto\EventHandler\Filter\FilterRegexMatchAll(non-empty-string $regex, int $flags = 0, int $offset = 0) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterRegexMatchAll.html) - Allow only messages or button queries matching the specified regex. +* [danog\MadelineProto\EventHandler\Filter\FilterReply »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterReply.html) - Allow messages that reply to other messages. +* [danog\MadelineProto\EventHandler\Filter\FilterReplyToSelf »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterReplyToSelf.html) - Allow messages that reply to one of our messages. +* [danog\MadelineProto\EventHandler\Filter\FilterRunning »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterRunning.html) - Allow only running calls. +* [danog\MadelineProto\EventHandler\Filter\FilterSecret »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterSecret.html) - Allow only updates coming from secret chats. +* [danog\MadelineProto\EventHandler\Filter\FilterSender(string|int $peer) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterSender.html) - Allow incoming or outgoing group messages made by a certain sender. +* [danog\MadelineProto\EventHandler\Filter\FilterSenders(string|int ...$idOrUsername) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterSenders.html) - Allow incoming or outgoing group messages made by a certain list of senders. +* [danog\MadelineProto\EventHandler\Filter\FilterService »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterService.html) - Allow only service messages of any type. +* [danog\MadelineProto\EventHandler\Filter\FilterText(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterText.html) - Allow only messages with a specific content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextCaseInsensitive(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextCaseInsensitive.html) - Allow only messages with a specific case-insensitive content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextContains(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContains.html) - Allow only messages that contain a specific content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextContainsCaseInsensitive(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextContainsCaseInsensitive.html) - Allow only messages that contain a specific case-insensitive content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextEnds(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEnds.html) - Allow only messages that ends with a specific content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextEndsCaseInsensitive(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextEndsCaseInsensitive.html) - Allow only messages that ends with a specific case-insensitive content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextStarts(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStarts.html) - Allow only messages that start with a specific content. +* [danog\MadelineProto\EventHandler\Filter\FilterTextStartsCaseInsensitive(string $content) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTextStartsCaseInsensitive.html) - Allow only messages that start with a specific case-insensitive content. +* [danog\MadelineProto\EventHandler\Filter\FilterTopic »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopic.html) - Allow only messages coming from groups that has topics (Supergroups only). +* [danog\MadelineProto\EventHandler\Filter\FilterTopicId(int $topicId) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/FilterTopicId.html) - Allow only messages with a specific topic id (Supergroups only). +* [danog\MadelineProto\EventHandler\Filter\Combinator\FilterNot(Filter $filter) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FilterNot.html) - NOTs a filter. +* [danog\MadelineProto\EventHandler\Filter\Combinator\FiltersAnd(Filter ...$filters) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersAnd.html) - ANDs multiple filters. +* [danog\MadelineProto\EventHandler\Filter\Combinator\FiltersOr(Filter ...$filters) »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Combinator/FiltersOr.html) - ORs multiple filters. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterAudio »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterAudio.html) - Allow only audio files. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterDocument »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocument.html) - Allow only documents. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterDocumentPhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterDocumentPhoto.html) - Allow only documents containing an image. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterGif »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterGif.html) - Allow only GIFs. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterPhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterPhoto.html) - Allow only photos. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterRoundVideo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterRoundVideo.html) - Allow only round videos. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterSticker »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterSticker.html) - Allow only stickers. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterVideo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVideo.html) - Allow only videos. +* [danog\MadelineProto\EventHandler\Filter\Media\FilterVoice »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Media/FilterVoice.html) - Allow only voice messages. +* [danog\MadelineProto\EventHandler\Filter\Poll\FilterMultiplePoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterMultiplePoll.html) - Allow only messages that contain a multiple poll. +* [danog\MadelineProto\EventHandler\Filter\Poll\FilterQuizPoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterQuizPoll.html) - Allow only messages that contain a quiz poll. +* [danog\MadelineProto\EventHandler\Filter\Poll\FilterSinglePoll »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Filter/Poll/FilterSinglePoll.html) - Allow only messages that contain a single poll. + + + + +### Creating custom attribute filters + +To create a custom attribute filter, simply create a method attribute that extends the Filter class. + +You must implement an `apply(Update $update): bool` method, that returns true or false according to the filter's logic. + +```php +applyIf; + } +} +``` + +You can also optionally implement the `public function initialize(EventHandler $API): Filter` function. + +This function is useful to perform expensive one-time initialization tasks, to avoid performing them during filtering, for example: + + + +```php +. + * + * @author Daniil Gentili + * @copyright 2016-2023 Daniil Gentili + * @license https://opensource.org/licenses/AGPL-3.0 AGPLv3 + * @link https://docs.madelineproto.xyz MadelineProto documentation + */ + +namespace danog\MadelineProto\EventHandler\Filter; + +use danog\MadelineProto\EventHandler; +use danog\MadelineProto\EventHandler\AbstractMessage; +use danog\MadelineProto\EventHandler\AbstractStory; +use danog\MadelineProto\EventHandler\BotCommands; +use danog\MadelineProto\EventHandler\ChatInviteRequester\BotChatInviteRequest; +use danog\MadelineProto\EventHandler\InlineQuery; +use danog\MadelineProto\EventHandler\Query\ButtonQuery; +use danog\MadelineProto\EventHandler\Story\StoryReaction; +use danog\MadelineProto\EventHandler\Typing; +use danog\MadelineProto\EventHandler\Update; +use danog\MadelineProto\EventHandler\User\Blocked; +use danog\MadelineProto\EventHandler\User\BotStopped; +use danog\MadelineProto\EventHandler\User\Phone; +use danog\MadelineProto\EventHandler\User\Status; +use danog\MadelineProto\EventHandler\User\Username; + +/** + * Allow incoming or outgoing group messages made by a certain list of senders. + * + * @internal + */ +abstract class AbstractFilterFromSenders extends Filter +{ + /** @var array */ + private readonly array $peers; + /** @var list */ + private readonly array $peersResolved; + public function __construct(string|int ...$idOrUsername) + { + $this->peers = array_unique($idOrUsername); + } + public function initialize(EventHandler $API): Filter + { + if (\count($this->peers) === 1) { + return (new FilterFromSender(array_values($this->peers)[0]))->initialize($API); + } + $res = []; + foreach ($this->peers as $peer) { + $res []= $API->getId($peer); + } + /** @psalm-suppress InaccessibleProperty */ + $this->peersResolved = $res; + return $this; + } + public function apply(Update $update): bool + { + return $update instanceof AbstractMessage && \in_array($update->senderId, $this->peersResolved, true) || + ($update instanceof AbstractStory && \in_array($update->senderId, $this->peersResolved, true)) || + ($update instanceof StoryReaction && \in_array($update->senderId, $this->peersResolved, true)) || + ($update instanceof ButtonQuery && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof InlineQuery && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof Typing && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof Blocked && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof BotStopped && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof Phone && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof Status && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof Username && \in_array($update->userId, $this->peersResolved, true)) || + ($update instanceof BotCommands && \in_array($update->botId, $this->peersResolved, true)) || + ($update instanceof BotChatInviteRequest && \in_array($update->userId, $this->peersResolved, true)); + } +} + +``` + + + +Usually you should return `$this` from `initialize()`, but if you want to replace the current filter with another filter, you can return the new filter, instead: + +```php +initialize($API); + } + + public function apply(Update $update): bool + { + throw new AssertionError("Unreachable!"); + } +} +``` + +Another example: + + + +```php +. + * + * @author Daniil Gentili + * @copyright 2016-2023 Daniil Gentili + * @license https://opensource.org/licenses/AGPL-3.0 AGPLv3 + * @link https://docs.madelineproto.xyz MadelineProto documentation + */ + +namespace danog\MadelineProto\EventHandler\Filter\Combinator; + +use Attribute; +use danog\MadelineProto\EventHandler; +use danog\MadelineProto\EventHandler\Filter\Filter; +use danog\MadelineProto\EventHandler\Update; + +/** + * NOTs a filter. + */ +#[Attribute(Attribute::TARGET_METHOD)] +final class FilterNot extends Filter +{ + public function __construct(private readonly Filter $filter) + { + } + public function initialize(EventHandler $API): Filter + { + $filter = $this->filter->initialize($API); + if ($filter instanceof self) { + // The nested filter is a FilterNot, optimize !!A => A + return $filter->filter; + } + if ($filter === $this->filter) { + // The nested filter didn't replace itself + return $this; + } + // The nested filter replaced itself, re-wrap it + return new self($filter); + } + + public function apply(Update $update): bool + { + return !$this->filter->apply($update); + } +} + +``` + + + +## MTProto filters + +MTProto filters are used to obtain raw MTProto updates in the form of arrays. +Unlike [simple updates](#simple-filters), raw MTProto updates do not have bound methods, but MadelineProto offers a bunch of [helper methods](https://docs.madelineproto.xyz/API_docs/methods/) that can be used, instead. + +**Please note that MTProto filters are not covered by any backwards compatibility promise**: they may change at any time, including in minor versions, because they're related directly to the Telegram API schema. +Use [simple filters](#simple-filters) for a stable object-oriented update API. + +MTProto filters are defined by creating a function with the appropriate name, for example to handle [updateNewMessage](https://docs.madelineproto.xyz/API_docs/constructors/updateNewMessage.html) updates: + +```php +use danog\MadelineProto\SimpleEventHandler; + +class MyEventHandler extends SimpleEventHandler +{ + /** + * Handle updates from users. + * + * 100+ other types of onUpdate... method types are available, see https://docs.madelineproto.xyz/API_docs/types/Update.html for the full list. + * You can also use onAny to catch all update types (only for debugging) + * A special onUpdateCustomEvent method can also be defined, to send messages to the event handler from an API instance, using the sendCustomEvent method. + * + * @param array $update Update + */ + public function onUpdateNewMessage(array $update): void + { + if ($update['message']['_'] === 'messageEmpty') { + return; + } + + $this->logger($update); + + // Chat ID + $id = $this->getId($update); + + // Sender ID, not always present + $from_id = isset($update['message']['from_id']) + ? $this->getId($update['message']['from_id']) + : null; + + + // In this example code, send the "This userbot is powered by MadelineProto!" message only once per chat. + // Ignore all further messages coming from this chat. + if (!isset($this->notifiedChats[$id])) { + $this->notifiedChats[$id] = true; + + $this->messages->sendMessage( + peer: $update, + message: "This userbot is powered by [MadelineProto](https://t.me/MadelineProto)!", + reply_to_msg_id: $update['message']['id'] ?? null, + parse_mode: 'Markdown' + ); + } + } +} +``` + +Here's a full list of all MTProto filters (click on each filter name to view the structure of the array that will be passed to it): + + + + * onUpdateCustomEvent: Receives messages sent to the event handler from an API instance using the [`sendCustomEvent` »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/API.html#sendcustomevent-mixed-payload-void) method. + * onAny: Catch-all filter, if defined catches all updates that aren't catched by any other filter. + * [onUpdateBroadcastProgress »](https://docs.madelineproto.xyz/docs/BROADCAST.html#get-progress): Used to receive updates to an in-progress [message broadcast »](https://docs.madelineproto.xyz/docs/BROADCAST.html)* [onUpdateNewMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewMessage.html) - New message in a private chat or in a [basic group](https://core.telegram.org/api/channel#basic-groups). +* [onUpdateMessageID »](https://docs.madelineproto.xyz/API_docs/constructors/updateMessageID.html) - Sent message with **random\_id** client identifier was assigned an identifier. +* [onUpdateDeleteMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updateDeleteMessages.html) - Messages were deleted. +* [onUpdateUserTyping »](https://docs.madelineproto.xyz/API_docs/constructors/updateUserTyping.html) - The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing +* [onUpdateChatUserTyping »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatUserTyping.html) - The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing +* [onUpdateChatParticipants »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatParticipants.html) - Composition of chat participants changed. +* [onUpdateUserStatus »](https://docs.madelineproto.xyz/API_docs/constructors/updateUserStatus.html) - Contact status update. +* [onUpdateUserName »](https://docs.madelineproto.xyz/API_docs/constructors/updateUserName.html) - Changes the user's first name, last name and username. +* [onUpdateNewAuthorization »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewAuthorization.html) - A new session logged into the current user's account through an unknown device. +* [onUpdateNewEncryptedMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewEncryptedMessage.html) - New encrypted message. +* [onUpdateEncryptedChatTyping »](https://docs.madelineproto.xyz/API_docs/constructors/updateEncryptedChatTyping.html) - Interlocutor is typing a message in an encrypted chat. Update period is 6 second. If upon this time there is no repeated update, it shall be considered that the interlocutor stopped typing. +* [onUpdateEncryption »](https://docs.madelineproto.xyz/API_docs/constructors/updateEncryption.html) - Change of state in an encrypted chat. +* [onUpdateEncryptedMessagesRead »](https://docs.madelineproto.xyz/API_docs/constructors/updateEncryptedMessagesRead.html) - Communication history in an encrypted chat was marked as read. +* [onUpdateChatParticipantAdd »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatParticipantAdd.html) - New group member. +* [onUpdateChatParticipantDelete »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatParticipantDelete.html) - A member has left the group. +* [onUpdateDcOptions »](https://docs.madelineproto.xyz/API_docs/constructors/updateDcOptions.html) - Changes in the data center configuration options. +* [onUpdateNotifySettings »](https://docs.madelineproto.xyz/API_docs/constructors/updateNotifySettings.html) - Changes in notification settings. +* [onUpdateServiceNotification »](https://docs.madelineproto.xyz/API_docs/constructors/updateServiceNotification.html) - A service message for the user. +* [onUpdatePrivacy »](https://docs.madelineproto.xyz/API_docs/constructors/updatePrivacy.html) - Privacy rules were changed +* [onUpdateUserPhone »](https://docs.madelineproto.xyz/API_docs/constructors/updateUserPhone.html) - A user's phone number was changed +* [onUpdateReadHistoryInbox »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadHistoryInbox.html) - Incoming messages were read +* [onUpdateReadHistoryOutbox »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadHistoryOutbox.html) - Outgoing messages were read +* [onUpdateWebPage »](https://docs.madelineproto.xyz/API_docs/constructors/updateWebPage.html) - An [instant view](https://instantview.telegram.org) webpage preview was generated +* [onUpdateReadMessagesContents »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadMessagesContents.html) - Contents of messages in the common [message box](https://core.telegram.org/api/updates) were read +* [onUpdateChannelTooLong »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelTooLong.html) - There are new updates in the specified channel, the client must fetch them. +* [onUpdateChannel »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannel.html) - A new channel or supergroup is available, or info about an existing channel has changed and must be refeteched. +* [onUpdateNewChannelMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewChannelMessage.html) - A new message was sent in a [channel/supergroup](https://core.telegram.org/api/channel) +* [onUpdateReadChannelInbox »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadChannelInbox.html) - Incoming messages in a [channel/supergroup](https://core.telegram.org/api/channel) were read +* [onUpdateDeleteChannelMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updateDeleteChannelMessages.html) - Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted +* [onUpdateChannelMessageViews »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelMessageViews.html) - The view counter of a message in a channel has changed +* [onUpdateChatParticipantAdmin »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatParticipantAdmin.html) - Admin permissions of a user in a [basic group](https://core.telegram.org/api/channel#basic-groups) were changed +* [onUpdateNewStickerSet »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewStickerSet.html) - A new stickerset was installed +* [onUpdateStickerSetsOrder »](https://docs.madelineproto.xyz/API_docs/constructors/updateStickerSetsOrder.html) - The order of stickersets was changed +* [onUpdateStickerSets »](https://docs.madelineproto.xyz/API_docs/constructors/updateStickerSets.html) - Installed stickersets have changed, the client should refetch them as [described in the docs](https://core.telegram.org/api/stickers#installing-stickersets). +* [onUpdateSavedGifs »](https://docs.madelineproto.xyz/API_docs/constructors/updateSavedGifs.html) - The saved gif list has changed, the client should refetch it using [messages.getSavedGifs](https://core.telegram.org/method/messages.getSavedGifs) +* [onUpdateBotInlineQuery »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotInlineQuery.html) - An incoming inline query +* [onUpdateBotInlineSend »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotInlineSend.html) - The result of an inline query that was chosen by a user and sent to their chat partner. Please see our documentation on the [feedback collecting](https://core.telegram.org/bots/inline#collecting-feedback) for details on how to enable these updates for your bot. +* [onUpdateEditChannelMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateEditChannelMessage.html) - A message was edited in a [channel/supergroup](https://core.telegram.org/api/channel) +* [onUpdateBotCallbackQuery »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotCallbackQuery.html) - A callback button was pressed, and the button data was sent to the bot that created the button +* [onUpdateEditMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateEditMessage.html) - A message was edited +* [onUpdateInlineBotCallbackQuery »](https://docs.madelineproto.xyz/API_docs/constructors/updateInlineBotCallbackQuery.html) - This notification is received by bots when a button is pressed +* [onUpdateReadChannelOutbox »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadChannelOutbox.html) - Outgoing messages in a [channel/supergroup](https://core.telegram.org/api/channel) were read +* [onUpdateDraftMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateDraftMessage.html) - Notifies a change of a message [draft](https://core.telegram.org/api/drafts). +* [onUpdateReadFeaturedStickers »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadFeaturedStickers.html) - Some featured stickers were marked as read +* [onUpdateRecentStickers »](https://docs.madelineproto.xyz/API_docs/constructors/updateRecentStickers.html) - The recent sticker list was updated +* [onUpdateConfig »](https://docs.madelineproto.xyz/API_docs/constructors/updateConfig.html) - The server-side configuration has changed; the client should re-fetch the config using [help.getConfig](https://docs.madelineproto.xyz/API_docs/methods/help.getConfig.html) +* [onUpdatePtsChanged »](https://docs.madelineproto.xyz/API_docs/constructors/updatePtsChanged.html) - [Common message box sequence PTS](https://core.telegram.org/api/updates) has changed, [state has to be refetched using updates.getState](https://core.telegram.org/api/updates#fetching-state) +* [onUpdateChannelWebPage »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelWebPage.html) - A webpage preview of a link in a [channel/supergroup](https://core.telegram.org/api/channel) message was generated +* [onUpdateDialogPinned »](https://docs.madelineproto.xyz/API_docs/constructors/updateDialogPinned.html) - A dialog was pinned/unpinned +* [onUpdatePinnedDialogs »](https://docs.madelineproto.xyz/API_docs/constructors/updatePinnedDialogs.html) - Pinned dialogs were updated +* [onUpdateBotWebhookJSON »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotWebhookJSON.html) - A new incoming event; for bots only +* [onUpdateBotWebhookJSONQuery »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotWebhookJSONQuery.html) - A new incoming query; for bots only +* [onUpdateBotShippingQuery »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotShippingQuery.html) - This object contains information about an incoming shipping query. +* [onUpdateBotPrecheckoutQuery »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotPrecheckoutQuery.html) - This object contains information about an incoming pre-checkout query. +* [onUpdatePhoneCall »](https://docs.madelineproto.xyz/API_docs/constructors/updatePhoneCall.html) - An incoming phone call +* [onUpdateLangPackTooLong »](https://docs.madelineproto.xyz/API_docs/constructors/updateLangPackTooLong.html) - A language pack has changed, the client should manually fetch the changed strings using [langpack.getDifference](https://docs.madelineproto.xyz/API_docs/methods/langpack.getDifference.html) +* [onUpdateLangPack »](https://docs.madelineproto.xyz/API_docs/constructors/updateLangPack.html) - Language pack updated +* [onUpdateFavedStickers »](https://docs.madelineproto.xyz/API_docs/constructors/updateFavedStickers.html) - The list of favorited stickers was changed, the client should call [messages.getFavedStickers](https://docs.madelineproto.xyz/API_docs/methods/messages.getFavedStickers.html) to refetch the new list +* [onUpdateChannelReadMessagesContents »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelReadMessagesContents.html) - The specified [channel/supergroup](https://core.telegram.org/api/channel) messages were read +* [onUpdateContactsReset »](https://docs.madelineproto.xyz/API_docs/constructors/updateContactsReset.html) - All contacts were deleted +* [onUpdateChannelAvailableMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelAvailableMessages.html) - The history of a [channel/supergroup](https://core.telegram.org/api/channel) was hidden. +* [onUpdateDialogUnreadMark »](https://docs.madelineproto.xyz/API_docs/constructors/updateDialogUnreadMark.html) - The manual unread mark of a chat was changed +* [onUpdateMessagePoll »](https://docs.madelineproto.xyz/API_docs/constructors/updateMessagePoll.html) - The results of a poll have changed +* [onUpdateChatDefaultBannedRights »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatDefaultBannedRights.html) - Default banned rights in a [normal chat](https://core.telegram.org/api/channel) were updated +* [onUpdateFolderPeers »](https://docs.madelineproto.xyz/API_docs/constructors/updateFolderPeers.html) - The peer list of a [peer folder](https://core.telegram.org/api/folders#peer-folders) was updated +* [onUpdatePeerSettings »](https://docs.madelineproto.xyz/API_docs/constructors/updatePeerSettings.html) - Settings of a certain peer have changed +* [onUpdatePeerLocated »](https://docs.madelineproto.xyz/API_docs/constructors/updatePeerLocated.html) - List of peers near you was updated +* [onUpdateNewScheduledMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewScheduledMessage.html) - A message was added to the [schedule queue of a chat](https://core.telegram.org/api/scheduled-messages) +* [onUpdateDeleteScheduledMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updateDeleteScheduledMessages.html) - Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat +* [onUpdateTheme »](https://docs.madelineproto.xyz/API_docs/constructors/updateTheme.html) - A cloud theme was updated +* [onUpdateGeoLiveViewed »](https://docs.madelineproto.xyz/API_docs/constructors/updateGeoLiveViewed.html) - Live geoposition message was viewed +* [onUpdateLoginToken »](https://docs.madelineproto.xyz/API_docs/constructors/updateLoginToken.html) - A login token (for login via QR code) was accepted. +* [onUpdateMessagePollVote »](https://docs.madelineproto.xyz/API_docs/constructors/updateMessagePollVote.html) - A specific peer has voted in a poll +* [onUpdateDialogFilter »](https://docs.madelineproto.xyz/API_docs/constructors/updateDialogFilter.html) - A new [folder](https://core.telegram.org/api/folders) was added +* [onUpdateDialogFilterOrder »](https://docs.madelineproto.xyz/API_docs/constructors/updateDialogFilterOrder.html) - New [folder](https://core.telegram.org/api/folders) order +* [onUpdateDialogFilters »](https://docs.madelineproto.xyz/API_docs/constructors/updateDialogFilters.html) - Clients should update [folder](https://core.telegram.org/api/folders) info +* [onUpdatePhoneCallSignalingData »](https://docs.madelineproto.xyz/API_docs/constructors/updatePhoneCallSignalingData.html) - Incoming phone call signaling payload +* [onUpdateChannelMessageForwards »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelMessageForwards.html) - The forward counter of a message in a channel has changed +* [onUpdateReadChannelDiscussionInbox »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadChannelDiscussionInbox.html) - Incoming comments in a [discussion thread](https://core.telegram.org/api/threads) were marked as read +* [onUpdateReadChannelDiscussionOutbox »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadChannelDiscussionOutbox.html) - Outgoing comments in a [discussion thread](https://core.telegram.org/api/threads) were marked as read +* [onUpdatePeerBlocked »](https://docs.madelineproto.xyz/API_docs/constructors/updatePeerBlocked.html) - We blocked a peer, see [here »](https://core.telegram.org/api/block) for more info on blocklists. +* [onUpdateChannelUserTyping »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelUserTyping.html) - A user is typing in a [supergroup, channel](https://core.telegram.org/api/channel) or [message thread](https://core.telegram.org/api/threads) +* [onUpdatePinnedMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updatePinnedMessages.html) - Some messages were pinned in a chat +* [onUpdatePinnedChannelMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updatePinnedChannelMessages.html) - Messages were pinned/unpinned in a [channel/supergroup](https://core.telegram.org/api/channel) +* [onUpdateChat »](https://docs.madelineproto.xyz/API_docs/constructors/updateChat.html) - A new chat is available +* [onUpdateGroupCallParticipants »](https://docs.madelineproto.xyz/API_docs/constructors/updateGroupCallParticipants.html) - The participant list of a certain group call has changed +* [onUpdateGroupCall »](https://docs.madelineproto.xyz/API_docs/constructors/updateGroupCall.html) - A new groupcall was started +* [onUpdatePeerHistoryTTL »](https://docs.madelineproto.xyz/API_docs/constructors/updatePeerHistoryTTL.html) - The Time-To-Live for messages sent by the current user in a specific chat has changed +* [onUpdateChatParticipant »](https://docs.madelineproto.xyz/API_docs/constructors/updateChatParticipant.html) - A user has joined or left a specific chat +* [onUpdateChannelParticipant »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelParticipant.html) - A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel). +* [onUpdateBotStopped »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotStopped.html) - A bot was stopped or re-started. +* [onUpdateGroupCallConnection »](https://docs.madelineproto.xyz/API_docs/constructors/updateGroupCallConnection.html) - New WebRTC parameters +* [onUpdateBotCommands »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotCommands.html) - The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed. +* [onUpdatePendingJoinRequests »](https://docs.madelineproto.xyz/API_docs/constructors/updatePendingJoinRequests.html) - Someone has requested to join a chat or channel +* [onUpdateBotChatInviteRequester »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotChatInviteRequester.html) - Someone has requested to join a chat or channel (bots only, users will receive an [updatePendingJoinRequests](https://docs.madelineproto.xyz/API_docs/constructors/updatePendingJoinRequests.html), instead) +* [onUpdateMessageReactions »](https://docs.madelineproto.xyz/API_docs/constructors/updateMessageReactions.html) - New [message reactions »](https://core.telegram.org/api/reactions) are available +* [onUpdateAttachMenuBots »](https://docs.madelineproto.xyz/API_docs/constructors/updateAttachMenuBots.html) - The list of installed [attachment menu entries »](https://core.telegram.org/api/bots/attach) has changed, use [messages.getAttachMenuBots](https://docs.madelineproto.xyz/API_docs/methods/messages.getAttachMenuBots.html) to fetch the updated list. +* [onUpdateWebViewResultSent »](https://docs.madelineproto.xyz/API_docs/constructors/updateWebViewResultSent.html) - Indicates to a bot that a webview was closed and an inline message was sent on behalf of the user using [messages.sendWebViewResultMessage](https://docs.madelineproto.xyz/API_docs/methods/messages.sendWebViewResultMessage.html) +* [onUpdateBotMenuButton »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotMenuButton.html) - The menu button behavior for the specified bot has changed +* [onUpdateSavedRingtones »](https://docs.madelineproto.xyz/API_docs/constructors/updateSavedRingtones.html) - The list of saved notification sounds has changed, use [account.getSavedRingtones](https://docs.madelineproto.xyz/API_docs/methods/account.getSavedRingtones.html) to fetch the new list. +* [onUpdateTranscribedAudio »](https://docs.madelineproto.xyz/API_docs/constructors/updateTranscribedAudio.html) - A pending [voice message transcription »](https://core.telegram.org/api/transcribe) initiated with [messages.transcribeAudio](https://docs.madelineproto.xyz/API_docs/methods/messages.transcribeAudio.html) was updated. +* [onUpdateReadFeaturedEmojiStickers »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadFeaturedEmojiStickers.html) - Some featured [custom emoji stickers](https://core.telegram.org/api/custom-emoji) were marked as read +* [onUpdateUserEmojiStatus »](https://docs.madelineproto.xyz/API_docs/constructors/updateUserEmojiStatus.html) - The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed +* [onUpdateRecentEmojiStatuses »](https://docs.madelineproto.xyz/API_docs/constructors/updateRecentEmojiStatuses.html) - The list of recent [emoji statuses](https://core.telegram.org/api/emoji-status) has changed +* [onUpdateRecentReactions »](https://docs.madelineproto.xyz/API_docs/constructors/updateRecentReactions.html) - The list of recent [message reactions](https://core.telegram.org/api/reactions) has changed +* [onUpdateMoveStickerSetToTop »](https://docs.madelineproto.xyz/API_docs/constructors/updateMoveStickerSetToTop.html) - A stickerset was just moved to top, [see here for more info »](https://core.telegram.org/api/stickers#recent-stickersets) +* [onUpdateMessageExtendedMedia »](https://docs.madelineproto.xyz/API_docs/constructors/updateMessageExtendedMedia.html) - Extended media update +* [onUpdateChannelPinnedTopic »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelPinnedTopic.html) - A [forum topic »](https://core.telegram.org/api/forum#forum-topics) was pinned or unpinned. +* [onUpdateChannelPinnedTopics »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelPinnedTopics.html) - The [pinned topics](https://core.telegram.org/api/forum#forum-topics) of a forum have changed. +* [onUpdateUser »](https://docs.madelineproto.xyz/API_docs/constructors/updateUser.html) - User information was updated, it must be refetched using [users.getFullUser](https://docs.madelineproto.xyz/API_docs/methods/users.getFullUser.html). +* [onUpdateAutoSaveSettings »](https://docs.madelineproto.xyz/API_docs/constructors/updateAutoSaveSettings.html) - Media autosave settings have changed and must be refetched using [account.getAutoSaveSettings](https://docs.madelineproto.xyz/API_docs/methods/account.getAutoSaveSettings.html). +* [onUpdateStory »](https://docs.madelineproto.xyz/API_docs/constructors/updateStory.html) - A new story was posted. +* [onUpdateReadStories »](https://docs.madelineproto.xyz/API_docs/constructors/updateReadStories.html) - Stories of a specific peer were marked as read. +* [onUpdateStoryID »](https://docs.madelineproto.xyz/API_docs/constructors/updateStoryID.html) - A story was successfully uploaded. +* [onUpdateStoriesStealthMode »](https://docs.madelineproto.xyz/API_docs/constructors/updateStoriesStealthMode.html) - Indicates that [stories stealth mode](https://core.telegram.org/api/stories#stealth-mode) was activated. +* [onUpdateSentStoryReaction »](https://docs.madelineproto.xyz/API_docs/constructors/updateSentStoryReaction.html) - Indicates we [reacted to a story »](https://core.telegram.org/api/stories#reactions). +* [onUpdateBotChatBoost »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotChatBoost.html) - A [channel boost](https://core.telegram.org/api/boost) has changed (bots only) +* [onUpdateChannelViewForumAsMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updateChannelViewForumAsMessages.html) - Users may also choose to display messages from all topics as if they were sent to a normal group, using a "View as messages" setting in the local client. +* [onUpdatePeerWallpaper »](https://docs.madelineproto.xyz/API_docs/constructors/updatePeerWallpaper.html) - The [wallpaper »](https://core.telegram.org/api/wallpapers) of a given peer has changed. +* [onUpdateBotMessageReaction »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotMessageReaction.html) - Bots only: a user has changed their reactions on a message with public reactions. +* [onUpdateBotMessageReactions »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotMessageReactions.html) - Bots only: the number of reactions on a message with anonymous reactions has changed. +* [onUpdateSavedDialogPinned »](https://docs.madelineproto.xyz/API_docs/constructors/updateSavedDialogPinned.html) - A [saved message dialog](https://core.telegram.org/api/saved-messages) was pinned/unpinned +* [onUpdatePinnedSavedDialogs »](https://docs.madelineproto.xyz/API_docs/constructors/updatePinnedSavedDialogs.html) - [Pinned saved dialogs »](https://core.telegram.org/api/saved-messages) were updated +* [onUpdateSavedReactionTags »](https://docs.madelineproto.xyz/API_docs/constructors/updateSavedReactionTags.html) - +* [onUpdateSmsJob »](https://docs.madelineproto.xyz/API_docs/constructors/updateSmsJob.html) - +* [onUpdateQuickReplies »](https://docs.madelineproto.xyz/API_docs/constructors/updateQuickReplies.html) - +* [onUpdateNewQuickReply »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewQuickReply.html) - +* [onUpdateDeleteQuickReply »](https://docs.madelineproto.xyz/API_docs/constructors/updateDeleteQuickReply.html) - +* [onUpdateQuickReplyMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateQuickReplyMessage.html) - +* [onUpdateDeleteQuickReplyMessages »](https://docs.madelineproto.xyz/API_docs/constructors/updateDeleteQuickReplyMessages.html) - +* [onUpdateBotBusinessConnect »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotBusinessConnect.html) - +* [onUpdateBotNewBusinessMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotNewBusinessMessage.html) - +* [onUpdateBotEditBusinessMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotEditBusinessMessage.html) - +* [onUpdateBotDeleteBusinessMessage »](https://docs.madelineproto.xyz/API_docs/constructors/updateBotDeleteBusinessMessage.html) - +* [onUpdateNewStoryReaction »](https://docs.madelineproto.xyz/API_docs/constructors/updateNewStoryReaction.html) - + + + + +Next section \ No newline at end of file diff --git a/docs/docs/FLOOD_WAIT.md b/docs/docs/FLOOD_WAIT.md new file mode 100644 index 0000000000..c462dcaf78 --- /dev/null +++ b/docs/docs/FLOOD_WAIT.md @@ -0,0 +1,17 @@ +--- +title: "Avoiding FLOOD_WAITs" +description: "If you make too many requests to telegram, you might get FLOOD_WAITed for a while. To avoid these flood waits, you must calculate the flood wait rate." +nav_order: 18 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Avoiding FLOOD_WAITs + +If you make too many requests to telegram, you might get FLOOD_WAITed for a while. To avoid these flood waits, you must calculate the flood wait rate. + +Calculate it by making N of method calls until you get a FLOOD_WAIT_X + +floodwaitrate = time it took you to make the method calls + X + +Use sleep to execute max N calls in `floodwaitrate` seconds, this way you won't get flood waited! + +Next section \ No newline at end of file diff --git a/docs/docs/INLINE_BUTTONS.md b/docs/docs/INLINE_BUTTONS.md new file mode 100644 index 0000000000..61fae0b1e4 --- /dev/null +++ b/docs/docs/INLINE_BUTTONS.md @@ -0,0 +1,57 @@ +--- +title: "Inline buttons" +description: "You can easily click inline buttons using MadelineProto, just access the correct button:" +nav_order: 24 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Inline buttons + +You can easily click inline buttons using MadelineProto, just access the correct button: + +```php +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\EventHandler\Attributes\Handler; +use danog\MadelineProto\EventHandler\Message; +use danog\MadelineProto\EventHandler\SimpleFilter\Incoming; + +class MyEventHandler extends SimpleEventHandler +{ + #[Handler] + public function clickButton(Incoming&Message $message): void + { + if ($message->keyboard) { + // Press keyboard button by name + $result = $message->keyboard->press("Button name", waitForResult: true); + + // Press keyboard button by coordinates + $result = $message->keyboard->pressByCoordinates( + row: 0, + column: 2, + waitForResult: true + ); + + // Or manually load button + $button = $message->keyboard->buttons[0][2]; + + $label = $button->label; + } + } +} + + +MyEventHandler::startAndLoop('session.madeline'); +``` + +You can also access properties of `$button` (they vary depending on the [type of button](https://docs.madelineproto.xyz/API_docs/types/KeyboardButton.html)): + +```php +$label = $button->label; +``` + +And click them: + +```php +$button->click(); +``` + +Next section \ No newline at end of file diff --git a/docs/docs/INSTALLATION.md b/docs/docs/INSTALLATION.md new file mode 100644 index 0000000000..b8a0b2ed1f --- /dev/null +++ b/docs/docs/INSTALLATION.md @@ -0,0 +1,89 @@ +--- +title: "Installation" +description: "There are various ways to install MadelineProto:" +nav_order: 9 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Installation + +There are various ways to install MadelineProto: + +* [Simple](#simple) +* [Composer from existing project](#composer-from-existing-project) +* [Composer from scratch](#composer-from-scratch) + + +## Simple + +```php +Next section \ No newline at end of file diff --git a/docs/docs/LOGGING.md b/docs/docs/LOGGING.md new file mode 100644 index 0000000000..3804b3c4b9 --- /dev/null +++ b/docs/docs/LOGGING.md @@ -0,0 +1,81 @@ +--- +title: "Logging" +description: "MadelineProto provides a unified class for logging messages to the logging destination defined in settings." +nav_order: 19 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Logging + +MadelineProto provides a unified class for logging messages to the logging destination defined in [settings](SETTINGS.html). + +Use the [settings class](../PHP/danog/MadelineProto/Settings/Logger.html) to modify the default logging destination and log verbosity: + +## Example: +```php +use danog\MadelineProto\Logger; +use danog\MadelineProto\Settings\Logger as LoggerSettings; + +$settings = (new LoggerSettings) + ->setType(Logger::FILE_LOGGER) + ->setExtra('custom.log') + ->setMaxSize(50*1024*1024); +$MadelineProto->updateSettings($settings); +``` + +Note: when running from web, MadelineProto will also automatically enable logging of **PHP errors** (not MadelineProto logs) to `MadelineProto.log`, located in the same directory as the script that loaded MadelineProto. + +## Usage: + +```php +$MadelineProto->logger($message, $level); +``` + +`$message` is a string, an integer, an array, or any json-encodable object. +`$level` (optional) is one of the following constants: + +* `\danog\MadelineProto\Logger::FATAL_ERROR` - Indicates a fatal error +* `\danog\MadelineProto\Logger::ERROR` - Indicates a recoverable error +* `\danog\MadelineProto\Logger::NOTICE` - Indicates an info message +* `\danog\MadelineProto\Logger::VERBOSE` - Indicates a verbose info message +* `\danog\MadelineProto\Logger::ULTRA_VERBOSE` - Indicates an ultra verbose + + +By default, `$level` is `\danog\MadelineProto\Logger::NOTICE`. + + +## Error reporting + +MadelineProto now can report errors automatically to the bot admin. +Simply use the following method: + +```php +// $message = (string) $exception, for example +$MadelineProto->report($message); +``` + +This will automatically report the error (and send the logfile!) to the bot admin, set using the `setReportPeers` method: + +```php +$MadelineProto->setReportPeers(['danogentili']); +``` + +**OR** using the `getReportPeers` method of [the event handler](https://docs.madelineproto.xyz/docs/UPDATES.html#async-event-driven). + +```php + + /** + * Get peer(s) where to report errors + * + * @return int|string|array + */ + public function getReportPeers() + { + return [self::ADMIN]; + } +``` + +If you use the [`startAndLoop`](https://docs.madelineproto.xyz/docs/UPDATES.html#async-event-driven) method to start update handling, all errors surfacing from the loop will be reported automatically. + +If memory profiling with [memprof](https://github.com/arnaud-lb/php-memory-profiler) is enabled, you can also use `reportMemoryProfile()` to send a pprof memory profile to all report peers. + +Next section \ No newline at end of file diff --git a/docs/docs/LOGIN.md b/docs/docs/LOGIN.md new file mode 100644 index 0000000000..e145bf35b9 --- /dev/null +++ b/docs/docs/LOGIN.md @@ -0,0 +1,195 @@ +--- +title: "Login" +description: "There are many ways you can login with MadelineProto." +nav_order: 5 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Login + +There are many ways you can login with MadelineProto. + +* [Getting permission to use the telegram API](#getting-permission-to-use-the-telegram-api) +* [Automatic](#automatic) +* [Manual (user)](#manual-user) + * [API ID](#api-id) +* [Manual (bot)](#manual-bot) +* [QR code login (user)](#qr-code-user) + +## Getting permission to use the telegram API + +Before you start using MadelineProto with the Telegram API, you have to understand that Telegram strictly controls userbots created on their platform. + +If you use MadelineProto or any other Telegram client, **including official clients**, for flooding, spamming, botting channels, you **will be banned forever**. + +Due to excessive abuse of the Telegram API, **all phone numbers** that sign up or log in using **even official or approved by telegram** API clients like MadelineProto are automatically put **under observation**, and __may__ get banned **even if you did nothing wrong**, simply because some internal flags are triggered in the **telegram servers**. + +To avoid this, you must let telegram know that you will use your account with a userbot: +When or before you first sign up or login you have to **send an email with the phone number to [recover@telegram.org](mailto:recover@telegram.org)**; explaining **what will your userbot do**. +**DO NOT LIE**, just tell them **what will you do with the userbot** you intend to create, asking them to not ban your account. + +If your account does get banned, write to [recover@telegram.org](mailto:recover@telegram.org) asking to unban it. + +**DO NOT ABUSE OF THIS OR ANY OTHER API FOR FLOODING; SPAMMING; BOTTING**; the consequences will fall not only on you, but on all other users of this and other libraries, and even normal users. + +There were cases when several **normal user accounts that did nothing wrong** were banned when telegram deployed a new spambot detection system: this is bad for the community, and it is bad for Telegram, so please do not abuse. + + +## Automatic + +```php +$MadelineProto->start(); +``` + +This will start an interactive login prompt via console (if running via CLI), or a login web UI (if running in the browser). +You will get to choose if login as user, or as bot. + +When using the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), use the static `startAndLoop` method, instead: + +```php +MyEventHandler::startAndLoop('session.madeline', $settings); +``` + +No explicit `$MadelineProto` instance is required or allowed when using the event handler. + + +## Manual (user) + +Before logging in, you must obtain an [API ID](https://docs.madelineproto.xyz/docs/SETTINGS.html) (if you're using the [automatic mode you don't have to do this](#automatic)). +You can do that by logging in to [my.telegram.org](https://my.telegram.org) and getting your API ID/hash. + +After you provide an API ID [in the settings](https://docs.madelineproto.xyz/docs/SETTINGS.html), you can then login (if you're using the [automatic mode you don't have to do this](#automatic)). + +```php +use danog\MadelineProto\Tools; + +$MadelineProto->phoneLogin(Tools::readLine('Enter your phone number: ')); +$authorization = $MadelineProto->completePhoneLogin(Tools::readLine('Enter the phone code: ')); +if ($authorization['_'] === 'account.password') { + $authorization = $MadelineProto->complete2falogin(Tools::readLine('Please enter your password (hint '.$authorization['hint'].'): ')); +} +if ($authorization['_'] === 'account.needSignup') { + $authorization = $MadelineProto->completeSignup(Tools::readLine('Please enter your first name: '), readline('Please enter your last name (can be empty): ')); +} +``` + +First, you must call `phoneLogin` to send the verification code, see [here for the parameters and the result](https://docs.madelineproto.xyz/phoneLogin.html). +Then, use `completePhoneLogin` to complete the login, see [here for the parameters and the result](https://docs.madelineproto.xyz/completePhoneLogin.html). + +Use `complete2falogin` to complete the login to an account with 2FA enabled, see [here for the parameters and the result](https://docs.madelineproto.xyz/complete2FALogin.html). + +If the account does not have an account, use `completeSignup` to signup, see [here for the parameters and the result](https://docs.madelineproto.xyz/completeSignup.html). + + +## Manual (bot) + +```php +$MadelineProto->botLogin('34298141894:aflknsaflknLKNFS'); +``` + +Use `botLogin` to login as a bot, see [here for the parameters and the result](https://docs.madelineproto.xyz/botLogin.html). + +## QR code (user) + +The new QR code login API can be used to render a QR code that can be scanned using the Telegram mobile apps in order to login. + +The API is designed to be easily used in parallel with another login mode (i.e. together with the manual modes described above), but it can also be used standalone. + +[See here for the full documentation of the QR code API »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/TL/Types/LoginQrCode.html). + +### CLI usage example + +```php +use Amp\CancelledException; +use Amp\CompositeCancellation; +use Amp\TimeoutCancellation; +use danog\MadelineProto\TL\Types\LoginQrCode; +use danog\MadelineProto\API; +use danog\MadelineProto\Tools; + +function login(\danog\MadelineProto\API $MadelineProto): void { + do { + $qr = $MadelineProto->qrLogin(); + if (!$qr) { + if ($MadelineProto->getAuthorization() === API::WAITING_PASSWORD) { + $MadelineProto->complete2faLogin(Tools::readLine('Please enter your password (hint '.$MadelineProto->getHint().'): ')); + } + // If null, we're already logged in + return; + } + + // Print QR code in text format + echo $qr->getQRText(); + + $expire = $qr->getExpirationCancellation(); + $login = $qr->getLoginCancellation(); + + $cancel = new CompositeCancellation($expire, $login); + + try { + $result = Tools::readLine("Enter your phone number, or scan the above QR code to login: ", $cancel); + break; + } catch (CancelledException) { + if ($login->isRequested()) { + echo(PHP_EOL.PHP_EOL."QR code login successful!".PHP_EOL); + if ($MadelineProto->getAuthorization() === API::WAITING_PASSWORD) { + $MadelineProto->complete2faLogin(Tools::readLine('Please enter your password (hint '.$MadelineProto->getHint().'): ')); + } + return; + } + echo(PHP_EOL."The QR code expired, generating a new one...".PHP_EOL); + } + } while (true); + + $MadelineProto->phoneLogin($result); + $authorization = $MadelineProto->completePhoneLogin(Tools::readLine('Enter the phone code: ')); + if ($authorization['_'] === 'account.password') { + $MadelineProto->complete2falogin(Tools::readLine('Please enter your password (hint '.$authorization['hint'].'): ')); + } + if ($authorization['_'] === 'account.needSignup') { + $MadelineProto->completeSignup(Tools::readLine('Please enter your first name: '), Tools::readline('Please enter your last name (can be empty): ')); + } +} +``` + +### Web usage example + +In this example, two endpoints are offered: + +* `?waitQrCodeOrLogin` long-polls the QR login API, waiting for the QR code to expire or for the user to scan the code. + * If the QR code expires, a new SVG with the QR code is returned in a JSON payload. + * If the user scans the code and approves login through a Telegram app, the `logged_in` field in the returned JSON payload is set to true. If the user has also set a 2FA password, the `needs_2fa` field will `true` and the web UI will have to ask for a password and invoke `complete2falogin`. +* `?getQrCode` does the same as `?waitQrCodeOrLogin`, except that it doesn't wait the additional 5 seconds (useful to fetch an initial QR code upon first page load). + +```php +use Amp\CancelledException; +use Amp\CompositeCancellation; +use Amp\TimeoutCancellation; +use danog\MadelineProto\TL\Types\LoginQrCode; +use danog\MadelineProto\API; + +if (isset($_GET['waitQrCodeOrLogin']) || isset($_GET['getQrCode'])) { + \header('Content-type: application/json'); + try { + $qr = $MadelineProto->qrLogin(); + if (isset($_GET['waitQrCodeOrLogin'])) { + $qr = $qr?->waitForLoginOrQrCodeExpiration(new TimeoutCancellation(5.0)); + } + } catch (CancelledException) { + $qr = $MadelineProto->qrLogin(); + } + if ($qr) { + $result = [ + 'logged_in' => false, + 'svg' => $qr->getQRSvg(400, 2) + ]; + } else { + $result = [ + 'logged_in' => true, + 'needs_2fa' => $MadelineProto->getAuthorization() === MTProto::WAITING_PASSWORD + ]; + } + echo(\json_encode($result)); +} +``` + +Next section \ No newline at end of file diff --git a/docs/docs/PLUGINS.md b/docs/docs/PLUGINS.md new file mode 100644 index 0000000000..c5462f4de2 --- /dev/null +++ b/docs/docs/PLUGINS.md @@ -0,0 +1,373 @@ +--- +title: "Plugins" +description: "MadelineProto offers a native plugin system, based on event handlers!" +nav_order: 13 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Plugins + +MadelineProto offers a native plugin system, based on [event handlers](https://docs.madelineproto.xyz/docs/UPDATES.html)! + +* [Installing plugins](#installing-plugins) + * [Simple installation](#simple-installation) + * [Composer installation](#composer-installation) + * [Builtin plugins](#builtin-plugins) +* [Creating plugins](#creating-plugins) + * [Full plugin example](#full-plugin-example) + * [Limitations](#limitations) + * [Namespace requirements](#namespace-requirements) + * [Distribution](#distribution) + +## Installing plugins + +Plugins can be installed by simply placing their files in the plugin path, or by installing them through composer. + +Plugins may be run either using a [plugin base »](https://github.com/danog/MadelineProto/raw/v8/examples/PluginBase.php), or directly (in which case they behave as normal bots). + +### Simple installation + +To install a plugin, copy the plugin's files into a `plugins/` folder, and use the following base code ([download »](https://github.com/danog/MadelineProto/raw/v8/examples/PluginBase.php)): + + + +```php +getLogger()->setLevel(Logger::LEVEL_ULTRA_VERBOSE); + +// You can also use Redis, MySQL or PostgreSQL +// $settings->setDb((new Redis)->setDatabase(0)->setPassword('pony')); +// $settings->setDb((new Postgres)->setDatabase('MadelineProto')->setUsername('daniil')->setPassword('pony')); +// $settings->setDb((new Mysql)->setDatabase('MadelineProto')->setUsername('daniil')->setPassword('pony')); + +// For users or bots +BaseHandler::startAndLoop('bot.madeline', $settings); + +// For bots only +// BaseHandler::startAndLoopBot('bot.madeline', 'bot token', $settings); + +``` + + + +Any other folder name may be used as well, and you can also return an array of folder names from `getPluginPaths()`. + +You can combine plugins installed with this mode with plugins installed using [composer](#composer-installation). + +### Composer installation + +To install a plugin via composer, require it first: + +```bash +composer require yournick/someplugin +``` + +Then return it from the `getPlugins` function of your base event handler: + +```php +getLogger()->setLevel(Logger::LEVEL_ULTRA_VERBOSE); + +// You can also use Redis, MySQL or PostgreSQL +// $settings->setDb((new Redis)->setDatabase(0)->setPassword('pony')); +// $settings->setDb((new Postgres)->setDatabase('MadelineProto')->setUsername('daniil')->setPassword('pony')); +// $settings->setDb((new Mysql)->setDatabase('MadelineProto')->setUsername('daniil')->setPassword('pony')); + +// For users or bots +BaseHandler::startAndLoop('bot.madeline', $settings); + +// For bots only +// BaseHandler::startAndLoopBot('bot.madeline', 'bot token', $settings); +``` + +You can combine plugins installed with this mode with plugins installed using a [plugin path](#simple-installation). + +### Builtin plugins + +MadelineProto itself also offers some useful builtin plugins that can be optionally enabled by returning them from the `getPlugins` function: + + + +* [danog\MadelineProto\EventHandler\Plugin\RestartPlugin »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Plugin/RestartPlugin.html) - Plugin that offers a /restart command to admins that can be used to restart the bot, applying changes. + + + + +Example: + + + +```php + + +## Creating plugins + +To create a plugin, simply create an [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html) that extends the `PluginEventHandler` class. + +### Full plugin example + +Full example (file name `plugins/Danogentili/PingPlugin.php`): + + + +```php +getPlugin(PingPlugin::class); + * + * $plugin->setPongText('UwU'); + * ``` + * + * This will automatically connect to the running instance of the plugin and call the specified method. + */ + public function setPongText(string $pong): void + { + $this->pongText = $pong; + } + + /** + * Returns a list of names for properties that will be automatically saved to the session database (MySQL/postgres/redis if configured, the session file otherwise). + */ + public function __sleep(): array + { + return ['pingCount', 'pongText']; + } + /** + * Initialization logic. + */ + public function onStart(): void + { + $this->logger("The bot was started!"); + $this->logger($this->getFullInfo('MadelineProto')); + + $this->sendMessageToAdmins("The bot was started!"); + } + + /** + * Plugins may be enabled or disabled at startup by returning true or false from this function. + */ + public function isPluginEnabled(): bool + { + return true; + } + + /** + * This cron function will be executed forever, every 60 seconds. + */ + #[Cron(period: 60.0)] + public function cron1(): void + { + $this->sendMessageToAdmins("The ping plugin is online, total pings so far: ".$this->pingCount); + } + + #[FilterText('ping')] + public function pingCommand(Incoming&Message $message): void + { + $message->reply($this->pongText); + $this->pingCount++; + } +} + +``` + + + +Plugins may be enabled or disabled at startup by returning `true` or `false` from `isPluginEnabled()`. + +### Limitations + +Plugins can handle updates, include other plugins using `getPlugins()` and store persistent data to the session using `__sleep`, [just like any non-plugin event handler](https://docs.madelineproto.xyz/docs/UPDATES.html). + +However, unlike normal event handlers, plugins can require other plugins using **only** `getPlugins()`, not `getPluginPaths()`. + +Also, plugins can only interact with the filesystem using MadelineProto's download and upload functions. + +For performance reasons, your plugin **should not** read files from the filesystem. + +Here's a list of common uses for files, and what they can be replaced with: + +* [Configuration](https://docs.madelineproto.xyz/docs/UPDATES.html#configuration) +* [Creating and uploading text files](https://docs.madelineproto.xyz/docs/UPDATES.html#creating-and-uploading-text-files) +* [Logging](https://docs.madelineproto.xyz/docs/UPDATES.html#logging) + +### Namespace requirements + +Plugins must be located in the `MadelinePlugin` vendor namespace, preferrably in a custom subnamespace to avoid conflicts with other plugins. + +So for example, if your nickname is `@danogentili`, use `namespace MadelinePlugin\Danogentili;`. + +All the classes, interfaces, functions and traits defined by your plugin's code must be defined in the namespace you chose. + +The file layout must follow the [PSR-4 autoloading standard](https://www.php-fig.org/psr/psr-4/); for example, if you have the following classes: + +* `MadelinePlugin\Danogentili\PingPlugin` - A ping plugin +* `MadelinePlugin\Danogentili\HelperPlugin` - A helper plugin +* `MadelinePlugin\Danogentili\CommonTrait` - A common trait with some tools, included by the plugins +* `MadelinePlugin\Danogentili\Internal\SomeOtherClass` - Some other class (not a plugin) + +This will be the directory structure: + +``` +plugins/Danogentili/PingPlugin.php +plugins/Danogentili/HelperPlugin.php +plugins/Danogentili/CommonTrait.php +plugins/Danogentili/Internal/SomeOtherClass.php +``` + +If you want to define some functions, put them in `plugins/Danog/functions.php` (or any subdirectory, as long as the name of the file is `functions.php`). + +### Distribution + +Plugins can be distributed in a simple zip file, or using composer. + +You can also distribute plugins as standalone files in the `MadelinePlugin` namespace (make sure to choose a really unique name!), for example `plugins/Danogentili.php`. + +Next section \ No newline at end of file diff --git a/docs/docs/PROXY.md b/docs/docs/PROXY.md new file mode 100644 index 0000000000..258e1942cc --- /dev/null +++ b/docs/docs/PROXY.md @@ -0,0 +1,181 @@ +--- +title: "Using a proxy" +description: "You can use a proxy with MadelineProto." +nav_order: 26 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Using a proxy + +You can use a proxy with MadelineProto. + +* [How to set a proxy](#how-to-set-a-proxy) +* [Multiple proxies with automatic switch](#multiple-proxies-with-automatic-switch) +* [Use pre-built MTProxy](#mtproxy) +* [Use pre-built Socks5 proxy](#socks5-proxy) +* [Use pre-built HTTP proxy](#http-proxy) +* [Build your own proxy](#build-your-proxy) + + +## How to set a proxy + +In order to set a proxy for MadelineProto, you have to modify the [settings](SETTINGS.html). +You can set multiple proxies, and let MadelineProto choose the best one. + + +```php +use danog\MadelineProto\Stream\MTProtoTransport\ObfuscatedStream; +use danog\MadelineProto\Stream\Proxy\HttpProxy; +use danog\MadelineProto\Stream\Proxy\SocksProxy; +use danog\MadelineProto\Settings\Connection; +use my\Custom\Namespace\MyProxy; + +$settings = new Connection; +$settings->addProxy( + ObfuscatedStream::class, + [ + 'address' => 'magtg.com', + 'port' => 443, + 'secret' => 'dd.....' + ] +); +$settings->addProxy( + ObfuscatedStream::class, + [ + 'address' => 'magtg2.com', + 'port' => 443, + 'secret' => 'dd.....' + ] +); +$settings->addProxy( + HttpProxy::class, + [ + 'address' => '0.0.0.0', + 'port' => 80, + 'username' => 'user', + 'password' => 'pass' + ], +); +$settings->addProxy( + SocksProxy::class, + [ + 'address' => '0.0.0.0', + 'port' => 80, + 'username' => 'user', + 'password' => 'pass' + ], +); +$settings->addProxy( + MyProxy::class, + [ + 'custom' => 'data' + ], +); + +$MadelineProto->updateSettings($settings); +``` + +## MTProxy + +```php +use danog\MadelineProto\Settings\Connection; +use danog\MadelineProto\Stream\MTProtoTransport\ObfuscatedStream; + +$settings = new Connection; +$settings->addProxy( + ObfuscatedStream::class, + [ + 'address' => 'magtg.com', + 'port' => 443, + 'secret' => 'dd.....' + ] +); + +$MadelineProto->updateSettings($settings); +``` + +Both normal and `dd` secrets are supported, the transport is changed automatically by MadelineProto. + +## Socks5 proxy + +No password: + +```php +use danog\MadelineProto\Stream\Proxy\SocksProxy; + +$settings = new Connection; +$settings->addProxy( + SocksProxy::class, + [ + 'address' => '0.0.0.0', + 'port' => 2343, + ] +); + +$MadelineProto->updateSettings($settings); +``` + + +With password: + +```php +use danog\MadelineProto\Stream\Proxy\SocksProxy; + +$settings = new Connection; +$settings->addProxy( + SocksProxy::class, + [ + 'address' => '0.0.0.0', + 'port' => 2343, + 'username' => 'username', + 'password' => 'password', + ] +); + +$MadelineProto->updateSettings($settings); +``` +## HTTP proxy + +No password: + +```php +use danog\MadelineProto\Stream\Proxy\HttpProxy; + +$settings = new Connection; +$settings->addProxy( + HttpProxy::class, + [ + 'address' => '0.0.0.0', + 'port' => 2343, + ] +); + +$MadelineProto->updateSettings($settings); +``` + + +With password: + +```php +use danog\MadelineProto\Stream\Proxy\HttpProxy; + +$settings = new Connection; +$settings->addProxy( + HttpProxy::class, + [ + 'address' => '0.0.0.0', + 'port' => 2343, + 'username' => 'username', + 'password' => 'password', + ] +); + +$MadelineProto->updateSettings($settings); +``` + +## Build your proxy + +In order to build your proxy, you have to use the new MadelineProto stream API to create your own proxy class. +Feel free to study [existing proxies](https://github.com/danog/MadelineProto/tree/v8/src/Stream/Proxy) and the [stream API](https://github.com/danog/MadelineProto/tree/v8/src/Stream): it's well structured and well documented, so feel free to read the code. +Don't forget to add support for [TLS connections](https://github.com/danog/MadelineProto/blob/v8/src/Stream/Proxy/SocksProxy.php#L141) as well! + +Next section \ No newline at end of file diff --git a/docs/docs/REQUIREMENTS.md b/docs/docs/REQUIREMENTS.md new file mode 100644 index 0000000000..366b91f079 --- /dev/null +++ b/docs/docs/REQUIREMENTS.md @@ -0,0 +1,56 @@ +--- +title: "Requirements" +description: "MadelineProto requires the mbstring, xml, json, fileinfo, gmp, openssl, iconv, gd extensions to function properly." +nav_order: 7 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Requirements + +MadelineProto requires the `mbstring`, `xml`, `json`, `fileinfo`, `gmp`, `openssl`, `iconv`, `gd` extensions to function properly. + +The `ffi` and `uv` extensions and the [PrimeModule](https://prime.madelineproto.xyz/) and `nghttp2` libraries are also highly recommended to improve performance. + +**PHP 8.2+ is required**. + +MadelineProto explicitly supports Linux and UNIX systems (including Mac OS). +I **don't recommend using Windows**: MadelineProto generally works on Windows, though there might be some random issues caused by AV engines, so I personally recommend using Linux. + +**Mac OS+Docker note**: If you encounter issues running MadelineProto on Docker on Mac OS, make sure to enable ephemeral filesystem support with a database [as described here »](https://docs.madelineproto.xyz/docs/DATABASE.html#ephemeral-filesystems), and change the session path in `bot.php` to point to a unique path in `/tmp`, not in a mounted volume. + +Running on webservers and webhosts is fully supported, but I highly recommend running long-running applications like [event handler bots](https://docs.madelineproto.xyz/docs/UPDATES.html) via CLI. + +**Running via docker is highly recommended**, see [here »](https://docs.madelineproto.xyz/docs/DOCKER.html) for more info on how to run MadelineProto in docker, on any Linux distro. + +Otherwise, see [here »](#ubuntu) for more info on how to install MadelineProto dependencies manually on Ubuntu. + +## Docker (recommended) + +Follow [these instructions »](https://docs.madelineproto.xyz/docs/DOCKER.html) to install MadelineProto dependencies on *any linux distro*, using the official docker image. + +## Ubuntu + +To install MadelineProto dependencies manually on Ubuntu, run the following command in your command line: + +```bash +sudo apt-get update +sudo apt-get install software-properties-common -y +sudo LC_ALL=C.UTF-8 add-apt-repository -y ppa:ondrej/php +sudo apt-get update +sudo apt-get install php8.2 php8.2-dev php8.2-xml php8.2-zip php8.2-gmp php8.2-cli php8.2-mbstring php8.2-ffi php8.2-iconv php-pear libuv1-dev nghttp2 -y +sudo pecl install uv-beta +echo extension=uv.so | sudo tee $(php --ini | sed '/additional .ini/!d;s/.*: //g')/uv.ini +echo ffi.enable=1 | sudo tee $(php --ini | sed '/additional .ini/!d;s/.*: //g')/ffi.ini + +echo 262144 | sudo tee /proc/sys/vm/max_map_count +echo vm.max_map_count=262144 | sudo tee /etc/sysctl.d/40-madelineproto.conf + +cd /tmp +sudo apt-get install build-essential +git clone https://github.com/danog/PrimeModule-ext +cd PrimeModule-ext && make -j$(nproc) && sudo make install + +``` + +The `max_map_count` sysctl configuration is required to avoid "Fiber stack allocate failed" and "Fiber stack protect failed" errors, since the PHP engine mmaps two memory regions per fiber. + +Next section \ No newline at end of file diff --git a/docs/docs/SECRET_CHATS.md b/docs/docs/SECRET_CHATS.md new file mode 100644 index 0000000000..3f42ed9ae2 --- /dev/null +++ b/docs/docs/SECRET_CHATS.md @@ -0,0 +1,75 @@ +--- +title: "Secret chats" +description: "MadelineProto provides wrappers to work with secret chats." +nav_order: 25 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Secret chats + +MadelineProto provides wrappers to work with secret chats. + +* [Requesting secret chats](#requesting-secret-chats) +* [Accepting secret chats](#accepting-secret-chats) +* [Checking secret chat status](#checking-secret-chat-status) +* [Sending secret messages](#sending-secret-messages) + +## Requesting secret chats + +```php +$secret_chat = $MadelineProto->requestSecretChat($InputUser); +``` + +[`requestSecretChat`](https://docs.madelineproto.xyz/requestSecretChat.html) requests a secret secret chat to the [InputUser](https://docs.madelineproto.xyz/API_docs/types/InputUser.html), ID, or username specified, and returns the secret chat ID. + + +## Accepting secret chats + +Secret chats are accepted or refused automatically, based on a value in the [settings](SETTINGS.html) (by default MadelineProto is set to accept all secret chats). + +Before sending any message, you must check if the secret chat was accepted by the other client with the following method: + +## Checking secret chat status + +```php +$status = $MadelineProto->secretChatStatus($chat); +``` + +$status is `\danog\MadelineProto\MTProto::SECRET_EMPTY` if the chat cannot be found in the local database, `MTProto::SECRET_REQUESTED` if the chat was requested but not yet accepted, and `MTProto::SECRET_READY` if it is a valid accepted secret chat. + +## Sending secret messages + +[Full example](https://github.com/danog/MadelineProto/blob/v8/examples/secret_bot.php) + +To send messages/files/service messages, simply use the sendEncrypted methods with objects that use the same layer used by the other client (specified by the number after the underscore in decryptedMessage object names, to obtain the layer that must be used for a secret chat use the following wrapper method). + +```php +$secret_chat = $MadelineProto->getSecretChat($chat); +/* +[ + 'key' => [ // The authorization key + 'auth_key' => 'string', // 256 bytes long + 'fingerprint' => 10387574747492, // a 64 bit signed integer + 'visualization_orig' => 'string', // 16 bytes long + 'visualization_46' => 'string', // 20 bytes long + // The two visualization strings must be concatenated to generate a visual fingerprint + ], + 'admin' => false, // Am I the creator of the chat? + 'user_id' => 101374607, // The user id of the other user + 'InputEncryptedChat' => [...], // An inputEncryptedChat object that represents the current chat + 'in_seq_no_x' => number, // in_seq_no must be multiplied by two and incremented by this before being sent over the network + 'out_seq_no_x' => number, // out_seq_no must be multiplied by two and incremeneted this begore being sent over the network + 'layer' => number, // The secret chat TL layer used by the other client + 'ttl' => number, // The default time to live of messages in this chat + 'ttr' => 100, // Time left before rekeying must be done, decremented by one every time a message as encrypted/decrypted with this key + 'updated' => time(), // Last time the key of the current chat was changed + 'incoming' => [], // Incoming messages, TL serialized strings + 'outgoing' => [], // Outgoing messages, TL serialized strings + 'created' => time(), // When was this chat created + 'rekeying' => [0] // Info for rekeying +]; +*/ +``` + +This method gets info about a certain chat. + +Next section \ No newline at end of file diff --git a/docs/docs/SELF.md b/docs/docs/SELF.md new file mode 100644 index 0000000000..2755a4b440 --- /dev/null +++ b/docs/docs/SELF.md @@ -0,0 +1,19 @@ +--- +title: "Getting info about the current user" +description: "Here's how you can fetch info about the currently logged in user" +nav_order: 16 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Getting info about the current user + +Here's how you can fetch info about the currently logged in user + +```php +$me = $MadelineProto->getSelf(); + +\danog\MadelineProto\Logger::log("Hi ".$me['first_name']."!"); +``` + +[`getSelf`](https://docs.madelineproto.xyz/getSelf.html) returns a [User object](../API_docs/types/User.html) that contains info about the currently logged in user/bot, or false if the current instance is not logged in. + +Next section \ No newline at end of file diff --git a/docs/docs/SETTINGS.md b/docs/docs/SETTINGS.md new file mode 100644 index 0000000000..1d36801975 --- /dev/null +++ b/docs/docs/SETTINGS.md @@ -0,0 +1,71 @@ +--- +title: "Settings" +description: "MadelineProto has lots of settings that can be used to modify the behaviour of the library." +nav_order: 15 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Settings + +MadelineProto has lots of settings that can be used to modify the behaviour of the library. +These settings are controlled by the following classes in the `\danog\MadelineProto\Settings` namespace: + +* [AppInfo: App information.](../PHP/danog/MadelineProto/Settings/AppInfo.html) +* [Auth: Cryptography settings.](../PHP/danog/MadelineProto/Settings/Auth.html) +* [Connection: Connection settings.](../PHP/danog/MadelineProto/Settings/Connection.html) +* [Files: File management settings.](../PHP/danog/MadelineProto/Settings/Files.html) +* [Logger: Logger settings.](../PHP/danog/MadelineProto/Settings/Logger.html) +* [Peer: Peer database settings.](../PHP/danog/MadelineProto/Settings/Peer.html) +* [Pwr: PWRTelegram settings.](../PHP/danog/MadelineProto/Settings/Pwr.html) +* [RPC: RPC settings.](../PHP/danog/MadelineProto/Settings/RPC.html) +* [SecretChats: Secret chat settings.](../PHP/danog/MadelineProto/Settings/SecretChats.html) +* [Serialization: Serialization settings.](../PHP/danog/MadelineProto/Settings/Serialization.html) +* [TLSchema: TL schema settings.](../PHP/danog/MadelineProto/Settings/TLSchema.html) +* [Templates: Web and CLI template settings for login.](../PHP/danog/MadelineProto/Settings/Templates.html) +* [VoIP: VoIP settings.](../PHP/danog/MadelineProto/Settings/VoIP.html) +* [Database\Memory: Memory backend settings.](../PHP/danog/MadelineProto/Settings/Database/Memory.html) +* [Database\Mysql: MySQL backend settings.](../PHP/danog/MadelineProto/Settings/Database/Mysql.html) +* [Database\Postgres: Postgres backend settings.](../PHP/danog/MadelineProto/Settings/Database/Postgres.html) +* [Database\Redis: Redis backend settings.](../PHP/danog/MadelineProto/Settings/Database/Redis.html) + +These classes can be instantiated and passed individually to MadelineProto: +```php +$settings = (new \danog\MadelineProto\Settings\AppInfo) + ->setApiId(124) + ->setApiHash('xx'); + +$API = new \danog\MadelineProto\API('session.madeline', $settings); +``` + +**It's heavily recommended** to remove (or pass null) the second `$settings` parameter passed to the constructor once the instance is logged in, to avoid the performance overhead of needlessly updating settings every time API is instantiated: + +To modify the settings of an already created instance, `updateSettings` should be used, instead: +```php +$settings = (new \danog\MadelineProto\Settings\AppInfo) + ->setApiId(124) + ->setApiHash('xx'); + +$MadelineProto->updateSettings($settings); +``` + +It's recommended you create a separate file that accesses the session just to modify the settings, as it's a very rare operation. + +You can also group settings in a single [\danog\MadelineProto\Settings](../PHP/danog/MadelineProto/Settings.html) object, to quickly modify multiple settings: + +**See [here »](../PHP/danog/MadelineProto/Settings.html) for more info on how to get and modify the instances of each subsetting class mentioned at the beginning of this page**. + +```php +$settings = new \danog\MadelineProto\Settings; +$settings->setDb((new \danog\MadelineProto\Settings\Database\Mysql) + ->setUri('tcp://localhost') + ->setPassword('pass') +); +$settings->setAppInfo((new \danog\MadelineProto\Settings\AppInfo) + ->setApiId(124) + ->setApiHash('xx') +); +$settings->getFiles()->setUploadParallelChunks(100); + +$MadelineProto->updateSettings($settings); +``` + +Next section \ No newline at end of file diff --git a/docs/docs/TEMPLATES.md b/docs/docs/TEMPLATES.md new file mode 100644 index 0000000000..e8387f9df7 --- /dev/null +++ b/docs/docs/TEMPLATES.md @@ -0,0 +1,33 @@ +--- +title: "Web templates for `$MadelineProto->start()`" +description: "The web template used for the $MadelineProto->start() and API ID web UIs can be changed." +nav_order: 32 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Web templates for `$MadelineProto->start()` + +The web template used for the `$MadelineProto->start()` and API ID web UIs can be changed. + +The change is made in the [settings »](https://docs.madelineproto.xyz/docs/SETTINGS.html), [`\danog\MadelineProto\Settings\Templates`](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Templates.html) class. + +By default, it is equal to: +```html + + + + MadelineProto + + +

MadelineProto

+
+ %s + +
+

%s

+ + +``` + +The new template must have a structure similar the the default template. + +Next section \ No newline at end of file diff --git a/docs/docs/UPDATES.md b/docs/docs/UPDATES.md new file mode 100644 index 0000000000..d1d913b9c3 --- /dev/null +++ b/docs/docs/UPDATES.md @@ -0,0 +1,1368 @@ +--- +title: "Handling updates (new messages & other events)" +description: "Update handling can be done in different ways:" +nav_order: 11 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Handling updates (new messages & other events) + +Update handling can be done in different ways: + +* [Async Event driven](#async-event-driven) + * [Full example](#async-event-driven) + * [Bound methods](#bound-methods) + * [Filters](https://docs.madelineproto.xyz/docs/FILTERS.html) + * [Simple filters](https://docs.madelineproto.xyz/docs/FILTERS.html#simple-filters) + * [Attribute filters](https://docs.madelineproto.xyz/docs/FILTERS.html#attribute-filters) + * [MTProto filters](https://docs.madelineproto.xyz/docs/FILTERS.html#mtproto-filters) + * [Plugins](https://docs.madelineproto.xyz/docs/PLUGINS.html) + * [Cron](#cron) + * [Persisting data and IPC](#persisting-data-and-ipc) + * [Built-in ORM](#built-in-orm) + * [IPC](#ipc) + * [Restarting](#restarting) + * [Self-restart on webhosts](#self-restart-on-webhosts) + * [Multi-account](#multiaccount) + * [Automatic static analysis](#automatic-static-analysis) + * [Avoiding the use of filesystem functions](#avoiding-the-use-of-filesystem-functions) +* [Webhook (for HTTP APIs)](#webhook) +* [getUpdates (only for Javascript APIs)](#getUpdates) +* [Noop (default)](#noop) + + +## Async Event driven + +[Plugins » are also supported!](https://docs.madelineproto.xyz/docs/PLUGINS.html) + +Simple example: + + +```php + + +Advanced example: + + +```php +. + * + * @author Daniil Gentili + * @copyright 2016-2023 Daniil Gentili + * @license https://opensource.org/licenses/AGPL-3.0 AGPLv3 + * @link https://docs.madelineproto.xyz MadelineProto documentation + */ + +use danog\MadelineProto\API; +use danog\MadelineProto\Broadcast\Progress; +use danog\MadelineProto\Broadcast\Status; +use danog\MadelineProto\EventHandler\Attributes\Cron; +use danog\MadelineProto\EventHandler\Attributes\Handler; +use danog\MadelineProto\EventHandler\Filter\FilterCommand; +use danog\MadelineProto\EventHandler\Filter\FilterRegex; +use danog\MadelineProto\EventHandler\Filter\FilterText; +use danog\MadelineProto\EventHandler\Filter\FilterTextCaseInsensitive; +use danog\MadelineProto\EventHandler\Message; +use danog\MadelineProto\EventHandler\Message\ChannelMessage; +use danog\MadelineProto\EventHandler\Message\Service\DialogPhotoChanged; +use danog\MadelineProto\EventHandler\Plugin\RestartPlugin; +use danog\MadelineProto\EventHandler\SimpleFilter\FromAdmin; +use danog\MadelineProto\EventHandler\SimpleFilter\Incoming; +use danog\MadelineProto\EventHandler\SimpleFilter\IsReply; +use danog\MadelineProto\Logger; +use danog\MadelineProto\ParseMode; +use danog\MadelineProto\RemoteUrl; +use danog\MadelineProto\Settings; +use danog\MadelineProto\Settings\Database\Mysql; +use danog\MadelineProto\Settings\Database\Postgres; +use danog\MadelineProto\Settings\Database\Redis; +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\VoIP; + +// MadelineProto is already loaded +if (class_exists(API::class)) { + // Otherwise, if a stable version of MadelineProto was installed via composer, load composer autoloader +} elseif (file_exists('vendor/autoload.php')) { + require_once 'vendor/autoload.php'; +} else { + // Otherwise download an !!! alpha !!! version of MadelineProto via madeline.php + if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); + } + require_once 'madeline.php'; +} +/** + * Event handler class. + * + * NOTE: ALL of the following methods are OPTIONAL. + * You can even provide an empty event handler if you want. + * + * All properties returned by __sleep are automatically stored in the database. + */ +class MyEventHandler extends SimpleEventHandler +{ + /** + * @var int|string Username or ID of bot admin + */ + public const ADMIN = "@me"; // !!! Change this to your username !!! + + /** + * @var array + */ + private array $notifiedChats = []; + + /** + * Returns a list of names for properties that will be automatically saved to the session database (MySQL/postgres/redis if configured, the session file otherwise). + */ + public function __sleep(): array + { + return ['notifiedChats']; + } + + /** + * Get peer(s) where to report errors. + * + * @return int|string|array + */ + public function getReportPeers() + { + return [self::ADMIN]; + } + /** + * Initialization logic. + */ + public function onStart(): void + { + $this->logger("The bot was started!"); + $this->logger($this->getFullInfo('MadelineProto')); + + $this->sendMessageToAdmins("The bot was started!"); + } + + /** + * Returns a set of plugins to activate. + */ + public static function getPlugins(): array + { + return [ + // Offers a /restart command to admins that can be used to restart the bot, applying changes. + // Make sure to run in a bash while loop when running via CLI to allow self-restarts. + RestartPlugin::class, + ]; + } + + /** + * This cron function will be executed forever, every 60 seconds. + */ + #[Cron(period: 60.0)] + public function cron1(): void + { + $this->sendMessageToAdmins("The bot is online, current time ".date(DATE_RFC850)."!"); + } + + /** + * Handle incoming updates from users, chats and channels. + */ + #[Handler] + public function handleMessage(Incoming&Message $message): void + { + // In this example code, send the "This userbot is powered by MadelineProto!" message only once per chat. + // Ignore all further messages coming from this chat. + if (!isset($this->notifiedChats[$message->chatId])) { + $this->notifiedChats[$message->chatId] = true; + + $message->reply( + message: "This userbot is powered by [MadelineProto](https://t.me/MadelineProto)!", + parseMode: ParseMode::MARKDOWN + ); + } + } + + /** + * Reposts a media file as a Telegram story. + */ + #[FilterCommand('story')] + public function storyCommand(Message & FromAdmin $message): void + { + if ($this->isSelfBot()) { + $message->reply("Only users can post Telegram Stories!"); + return; + } + $media = $message->getReply(Message::class)?->media; + if (!$media) { + $message->reply("You should reply to a photo or video to repost it as a story!"); + return; + } + + $this->stories->sendStory( + peer: 'me', + media: $media, + caption: "This story was posted using [MadelineProto](https://t.me/MadelineProto)!", + parse_mode: ParseMode::MARKDOWN, + privacy_rules: [['_' => 'inputPrivacyValueAllowAll']] + ); + } + + /** + * Automatically sends a comment to all new incoming channel posts. + */ + #[Handler] + public function makeComment(Incoming&ChannelMessage $message): void + { + if ($this->isSelfBot()) { + return; + } + $message->getDiscussion()->reply( + message: "This comment is powered by [MadelineProto](https://t.me/MadelineProto)!", + parseMode: ParseMode::MARKDOWN + ); + } + + #[FilterCommand('broadcast')] + public function broadcastCommand(Message & FromAdmin $message): void + { + // We can broadcast messages to all users with /broadcast + if (!$message->replyToMsgId) { + $message->reply("You should reply to the message you want to broadcast."); + return; + } + $this->broadcastForwardMessages( + from_peer: $message->senderId, + message_ids: [$message->replyToMsgId], + drop_author: true, + pin: true, + ); + } + + private int $lastLog = 0; + /** + * Handles updates to an in-progress broadcast. + */ + #[Handler] + public function handleBroadcastProgress(Progress $progress): void + { + if (time() - $this->lastLog > 5 || $progress->status === Status::FINISHED) { + $this->lastLog = time(); + $this->sendMessageToAdmins((string) $progress); + } + } + + #[FilterCommand('echo')] + public function echoCmd(Message $message): void + { + // Contains the arguments of the command + $args = $message->commandArgs; + + $message->reply($args[0] ?? ''); + } + + #[FilterRegex('/.*(mt?proto)[^.]?.*/i')] + public function testRegex(Incoming & Message $message): void + { + $message->reply("Did you mean to write MadelineProto instead of ".$message->matches[1].'?'); + } + + #[FilterText('test')] + public function pingCommand(Message $message): void + { + $message->reply('test reply'); + } + + #[FilterCommand('react')] + public function reactCommand(Message&IsReply $message): void + { + $message->getReply(Message::class)->addReaction('👌'); + } + + #[FilterCommand('unreact')] + public function unreactCommand(Message&IsReply $message): void + { + $message->getReply(Message::class)->delReaction('👌'); + } + + #[FilterTextCaseInsensitive('hi')] + public function pingCommandCaseInsensitive(Message $message): void + { + $message->reply('hello'); + } + + /** + * Called when the dialog photo of a chat or channel changes. + */ + #[Handler] + public function logPhotoChanged(Incoming&DialogPhotoChanged $message): void + { + if ($message->photo) { + $message->reply("Nice! Here's a download link for the photo: ".$message->photo->getDownloadLink()); + } + // The group photo was deleted + } + + /** + * Gets a download link for any file up to 4GB! + * + * The bot must be started via web for this command to work. + * + * You can also start it via CLI but you'll have to specify a download script URL in the settings: https://docs.madelineproto.xyz/docs/FILES.html#getting-a-download-link-cli-bots. + */ + #[FilterCommand('dl')] + public function downloadLink(Incoming&Message $message): void + { + $reply = $message->getReply(Message::class); + if (!$reply?->media) { + $message->reply("This command must reply to a media message!"); + return; + } + $reply->reply("Download link: ".$reply->media->getDownloadLink()); + } + + #[FilterCommand('call')] + public function callVoip(Incoming&Message $message): void + { + $this->requestCall($message->senderId)->play(new RemoteUrl('http://icestreaming.rai.it/1.mp3')); + } + + #[Handler] + public function handleIncomingCall(VoIP&Incoming $call): void + { + $call->accept()->play(new RemoteUrl('http://icestreaming.rai.it/1.mp3')); + } + + public static function getPluginPaths(): string|array|null + { + return 'plugins/'; + } +} + +$settings = new Settings; +$settings->getLogger()->setLevel(Logger::LEVEL_ULTRA_VERBOSE); + +// You can also use Redis, MySQL or PostgreSQL. +// Data is migrated automatically. +// +// $settings->setDb((new Redis)->setDatabase(0)->setPassword('pony')); +// $settings->setDb((new Postgres)->setDatabase('MadelineProto')->setUsername('daniil')->setPassword('pony')); +// $settings->setDb((new Mysql)->setDatabase('MadelineProto')->setUsername('daniil')->setPassword('pony')); + +// For users or bots +MyEventHandler::startAndLoop('bot.madeline', $settings); + +// For bots only +// MyEventHandler::startAndLoopBot('bot.madeline', 'bot token', $settings); + +``` + + + +The example code above defines an event handler class `MyEventHandler`, creates a MadelineProto session, and sets the event handler class to our newly created event handler. + +The **new** `startAndLoop` method automatically initializes MadelineProto, **enables async**, logs in the user/bot, initializes error reporting, catches and reports all errors surfacing from the event loop to the peers returned by the `getReportPeers` method. + +All events are handled concurrently thanks to async, [here's a full explanation](ASYNC.html). + +All incoming events are **always handled**, **including old events that occurred while the script was turned off**. + +To access the `$MadelineProto` instance inside of the event handler, simply access `$this`: +```php +$this->messages->sendMessage(['peer' => '@danogentili', 'message' => 'hi']); +``` + +### Bound methods + +MadelineProto offers a large number of helper bound methods and properties, depending on the filter type you specify in the typehint of `#[Handler]` methods. + +See [here »](https://docs.madelineproto.xyz/docs/FILTERS.html#simple-filters) for more info on how to use bound methods, properties and filters. + +Here's a full list of the concrete object types on which bound methods and properties are defined: + + + +* [danog\MadelineProto\Broadcast\Progress »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html) - Broadcast progress. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html#method-list) +* [danog\MadelineProto\EventHandler\AbstractMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html) - Represents an incoming or outgoing message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractMessage.html#method-list) +* [danog\MadelineProto\EventHandler\AbstractPrivateMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html) - Represents a private or secret chat message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractPrivateMessage.html#method-list) +* [danog\MadelineProto\EventHandler\AbstractStory »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractStory.html) - Represents a Telegram Story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractStory.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/AbstractStory.html#method-list) +* [danog\MadelineProto\EventHandler\BotCommands »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html) - The [command set](https://core.telegram.org/api/bots/commands) of a certain bot in a certain chat has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html#method-list) +* [danog\MadelineProto\EventHandler\CallbackQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html) - Represents a query sent by the user by clicking on a button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/CallbackQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\ChannelParticipant »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html) - A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\MessageForwards »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html) - Indicates that the forward counter of a message in a channel has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageForwards.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\MessageViewsChanged »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html) - Indicates that the view counter of a message in a channel has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/MessageViewsChanged.html#method-list) +* [danog\MadelineProto\EventHandler\Channel\UpdateChannel »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html) - A new channel is available, or info about an existing channel was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/UpdateChannel.html#method-list) +* [danog\MadelineProto\EventHandler\ChatInviteRequester »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html) - Indicates someone has requested to join a chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester.html#method-list) +* [danog\MadelineProto\EventHandler\ChatInviteRequester\BotChatInviteRequest »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html) - Indicates someone has requested to join a chat or channel (bots only). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/BotChatInviteRequest.html#method-list) +* [danog\MadelineProto\EventHandler\ChatInviteRequester\PendingJoinRequests »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html) - Someone has requested to join a chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/ChatInviteRequester/PendingJoinRequests.html#method-list) +* [danog\MadelineProto\EventHandler\Delete »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete.html) - Indicates that some messages were deleted. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete.html#method-list) +* [danog\MadelineProto\EventHandler\Delete\DeleteChannelMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html) - Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) were deleted. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Delete\DeleteMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html) - Some messages were deleted in a private chat or simple group. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Delete\DeleteScheduledMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html) - Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) were deleted from the schedule queue of a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html#method-list) +* [danog\MadelineProto\EventHandler\InlineQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/InlineQuery.html) - An incoming inline query. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/InlineQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/InlineQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Message »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message.html) - Represents an incoming or outgoing message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message.html#method-list) +* [danog\MadelineProto\EventHandler\Message\ChannelMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html) - Represents an incoming or outgoing channel message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ChannelMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\GroupMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html) - Represents an incoming or outgoing group message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/GroupMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\PrivateMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html) - Represents an incoming or outgoing private message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/PrivateMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\SecretMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html) - Represents New encrypted message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/SecretMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\ServiceMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html) - Represents info about a service message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\ServiceMessage »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html) - Represents info about a service message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/ServiceMessage.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogBotAllowed »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html) - We have given the bot permission to send us direct messages. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogBotAllowed.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChannelCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html) - The channel was created. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelCreated.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChannelMigrateFrom »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html) - Indicates the channel was [migrated](https://core.telegram.org/api/channel) from the specified chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChatJoinedByLink »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html) - A user joined the chat via an invite link. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatJoinedByLink.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogChatMigrateTo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html) - Indicates the chat was [migrated](https://core.telegram.org/api/channel) to the specified supergroup. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogContactSignUp »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html) - A contact just signed up to telegram. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogContactSignUp.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html) - A chat or channel was created. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogCreated.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogDeleteMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html) - Deleted messages. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogDeleteMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGameScore »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html) - Someone scored in a game. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGameScore.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGeoProximityReached »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html) - A user of the chat is now in proximity of another user. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGeoProximityReached.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGiftPremium »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html) - Info about a gifted Telegram Premium subscription. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGiftPremium.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html) - Represents a service message about a group call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCall »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html) - The group call has started or ended. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCall.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallInvited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html) - A set of users was invited to the group call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallInvited.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogGroupCall\GroupCallScheduled »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html) - A group call was scheduled. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogGroupCall/GroupCallScheduled.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogHistoryCleared »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html) - Chat history was cleared. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogHistoryCleared.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMemberJoinedByRequest »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html) - A user was accepted into the group by an admin. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberJoinedByRequest.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMemberLeft »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html) - A member left the chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMemberLeft.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMembersJoined »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html) - Some members joined the chat or channel. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMembersJoined.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogMessagePinned »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html) - A message was pinned in a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogMessagePinned.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogPeerRequested »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html) - Contains info about a peer that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogPhoneCall »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html) - A phone call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhoneCall.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogPhotoChanged »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html) - The photo of the dialog was changed or deleted. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPhotoChanged.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogReadMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html) - Messages marked as read. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogReadMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogScreenshotTaken »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html) - A screenshot of the chat was taken. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogScreenshotTaken.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSetChatTheme »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html) - The chat theme was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatTheme.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSetChatWallPaper »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html) - The [wallpaper](https://core.telegram.org/api/wallpapers) of the current chat was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSetTTL »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html) - The Time-To-Live of messages in this chat was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetTTL.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogSuggestProfilePhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html) - A new profile picture was suggested using [photos.uploadContactProfilePhoto](https://docs.madelineproto.xyz/API_docs/methods/photos.uploadContactProfilePhoto.html). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogTitleChanged »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html) - The title of a channel or group has changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTitleChanged.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html) - A [forum topic](https://core.telegram.org/api/forum#forum-topics) was created. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) - [Forum topic](https://core.telegram.org/api/forum#forum-topics) information was edited. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html#method-list) +* [danog\MadelineProto\EventHandler\Message\Service\DialogWebView »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html) - Data from an opened [reply keyboard bot web app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user & bot side service message). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned.html) - Indicates that some messages were pinned/unpinned. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned\PinnedChannelMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html) - Represents messages that were pinned/unpinned in a [channel](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned\PinnedGroupMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html) - Represents messages that were pinned/unpinned in a [chat/supergroup](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Pinned\PinnedPrivateMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html) - Some messages were pinned in a private chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedPrivateMessages.html#method-list) +* [danog\MadelineProto\EventHandler\Privacy »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Privacy.html) - Indicates some privacy rules for a user or set of users. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Privacy.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Privacy.html#method-list) +* [danog\MadelineProto\EventHandler\Query\ButtonQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html) - Represents a query sent by the user by clicking on a button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ButtonQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\ChatButtonQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html) - Represents a query sent by the user by clicking on a button in a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatButtonQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\ChatGameQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html) - Represents a query sent by the user by clicking on a "Play game" button in a chat. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/ChatGameQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\GameQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html) - Represents a query sent by the user by clicking on a "Play game" button. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/GameQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\InlineButtonQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html) - Represents a query sent by the user by clicking on a button in an inline message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineButtonQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Query\InlineGameQuery »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html) - Represents a query sent by the user by clicking on a "Play game" button in an inline message. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Query/InlineGameQuery.html#method-list) +* [danog\MadelineProto\EventHandler\Story\Story »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/Story.html) - Represents a Telegram story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/Story.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/Story.html#method-list) +* [danog\MadelineProto\EventHandler\Story\StoryDeleted »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html) - Represents a deleted story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryDeleted.html#method-list) +* [danog\MadelineProto\EventHandler\Story\StoryReaction »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html) - Represents a reaction to a story. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Story/StoryReaction.html#method-list) +* [danog\MadelineProto\EventHandler\Typing »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing.html) - A user is typing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\ChatUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html) - The user is preparing a message in a group; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/ChatUserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\SecretUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html) - The user is preparing a message in a secret chat; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SecretUserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\SupergroupUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html) - A user is typing in a [supergroup](https://core.telegram.org/api/channel). + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\Typing\UserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html) - The user is preparing a message; typing, recording, uploading, etc. This update is valid for 6 seconds. If no further updates of this kind are received after 6 seconds, it should be considered that the user stopped doing whatever they were doing. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/UserTyping.html#method-list) +* [danog\MadelineProto\EventHandler\User\Blocked »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Blocked.html) - A peer was blocked. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Blocked.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Blocked.html#method-list) +* [danog\MadelineProto\EventHandler\User\BotStopped »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html) - A bot was stopped or re-started. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/BotStopped.html#method-list) +* [danog\MadelineProto\EventHandler\User\Phone »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Phone.html) - A user’s phone number was changed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Phone.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Phone.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status.html) - Contains a status update. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Emoji »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html) - The [emoji status](https://core.telegram.org/api/emoji-status) of a certain user has changed or was removed. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\EmptyStatus »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html) - User status has not been set yet. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/EmptyStatus.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\LastMonth »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html) - Online status: last seen last month. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastMonth.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\LastWeek »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html) - Online status: last seen last week. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/LastWeek.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Offline »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html) - The user’s offline status. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Offline.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Online »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html) - Online status of the user. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Online.html#method-list) +* [danog\MadelineProto\EventHandler\User\Status\Recently »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html) - Online status: last seen recently. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Recently.html#method-list) +* [danog\MadelineProto\EventHandler\User\Username »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Username.html) - Changes were made to the user’s first name, last name or username. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Username.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Username.html#method-list) +* [danog\MadelineProto\VoIP »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) - This update represents a VoIP Telegram call. + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html#method-list) + + + + + +### Filters + +MadelineProto offers three different filter types, used to filter updates by type or other attributes, click on the following links for more info: + +* [Simple filters »](https://docs.madelineproto.xyz/docs/FILTERS.html#simple-filters) +* [Attribute filters »](https://docs.madelineproto.xyz/docs/FILTERS.html#attribute-filters) +* [MTProto filters »](https://docs.madelineproto.xyz/docs/FILTERS.html#mtproto-filters) + +### Plugins + +Plugins are also supported, check out the [plugin docs »](https://docs.madelineproto.xyz/docs/PLUGINS.html) for more info! + +### Cron + +All event handler methods marked by the `danog\MadelineProto\EventHandler\Attributes\Cron` attribute are periodically invoked by MadelineProto every `period` seconds: + +```php +use danog\MadelineProto\EventHandler\Attributes\Cron; + +class MyEventHandler extends SimpleEventHandler +{ + /** + * This cron function will be executed forever, every 60 seconds. + */ + #[Cron(period: 60.0)] + public function cron1(): void + { + $this->sendMessageToAdmins("The bot is online, current time ".date(DATE_RFC850)."!"); + } +} +``` + +You can also specify millisecond intervals like `0.5` (500 milliseconds). + +MadelineProto's crons are based on the [danog/loop](https://daniil.it/loop) library: the associated PeriodicLoop instance that can be used to stop or restart the loop is passed as first parameter to the cron, and can also be fetched using `$this->getPeriodicLoop('methodName')`, in this case `$this->getPeriodicLoop('cron1')`. + +### Persisting data and IPC + +All property names returned by the `__sleep` method will be saved in the database/session file, and then automatically loaded when the bot is restarted. + + + +```php +getPlugin(PingPlugin::class); + * + * $plugin->setPongText('UwU'); + * ``` + * + * This will automatically connect to the running instance of the plugin and call the specified method. + */ + public function setPongText(string $pong): void + { + $this->pongText = $pong; + } + + /** + * Returns a list of names for properties that will be automatically saved to the session database (MySQL/postgres/redis if configured, the session file otherwise). + */ + public function __sleep(): array + { + return ['pingCount', 'pongText']; + } + /** + * Initialization logic. + */ + public function onStart(): void + { + $this->logger("The bot was started!"); + $this->logger($this->getFullInfo('MadelineProto')); + + $this->sendMessageToAdmins("The bot was started!"); + } + + /** + * Plugins may be enabled or disabled at startup by returning true or false from this function. + */ + public function isPluginEnabled(): bool + { + return true; + } + + /** + * This cron function will be executed forever, every 60 seconds. + */ + #[Cron(period: 60.0)] + public function cron1(): void + { + $this->sendMessageToAdmins("The ping plugin is online, total pings so far: ".$this->pingCount); + } + + #[FilterText('ping')] + public function pingCommand(Incoming&Message $message): void + { + $message->reply($this->pongText); + $this->pingCount++; + } +} + +``` + + + +You can read and write to those properties from the outside using getter and setter methods, for example: + +```php +use danog\MadelineProto\API; +use MadelinePlugin\Danogentili\PingPlugin; + +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$a = new API('bot.madeline'); + +$handler = $a->getEventHandler(PingPlugin::class); + +$handler->setPongText('UwU'); +``` + +#### Built-in ORM + +You can also directly connect to any database using the same [async MySQL/Postgres/Redis ORM](DATABASE.html) used by MadelineProto internally, [danog/AsyncOrm](https://github.com/danog/AsyncOrm)! + +To do so, simply [specify the database settings](DATABASE.html), and use the `OrmMappedArray` attribute to initialize the async database mapper: +```php + +use danog\AsyncOrm\Annotations\OrmMappedArray; +use danog\AsyncOrm\DbArray; +use danog\AsyncOrm\KeyType; +use danog\AsyncOrm\ValueType; +use danog\MadelineProto\SimpleEventHandler; + +class MyEventHandler extends SimpleEventHandler { + /** + * @var DbArray + * + * This ORM property is also persisted to the database, and is *not* fully kept in RAM at all times. + * + * You can also provide more specific type parameters (i.e. ; etc), + * as well as custom caching settings. + * + * See https://github.com/danog/AsyncOrm for full documentation and more examples. + */ + #[OrmMappedArray(KeyType::STRING, ValueType::INT)] + protected DbArray $ormProperty; + + /** + * This raw property is also persisted to the database, but is always kept in RAM at all times. + */ + private array $rawProperty = []; + + /** + * Returns a list of names for properties that will be automatically saved to the session database (MySQL/postgres/redis if configured, the session file otherwise). + */ + public function __sleep(): array + { + return ['ormProperty', 'rawProperty']; + } + // ... +} +``` + +And use the newly created `$dataStoredOnDb` property to access the database: +```php +// Can be anything serializable, an array, an int, an object +$myData = []; + +// Use the isset method to check whether some data exists in the database +if (isset($this->dataStoredOnDb['yourKey'])) { + // Always when fetching data + $myData = $this->dataStoredOnDb['yourKey']; +} +$this->dataStoredOnDb['yourKey'] = 123; + +$this->dataStoredOnDb['otherKey'] = 0; +unset($this->dataStoredOnDb['otherKey']); + +$this->logger("Count: ".count($this->dataStoredOnDb)); + +foreach ($this->dataStoredOnDb as $key => $value) { + $this->logger($key); + $this->logger($value); +} +``` + +[Psalm](https://psalm.dev) generic typing is supported. + +Each element of the array is stored in a separate database row (MySQL, Postgres or Redis, configured as specified [here »](https://docs.madelineproto.xyz/docs/DATABASE.html)), and is only kept in memory for the number of seconds specified in the cache TTL setting; when the TTL of an element expires, it is individually flushed to the database (if its value was changed), and then the row is removed from RAM. + +Pros of using ORM `DbArray` properties instead of raw properties: + +* Much lower RAM usage, as the entire array is **not** kept in RAM at all times, only the most frequently used elements, according to the configured TTL. +* Added possibility of storing even gigabytes of data in a single `DbArray`, without keeping it all in memory. +* If caching is disabled, the array is **never** kept in RAM, significantly hindering performance but further reducing RAM usage for truly **huge** elements (gigabyte-level). + +Cons of using ORM `DbArray` properties: + +* Reads and writes are not atomic. Since each handler is started in a concurrent green thread (fiber), race conditions may ensue, thus accesses must be syncronized where and if needed using [amphp/sync](https://github.com/amphp/sync). +* Slower than raw properties (**much** slower if caching is fully disabled). + +Both raw properties and ORM `DbArray` properties are ultimately persisted on the database. + +If no database is configured in the global settings, ORM properties behave pretty much like raw array properties, kept entirely in RAM and persisted to the session file. + +### IPC + +You can communicate with the event handler from the outside, by invoking methods on the proxy returned by getEventHandler: + +bot.php: + +```php +getEventHandler(MyEventHandler::class); + +$handler->someMethod(); +``` + +### Restarting + +To forcefully restart and apply changes made to the event handler class, call `$this->restart();`. + +When running via cli, the bot must run in the official [docker image](https://docs.madelineproto.xyz/docs/DOCKER.html) with `restart: always` or inside of a bash while true loop in order for `restart()` to work. + +### Self-restart on webhosts + +When running the event handler via web, MadelineProto will automatically enable a **magical self-restart hack** (callback ID `restarter`), to keep the bot running even on webhosts with limited execution time. + +Locking will also be handled automatically (as well as disconnection from the user that opened the page), so even if you start the script via web several times, only one instance will be running at a time (no need to do flocking manually!). + +>Please note that this self-restart logic may fail in case of a physical server reboot or web server/php-fpm restart, so it's always a better idea to run via CLI, or use a cron to periodically ping the bot's URL. + +It relies on the shutdown function, so you must not set a custom shutdown function in your code, and instead use the **MadelineProto shutdown static API**: + +```php +use danog\MadelineProto\Shutdown; + +$id = Shutdown::addCallback(static function () { + // This function will run on shutdown +}); + +$id = Shutdown::addCallback(static function () { + // This function will run on shutdown +}, 'custom id'); + +$id = Shutdown::addCallback(static function () { + // This function will overwrite the previously set function with custom id +}, 'custom id'); + +$ok = Shutdown::removeCallback($id); +``` + +You can of course pass non-static functions, any type of callable is accepted. +A second optional parameter can also be accepted, containing the ID of the callable: you can use this if you want to later overwrite the callable with another callback, or remove it altogether. + +The `removeCallback` will return true if the callback exists and it was removed correctly, false otherwise. + + +### Multiaccount + +```php +use danog\MadelineProto\EventHandler; +use danog\MadelineProto\Tools; +use danog\MadelineProto\API; +use danog\MadelineProto\Logger; + +// Normal event handler definition as above + +$MadelineProtos = []; +foreach ([ + 'bot.madeline' => 'Bot Login', + 'user.madeline' => 'Userbot login', + 'user2.madeline' => 'Userbot login (2)' +] as $session => $message) { + $MadelineProtos []= new API($session); +} + +API::startAndLoopMulti($MadelineProtos, MyEventHandler::class); +``` + +This will create an event handler class `EventHandler`, create a **combined** MadelineProto session with session files `bot.madeline`, `user.madeline`, `user2.madeline`, and set the event handler class to our newly created event handler. + +Usage is the same as for [the normal event handler](#async-event-driven), with the difference is that multiple accounts can receive and handle updates in parallel, each with its own event handler instance. + +Errors thrown inside of the event loop will be reported to the report peers specified by each separate instance. + +Note that for performance reasons, some internal or connection exceptions not thrown from the EventHandler and exceptions thrown from `onStart` may still get reported (only to, or also to) the last started event handler. + +To dynamically start a new event handler in the background, use `EventLoop::queue(MyEventHandler::startAndLoop(...), 'session.madeline', $settings))`. + +**Warning**: this can only be done with already logged-in sessions, if your sessions aren't logged in yet use `startAndLoopMulti`, or login first. + +```php +use danog\MadelineProto\EventHandler; +use danog\MadelineProto\Tools; +use Revolt\EventLoop; + +// Normal event handler definition as above + +foreach ([ + 'bot.madeline' => 'Bot Login', + 'user.madeline' => 'Userbot login', + 'user2.madeline' => 'Userbot login (2)' +] as $session => $message) { + EventLoop::queue(MyEventHandler::startAndLoop(...), $session); +} + +EventLoop::run(); // Or continue using some other async code... +``` + +### Automatic static analysis + +MadelineProto will automatically analyze the event handler code, blocking execution if performance or security issues are detected! + +For example, the following functions and classes are **banned**, and the specified async counterparts must be used, instead: + +* `file_get_contents`, `file_put_contents`, `fopen` - Please use https://github.com/amphp/file or https://github.com/amphp/http-client, instead +* `curl_exec` - Please use https://github.com/amphp/http-client, instead +* `mysqli_query`, `mysqli_connect`, `mysql_connect`, `PDO`, `mysqli` - Please use https://github.com/amphp/mysql or https://github.com/amphp/postgres, instead +* `fsockopen` - Please use https://github.com/amphp/socket, instead + + +### Avoiding the use of filesystem functions + +For performance reasons, it is heavily *recommended* you **do not** read files from the filesystem at all, even using async functions. + +MadelineProto does not block the usage of async file functions, but 99% of the time they can be replaced with a much faster alternative. + +Here's a list of common uses for files, and what they can be replaced with: + +* [Configuration](#configuration) +* [Creating and uploading text files](#creating-and-uploading-text-files) +* [Logging](#logging) + +#### Configuration + +Configuration can be done entirely using persistent properties, for example **DON'T** do this: + +```php +account->updateStatus(offline: false); + } else { + $this->account->updateStatus(offline: true); + } + } +} +``` + +Do this, instead: + + + +```php +isOnline = $online; + } + + public function isPluginEnabled(): bool + { + // Only users can be online/offline + return $this->getSelf()['bot'] === false; + } + + #[Cron(period: 60.0)] + public function cron(): void + { + $this->account->updateStatus(offline: !$this->isOnline); + } + + #[FilterCommand('online')] + public function toggleOnline(Incoming&Message&FromAdmin $message): void + { + $this->isOnline = true; + } + + #[FilterCommand('offline')] + public function toggleOffline(Incoming&Message&FromAdmin $message): void + { + $this->isOnline = false; + } +} + +``` + + + +And, to toggle the settings from the outside of the bot (for example using a helper bot, or another program): + +```php +getEventHandler(\MadelinePlugin\Danogentili\OnlinePlugin::class)->setOnline($online); +``` + +#### Creating and uploading text files + +Instead of writing to a file and then uploading it, you can use a `ReadableBuffer` to upload a file from a string, instead: + +```php +use Amp\ReadableBuffer; + +$contents = "Something"; + +$this->sendDocument( + peer: 'danogentili', + file: new ReadableBuffer($contents) +); +``` + +#### Logging + +Instead of logging to separate files, you can use MadelineProto's built-in logger, which will write everything to `MadelineProto.log`: + +```php +$this->logger("Some text"); +``` + +You can also use the new `openFileAppendOnly` function, to open a file in write-only append-only mode in onStart and use it in your bot. +You may also wrap the `File` resource returned by openFileAppendOnly in a proper PSR logger using [amphp/log](https://github.com/amphp/log). + +```php +use danog\MadelineProto\SimpleEventHandler; +use danog\MadelineProto\Tools; +use Amp\Log\ConsoleFormatter; +use Amp\Log\StreamHandler; +use Monolog\Logger; + +class MyEventHandler extends SimpleEventHandler { + private Logger $customLogger; + public function onStart() + { + // As documented in https://github.com/amphp/log + $handler = new StreamHandler(Tools::openFileAppendOnly('file.log')); + + $this->customLogger = new Logger('main'); + $this->customLogger->pushHandler($handler); + } + + public function someOtherMethod(): void { + $this->customLogger->debug("Hello, world!"); + $this->customLogger->info("Hello, world!"); + $this->customLogger->notice("Hello, world!"); + $this->customLogger->error("Hello, world!"); + $this->customLogger->alert("Hello, world!"); + } +} +``` + +## Noop + +```php +$MadelineProto = new \danog\MadelineProto\API('bot.madeline'); + +$MadelineProto->start(); +$MadelineProto->setNoop(); +``` +When an [Update](https://docs.madelineproto.xyz/API_docs/types/Update.html) is received, nothing is done. This is useful if you need to populate the internal peer database with peers to avoid `This peer is not present in the internal peer database errors`, but don't need to handle updates. +This is the default. + +## Webhook + +Useful when consuming MadelineProto updates through an API, **not recommended when directly writing MadelineProto bots**. + +Webhooks will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + +Webhooks must **only** be used when consuming MadelineProto updates from another programming language, like for example **Javascript**. + +If your bot is written in PHP, [use the event handler, instead](https://docs.madelineproto.xyz/docs/UPDATES.html). + +```php +$MadelineProto = new \danog\MadelineProto\API('bot.madeline'); + +// NOT recommended when directly writing MadelineProto bots. +// ONLY use when exposing updates via an HTTP API to another language (like Javascript). + +$MadelineProto->setWebhook('https://example.com'); +``` + +## getUpdates + +Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**. + +`getUpdates` will **greatly slow down your bot** if used directly inside of PHP code. + +**Only use the [event handler](#async-event-driven) when writing a MadelineProto bot**, because update handling in the **event handler** is completely parallelized and non-blocking. + +`getUpdates` must **only** be used when consuming MadelineProto updates from another programming language, like for example **Javascript**. + +If your bot is written in PHP, [use the event handler, instead](https://docs.madelineproto.xyz/docs/UPDATES.html). + +```php +$MadelineProto = new \danog\MadelineProto\API('bot.madeline'); + +// NOT recommended when directly writing MadelineProto bots. +// ONLY use when exposing updates via an HTTP API to another language (like Javascript). + +// DO NOT use this to handle updates in PHP code, it will cause crashes. + +// Same parameters as for bot API getUpdates +echo json_encode($MadelineProto->getUpdates($_GET)); +``` + +Next section \ No newline at end of file diff --git a/docs/docs/UPDATES_INTERNAL.md b/docs/docs/UPDATES_INTERNAL.md new file mode 100644 index 0000000000..e2eb91d605 --- /dev/null +++ b/docs/docs/UPDATES_INTERNAL.md @@ -0,0 +1,29 @@ +--- +title: Working with updates in MTProto +description: Apart from the basic operations required to work with MTProto update sequences, implementations also have to take care to postpone updates received via the socket while filling gaps in the event and Update sequences, as well as avoid filling gaps in the same sequence. +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- + +# Working with updates in MTProto + +Apart from the basic operations [required to work with MTProto update sequences](https://core.telegram.org/api/updates), implementations also have to take care to postpone updates received via the socket while filling gaps in the event and Update sequences, as well as avoid filling gaps in the same sequence. + +An interesting and easy way this can be implemented, instead of using various locks, is by running background threads, like in [MadelineProto](https://github.com/danog/MadelineProto/tree/v8/src/Loop/Update). + +* A background _feeder_ thread for each [sequence](#event-sequences), associated to a FIFO queue is initialized and then paused ([event sequence FeedLoop](https://github.com/danog/MadelineProto/blob/2672728fe3b7ddbc03c59299e2483e6708919896/src/Loop/Update/FeedLoop.php), [common sequence SeqLoop](https://github.com/danog/MadelineProto/blob/2672728fe3b7ddbc03c59299e2483e6708919896/src/Loop/Update/SeqLoop.php)). +* Another set of _updater_ threads is started: one for the common [sequence](#event-sequences), one for each channel [sequence](#event-sequences) ([UpdateLoop](https://github.com/danog/MadelineProto/blob/2672728fe3b7ddbc03c59299e2483e6708919896/src/Loop/Update/UpdateLoop.php)). + +When a getDifference is requested, a signal resumes the _updater_ thread, which starts fetching difference until the gap is filled, then it pauses itself again. + +When a new Updates constructor or event is received, it is added to the FIFO queue of the correspondent _feeder_ thread, and a signal is sent to said thread. +The signal wakes up the thread, which starts parsing the queued events: as per [update handling](#update-handling), duplicates are eliminated, correct events are accepted and the [state](#fetching-state) is updated. +When a gap is encountered, the _updater_ thread is resumed: the _feeder_ thread waits until the _updater_ thread is paused again. +Finally, the manually fetched difference is prepended to the _feeder_ FIFO queue, to parse it before any additional update that was fetched from the socket while fetching the difference. + +The simplicity of this approach is in its sequentiality: + +* Each thread can only execute one action at a time. +* Each event is fetched one by one from the FIFO queue +* Threads cannot start handling a new event received from the socket while fetching the difference, or while still handling the previous one +* Only one part of the application at a time can trigger a getDifference, to avoid re-fetching and re-saving the same difference twice. diff --git a/docs/docs/UPGRADING.md b/docs/docs/UPGRADING.md new file mode 100644 index 0000000000..4cbc8e138d --- /dev/null +++ b/docs/docs/UPGRADING.md @@ -0,0 +1,273 @@ +--- +title: "Upgrading from MadelineProto v7 to v8" +description: "MadelineProto v8 is a major MadelineProto update, that removes a large number of long-deprecated APIs: I've created this upgrade checklist, to simplify the upgrade process." +nav_order: 29 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Upgrading from MadelineProto v7 to v8 + +MadelineProto v8 is a major MadelineProto update, that removes a large number of long-deprecated APIs: I've created this upgrade checklist, to simplify the upgrade process. + +A much simpler way to check for backwards incompatible changes is to scan your project using [Psalm](https://psalm.dev), it's truly a lifesaver! + +Make sure to recreate the session too, as v7 sessions are not compatible with v8. + +## Settings + +The main breaking change is the removal of array settings, deprecated since v6. +You can use object settings, instead, see [here »](https://docs.madelineproto.xyz/docs/SETTINGS.html) for the full documentation, here's a brief conversion example: + +Before: + +```php +$settings = ['app_info' => ['api_id' => 123456, 'api_hash' => 'xxx']]; +``` + +After: + +```php +$settings = (new \danog\MadelineProto\Settings\AppInfo) + ->setApiId(123456) + ->setApiHash('xxx'); +``` + +See [here »](https://docs.madelineproto.xyz/docs/SETTINGS.html) for the full list of MadelineProto v8 settings. + +Please note that since v8, usage of invalid setting setters and getters will throw an exception (in v7 those usages were simply ignored). + +## Amp v3 + +MadelineProto v8 switches to using fibers and Amp v3 libraries. + +Check out the changelogs of the [amphp](https://github.com/amphp/) libraries for a list of breaking changes introduced with the update of Amp v3. + +Regarding MadelineProto, `yield` support in the event handler was removed and the `async` and `loop` methods were removed, along with all the Generator combinator methods (`Tools::after`, `Tools::all`, `Tools::any`, `Tools::first`, et cetera). + +Instead, you can use the new async Amp v3 APIs, which do not require special keywords like `yield` anymore! + +Before: + +```php +class MyEventHandler { + public function onUpdateNewMessage(array $update): \Generator + { + $this->callForkDefer(function () { + yield $this->sleep(1.0); + yield $this->messages->sendMessage(...); + }); + yield $this->messages->sendMessage(...); + } +} +``` + +After: + +```php +use Revolt\EventLoop; +use Amp\delay; + +class MyEventHandler { + public function onUpdateNewMessage(array $update): void + { + EventLoop::queue(function () { + delay(1.0); + $this->messages->sendMessage(...); + }); + $this->messages->sendMessage(...); + } +} +``` + +Before: + +```php +$API = new \danog\MadelineProto\API('session.madeline'); +$API->async(true); +$API->loop(function () use ($API) { + yield $API->messages->sendMessage(); +}); +``` + +After: + +```php +$API = new \danog\MadelineProto\API('session.madeline'); +$API->messages->sendMessage(); +``` + + +## Loop API + +The `danog/loop` library was refactored, making it much more stable, and fixing some coroutine leaks which may have occurred in certain conditions. + +All loop classes were moved to the `danog\Loop` namespace, and the API now works with seconds instead of milliseconds. + +Before: + +```php +use \danog\Loop\Generic\GenericLoop; + +class ZeusHandler extends EventHandler +{ + public function genLoop() + { + yield $this->account->updateStatus([ + 'offline' => false + ]); + return 20 * 1000; + } + public function onStart() + { + $genLoop = new GenericLoop([$this, 'genLoop'], 'update Status'); + $genLoop->start(); + } +} +``` + +After: + +```php +use \danog\Loop\GenericLoop; + +class ZeusHandler extends EventHandler +{ + public function genLoop(): ?float + { + $this->account->updateStatus([ + 'offline' => false + ]); + return 20.0; + } + public function onStart() + { + $genLoop = new GenericLoop($this->genLoop(...), 'update Status'); + $genLoop->start(); + } +} +``` + + +## Event handler + +- Removed the long-deprecated `setEventHandler` and `$MadelineProto->startAndLoop` methods, you should use `MyEventHandler::startAndLoop`, instead. +- Removed support for the deprecated onLoop method. + +Most importantly, the `EventHandler` class was deprecated, please use the `SimpleEventHandler` class now. + +The `SimpleEventHandler` class still supports the legacy `onUpdatexxx` event handler methods, however starting from v8 **they are not covered by the backwards compatibility promise anymore**. + +This means that the structure of updates received in `onUpdatexxx` event handler methods will change at any time, including in minor versions of MadelineProto v8: fields will be removed and changed with only a minor note will be added to the changelog. + +The new [filter-based event API »](https://docs.madelineproto.xyz/docs/FILTERS.html) should be used instead of `onUpdatexxx` methods: it's much simpler to use, and **is** covered by the backwards compatibility promise, so its fields will **not** change or be removed in minor versions of MadelineProto v8. + + +```php +class MyEventHandler extends \danog\MadelineProto\EventHandler { + +} + +$settings = ['app_info' => ['api_id' => 123456, 'api_hash' => 'xxx']]; +$API = new \danog\MadelineProto\API('bot.madeline', $settings); +$API->startAndLoop(MyEventHandler::class); +``` + +After: + +```php +class MyEventHandler extends \danog\MadelineProto\SimpleEventHandler { + +} + +$settings = (new \danog\MadelineProto\Settings\AppInfo) + ->setApiId(123456) + ->setApiHash('xxx'); +MyEventHandler::startAndLoop('bot.madeline', $settings); +``` + +Also, MadelineProto will actively prevent new event handler code from using blocking functions like `file_get_contents`, `file_put_contents`, `curl`: see [here »](https://docs.madelineproto.xyz/docs/UPDATES.html#automatic-static-analysis) for a more detailed list of async alternatives. + +## No more snake_case methods + +You can't use `snake_case` variants of MadelineProto methods anymore (deprecated since v5). + +Before: + +```php +$info = $API->get_info('danogentili'); +$me = $API->get_self(); +``` + +After: + + +```php +$info = $API->getInfo('danogentili'); +$me = $API->getSelf(); +``` + +## Full breaking changelog + +- [BC] REMOVED: the `getDialogs` method, please use the `getDialogIds` method, instead. +- [BC] CHANGED: all `peerUser`, `peerChat`, `peerChannel` constructors were replaced with integer IDs. +- [BC] REMOVED: internal `Input*` fields returned by `getInfo` +- [BC] REMOVED: the long-deprecated `setEventHandler` method, you should use `MyEventHandler::startAndLoop`, instead. +- [BC] REMOVED: the deprecated $MadelineProto->startAndLoop method. Please use MyEventHandler::startAndLoop instead, remove any new \danog\MadelineProto\API line you have in your code if you're using only the event handler. +- [BC] REMOVED: support for the deprecated onLoop method. +- [BC] REMOVED: the setCallback update handling method, please use the event handler with onAny instead. +- [BC] REMOVED: Promise wrapper types from return types everywhere. +- [BC] REMOVED: Removed the legacy MadelineProto Loop APIs, the new github.com/danog/loop APIs do not support generators anymore. +- [BC] REMOVED: Removed support for the long-deprecated snake_case methods, now only camelCase is supported (get_info will not work, only getInfo; and so on). +- [BC] REMOVED: Method danog\MadelineProto\VoIP#whenCreated() was removed +- [BC] REMOVED: Method danog\MadelineProto\StrTools::methodEscape() was removed +- [BC] REMOVED: Method danog\MadelineProto\StrTools::typeEscape() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::after() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::all() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::any() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::callForkDefer() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::call() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::first() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::getVar() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::hasVar() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::setVar() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::some() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::timeout() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::timeoutWithDefault() was removed +- [BC] REMOVED: Method danog\MadelineProto\Tools::wait() was removed +- [BC] REMOVED: Method danog\MadelineProto\Wrappers\Events#setEventHandler() was removed +- [BC] REMOVED: Method danog\MadelineProto\Wrappers\Loop#loopFork() was removed +- [BC] REMOVED: Method danog\MadelineProto\Wrappers\Loop#loop() was removed +- [BC] CHANGED: the isSupergroup, toSupergroup, fromSupergroup methods to a DialogId class, which also has many other useful methods to work with bot API IDs. +- [BC] CHANGED: All download methods except for downloadToFile and downloadToDir now return null instead of true. +- [BC] CHANGED: All `danog\MadelineProto\VoIP` constants were replaced with the `danog\MadelineProto\VoIP\CallState`, `danog\MadelineProto\VoIP\VoIPState` enums. +- [BC] CHANGED: The `danog\MadelineProto\VoIP` class was completely refactored, check out the [new API](docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) for more info. +- [BC] CHANGED: ORM properties can directly be iterated upon in a foreach without using getIterator (which will not return an amphp iterator anymore). +- [BC] CHANGED: Finalized a lot of classes that were mistakenly not marked as final. +- [BC] CHANGED: Made some internal details fully private. +- [BC] CHANGED: The session is now contained in a directory, instead of separate files. +- [BC] CHANGED: Automatic API ID fetching via the my.telegram.org wrapper was temporarily removed due to possible IP bans on webhosts. +- [BC] CHANGED: onStart now blocks all updates until it finishes executing. Use the amphp async primitives to start long-running processes in onStart like starting a webserver. +- [BC] CHANGED: You can't assign arbitrary properties to an API instance anymore. +- [BC] CHANGED: Switched to a custom markdown parser with bot API [MarkdownV2](https://core.telegram.org/bots/api#markdownv2-style) syntax, which differs from the previous Markdown syntax supported by parsedown. +- [BC] CHANGED: Markdown text can't contain HTML anymore. +- [BC] CHANGED: danog\MadelineProto\StrTools::methodEscape() was marked "@internal" +- [BC] CHANGED: danog\MadelineProto\StrTools::typeEscape() was marked "@internal" +- [BC] CHANGED: danog\MadelineProto\Tools::getVar() was marked "@internal" +- [BC] CHANGED: danog\MadelineProto\Tools::setVar() was marked "@internal" +- [BC] CHANGED: Parameter 0 of danog\MadelineProto\Tools::callFork() changed name from promise to callable +- [BC] CHANGED: Parameter 0 of danog\MadelineProto\Tools::genVectorHash() changed name from ints to longs +- [BC] CHANGED: Parameter 1 of danog\MadelineProto\Tools::callFork() changed name from actual to args +- [BC] CHANGED: The parameter $token of danog\MadelineProto\Tools::flock() changed from Amp\Promise|null to Amp\Cancellation|null +- [BC] CHANGED: The parameter $token of danog\MadelineProto\Tools::flock() changed from Amp\Promise|null to a non-contravariant Amp\Cancellation|null +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::callFork() changed to Amp\Future +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::echo() changed from Amp\Promise to the non-covariant void +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::echo() changed from Amp\Promise to void +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::flock() changed from Amp\Promise to Closure|null +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::flock() changed from Amp\Promise to the non-covariant Closure|null +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::readLine() changed from Amp\Promise to string +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::readLine() changed from Amp\Promise to the non-covariant string +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::sleep() changed from Amp\Promise to the non-covariant void +- [BC] CHANGED: The return type of danog\MadelineProto\Tools::sleep() changed from Amp\Promise to void +- [BC] CHANGED: The return type of danog\MadelineProto\Wrappers\Events#getEventHandler() changed from danog\MadelineProto\EventHandler to danog\MadelineProto\EventHandler|danog\MadelineProto\Ipc\EventHandlerProxy|__PHP_Incomplete_Class|null +- [BC] CHANGED: The return type of danog\MadelineProto\Wrappers\Events#getEventHandler() changed from danog\MadelineProto\EventHandler to the non-covariant danog\MadelineProto\EventHandler|danog\MadelineProto\Ipc\EventHandlerProxy|__PHP_Incomplete_Class|null + +Next section \ No newline at end of file diff --git a/docs/docs/USING_METHODS.md b/docs/docs/USING_METHODS.md new file mode 100644 index 0000000000..9b13502eee --- /dev/null +++ b/docs/docs/USING_METHODS.md @@ -0,0 +1,103 @@ +--- +title: "Using methods" +description: "There are simplifications for many, if not all of, these methods." +nav_order: 30 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Using methods + +There are simplifications for many, if not all of, these methods. + +A list of all of the methods that can be called with MadelineProto can be found here: [here (layer 179)](https://docs.madelineproto.xyz/API_docs/). + + [Now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html) + +* [Named arguments](#named-arguments) +* [Peers](#peers) +* [Files](https://docs.madelineproto.xyz/docs/FILES.html) +* [Secret chats](#secret-chats) +* [Entities (Markdown & HTML)](#entities) +* [reply_markup (keyboards & inline keyboards)](#reply_markup) +* [bot API objects](#bot-api-objects) +* [No result](#no-result) +* [Multiple method calls](#multiple-method-calls) +* [Cancellation](#cancellation) +* [FULL API Documentation with descriptions](https://docs.madelineproto.xyz/API_docs/methods/) + +## Named arguments + +You must use named arguments instead of arrays to provide method arguments, which allows for much cleaner syntax: + +```php +$MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'Testing MadelineProto...'); +``` + +## Peers +[Full example](https://github.com/danog/MadelineProto/blob/v8/bot.php) + +If an object of type User, InputUser, Chat, InputChannel, Peer or InputPeer must be provided as a parameter to a method, you can substitute it with the user/group/channel's username (`@username`), bot API id (`-1029449`, `1249421`, `-100412412901`), or update. + +```php +$MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'Testing MadelineProto...'); +``` + + +## Secret chats +[Full example](https://github.com/danog/MadelineProto/blob/v8/examples/secret_bot.php) +If an object of type InputSecretChat must be provided as a parameter to a method, you can substitute it with the secret chat's id, the updateNewEncrypted message or the decryptedMessage: + +```php +$MadelineProto->messages->sendEncrypted(peer: $update, message: ['_' => 'decryptedMessage', 'ttl' => 0, 'message' => 'Hi']); +``` + + +## Entities +[Full example](https://github.com/danog/MadelineProto/blob/v8/tests/testing.php) +Methods that allow sending message entities ([messages.sendMessage](http://docs.madelineproto.xyz/API_docs/methods/messages_sendMessage.html) for example) also have an additional `parse_mode` parameter that enables or disables html/markdown parsing of the message to be sent. + +```php +$MadelineProto->messages->sendMessage(peer: '@danogentili', message: '[Testing Markdown in MadelineProto](https://docs.madelineproto.xyz)', parse_mode: 'Markdown'); +$MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'Testing HTML in MadelineProto', parse_mode: 'HTML'); +``` + + + +## reply_markup +reply_markup accepts bot API reply markup objects as well as MTProto ones. + +```php +$bot_API_markup = ['inline_keyboard' => + [ + [ + ['text' => 'MadelineProto docs', 'url' => 'https://docs.madelineproto.xyz'], + ['text' => 'MadelineProto channel', 'url' => 'https://t.me/MadelineProto'] + ] + ] +]; +$MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'lel', reply_markup: $bot_API_markup); +``` + + +## Bot API objects +To convert the results of methods to bot API objects you can use the MTProtoToBotAPI method. + +```php +$bot_API_object = $MadelineProto->MTProtoToBotAPI($MadelineProto->messages->sendMessage(peer: '@danogentili', message: 'lel')); +``` + +MadelineProto also [supports bot API file IDs when working with files](FILES.html) + + +## No result + +See [ignored async](https://docs.madelineproto.xyz/docs/ASYNC.html#ignored-async). + +## Multiple method calls + +See [multiple async](https://docs.madelineproto.xyz/docs/ASYNC.html#multiple-async). + +## Cancellation + +See [cancellation »](https://docs.madelineproto.xyz/docs/ASYNC.html#cancellation). + +Next section \ No newline at end of file diff --git a/docs/favicons/android-chrome-192x192.png b/docs/favicons/android-chrome-192x192.png new file mode 100644 index 0000000000..f40588bfa3 Binary files /dev/null and b/docs/favicons/android-chrome-192x192.png differ diff --git a/docs/favicons/android-chrome-256x256.png b/docs/favicons/android-chrome-256x256.png new file mode 100644 index 0000000000..d3059f5683 Binary files /dev/null and b/docs/favicons/android-chrome-256x256.png differ diff --git a/docs/favicons/apple-touch-icon.png b/docs/favicons/apple-touch-icon.png new file mode 100644 index 0000000000..56f9f43bf7 Binary files /dev/null and b/docs/favicons/apple-touch-icon.png differ diff --git a/docs/favicons/browserconfig.xml b/docs/favicons/browserconfig.xml new file mode 100644 index 0000000000..ac3f71408c --- /dev/null +++ b/docs/favicons/browserconfig.xml @@ -0,0 +1,9 @@ + + + + + + #00aba9 + + + diff --git a/docs/favicons/favicon-16x16.png b/docs/favicons/favicon-16x16.png new file mode 100644 index 0000000000..a40344625c Binary files /dev/null and b/docs/favicons/favicon-16x16.png differ diff --git a/docs/favicons/favicon-32x32.png b/docs/favicons/favicon-32x32.png new file mode 100644 index 0000000000..93db99c634 Binary files /dev/null and b/docs/favicons/favicon-32x32.png differ diff --git a/docs/favicons/favicon.ico b/docs/favicons/favicon.ico new file mode 100644 index 0000000000..c8b8f8f9ab Binary files /dev/null and b/docs/favicons/favicon.ico differ diff --git a/docs/favicons/manifest.json b/docs/favicons/manifest.json new file mode 100644 index 0000000000..c3e8c5f0b1 --- /dev/null +++ b/docs/favicons/manifest.json @@ -0,0 +1,17 @@ +{ + "name": "MadelineProto", + "icons": [ + { + "src": "\/favicons\/android-chrome-192x192.png", + "sizes": "192x192", + "type": "image\/png" + }, + { + "src": "\/favicons\/android-chrome-256x256.png", + "sizes": "256x256", + "type": "image\/png" + } + ], + "theme_color": "#00aba9", + "display": "standalone" +} diff --git a/docs/favicons/mstile-150x150.png b/docs/favicons/mstile-150x150.png new file mode 100644 index 0000000000..4e685d9866 Binary files /dev/null and b/docs/favicons/mstile-150x150.png differ diff --git a/docs/favicons/safari-pinned-tab.svg b/docs/favicons/safari-pinned-tab.svg new file mode 100644 index 0000000000..e0f89dd028 --- /dev/null +++ b/docs/favicons/safari-pinned-tab.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/getFullDialogs.md b/docs/getFullDialogs.md new file mode 100644 index 0000000000..4b1bef511b --- /dev/null +++ b/docs/getFullDialogs.md @@ -0,0 +1,22 @@ +--- +title: getFullDialogs +description: getFullDialogs parameters, return type and example +redirect_from: /get_full_dialogs.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: getDialogs + +Gets full list of dialogs + +### Return type: Array of [Dialog objects](API_docs/types/Dialog.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$Dialogs = $MadelineProto->getFullDialogs(); +``` + +Or, if you're into Lua: + diff --git a/docs/getFullInfo.md b/docs/getFullInfo.md new file mode 100644 index 0000000000..a1c4cd326a --- /dev/null +++ b/docs/getFullInfo.md @@ -0,0 +1,25 @@ +--- +title: getFullInfo +description: getFullInfo parameters, return type and example +redirect_from: /get_full_info.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: getFullInfo + + +### Parameters: + +| Name | Type | +|----------|---------------| +|id| A username, a bot API chat id, a tg-cli chat id, a [Chat](API_docs/types/Chat.html), a [User](API_docs/types/User.html), an [InputPeer](API_docs/types/InputPeer.html), an [InputUser](API_docs/types/InputUser.html), an [InputChannel](API_docs/types/InputChannel.html), a [Peer](API_docs/types/Peer.html), or a [Chat](API_docs/types/Chat.html) object| + +### Return type: [FullInfo](FullInfo.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$Chat = $MadelineProto->getFullInfo($id); +``` + diff --git a/docs/getId.md b/docs/getId.md new file mode 100644 index 0000000000..4aeb568694 --- /dev/null +++ b/docs/getId.md @@ -0,0 +1,25 @@ +--- +title: getId +description: getId parameters, return type and example +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: getId + +Gets a bot API ID from a username, update, message, or other related constructors. + +### Parameters: + +| Name | Type | +|----------|---------------| +|id| A username, a bot API chat id, a tg-cli chat id, a [Chat](API_docs/types/Chat.html), a [User](API_docs/types/User.html), an [InputPeer](API_docs/types/InputPeer.html), an [InputUser](API_docs/types/InputUser.html), an [InputChannel](API_docs/types/InputChannel.html), a [Peer](API_docs/types/Peer.html), or a [Chat](API_docs/types/Chat.html) object| + +### Return type: integer + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$id = $MadelineProto->getId($id); +``` + diff --git a/docs/getInfo.md b/docs/getInfo.md new file mode 100644 index 0000000000..6c2903feab --- /dev/null +++ b/docs/getInfo.md @@ -0,0 +1,25 @@ +--- +title: getInfo +description: getInfo parameters, return type and example +redirect_from: /get_info.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: getInfo + + +### Parameters: + +| Name | Type | +|----------|---------------| +|id| A username, a bot API chat id, a tg-cli chat id, a [Chat](API_docs/types/Chat.html), a [User](API_docs/types/User.html), an [InputPeer](API_docs/types/InputPeer.html), an [InputUser](API_docs/types/InputUser.html), an [InputChannel](API_docs/types/InputChannel.html), a [Peer](API_docs/types/Peer.html), or a [Chat](API_docs/types/Chat.html) object| + +### Return type: [Info](Info.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$Chat = $MadelineProto->getInfo($id); +``` + diff --git a/docs/getPwrChat.md b/docs/getPwrChat.md new file mode 100644 index 0000000000..6ca993efca --- /dev/null +++ b/docs/getPwrChat.md @@ -0,0 +1,26 @@ +--- +title: getPwrChat +description: getPwrChat parameters, return type and example +redirect_from: /get_pwr_chat.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: getPwrChat + + +### Parameters: + +| Name | Type | +|----------|---------------| +|id| A username, a bot API chat id, a tg-cli chat id, a [Chat](API_docs/types/Chat.html), a [User](API_docs/types/User.html), an [InputPeer](API_docs/types/InputPeer.html), an [InputUser](API_docs/types/InputUser.html), an [InputChannel](API_docs/types/InputChannel.html), a [Peer](API_docs/types/Peer.html), or a [Chat](API_docs/types/Chat.html) object| +|fullfetch| Optional, a boolean that if set to true (the default) fetches full info (chat photo, invite link, bot info, common_chats_count, phone_calls_available, phone_calls_private, can_set_username, can_view_participants, participants)| + +### Return type: [PWRTelegram Chat](Chat.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$Chat = $MadelineProto->getPwrChat($id); +``` + diff --git a/docs/getSelf.md b/docs/getSelf.md new file mode 100644 index 0000000000..0c3701d809 --- /dev/null +++ b/docs/getSelf.md @@ -0,0 +1,22 @@ +--- +title: getSelf +description: getSelf parameters, return type and example +redirect_from: /get_self.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: getSelf + +Gets info about the currently logged-in user. + +No parameters + +### Return type: [User object](API_docs/types/User.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$User = $MadelineProto->getSelf(); +``` + diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000000..6c6a6890b3 --- /dev/null +++ b/docs/index.md @@ -0,0 +1,1095 @@ +--- +title: MadelineProto +description: PHP client/server for the telegram MTProto protocol (a better tg-cli) +nav_order: 1 +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# MadelineProto, a PHP MTProto telegram client + +Created by Daniil Gentili + +`#StandWithUkraine 🇺🇦` + +Do join the official channel, [@MadelineProto](https://t.me/MadelineProto) and the [support groups](https://t.me/pwrtelegramgroup)! + +Approved by Telegram! + +## What's this? + +This library can be used to easily interact with Telegram **without** the bot API, just like the official apps. + +It can login with a phone number (MTProto API), or with a bot token (MTProto API, **no bot API involved!**). + +[It is now fully async](https://docs.madelineproto.xyz/docs/ASYNC.html)! + +## Getting started ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)) + +```php +start(); + +$me = $MadelineProto->getSelf(); + +$MadelineProto->logger($me); + +if (!$me['bot']) { + $MadelineProto->messages->sendMessage(peer: '@stickeroptimizerbot', message: "/start"); + + $MadelineProto->channels->joinChannel(channel: '@MadelineProto'); + + try { + $MadelineProto->messages->importChatInvite(hash: 'https://t.me/+Por5orOjwgccnt2w'); + } catch (\danog\MadelineProto\RPCErrorException $e) { + $MadelineProto->logger($e); + } +} +$MadelineProto->echo('OK, done!'); +``` + +Try running this code in a browser or in a console! + + +Tip: if you receive an error (or nothing), [send us](https://t.me/pwrtelegramgroup) the error message and the `MadelineProto.log` file that was created in the same directory (if running from a browser). + +## Made with MadelineProto + +The following open source projects were created using MadelineProto: you can directly install them, or explore the source code as direct examples on how to use MadelineProto's many features! + +* [magnaluna webradio](https://magna.madelineproto.xyz) - Multifeatured Telegram VoIP webradio +* [TelegramApiServer](https://github.com/xtrime-ru/TelegramApiServer) - Fast, simple, async php telegram api server: an HTTP JSON API for MadelineProto! +* [`simpleBot.php`](https://github.com/danog/MadelineProto/blob/v8/examples/simpleBot.php) - Extremely basic example +* [`tgstories_dl_bot.php`](https://github.com/danog/MadelineProto/blob/v8/examples/tgstories_dl_bot.php) - Source code of [@tgstories_dl_bot](https://t.me/tgstories_dl_bot) - Bot to download any Telegram Story! +* [`downloadRenameBot.php`](https://github.com/danog/downloadRenameBot/blob/main/bot.php) - Download files by URL and rename Telegram files using this async parallelized bot! +* [`secret_bot.php`](https://github.com/danog/MadelineProto/blob/v8/examples/secret_bot.php) - Secret chat bot! +* [`pipesbot.php`](https://github.com/danog/pipesbot) - Creating inline bots and using other inline bots via a userbot! +* [`bot.php`](https://github.com/danog/MadelineProto/blob/v8/examples/bot.php) - Examples for how to use filters, updates, get download links for any file, Telegram Stories and much more! + +Some of MadelineProto's core components are also available as separate, standalone libraries: + +- [danog/async-orm](https://github.com/danog/AsyncOrm) - Async ORM based on AMPHP v3 and fibers. +- [danog/telegram-entities](https://github.com/danog/telegram-entities) - A library to work with Telegram UTF-16 styled text entities. +- [danog/tg-file-decoder](https://github.com/danog/tg-file-decoder) - A library to work with Telegram bot API file IDs. +- [danog/loop](https://github.com/danog/loop) - Loop/actor model abstraction for AMPHP. +- [danog/ipc](https://github.com/danog/ipc) - Async IPC component for AMPHP. +- [danog/dns-over-https](https://github.com/danog/dns-over-https) - Async DNS-over-HTTPS resolution for AMPHP. + +Want to add your own open-source project to this list? [Click here!](https://docs.madelineproto.xyz/FOSS.html) + +## Documentation + +* [Creating a client](https://docs.madelineproto.xyz/docs/CREATING_A_CLIENT.html) - This page explains how to create a MadelineProto instance. +* [Login](https://docs.madelineproto.xyz/docs/LOGIN.html) - There are many ways you can login with MadelineProto. + * [Getting permission to use the telegram API](https://docs.madelineproto.xyz/docs/LOGIN.html#getting-permission-to-use-the-telegram-api) + * [Automatic](https://docs.madelineproto.xyz/docs/LOGIN.html#automatic) + * [Manual (user)](https://docs.madelineproto.xyz/docs/LOGIN.html#manual-user) + * [API ID](https://docs.madelineproto.xyz/docs/LOGIN.html#api-id) + * [Manual (bot)](https://docs.madelineproto.xyz/docs/LOGIN.html#manual-bot) + * [QR code login (user)](https://docs.madelineproto.xyz/docs/LOGIN.html#qr-code-user) +* [Features](https://docs.madelineproto.xyz/docs/FEATURES.html) - MadelineProto can do everything official clients can do, and more! +* [Requirements](https://docs.madelineproto.xyz/docs/REQUIREMENTS.html) - MadelineProto requires the mbstring, xml, json, fileinfo, gmp, openssl, iconv, gd extensions to function properly. +* [MadelineProto on Docker](https://docs.madelineproto.xyz/docs/DOCKER.html) - MadelineProto offers an official MadelineProto docker image for the linux/amd64, linux/arm64 and linux/riscv64 platforms @ hub.madelineproto.xyz/danog/madelineproto. + * [Getting started](https://docs.madelineproto.xyz/docs/DOCKER.html#getting-started) + * [CLI bot (recommended)](https://docs.madelineproto.xyz/docs/DOCKER.html#cli-bot-recommended) + * [Databases on docker](https://docs.madelineproto.xyz/docs/DOCKER.html#databases-on-docker) + * [Web docker](https://docs.madelineproto.xyz/docs/DOCKER.html#web-docker) + * [Custom extensions](https://docs.madelineproto.xyz/docs/DOCKER.html#custom-extensions) +* [Installation](https://docs.madelineproto.xyz/docs/INSTALLATION.html) - There are various ways to install MadelineProto: + * [Simple](https://docs.madelineproto.xyz/docs/INSTALLATION.html#simple) + * [Composer from existing project](https://docs.madelineproto.xyz/docs/INSTALLATION.html#composer-from-existing-project) + * [Composer from scratch](https://docs.madelineproto.xyz/docs/INSTALLATION.html#composer-from-scratch) +* [Broadcasting messages to all users](https://docs.madelineproto.xyz/docs/BROADCAST.html) - MadelineProto can be used to broadcast messages to all users, chats and channels of a bot or userbot. +* [Handling updates (new messages & other events)](https://docs.madelineproto.xyz/docs/UPDATES.html) - Update handling can be done in different ways: + * [Async Event driven](https://docs.madelineproto.xyz/docs/UPDATES.html#async-event-driven) + * [Full example](https://docs.madelineproto.xyz/docs/UPDATES.html#async-event-driven) + * [Bound methods](https://docs.madelineproto.xyz/docs/UPDATES.html#bound-methods) + * [Filters](https://docs.madelineproto.xyz/docs/FILTERS.html) + * [Simple filters](https://docs.madelineproto.xyz/docs/FILTERS.html#simple-filters) + * [Attribute filters](https://docs.madelineproto.xyz/docs/FILTERS.html#attribute-filters) + * [MTProto filters](https://docs.madelineproto.xyz/docs/FILTERS.html#mtproto-filters) + * [Plugins](https://docs.madelineproto.xyz/docs/PLUGINS.html) + * [Cron](https://docs.madelineproto.xyz/docs/UPDATES.html#cron) + * [Persisting data and IPC](https://docs.madelineproto.xyz/docs/UPDATES.html#persisting-data-and-ipc) + * [Built-in ORM](https://docs.madelineproto.xyz/docs/UPDATES.html#built-in-orm) + * [IPC](https://docs.madelineproto.xyz/docs/UPDATES.html#ipc) + * [Restarting](https://docs.madelineproto.xyz/docs/UPDATES.html#restarting) + * [Self-restart on webhosts](https://docs.madelineproto.xyz/docs/UPDATES.html#self-restart-on-webhosts) + * [Multi-account](https://docs.madelineproto.xyz/docs/UPDATES.html#multiaccount) + * [Automatic static analysis](https://docs.madelineproto.xyz/docs/UPDATES.html#automatic-static-analysis) + * [Avoiding the use of filesystem functions](https://docs.madelineproto.xyz/docs/UPDATES.html#avoiding-the-use-of-filesystem-functions) + * [Webhook (for HTTP APIs)](https://docs.madelineproto.xyz/docs/UPDATES.html#webhook) + * [getUpdates (only for Javascript APIs)](https://docs.madelineproto.xyz/docs/UPDATES.html#getUpdates) + * [Noop (default)](https://docs.madelineproto.xyz/docs/UPDATES.html#noop) + * [danog\MadelineProto\Broadcast\Progress »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html) + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Broadcast/Progress.html#method-list) + * [danog\MadelineProto\EventHandler\BotCommands »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/BotCommands.html) - The [command set](https://core.telegram.org/api/bots/commands) + * [danog\MadelineProto\EventHandler\Channel\ChannelParticipant »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Channel/ChannelParticipant.html) - A participant has left, joined, was banned or admined in a [channel or supergroup](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\Delete\DeleteChannelMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteChannelMessages.html) - Some messages in a [supergroup/channel](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\Delete\DeleteScheduledMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Delete/DeleteScheduledMessages.html) - Some [scheduled messages](https://core.telegram.org/api/scheduled-messages) + * [danog\MadelineProto\EventHandler\Message\Service\DialogChannelMigrateFrom »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChannelMigrateFrom.html) - Indicates the channel was [migrated](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\Message\Service\DialogChatMigrateTo »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogChatMigrateTo.html) - Indicates the chat was [migrated](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\Message\Service\DialogPeerRequested »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogPeerRequested.html) - Contains info about a peer that the user shared with the bot after clicking on a [keyboardButtonRequestPeer](https://docs.madelineproto.xyz/API_docs/constructors/keyboardButtonRequestPeer.html) + * [danog\MadelineProto\EventHandler\Message\Service\DialogSetChatWallPaper »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSetChatWallPaper.html) - The [wallpaper](https://core.telegram.org/api/wallpapers) + * [danog\MadelineProto\EventHandler\Message\Service\DialogSuggestProfilePhoto »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogSuggestProfilePhoto.html) - A new profile picture was suggested using [photos.uploadContactProfilePhoto](https://docs.madelineproto.xyz/API_docs/methods/photos.uploadContactProfilePhoto.html) + * [danog\MadelineProto\EventHandler\Message\Service\DialogTopicCreated »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicCreated.html) - A [forum topic](https://core.telegram.org/api/forum#forum-topics) + * [danog\MadelineProto\EventHandler\Message\Service\DialogTopicEdited »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogTopicEdited.html) - [Forum topic](https://core.telegram.org/api/forum#forum-topics) + * [danog\MadelineProto\EventHandler\Message\Service\DialogWebView »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Message/Service/DialogWebView.html) - Data from an opened [reply keyboard bot web app](https://core.telegram.org/api/bots/webapps) was relayed to the bot that owns it (user & bot side service message) + * [danog\MadelineProto\EventHandler\Pinned\PinnedChannelMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedChannelMessages.html) - Represents messages that were pinned/unpinned in a [channel](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\Pinned\PinnedGroupMessages »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Pinned/PinnedGroupMessages.html) - Represents messages that were pinned/unpinned in a [chat/supergroup](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\Typing\SupergroupUserTyping »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Typing/SupergroupUserTyping.html) - A user is typing in a [supergroup](https://core.telegram.org/api/channel) + * [danog\MadelineProto\EventHandler\User\Status\Emoji »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/User/Status/Emoji.html) - The [emoji status](https://core.telegram.org/api/emoji-status) + * [danog\MadelineProto\VoIP »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) + * [Full property list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html#properties) + * [Full bound method list »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html#method-list) + * [Simple filters »](https://docs.madelineproto.xyz/docs/FILTERS.html#simple-filters) + * [Attribute filters »](https://docs.madelineproto.xyz/docs/FILTERS.html#attribute-filters) + * [MTProto filters »](https://docs.madelineproto.xyz/docs/FILTERS.html#mtproto-filters) + * [Configuration](https://docs.madelineproto.xyz/docs/UPDATES.html#configuration) + * [Creating and uploading text files](https://docs.madelineproto.xyz/docs/UPDATES.html#creating-and-uploading-text-files) + * [Logging](https://docs.madelineproto.xyz/docs/UPDATES.html#logging) +* [Filters](https://docs.madelineproto.xyz/docs/FILTERS.html) - MadelineProto offers a very simple and intuitive message filtering system, based on PHP's type system and attributes. + * [Simple filters](https://docs.madelineproto.xyz/docs/FILTERS.html#simple-filters) + * [Attribute filters](https://docs.madelineproto.xyz/docs/FILTERS.html#attribute-filters) + * [Creating custom attribute filters](https://docs.madelineproto.xyz/docs/FILTERS.html#creating-custom-attribute-filters) + * [MTProto filters](https://docs.madelineproto.xyz/docs/FILTERS.html#mtproto-filters) +* [Plugins](https://docs.madelineproto.xyz/docs/PLUGINS.html) - MadelineProto offers a native plugin system, based on event handlers! + * [Installing plugins](https://docs.madelineproto.xyz/docs/PLUGINS.html#installing-plugins) + * [Simple installation](https://docs.madelineproto.xyz/docs/PLUGINS.html#simple-installation) + * [Composer installation](https://docs.madelineproto.xyz/docs/PLUGINS.html#composer-installation) + * [Builtin plugins](https://docs.madelineproto.xyz/docs/PLUGINS.html#builtin-plugins) + * [Creating plugins](https://docs.madelineproto.xyz/docs/PLUGINS.html#creating-plugins) + * [Full plugin example](https://docs.madelineproto.xyz/docs/PLUGINS.html#full-plugin-example) + * [Limitations](https://docs.madelineproto.xyz/docs/PLUGINS.html#limitations) + * [Namespace requirements](https://docs.madelineproto.xyz/docs/PLUGINS.html#namespace-requirements) + * [Distribution](https://docs.madelineproto.xyz/docs/PLUGINS.html#distribution) + * [danog\MadelineProto\EventHandler\Plugin\RestartPlugin »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/EventHandler/Plugin/RestartPlugin.html) + * [Configuration](https://docs.madelineproto.xyz/docs/UPDATES.html#configuration) + * [Creating and uploading text files](https://docs.madelineproto.xyz/docs/UPDATES.html#creating-and-uploading-text-files) + * [Logging](https://docs.madelineproto.xyz/docs/UPDATES.html#logging) +* [Database](https://docs.madelineproto.xyz/docs/DATABASE.html) - MadelineProto optionally can keep some of its internal data in a database, such as mysql, mariadb, postgres or redis (you can also add your own!), reducing RAM usage. + * [\danog\MadelineProto\Settings\Database\Memory: Memory backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Memory.html) + * [\danog\MadelineProto\Settings\Database\Mysql: MySQL backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Mysql.html) + * [\danog\MadelineProto\Settings\Database\Postgres: Postgres backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Postgres.html) + * [\danog\MadelineProto\Settings\Database\Redis: Redis backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Redis.html) +* [Settings](https://docs.madelineproto.xyz/docs/SETTINGS.html) - MadelineProto has lots of settings that can be used to modify the behaviour of the library. + * [AppInfo: App information.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/AppInfo.html) + * [Auth: Cryptography settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Auth.html) + * [Connection: Connection settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Connection.html) + * [Files: File management settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Files.html) + * [Logger: Logger settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Logger.html) + * [Peer: Peer database settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Peer.html) + * [Pwr: PWRTelegram settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Pwr.html) + * [RPC: RPC settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/RPC.html) + * [SecretChats: Secret chat settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/SecretChats.html) + * [Serialization: Serialization settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Serialization.html) + * [TLSchema: TL schema settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/TLSchema.html) + * [Templates: Web and CLI template settings for login.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Templates.html) + * [VoIP: VoIP settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/VoIP.html) + * [Database\Memory: Memory backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Memory.html) + * [Database\Mysql: MySQL backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Mysql.html) + * [Database\Postgres: Postgres backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Postgres.html) + * [Database\Redis: Redis backend settings.](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/Settings/Database/Redis.html) +* [Getting info about the current user](https://docs.madelineproto.xyz/docs/SELF.html) - Here's how you can fetch info about the currently logged in user +* [Exceptions](https://docs.madelineproto.xyz/docs/EXCEPTIONS.html) - MadelineProto can throw lots of different exceptions. + * [List of exception types](https://docs.madelineproto.xyz/docs/EXCEPTIONS.html#list-of-exception-types) + * [Pretty TL trace](https://docs.madelineproto.xyz/docs/EXCEPTIONS.html#pretty-tl-trace) + * [Getting the TL trace](https://docs.madelineproto.xyz/docs/EXCEPTIONS.html#getting-the-tl-trace) +* [Avoiding FLOOD_WAITs](https://docs.madelineproto.xyz/docs/FLOOD_WAIT.html) - If you make too many requests to telegram, you might get FLOOD_WAITed for a while. To avoid these flood waits, you must calculate the flood wait rate. +* [Logging](https://docs.madelineproto.xyz/docs/LOGGING.html) - MadelineProto provides a unified class for logging messages to the logging destination defined in settings. +* [Telegram VoIP phone calls](https://docs.madelineproto.xyz/docs/CALLS.html) - MadelineProto provides an easy wrapper to work with phone calls. + * [Requesting a call](https://docs.madelineproto.xyz/docs/CALLS.html#requesting-a-call) + * [Playing audio files](https://docs.madelineproto.xyz/docs/CALLS.html#playing-audio-files) + * [Webhost support!](https://docs.madelineproto.xyz/docs/CALLS.html#webhost-support) + * [Accepting calls](https://docs.madelineproto.xyz/docs/CALLS.html#accepting-calls) +* [Uploading and downloading files](https://docs.madelineproto.xyz/docs/FILES.html) - MadelineProto provides fully parallelized wrapper methods to upload and download files that support bot API file ids, direct upload by URL and file renaming. + * [Bot API file IDs](https://docs.madelineproto.xyz/docs/FILES.html#bot-api-file-ids) + * [Uploading & sending files](https://docs.madelineproto.xyz/docs/FILES.html#sending-files) + * [Security notice](https://docs.madelineproto.xyz/docs/FILES.html#security-notice) + * [Photos](https://docs.madelineproto.xyz/docs/FILES.html#photos) + * [Photos as documents](https://docs.madelineproto.xyz/docs/FILES.html#photos-as-documents) + * [Documents](https://docs.madelineproto.xyz/docs/FILES.html#documents) + * [GIFs](https://docs.madelineproto.xyz/docs/FILES.html#gifs) + * [Videos](https://docs.madelineproto.xyz/docs/FILES.html#videos) + * [Music](https://docs.madelineproto.xyz/docs/FILES.html#music) + * [Voice](https://docs.madelineproto.xyz/docs/FILES.html#voice) + * [Stickers](https://docs.madelineproto.xyz/docs/FILES.html#stickers) + * [Uploading files](https://docs.madelineproto.xyz/docs/FILES.html#uploading-files) + * [Reusing uploaded files](https://docs.madelineproto.xyz/docs/FILES.html#reusing-uploaded-files) + * [Renaming files](https://docs.madelineproto.xyz/docs/FILES.html#renaming-files) + * [Downloading files](https://docs.madelineproto.xyz/docs/FILES.html#downloading-files) + * [Extracting download info](https://docs.madelineproto.xyz/docs/FILES.html#extracting-download-info) + * [Getting a download link](https://docs.madelineproto.xyz/docs/FILES.html#getting-a-download-link) + * [Downloading profile pictures](https://docs.madelineproto.xyz/docs/FILES.html#downloading-profile-pictures) + * [Download to directory](https://docs.madelineproto.xyz/docs/FILES.html#download-to-directory) + * [Download to file](https://docs.madelineproto.xyz/docs/FILES.html#download-to-file) + * [Download to stream](https://docs.madelineproto.xyz/docs/FILES.html#download-to-stream) + * [Download to callback](https://docs.madelineproto.xyz/docs/FILES.html#download-to-callback) + * [Download to http-server](https://docs.madelineproto.xyz/docs/FILES.html#download-to-http-server) + * [Download to browser](https://docs.madelineproto.xyz/docs/FILES.html#download-to-browser) + * [Getting progress](https://docs.madelineproto.xyz/docs/FILES.html#getting-progress) +* [Getting info about chats](https://docs.madelineproto.xyz/docs/CHAT_INFO.html) - There are various methods that can be used to fetch info about chats, based on bot API id, tg-cli ID, Peer, User, Chat objects. + * [Full chat info with full list of participants](https://docs.madelineproto.xyz/docs/CHAT_INFO.html#getPwrChat) + * [Full chat info](https://docs.madelineproto.xyz/docs/CHAT_INFO.html#getFullInfo) + * [Reduced chat info (very fast)](https://docs.madelineproto.xyz/docs/CHAT_INFO.html#getInfo) + * [Just the chat ID (extremely fast)](https://docs.madelineproto.xyz/docs/CHAT_INFO.html#getId) +* [Getting all chats (dialogs)](https://docs.madelineproto.xyz/docs/DIALOGS.html) - There are two ways to get a list of all chats, depending if you logged in as a user, or as a bot. + * [Dialog ID list](https://docs.madelineproto.xyz/docs/DIALOGS.html#getDialogIds) + * [Full dialog info](https://docs.madelineproto.xyz/docs/DIALOGS.html#getFullDialogs) +* [Inline buttons](https://docs.madelineproto.xyz/docs/INLINE_BUTTONS.html) - You can easily click inline buttons using MadelineProto, just access the correct button: +* [Secret chats](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html) - MadelineProto provides wrappers to work with secret chats. + * [Requesting secret chats](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html#requesting-secret-chats) + * [Accepting secret chats](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html#accepting-secret-chats) + * [Checking secret chat status](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html#checking-secret-chat-status) + * [Sending secret messages](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html#sending-secret-messages) +* [Using a proxy](https://docs.madelineproto.xyz/docs/PROXY.html) - You can use a proxy with MadelineProto. + * [How to set a proxy](https://docs.madelineproto.xyz/docs/PROXY.html#how-to-set-a-proxy) + * [Multiple proxies with automatic switch](https://docs.madelineproto.xyz/docs/PROXY.html#multiple-proxies-with-automatic-switch) + * [Use pre-built MTProxy](https://docs.madelineproto.xyz/docs/PROXY.html#mtproxy) + * [Use pre-built Socks5 proxy](https://docs.madelineproto.xyz/docs/PROXY.html#socks5-proxy) + * [Use pre-built HTTP proxy](https://docs.madelineproto.xyz/docs/PROXY.html#http-proxy) + * [Build your own proxy](https://docs.madelineproto.xyz/docs/PROXY.html#build-your-proxy) +* [Async](https://docs.madelineproto.xyz/docs/ASYNC.html) - MadelineProto now features async, for incredible speed improvements, and parallel processing, all powered by amphp. + * [Usage](https://docs.madelineproto.xyz/docs/ASYNC.html#usage) + * [Async in event handler](https://docs.madelineproto.xyz/docs/ASYNC.html#async-in-event-handler) + * [Multiple async](https://docs.madelineproto.xyz/docs/ASYNC.html#multiple-async) + * [Ignored async](https://docs.madelineproto.xyz/docs/ASYNC.html#ignored-async) + * [Combining async operations](https://docs.madelineproto.xyz/docs/ASYNC.html#combining-async-operations) + * [MadelineProto and AMPHP async APIs](https://docs.madelineproto.xyz/docs/ASYNC.html#madelineproto-and-amphp-async-apis) + * [Helper methods](https://docs.madelineproto.xyz/docs/ASYNC.html#helper-methods) + * [Async sleep](https://docs.madelineproto.xyz/docs/ASYNC.html#async-sleep-does-not-block-the-main-thread) + * [Async readline](https://docs.madelineproto.xyz/docs/ASYNC.html#async-readline-does-not-block-the-main-thread) + * [Async echo](https://docs.madelineproto.xyz/docs/ASYNC.html#async-echo-does-not-block-the-main-thread) + * [MadelineProto HTTP client](https://docs.madelineproto.xyz/docs/ASYNC.html#madelineproto-http-client) + * [Async forking](https://docs.madelineproto.xyz/docs/ASYNC.html#async-forking-does-async-green-thread-forking) + * [Async flock](https://docs.madelineproto.xyz/docs/ASYNC.html#async-flock) + * [MadelineProto async loop APIs](https://docs.madelineproto.xyz/docs/ASYNC.html#async-loop-apis) +* [FAQ](https://docs.madelineproto.xyz/docs/FAQ.html) - Here's a list of common MadelineProto questions and answers. +* [Upgrading from MadelineProto v7 to v8](https://docs.madelineproto.xyz/docs/UPGRADING.html) - MadelineProto v8 is a major MadelineProto update, that removes a large number of long-deprecated APIs: I've created this upgrade checklist, to simplify the upgrade process. +* [Using methods](https://docs.madelineproto.xyz/docs/USING_METHODS.html) - There are simplifications for many, if not all of, these methods. + * [Named arguments](https://docs.madelineproto.xyz/docs/USING_METHODS.html#named-arguments) + * [Peers](https://docs.madelineproto.xyz/docs/USING_METHODS.html#peers) + * [Files](https://docs.madelineproto.xyz/docs/FILES.html) + * [Secret chats](https://docs.madelineproto.xyz/docs/USING_METHODS.html#secret-chats) + * [Entities (Markdown & HTML)](https://docs.madelineproto.xyz/docs/USING_METHODS.html#entities) + * [reply_markup (keyboards & inline keyboards)](https://docs.madelineproto.xyz/docs/USING_METHODS.html#reply_markup) + * [bot API objects](https://docs.madelineproto.xyz/docs/USING_METHODS.html#bot-api-objects) + * [No result](https://docs.madelineproto.xyz/docs/USING_METHODS.html#no-result) + * [Multiple method calls](https://docs.madelineproto.xyz/docs/USING_METHODS.html#multiple-method-calls) + * [Cancellation](https://docs.madelineproto.xyz/docs/USING_METHODS.html#cancellation) + * [FULL API Documentation with descriptions](https://docs.madelineproto.xyz/API_docs/methods/) + * [Login](https://docs.madelineproto.xyz/docs/LOGIN.html) + * [Change 2FA password: update2FA](https://docs.madelineproto.xyz/update2fa.html) + * [Get all chats, broadcast a message to all chats: getDialogIds, getDialogs, getFullDialogs](https://docs.madelineproto.xyz/docs/DIALOGS.html) + * [Get the full participant list of a channel/group/supergroup: getPwrChat](https://docs.madelineproto.xyz/getPwrChat.html) + * [Get full info about a user/chat/supergroup/channel: getFullInfo](https://docs.madelineproto.xyz/getFullInfo.html) + * [Get info about a user/chat/supergroup/channel: getInfo](https://docs.madelineproto.xyz/getInfo.html) + * [Get the ID of a user/chat/supergroup/channel/update: getID](https://docs.madelineproto.xyz/getId.html) + * [Get info about the currently logged-in user: getSelf](https://docs.madelineproto.xyz/getSelf.html) + * [Upload or download files up to 4 GB: uploadFrom*, downloadTo*](https://docs.madelineproto.xyz/docs/FILES.html) + * [Make a phone call and play a song](https://docs.madelineproto.xyz/docs/CALLS.html) + * [Create a secret chat bot](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html) + * Abort a pending 2FA password reset, see here for more info »: account.declinePasswordReset + * Accept QR code login token, logging in the app that generated it: auth.acceptLoginToken + * Accept call: acceptCall + * Accept secret chat: acceptSecretChat + * Accept the new terms of service: help.acceptTermsOfService + * Activate or deactivate a purchased fragment.com username associated to a bot we own: bots.toggleUsername + * Activate or deactivate a purchased fragment.com username associated to a supergroup or channel we own: channels.toggleUsername + * Activate or deactivate a purchased fragment.com username associated to the currently logged-in user: account.toggleUsername + * Activates stories stealth mode, see here » for more info: stories.activateStealthMode + * Add GIF to saved gifs list: messages.saveGif + * Add a sticker to a stickerset, bots only. The sticker set must have been created by the bot: stickers.addStickerToSet + * Add an existing telegram user as contact: contacts.addContact + * Add/remove sticker from recent stickers list: messages.saveRecentSticker + * Adds a peer to a blocklist, see here » for more info: contacts.block + * Adds a user to a chat and sends a service message on it: messages.addChatUser + * Allow the specified bot to send us messages: bots.allowSendMessage + * Answer an inline query, for bots only: messages.setInlineBotResults + * Answers a custom query; for bots only: bots.answerWebhookJSONQuery + * Apply a Telegram Premium giftcode »: payments.applyGiftCode + * Apply changes to multiple stickersets: messages.toggleStickerSets + * Apply one or more boosts » to a peer: premium.applyBoost + * Associate a group to a channel as discussion group for that channel: channels.setDiscussionGroup + * Associate a stickerset to the supergroup: channels.setStickers + * Asynchronously lock a file: flock + * Asynchronously read line: readLine + * Asynchronously sleep: sleep + * Asynchronously write to stdout/browser: echo + * Ban/unban/kick a user in a supergroup/channel: channels.editBanned + * Base64URL encode: base64urlEncode + * Can only be used by TSF members to obtain internal information: help.getUserInfo + * Cancel a running broadcast: cancelBroadcast + * Cancel the code that was sent to verify an email to use as 2FA recovery method: account.cancelPasswordEmail + * Cancel the login verification code: auth.cancelCode + * Change default emoji reaction to use in the quick reaction menu: the value is synced across devices and can be fetched using help.getConfig, reactions_default field: messages.setDefaultReaction + * Change group call settings: phone.toggleGroupCallSettings + * Change media autodownload settings: account.saveAutoDownloadSettings + * Change or remove the username of a supergroup/channel: channels.updateUsername + * Change privacy settings of current account: account.setPrivacy + * Change settings related to a session: account.changeAuthorizationSettings + * Change the chat theme of a certain chat: messages.setChatTheme + * Change the default peer that should be used when sending messages, reactions, poll votes to a specific group: messages.saveDefaultSendAs + * Change the phone number of the current account: account.changePhone + * Change the photo of a channel/supergroup: channels.editPhoto + * Change the set of message reactions » that can be used in a certain group, supergroup or channel: messages.setChatAvailableReactions + * Changes chat name and sends a service message on it: messages.editChatTitle + * Changes chat photo and sends a service message on it: messages.editChatPhoto + * Changes the absolute position of a sticker in the set to which it belongs; for bots only. The sticker set must have been created by the bot: stickers.changeStickerPosition + * Changes the default value of the Time-To-Live setting, applied to all new chats: messages.setDefaultHistoryTTL + * Changes username for the current user: account.updateUsername + * Check if a certain event handler plugin is installed: hasPlugin + * Check if a username is free and can be assigned to a channel/supergroup: channels.checkUsername + * Check if an event handler instance is present: hasEventHandler + * Check if has admins: hasAdmins + * Check if has report peers: hasReportPeers + * Check if is array or similar (traversable && countable && arrayAccess): isArrayOrAlike + * Check if peer is present in internal peer database: peerIsset + * Check if the 2FA recovery code sent using auth.requestPasswordRecovery is valid, before passing it to auth.recoverPassword: auth.checkRecoveryPassword + * Check if the specified peer is a bot: isBot + * Check if the specified peer is a forum: isForum + * Check the validity of a chat invite link and get basic info about it: messages.checkChatInvite + * Check whether chat history exported from another chat app can be imported into a specific Telegram chat, click here for more info »: messages.checkHistoryImportPeer + * Check whether secret chat exists: hasSecretChat + * Check whether the given short name is available: stickers.checkShortName + * Check whether the group call Server Forwarding Unit is currently receiving the streams with the specified WebRTC source IDs.: phone.checkGroupCall + * Check whether the specified bot can send us messages: bots.canSendMessage + * Check whether we can post stories as the specified peer: stories.canSendStory + * Checks whether Telegram Premium purchase is possible. Must be called before in-store Premium purchase, official apps only: payments.canPurchasePremium + * Clear all drafts: messages.clearAllDrafts + * Clear all peer-specific autosave settings: account.deleteAutoSaveExceptions + * Clear bot commands for the specified bot scope and language code: bots.resetBotCommands + * Clear recent stickers: messages.clearRecentStickers + * Clear recently used message reactions: messages.clearRecentReactions + * Clear saved payment information: payments.clearSavedInfo + * Clears list of recently used emoji statuses: account.clearRecentEmojiStatuses + * Close connection with client, connected via web: closeConnection + * Complet user login using login code: completePhoneLogin + * Complete 2FA login: complete2faLogin + * Complete signup to Telegram: completeSignup + * Complete the history import process, importing all messages into the chat.: messages.startHistoryImport + * Confirm a phone number to cancel account deletion, for more info click here »: account.confirmPhone + * Confirms receipt of messages by a client, cancels PUSH-notification sending: messages.receivedMessages + * Convert MTProto parameters to bot API parameters: MTProtoToBotAPI + * Convert TD parameters to tdcli: tdToTdcli + * Convert TD to MTProto parameters: tdToMTProto + * Convert a message and a set of entities to HTML: entitiesToHtml + * Convert a supergroup to a gigagroup, when requested by channel suggestions: channels.convertToGigagroup + * Convert bot API parameters to MTProto parameters: botAPIToMTProto + * Convert double to binary version: packDouble + * Convert integer to base256 long: packSignedLong + * Convert integer to base256 signed int: packSignedInt + * Convert tdcli parameters to tdcli: tdcliToTd + * Convert to camelCase: toCamelCase + * Convert to snake_case: toSnakeCase + * Convert value to unsigned base256 int: packUnsignedInt + * Converts a string into an async amphp stream: stringToStream + * Create a forum topic; requires manage_topics rights: channels.createForumTopic + * Create a group call or livestream: phone.createGroupCall + * Create a stickerset, bots only: stickers.createStickerSet + * Create a supergroup/channel: channels.createChannel + * Create a theme: account.createTheme + * Create and upload a new wallpaper: account.uploadWallPaper + * Create array: arr + * Creates a new chat: messages.createChat + * Delete a channel/supergroup: channels.deleteChannel + * Delete a chat invite: messages.deleteExportedChatInvite + * Delete a chat: messages.deleteChat + * Delete a folder imported using a chat folder deep link »: chatlists.leaveChatlist + * Delete a previously created chat folder deep link »: chatlists.deleteExportedInvite + * Delete all installed wallpapers, reverting to the default wallpaper set: account.resetWallPapers + * Delete all messages sent by a specific participant of a given supergroup: channels.deleteParticipantHistory + * Delete all revoked chat invites: messages.deleteRevokedExportedChatInvites + * Delete all temporary authorization keys except for the ones specified: auth.dropTempAuthKeys + * Delete contacts by phone number: contacts.deleteByPhones + * Delete message history of a forum topic: channels.deleteTopicHistory + * Delete messages in a channel/supergroup: channels.deleteMessages + * Delete scheduled messages: messages.deleteScheduledMessages + * Delete stored Telegram Passport documents, for more info see the passport docs »: account.deleteSecureValue + * Delete the entire phone call history: messages.deletePhoneCallHistory + * Delete the history of a supergroup: channels.deleteHistory + * Delete the user's account from the telegram servers: account.deleteAccount + * Deletes a device by its token, stops sending PUSH-notifications to it: account.unregisterDevice + * Deletes a peer from a blocklist, see here » for more info: contacts.unblock + * Deletes a stickerset we created, bots only: stickers.deleteStickerSet + * Deletes a user from a chat and sends a service message on it: messages.deleteChatUser + * Deletes communication history: messages.deleteHistory + * Deletes messages by their identifiers: messages.deleteMessages + * Deletes messages forwarded from a specific peer to saved messages »: messages.deleteSavedHistory + * Deletes profile photos. The method returns a list of successfully deleted photo IDs: photos.deletePhotos + * Deletes several contacts from the list: contacts.deleteContacts + * Deletes some posted stories: stories.deleteStories + * Disable all purchased usernames of a supergroup or channel: channels.deactivateAllUsernames + * Discard call: discardCall + * Discard secret chat: discardSecretChat + * Dismiss a suggestion, see here for more info »: help.dismissSuggestion + * Dismiss new pending peers recently added to a chat folder deep link »: chatlists.hideChatlistUpdates + * Dismiss or approve a chat join request related to a specific chat or channel: messages.hideChatJoinRequest + * Dismiss or approve all join requests related to a specific chat or channel: messages.hideAllChatJoinRequests + * Download file to amphp/http-server response: downloadToResponse + * Download file to an amphp stream, returning it: downloadToReturnedStream + * Download file to browser: downloadToBrowser + * Download file to callable: downloadToCallable + * Download file to directory: downloadToDir + * Download file to stream: downloadToStream + * Download file: downloadToFile + * Downloads a file to the browser using the specified session file: downloadServer + * Edit a chat folder deep link »: chatlists.editExportedInvite + * Edit an exported chat invite: messages.editExportedChatInvite + * Edit an inline bot message: messages.editInlineBotMessage + * Edit an uploaded story: stories.editStory + * Edit forum topic; requires manage_topics rights: channels.editForumTopic + * Edit information about a given group call participant: phone.editGroupCallParticipant + * Edit location of geogroup, see here » for more info on geogroups: channels.editLocation + * Edit message: messages.editMessage + * Edit peers in peer folder: folders.editPeerFolders + * Edit the close friends list, see here » for more info: contacts.editCloseFriends + * Edit the default banned rights of a channel/supergroup/group: messages.editChatDefaultBannedRights + * Edit the description of a group/supergroup/channel: messages.editChatAbout + * Edit the name of a channel/supergroup: channels.editTitle + * Edit the title of a group call or livestream: phone.editGroupCallTitle + * Edits notification settings from a given user/group, from all users/all groups: account.updateNotifySettings + * Enable or disable content protection on a channel or chat: messages.toggleNoForwards + * Enable or disable forum functionality in a supergroup: channels.toggleForum + * Enable or disable the native antispam system: channels.toggleAntiSpam + * Enable or disable web bot attachment menu »: messages.toggleBotInAttachMenu + * Enable/disable message signatures in channels: channels.toggleSignatures + * Enable/disable top peers: contacts.toggleTopPeers + * Escape string for MadelineProto's HTML entity converter: htmlEscape + * Escape string for URL: markdownUrlEscape + * Escape string for markdown code section: markdownCodeEscape + * Escape string for markdown codeblock: markdownCodeblockEscape + * Escape string for markdown: markdownEscape + * Executes a custom broadcast action with all peers (users, chats, channels) of the bot: broadcastCustom + * Export a folder », creating a chat folder deep link »: chatlists.exportChatlistInvite + * Export an invite link for a chat: messages.exportChatInvite + * Export authorization: exportAuthorization + * Extract Update constructors from an Updates constructor: extractUpdates + * Extract a message ID from an Updates constructor: extractMessageId + * Extract a message constructor from an Updates constructor: extractMessage + * Extract an update message constructor from an Updates constructor: extractMessageUpdate + * Extract file info from bot API message: extractBotAPIFile + * Fetch custom emoji stickers »: messages.getCustomEmojiDocuments + * Fetch new chats associated with an imported chat folder deep link ». Must be invoked at most every chatlist_update_period seconds (as per the related client configuration parameter »): chatlists.getChatlistUpdates + * Fetch saved notification sounds: account.getSavedRingtones + * Fetch the List of active (or active and hidden) stories, see here » for more info on watching stories: stories.getAllStories + * Fetch the full active story list of a specific peer: stories.getPeerStories + * Fetch the stories pinned on a peer's profile: stories.getPinnedStories + * Fetch the story archive » of a peer we control: stories.getStoriesArchive + * Find out if a media message's caption can be edited: messages.getMessageEditData + * Fork a new green thread and execute the passed function in the background: callFork + * Forwards a list of messages to all peers (users, chats, channels) of the bot: broadcastForwardMessages + * Forwards messages by their IDs: messages.forwardMessages + * Generate MTProto vector hash: genVectorHash + * Generate a login token, for login via QR code.: auth.exportLoginToken + * Generate a story deep link for a specific story: stories.exportStoryLink + * Generate an invoice deep link: payments.exportInvoice + * Generates a temporary profile link for the currently logged-in user: contacts.exportContactToken + * Get MTProxy/Public Service Announcement information: help.getPromoData + * Get PSR logger: getPsrLogger + * Get RTMP URL and stream key for RTMP livestreams. Can be used even before creating the actual RTMP livestream with phone.createGroupCall (the rtmp_stream flag must be set): phone.getGroupCallStreamRtmpUrl + * Get TL namespaces: getMethodNamespaces + * Get TL serializer: getTL + * Get Telegram Premium promotion information: help.getPremiumPromo + * Get Telegram UTF-8 length of string: mbStrlen + * Get a document by its SHA256 hash, mainly used for gifs: messages.getDocumentByHash + * Get a list of channels/supergroups we left, requires a takeout session, see here » for more info: channels.getLeftChannels + * Get a list of default suggested channel emoji statuses: account.getChannelDefaultEmojiStatuses + * Get a list of default suggested emoji statuses: account.getDefaultEmojiStatuses + * Get a list of peers that can be used to join a group call, presenting yourself as a specific user/channel: phone.getGroupCallJoinAs + * Get a list of sponsored messages: channels.getSponsoredMessages + * Get a message to show to the user when starting the bot: getWebMessage + * Get a payment form: payments.getPaymentForm + * Get a set of suggested custom emoji stickers that can be used as group picture: account.getDefaultGroupPhotoEmojis + * Get a set of suggested custom emoji stickers that can be used as profile picture: account.getDefaultProfilePhotoEmojis + * Get a set of suggested custom emoji stickers that can be used in an accent color pattern: account.getDefaultBackgroundEmojis + * Get admin IDs (equal to all user report peers): getAdminIds + * Get all archived stickers: messages.getArchivedStickers + * Get all available chat themes »: account.getChatThemes + * Get all contacts, requires a takeout session, see here » for more info: contacts.getSaved + * Get all groups that can be used as discussion groups: channels.getGroupsForDiscussion + * Get all installed stickers: messages.getAllStickers + * Get all pending and running calls, indexed by user ID: getAllCalls + * Get all saved Telegram Passport documents, for more info see the passport docs »: account.getAllSecureValues + * Get an invite link for a group call or livestream: phone.exportGroupCallInvite + * Get and increase the view counter of a message sent or forwarded from a channel: messages.getMessagesViews + * Get app-specific configuration, see client configuration for more info on the result: help.getAppConfig + * Get async DNS client: getDNSClient + * Get async HTTP client: getHTTPClient + * Get authorization info: getAuthorization + * Get autosave settings: account.getAutoSaveSettings + * Get cached (or eventually re-fetch) server-side config: getConfig + * Get cached server-side config: getCachedConfig + * Get call state: getCallState + * Get changed emoji keywords »: messages.getEmojiKeywordsDifference + * Get channel statistics: stats.getBroadcastStats + * Get channel/supergroup messages: channels.getMessages + * Get channels/supergroups/geogroups we're admin in. Usually called when the user exceeds the limit for owned public channels/supergroups/geogroups, and the user is given the choice to remove one of his channels/supergroups/geogroups: channels.getAdminedPublicChannels + * Get chats in common with a user: messages.getCommonChats + * Get configuration for CDN file downloads: help.getCdnConfig + * Get contents of remote file asynchronously: fileGetContents + * Get count of online users in a chat: messages.getOnlines + * Get current number of memory-mapped regions, UNIX only: getMaps + * Get current password hint: getHint + * Get days to live of account: account.getAccountTTL + * Get dialog info of specified peers: messages.getPeerDialogs + * Get dialogs manually marked as unread: messages.getDialogUnreadMarks + * Get diffie-hellman configuration: getDhConfig + * Get discussion message from the associated discussion group of a channel to show it on top of the comment section, without actually joining the group: messages.getDiscussionMessage + * Get download info of file: getDownloadInfo + * Get download link of media file: getDownloadLink + * Get event handler (or plugin instance): getEventHandler + * Get extension from file location: getExtensionFromLocation + * Get extension from mime type: getExtensionFromMime + * Get faved stickers: messages.getFavedStickers + * Get featured stickers: messages.getFeaturedStickers + * Get final element of array: end + * Get folders: messages.getDialogFilters + * Get forum topics by their ID: channels.getForumTopicsByID + * Get full list of MTProto and API methods: getAllMethods + * Get global privacy settings: account.getGlobalPrivacySettings + * Get group call participants: phone.getGroupParticipants + * Get highscores of a game sent using an inline bot: messages.getInlineGameHighScores + * Get highscores of a game: messages.getGameHighScores + * Get inactive channels and supergroups: channels.getInactiveChannels + * Get info about RTMP streams in a group call or livestream.: phone.getGroupCallStreamChannels + * Get info about a certain wallpaper: account.getWallPaper + * Get info about a channel/supergroup participant: channels.getParticipant + * Get info about a chat invite: messages.getExportedChatInvite + * Get info about a credit card: payments.getBankCardData + * Get info about a group call: phone.getGroupCall + * Get info about a stickerset: messages.getStickerSet + * Get info about an unsupported deep link, see here for more info »: help.getDeepLinkInfo + * Get info about chat invites generated by admins: messages.getAdminsWithInvites + * Get info about file: getFileInfo + * Get info about multiple wallpapers: account.getMultiWallPapers + * Get info about the chat invites of a specific chat: messages.getExportedChatInvites + * Get info about the logged-in user, not cached: fullGetSelf + * Get info about the users that joined the chat using a specific chat invite: messages.getChatInviteImporters + * Get information about a language in a localization pack: langpack.getLanguage + * Get information about all languages in a localization pack: langpack.getLanguages + * Get information about extended media: messages.getExtendedMedia + * Get installed mask stickers: messages.getMaskStickers + * Get installed themes: account.getThemes + * Get instant view page: messages.getWebPage + * Get link and embed info of a message in a channel/supergroup: channels.exportMessageLink + * Get live location history of a certain user: messages.getRecentLocations + * Get localization pack strings: langpack.getLangPack + * Get localized emoji keywords »: messages.getEmojiKeywords + * Get localized name of the telegram support user: help.getSupportName + * Get localized name, about text and description of a bot (or of the current account, if called by a bot): bots.getBotInfo + * Get logged-in sessions: account.getAuthorizations + * Get logger: getLogger + * Get maximum number of memory-mapped regions, UNIX only: getMaxMaps + * Get media autodownload settings: account.getAutoDownloadSettings + * Get message ranges for saving the user's chat history: messages.getSplitRanges + * Get message reaction list, along with the sender of each reaction: messages.getMessageReactionsList + * Get message reactions »: messages.getMessagesReactions + * Get message statistics: stats.getMessageStats + * Get messages in a reply thread: messages.getReplies + * Get mime type from buffer: getMimeFromBuffer + * Get mime type from file extension: getMimeFromExtension + * Get mime type of file: getMimeFromFile + * Get more info about a Seamless Telegram Login authorization request, for more info click here »: messages.requestUrlAuth + * Get most used peers: contacts.getTopPeers + * Get name, ISO code, localized name and phone codes/patterns of all available countries: help.getCountriesList + * Get namespaced methods (method => namespace): getMethodsNamespaced + * Get new strings in language pack: langpack.getDifference + * Get passport configuration: help.getPassportConfig + * Get payment receipt: payments.getPaymentReceipt + * Get peer settings: messages.getPeerSettings + * Get phone call configuration to be passed to libtgvoip's shared config: phone.getCallConfig + * Get phone call information: getCall + * Get pinned dialogs: messages.getPinnedDialogs + * Get pinned saved dialogs, see here » for more info: messages.getPinnedSavedDialogs + * Get poll results for non-anonymous polls: messages.getPollVotes + * Get poll results: messages.getPollResults + * Get preview of webpage: messages.getWebPagePreview + * Get privacy settings of current account: account.getPrivacy + * Get random integer: randomInt + * Get recent stickers: messages.getRecentStickers + * Get recently used emoji statuses: account.getRecentEmojiStatuses + * Get recently used message reactions: messages.getRecentReactions + * Get recently used t.me links: help.getRecentMeUrls + * Get saved GIFs: messages.getSavedGifs + * Get saved Telegram Passport document, for more info see the passport docs »: account.getSecureValue + * Get saved payment information: payments.getSavedInfo + * Get scheduled messages: messages.getScheduledHistory + * Get scheduled messages: messages.getScheduledMessages + * Get secret chat: getSecretChat + * Get secure random string of specified length: random + * Get sensitive content settings: account.getContentSettings + * Get sponsored messages for channel: getSponsoredMessages + * Get statistics for a certain story: stats.getStoryStats + * Get stickers attached to a photo or video: messages.getAttachedStickers + * Get stickers by emoji: messages.getStickers + * Get strings from a language pack: langpack.getStrings + * Get suggested folders: messages.getSuggestedDialogFilters + * Get supergroup statistics: stats.getMegagroupStats + * Get temporary payment password: account.getTmpPassword + * Get the IDs of the maximum read stories for a set of peers: stories.getPeerMaxIDs + * Get the admin log of a channel/supergroup: channels.getAdminLog + * Get the file that is currently being played: callGetCurrent + * Get the number of results that would be found by a messages.search call with the same parameters: messages.getSearchCounters + * Get the participants of a supergroup/channel: channels.getParticipants + * Get the phone call with the specified user ID: getCallByPeer + * Get the progress of a currently running broadcast: getBroadcastProgress + * Get the reaction and interaction list of a story posted to a channel, along with the sender of each reaction: stories.getStoryReactionsList + * Get the set of accent color palettes » that can be used for message accents: help.getPeerColors + * Get the set of accent color palettes » that can be used in profile page backgrounds: help.getPeerProfileColors + * Get the telegram IDs of all contacts.: contacts.getContactIDs + * Get theme information: account.getTheme + * Get topics of a forum: channels.getForumTopics + * Get type of peer: getType + * Get unread messages where we were mentioned: messages.getUnreadMentions + * Get unread reactions to messages you sent: messages.getUnreadReactions + * Get users and geochats near you, see here » for more info: contacts.getLocated + * Get various warnings to show to the user in the web UI: getWebWarnings + * Get web login widget authorizations: account.getWebAuthorizations + * Get which users read a specific message: only available for groups and supergroups with less than chat_read_mark_size_threshold members, read receipts will be stored for chat_read_mark_expire_period seconds after the message was sent, see client configuration for more info »: messages.getMessageReadParticipants + * Gets a secret chat message: getSecretMessage + * Gets current notification settings for a given user/group, from all users/all groups: account.getNotifySettings + * Gets featured custom emoji stickersets: messages.getFeaturedEmojiStickers + * Gets info of the propic of a user: getPropicInfo + * Gets the current number of boosts of a channel: premium.getBoostsStatus + * Gets the default value of the Time-To-Live setting, applied to all new chats: messages.getDefaultHistoryTTL + * Gets the list of currently installed custom emoji stickersets: messages.getEmojiStickers + * Gets the menu button action for a given user or for all users, previously set using bots.setBotMenuButton; users can see this information in the botInfo constructor: bots.getBotMenuButton + * Got popular message reactions: messages.getTopReactions + * Hide MTProxy/Public Service Announcement information: help.hidePromoData + * Hide or display the participants list in a supergroup: channels.toggleParticipantsHidden + * Hide the active stories of a specific peer, preventing them from being displayed on the action bar on the homescreen: stories.toggleAllStoriesHidden + * Hide the active stories of a user, preventing them from being displayed on the action bar on the homescreen, see here » for more info: stories.togglePeerStoriesHidden + * Hide/unhide message history for new channel/supergroup users: channels.togglePreHistoryHidden + * If the add contact action bar is active, add that user as contact: contacts.acceptContact + * If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the bot will receive an updateBotShippingQuery update. Use this method to reply to shipping queries: messages.setBotShippingResults + * Import a chat folder deep link », joining some or all the chats in the folder: chatlists.joinChatlistInvite + * Import a chat invite and join a private chat/supergroup/channel: messages.importChatInvite + * Import authorization: importAuthorization + * Import chat history from a foreign chat app into a specific Telegram chat, click here for more info about imported chats »: messages.initHistoryImport + * Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info: contacts.importContacts + * Increment the view counter of one or more stories: stories.incrementStoryViews + * Indicate to the server (from the user side) that the user is still using a web app: messages.prolongWebView + * Inflate stripped photosize to full JPG payload: inflateStripped + * Informs server about a purchase made through the App Store: for official applications only: payments.assignAppStoreTransaction + * Informs server about a purchase made through the Play Store: for official applications only: payments.assignPlayMarketTransaction + * Informs the server about the number of pending bot updates if they haven't been processed for a long time; for bots only: help.setBotUpdatesStatus + * Informs the server that the user has either:: channels.clickSponsoredMessage + * Initialize a takeout session, see here » for more info: account.initTakeoutSession + * Initialize connection: initConnection + * Initialize self-restart hack: initSelfRestart + * Initiate a 2FA password reset: can only be used if the user is already logged-in, see here for more info »: account.resetPassword + * Initiates QR code login: qrLogin + * Install a stickerset: messages.installStickerSet + * Install a theme: account.installTheme + * Install wallpaper: account.installWallPaper + * Install/uninstall wallpaper: account.saveWallPaper + * Installs a previously uploaded photo as a profile photo: photos.updateProfilePhoto + * Internal endpoint used by the download server: processDownloadServerPing + * Internal use: help.editUserInfo + * Invalidate the specified login codes, see here » for more info: account.invalidateSignInCodes + * Invite a set of users to a group call: phone.inviteToGroupCall + * Invite users to a channel/supergroup: channels.inviteToChannel + * Invoke a method within a takeout session, see here » for more info: invokeWithTakeout + * Invoke a request without subscribing the used connection for updates (this is enabled by default for file queries): invokeWithoutUpdates + * Invoke the specified query using the specified API layer: invokeWithLayer + * Invoke with the given message range: invokeWithMessagesRange + * Invokes a query after a successful completion of previous queries: invokeAfterMsgs + * Invokes a query after successful completion of one of the previous queries: invokeAfterMsg + * Join a channel/supergroup: channels.joinChannel + * Join a group call: phone.joinGroupCall + * Join channels and supergroups recently added to a chat folder deep link »: chatlists.joinChatlistUpdates + * Launch a prepaid giveaway »: payments.launchPrepaidGiveaway + * Leave a channel/supergroup: channels.leaveChannel + * Leave a group call: phone.leaveGroupCall + * List all chat folder deep links » associated to a folder: chatlists.getExportedInvites + * Load channel statistics graph asynchronously: stats.loadAsyncGraph + * Log in to telegram (via CLI or web): start + * Log out an active authorized session by its hash: account.resetAuthorization + * Log out an active web telegram login session: account.resetWebAuthorization + * Logger: logger + * Login as bot: botLogin + * Login as user: phoneLogin + * Login by importing an authorization token: auth.importWebTokenAuthorization + * Login using a redirected login token, generated in case of DC mismatch during QR code login: auth.importLoginToken + * Logout the session: logout + * Look for custom emojis associated to a UTF8 emoji: messages.searchCustomEmoji + * Look for updates of telegram's terms of service: help.getTermsOfServiceUpdate + * MTProto to TD params: MTProtoToTd + * MTProto to TDCLI params: MTProtoToTdcli + * Make a user admin in a basic group: messages.editChatAdmin + * Manually convert HTML to a message and a set of entities: htmlToMessageEntities + * Manually convert markdown to a message and a set of entities: markdownToMessageEntities + * Manually mark dialog as unread: messages.markDialogUnread + * Mark a specific sponsored message as read: channels.viewSponsoredMessage + * Mark a thread as read: messages.readDiscussion + * Mark all stories up to a certain ID as read, for a given peer; will emit an updateReadStories update to all logged-in sessions: stories.readStories + * Mark channel/supergroup history as read: channels.readHistory + * Mark channel/supergroup message contents as read: channels.readMessageContents + * Mark mentions as read: messages.readMentions + * Mark message reactions » as read: messages.readReactions + * Mark new featured stickers as read: messages.readFeaturedStickers + * Mark or unmark a sticker as favorite: messages.faveSticker + * Mark sponsored message as read: viewSponsoredMessage + * Marks message history as read: messages.readHistory + * Marks message history within a secret chat as read: messages.readEncryptedHistory + * Method for fetching previously featured stickers: messages.getOldFeaturedStickers + * Modify autosave settings: account.saveAutoSaveSettings + * Modify the admin rights of a user in a supergroup/channel: channels.editAdmin + * Notifies the sender about the recipient having listened a voice message or watched a video: messages.readMessageContents + * Notify the other user in a private chat that a screenshot of the chat was taken: messages.sendScreenshotNotification + * Notify the user that the sent passport data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change): users.setSecureValueErrors + * Obtain a certain event handler plugin instance: getPlugin + * Obtain a list of Telegram Premium giveaway/gift code » options: payments.getPremiumGiftCodeOptions + * Obtain a list of bot commands for the specified bot scope and language code: bots.getBotCommands + * Obtain a list of channels where the user can post stories: stories.getChatsToSend + * Obtain a list of related languages that must be used when fetching emoji keyword lists »: messages.getEmojiKeywordsLanguages + * Obtain a list of similarly themed public channels, selected based on similarities in their subscriber bases: channels.getChannelRecommendations + * Obtain available message reactions »: messages.getAvailableReactions + * Obtain configuration for two-factor authorization with password: account.getPassword + * Obtain forwards of a story as a message to public chats and reposts by public channels: stats.getStoryPublicForwards + * Obtain full info about a set of stories by their IDs: stories.getStoriesByID + * Obtain info about the view count, forward count, reactions and recent viewers of one or more stories: stories.getStoriesViews + * Obtain information about a Telegram Premium giftcode »: payments.checkGiftCode + * Obtain information about a Telegram Premium giveaway »: payments.getGiveawayInfo + * Obtain information about a chat folder deep link »: chatlists.checkChatlistInvite + * Obtain information about a direct link Mini App: messages.getBotApp + * Obtain the API ID UI template: getWebAPITemplate + * Obtain the latest read story ID for all peers when first logging in, returned as a list of updateReadStories updates, see here » for more info: stories.getAllReadPeerStories + * Obtain the list of users that have viewed a specific story we posted: stories.getStoryViewsList + * Obtain user info from a temporary profile link: contacts.importContactToken + * Obtain which peers are we currently boosting, and how many boost slots we have left: premium.getMyBoosts + * Obtains a list of messages, indicating to which other public channels was a channel message forwarded.: stats.getMessagePublicForwards + * Obtains a list of peers that can be used to send messages in a specific group: channels.getSendAs + * Obtains a pipe that can be used to upload a file from a stream: getStreamPipe + * Obtains info about the boosts that were applied to a certain channel (admins only): premium.getBoostsList + * Obtains information about a chat export file, generated by a foreign chat app, click here for more info about imported chats »: messages.checkHistoryImport + * Once the user has confirmed their payment and shipping details, the bot receives an updateBotPrecheckoutQuery update.: messages.setBotPrecheckoutResults + * Only useful when consuming MadelineProto updates through an API in another language (like Javascript), **absolutely not recommended when directly writing MadelineProto bots**: getUpdates + * Open a bot mini app from a direct Mini App deep link, sending over user information after user confirmation: messages.requestAppWebView + * Open a bot mini app, sending over user information after user confirmation: messages.requestWebView + * Open a bot mini app: messages.requestSimpleWebView + * Opens a file in append-only mode: openFileAppendOnly + * Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended: phone.receivedCall + * Parse, update and store settings: updateSettings + * Pauses playback of the current audio file in the call: pausePlay + * Perform static analysis on a certain event handler class, to make sure it satisfies some performance requirements: validateEventHandlerClass + * Pin a message: messages.updatePinnedMessage + * Pin or unpin a saved message dialog »: messages.toggleSavedDialogPin + * Pin or unpin forum topics: channels.updatePinnedForumTopic + * Pin or unpin one or more stories: stories.togglePinned + * Pin/unpin a dialog: messages.toggleDialogPin + * Play file in call: callPlay + * Play files on hold in call: callPlayOnHold + * Positive modulo: posmod + * Press an inline callback button and get a callback answer from the bot: messages.getBotCallbackAnswer + * Provide a buffered reader for a file, URL or amp stream: openBuffered + * Provide a stream for a file, URL or amp stream: getStream + * Query an inline bot: messages.getInlineBotResults + * Rate a call, returns info about the rating message sent to the official VoIP bot: phone.setCallRating + * Rate transcribed voice message: messages.rateTranscribedAudio + * React to a story: stories.sendReaction + * React to message: messages.sendReaction + * Refresh full peer cache for a certain peer: refreshFullPeerCache + * Refresh peer cache for a certain peer: refreshPeerCache + * Register device to receive PUSH notifications: account.registerDevice + * Remove a sticker from the set where it belongs, bots only. The sticker set must have been created by the bot: stickers.removeStickerFromSet + * Removes all contacts without an associated Telegram account: contacts.resetSaved + * Renames a stickerset, bots only: stickers.renameStickerSet + * Reorder active usernames: channels.reorderUsernames + * Reorder folders: messages.updateDialogFiltersOrder + * Reorder installed stickersets: messages.reorderStickerSets + * Reorder pinned dialogs: messages.reorderPinnedDialogs + * Reorder pinned forum topics: channels.reorderPinnedForumTopics + * Reorder pinned saved message dialogs »: messages.reorderPinnedSavedDialogs + * Reorder usernames associated to a bot we own: bots.reorderUsernames + * Reorder usernames associated with the currently logged-in user: account.reorderUsernames + * Replace the contents of an entire blocklist, see here for more info »: contacts.setBlocked + * Report a message in a chat for violation of telegram's Terms of Service: messages.report + * Report a message reaction: messages.reportReaction + * Report a native antispam false positive: channels.reportAntiSpamFalsePositive + * Report a new incoming chat for spam, if the peer settings of the chat allow us to do that: messages.reportSpam + * Report a peer for violation of telegram's Terms of Service: account.reportPeer + * Report a profile photo of a dialog: account.reportProfilePhoto + * Report a secret chat for spam: messages.reportEncryptedSpam + * Report a story: stories.report + * Report an error to the previously set peer: report + * Report memory profile with memprof: reportMemoryProfile + * Reports some messages from a user in a supergroup as spam; requires administrator rights in the supergroup: channels.reportSpam + * Represents a list of emoji categories, to be used when selecting custom emojis to set as custom emoji status: messages.getEmojiStatusGroups + * Represents a list of emoji categories, to be used when selecting custom emojis to set as profile picture: messages.getEmojiProfilePhotoGroups + * Represents a list of emoji categories, to be used when selecting custom emojis: messages.getEmojiGroups + * Request VoIP call: requestCall + * Request an SMS code via Firebase: auth.requestFirebaseSms + * Request recovery code of a 2FA password, only for accounts with a recovery email configured: auth.requestPasswordRecovery + * Request secret chat: requestSecretChat + * Resend the code to verify an email to use as 2FA recovery method: account.resendPasswordEmail + * Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see login for more info: auth.resendCode + * Reset all active web telegram login sessions: account.resetWebAuthorizations + * Reset rating of top peer: contacts.resetTopPeerRating + * Reset the 2FA password using the recovery code sent using auth.requestPasswordRecovery: auth.recoverPassword + * Reset the login email »: auth.resetLoginEmail + * Reset the update state and fetch all updates from the beginning: resetUpdateState + * Resets all notification settings from users and groups: account.resetNotifySettings + * Resolve a phone number to get user info, if their privacy settings allow it: contacts.resolvePhone + * Restart update loop: restart + * Resumes playback of the current audio file in the call: resumePlay + * Rethrow exception into event loop: rethrow + * Return all message drafts.: messages.getAllDrafts + * Return current settings: getSettings + * Returns a Telegram Passport authorization form for sharing data with a service: account.getAuthorizationForm + * Returns a list of available wallpapers: account.getWallPapers + * Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new emoji keywords ». The URL will be valid for 30 seconds after generation: messages.getEmojiURL + * Returns attachment menu entry for a bot mini app that can be launched from the attachment menu »: messages.getAttachMenuBot + * Returns chat basic info on their IDs: messages.getChats + * Returns content of a web file, by proxying the request through telegram, see the webfile docs for more info: upload.getWebFile + * Returns current configuration, including data center configuration: help.getConfig + * Returns fetch the full list of custom emoji IDs » that cannot be used in channel emoji statuses »: account.getChannelRestrictedStatusEmojis + * Returns identifiers of pinned or always included chats from a chat folder imported using a chat folder deep link », which are suggested to be left when the chat folder is deleted: chatlists.getLeaveChatlistSuggestions + * Returns info on data center nearest to the user: help.getNearestDc + * Returns information about the next messages of the specified type in the chat split by days: messages.getSearchResultsCalendar + * Returns information on update availability for the current application: help.getAppUpdate + * Returns installed attachment menu bot mini apps »: messages.getAttachMenuBots + * Returns list of chats with non-default notification settings: account.getNotifyExceptions + * Returns localized text of a text message with an invitation: help.getInviteText + * Returns saved messages » forwarded from a specific peer: messages.getSavedHistory + * Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation: messages.getSearchResultsPositions + * Returns the conversation history with one interlocutor / within a chat: messages.getHistory + * Returns the current saved dialog list, see here » for more info: messages.getSavedDialogs + * Returns the current user dialog list: messages.getDialogs + * Returns the current user's contact list: contacts.getContacts + * Returns the list of blocked users: contacts.getBlocked + * Returns the list of messages by their IDs: messages.getMessages + * Returns the list of user photos: photos.getUserPhotos + * Returns the lists of boost that were applied to a channel by a specific user (admins only): premium.getUserBoosts + * Returns the session name: getSessionName + * Returns the support user for the "ask a question" feature: help.getSupport + * Returns users found by username substring: contacts.search + * Returns whether the current user is a bot: isSelfBot + * Returns whether the current user is a premium user, cached: isPremium + * Returns whether the current user is a user: isSelfUser + * Reupload telegram file: uploadFromTgfile + * Save a message draft associated to a chat: messages.saveDraft + * Save a theme: account.saveTheme + * Save or remove saved notification sound: account.saveRingtone + * Save phone call debug information: phone.saveCallLog + * Saves logs of application on the server: help.saveAppLog + * Search for custom emoji stickersets »: messages.searchEmojiStickerSets + * Search for messages and peers globally: messages.searchGlobal + * Search for messages: messages.search + * Search for stickersets: messages.searchStickerSets + * Securely save Telegram Passport document, for more info see the passport docs »: account.saveSecureValue + * Send VoIP signaling data: phone.sendSignalingData + * Send a custom request from a mini bot app, triggered by a web_app_invoke_custom_method event »: bots.invokeWebViewCustomMethod + * Send a media: messages.sendMedia + * Send a result obtained using messages.getInlineBotResults: messages.sendInlineBotResult + * Send an album or grouped media: messages.sendMultiMedia + * Send an email verification code: account.sendVerifyEmailCode + * Send compiled payment form: payments.sendPaymentForm + * Send confirmation code to cancel account deletion, for more info click here »: account.sendConfirmPhoneCode + * Send one or more chosen peers, as requested by a keyboardButtonRequestPeer button: messages.sendBotRequestedPeer + * Send phone call debug data to server: phone.saveCallDebug + * Send scheduled messages right away: messages.sendScheduledMessages + * Send the verification phone code for telegram passport: account.sendVerifyPhoneCode + * Send typing event by the current user to a secret chat: messages.setEncryptedTyping + * Sends a Telegram Passport authorization form, effectively sharing data with the service: account.acceptAuthorization + * Sends a current user typing event (see SendMessageAction for all event types) to a conversation partner or group: messages.setTyping + * Sends a custom request; for bots only: bots.sendCustomRequest + * Sends a document: sendDocument + * Sends a gif: sendGif + * Sends a list of messages to all peers (users, chats, channels) of the bot: broadcastMessages + * Sends a message to a chat: messages.sendMessage + * Sends a message to all report peers (admins of the bot): sendMessageToAdmins + * Sends a message with a file attachment to a secret chat: messages.sendEncryptedFile + * Sends a message: sendMessage + * Sends a photo: sendDocumentPhoto + * Sends a photo: sendPhoto + * Sends a service message to a secret chat: messages.sendEncryptedService + * Sends a sticker: sendSticker + * Sends a text message to a secret chat: messages.sendEncrypted + * Sends a video: sendVideo + * Sends a voice: sendVoice + * Sends an audio: sendAudio + * Sends an updateCustomEvent update to the event handler: sendCustomEvent + * Set NOOP update handler, ignoring all updates: setNoop + * Set a custom wallpaper » in a specific private chat with another user: messages.setChatWallPaper + * Set account self-destruction period: account.setAccountTTL + * Set an emoji status for a channel: channels.updateEmojiStatus + * Set an emoji status: account.updateEmojiStatus + * Set bot command list: bots.setBotCommands + * Set global privacy settings: account.setGlobalPrivacySettings + * Set localized name, about text and description of a bot (or of the current account, if called by a bot): bots.setBotInfo + * Set maximum Time-To-Live of all messages in the specified chat: messages.setHistoryTTL + * Set output file or stream for incoming OPUS audio packets in a call: callSetOutput + * Set peer(s) where to send errors occurred in the event loop: setReportPeers + * Set sensitive content settings (for viewing or hiding NSFW content): account.setContentSettings + * Set stickerset thumbnail: stickers.setStickerSetThumb + * Set the API ID UI template: setWebApiTemplate + * Set the callback answer to a user button press (bots only): messages.setBotCallbackAnswer + * Set the default peer that will be used to join a group call in a specific dialog: phone.saveDefaultGroupCallJoinAs + * Set the default suggested admin rights for bots being added as admins to channels, see here for more info on how to handle them »: bots.setBotBroadcastDefaultAdminRights + * Set the default suggested admin rights for bots being added as admins to groups, see here for more info on how to handle them »: bots.setBotGroupDefaultAdminRights + * Set time-to-live of current session: account.setAuthorizationTTL + * Set webhook update handler: setWebhook + * Set whether all users should join a discussion group in order to comment on a post »: channels.toggleJoinToSend + * Set whether all users should request admin approval to join the group »: channels.toggleJoinRequest + * Sets the menu button action » for a given user or for all users: bots.setBotMenuButton + * Should be called after the user hides the report spam/add as contact bar of a new chat, effectively prevents the user from executing the actions specified in the action bar »: messages.hidePeerSettingsBar + * Show or hide the real-time chat translation popup for a certain chat: messages.togglePeerTranslations + * Start a conversation with a bot using a deep linking parameter: messages.startBot + * Start a scheduled group call: phone.startScheduledGroupCall + * Start multiple instances of MadelineProto and the event handlers (enables async): startAndLoopMulti + * Start or stop recording a group call: the recorded audio and video streams will be automatically sent to Saved messages (the chat with ourselves): phone.toggleGroupCallRecord + * Start screen sharing in a call: phone.joinGroupCallPresentation + * Stop getting notifications about discussion replies of a certain user in @replies: contacts.blockFromReplies + * Stop screen sharing in a group call: phone.leaveGroupCallPresentation + * Stop update loop: stop + * Stops playing all files in the call, clears the main and the hold playlist: stopPlay + * Store RSA keys for CDN datacenters: getCdnConfig + * Submit requested order information for validation: payments.validateRequestedInfo + * Subscribe or unsubscribe to a scheduled group call: phone.toggleGroupCallStartSubscription + * Subscribe to event handler updates for a channel/supergroup we're not a member of: subscribeToUpdates + * Suggests a short name for a given stickerpack name: stickers.suggestShortName + * Telegram UTF-8 multibyte split: mbStrSplit + * Telegram UTF-8 multibyte substring: mbSubstr + * Terminate a group call: phone.discardGroupCall + * Terminate a takeout session, see here » for more info: account.finishTakeoutSession + * Terminate webview interaction started with messages.requestWebView, sending the specified message to the chat on behalf of the user: messages.sendWebViewResultMessage + * Terminates all user's authorized sessions except for the current one: auth.resetAuthorizations + * Test fibers: testFibers + * Toggle contact sign up notifications: account.setContactSignUpNotification + * Toggle supergroup slow mode: if enabled, users will only be able to send one message every seconds seconds: channels.toggleSlowMode + * Transcribe voice message: messages.transcribeAudio + * Transfer channel ownership: channels.editCreator + * Translate a given text: messages.translateText + * Turn a basic group into a supergroup: messages.migrateChat + * Uninstall a stickerset: messages.uninstallStickerSet + * Unpack base256 signed int: unpackSignedInt + * Unpack base256 signed long to string: unpackSignedLongString + * Unpack base256 signed long: unpackSignedLong + * Unpack binary double: unpackDouble + * Unpack bot API file ID: unpackFileId + * Unpin all pinned messages: messages.unpinAllMessages + * Unset event handler: unsetEventHandler + * Update folder: messages.updateDialogFilter + * Update the accent color and background custom emoji » of a channel: channels.updateColor + * Update the accent color and background custom emoji » of the current account: account.updateColor + * Update the keywords, emojis or mask coordinates of a sticker, bots only: stickers.changeSticker + * Update theme: account.updateTheme + * Updates current user profile photo: photos.uploadProfilePhoto + * Updates online user status: account.updateStatus + * Updates user profile: account.updateProfile + * Upload a custom profile picture for a contact, or suggest a new profile picture to a contact: photos.uploadContactProfilePhoto + * Upload a file and associate it to a chat (without actually sending it to the chat): messages.uploadMedia + * Upload a media file associated with an imported chat, click here for more info »: messages.uploadImportedMedia + * Upload encrypted file and associate it to a secret chat: messages.uploadEncryptedFile + * Upload file from URL: uploadFromUrl + * Upload file from callable: uploadFromCallable + * Upload file from stream: uploadFromStream + * Upload file to secret chat: uploadEncrypted + * Upload file: upload + * Upload notification sound, use account.saveRingtone to convert it and add it to the list of saved notification sounds: account.uploadRingtone + * Upload theme: account.uploadTheme + * Uploads a Telegram Story: stories.sendStory + * Use this method to obtain the online statuses of all contacts with an accessible Telegram account: contacts.getStatuses + * Use this method to set the score of the specified user in a game sent as a normal message (bots only): messages.setGameScore + * Use this method to set the score of the specified user in a game sent as an inline message (bots only): messages.setInlineGameScore + * Use this to accept a Seamless Telegram Login authorization request, for more info click here »: messages.acceptUrlAuth + * Used by the user to relay data from an opened reply keyboard bot mini app to the bot that owns it: messages.sendWebViewData + * Users may also choose to display messages from all topics of a forum as if they were sent to a normal group, using a "View as messages" setting in the local client: this setting only affects the current account, and is synced to other logged in sessions using this method: channels.toggleViewForumAsMessages + * Validates a username and checks availability: account.checkUsername + * Verify a new phone number to associate to the current account: account.sendChangePhoneCode + * Verify a phone number for telegram passport: account.verifyPhone + * Verify an email address: account.verifyEmail + * Verify an email to use as 2FA recovery method: account.confirmPasswordEmail + * View and search recently sent media.: messages.searchSentMedia + * Vote in a poll: messages.sendVote + * When called, skips to the next file in the playlist: skipPlay + * When client-side passcode lock feature is enabled, will not show message texts in incoming PUSH notifications: account.updateDeviceLocked + * When was full info for this chat last cached: fullChatLastUpdated + * Whether the currently playing audio file is paused: isPlayPaused + * Whether the user will receive notifications when contacts sign up: account.getContactSignUpNotification + * Whether this is altervista: isAltervista + * Whether we can convert any audio/video file to a VoIP OGG OPUS file, or the files must be preconverted using @libtgvoipbot: canConvertOgg + * Whether we can convert any audio/video file using ffmpeg: canUseFFmpeg + * Whether we're an IPC client instance: isIpc + * Whether we're an IPC server process (as opposed to an event handler): isIpcWorker + * Whether we're currently connected to the test DCs: isTestMode + * Wrap a Message constructor into an abstract Message object: wrapMessage + * Wrap a Pin constructor into an abstract Pinned object: wrapPin + * Wrap a media constructor into an abstract Media object: wrapMedia + * Wrap an Update constructor into an abstract Update object: wrapUpdate + * account.createBusinessChatLink + * account.deleteBusinessChatLink + * account.disablePeerConnectedBot + * account.editBusinessChatLink + * account.getBotBusinessConnection + * account.getBusinessChatLinks + * account.getConnectedBots + * account.getReactionsNotifySettings + * account.resolveBusinessChatLink + * account.setReactionsNotifySettings + * account.toggleConnectedBotPaused + * account.toggleSponsoredMessages + * account.updateBirthday + * account.updateBusinessAwayMessage + * account.updateBusinessGreetingMessage + * account.updateBusinessIntro + * account.updateBusinessLocation + * account.updateBusinessWorkHours + * account.updateConnectedBot + * account.updatePersonalChannel + * auth.reportMissingCode + * base64URL decode: base64urlDecode + * channels.reportSponsoredMessage + * channels.restrictSponsoredMessages + * channels.setBoostsToUnblockRestrictions + * channels.setEmojiStickers + * contacts.getBirthdays + * fragment.getCollectibleInfo + * help.getTimezonesList + * invokeWithBusinessConnection + * messages.checkQuickReplyShortcut + * messages.deleteQuickReplyMessages + * messages.deleteQuickReplyShortcut + * messages.editQuickReplyShortcut + * messages.getDefaultTagReactions + * messages.getEmojiStickerGroups + * messages.getMyStickers + * messages.getOutboxReadDate + * messages.getQuickReplies + * messages.getQuickReplyMessages + * messages.getSavedReactionTags + * messages.reorderQuickReplies + * messages.sendQuickReplyMessages + * messages.toggleDialogFilterTags + * messages.updateSavedReactionTag + * null-byte RLE decode: rleDecode + * null-byte RLE encode: rleEncode + * smsjobs.finishJob + * smsjobs.getSmsJob + * smsjobs.getStatus + * smsjobs.isEligibleToJoin + * smsjobs.join + * smsjobs.leave + * smsjobs.updateSettings + * stats.getBroadcastRevenueStats + * stats.getBroadcastRevenueTransactions + * stats.getBroadcastRevenueWithdrawalUrl + * stickers.replaceSticker + * stories.togglePinnedToTop + * users.getIsPremiumRequiredToContact +* [Contributing](https://docs.madelineproto.xyz/docs/CONTRIB.html) - You can contribute in various ways. + * [Translation](https://docs.madelineproto.xyz/docs/CONTRIB.html#translation) + * [Contribution guide](https://docs.madelineproto.xyz/docs/CONTRIB.html#contribution-guide) + * [Credits](https://docs.madelineproto.xyz/docs/CONTRIB.html#credits) +* [Web templates for `$MadelineProto->start()`](https://docs.madelineproto.xyz/docs/TEMPLATES.html) - The web template used for the $MadelineProto->start() and API ID web UIs can be changed. + diff --git a/docs/logo-hover.png b/docs/logo-hover.png new file mode 100644 index 0000000000..87af34448d Binary files /dev/null and b/docs/logo-hover.png differ diff --git a/docs/logo.png b/docs/logo.png new file mode 100644 index 0000000000..476ad6d58d Binary files /dev/null and b/docs/logo.png differ diff --git a/docs/phoneLogin.md b/docs/phoneLogin.md new file mode 100644 index 0000000000..49028be3ca --- /dev/null +++ b/docs/phoneLogin.md @@ -0,0 +1,39 @@ +--- +title: phoneLogin +description: phoneLogin parameters, return type and example +redirect_from: /phone_login.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: phoneLogin + + +### Parameters: + +| Name | Type | +|----------|---------------| +|number| A string with the phone number, including the country code| + +### Return type: [auth.SentCode](API_docs/types/auth.SentCode.html) + +You must then use [completePhoneLogin](completePhoneLogin.html) + + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$MadelineProto->phoneLogin(readline('Enter your phone number: ')); +$authorization = $MadelineProto->completePhoneLogin(readline('Enter the code you received: ')); +if ($authorization['_'] === 'account.noPassword') { + throw new \danog\MadelineProto\Exception('2FA is enabled but no password is set!'); +} +if ($authorization['_'] === 'account.password') { + $authorization = $MadelineProto->complete2falogin(readline('Please enter your password (hint '.$authorization['hint'].'): ')); +} +if ($authorization['_'] === 'account.needSignup') { + $authorization = $MadelineProto->completeSignup(readline('Please enter your first name: '), readline('Please enter your last name (can be empty): ')); +} + +``` + diff --git a/docs/requestSecretChat.md b/docs/requestSecretChat.md new file mode 100644 index 0000000000..28c8d61abc --- /dev/null +++ b/docs/requestSecretChat.md @@ -0,0 +1,27 @@ +--- +title: requestSecretChat +description: requestSecretChat parameters, return type and example +redirect_from: /request_secret_chat.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: requestSecretChat + + +### Parameters: + +| Name | Type | +|----------|---------------| +|id| A username, a bot API chat id, a tg-cli chat id, a [User](API_docs/types/User.html), an [InputPeer](API_docs/types/InputPeer.html), an [InputUser](API_docs/types/InputUser.html), a [Peer](API_docs/types/Peer.html)| + +### Return type: Number + +Returns the secret chat ID + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +$secret_chat_id = $MadelineProto->requestSecretChat('@danogentili'); +``` + diff --git a/docs/res/bg1.png b/docs/res/bg1.png new file mode 100644 index 0000000000..a09782f97f Binary files /dev/null and b/docs/res/bg1.png differ diff --git a/docs/res/bg1_blured.png b/docs/res/bg1_blured.png new file mode 100644 index 0000000000..afda0bc47c Binary files /dev/null and b/docs/res/bg1_blured.png differ diff --git a/docs/robots.txt b/docs/robots.txt new file mode 100644 index 0000000000..824b433c13 --- /dev/null +++ b/docs/robots.txt @@ -0,0 +1,5 @@ +User-agent: * +Allow: / + +sitemap: https://docs.madelineproto.xyz/sitemap.xml + diff --git a/docs/update2fa.md b/docs/update2fa.md new file mode 100644 index 0000000000..8acbbf0f23 --- /dev/null +++ b/docs/update2fa.md @@ -0,0 +1,33 @@ +--- +title: update2fa +description: Update 2FA password +redirect_from: /update_2fa.html +grand_parent: "Telegram RPC API" +parent: "Methods" +--- +## Method: update2fa + +The params array can contain password (current password), new_password, email (optional) and hint params. + +### Parameters: + +| Name | Type | +|----------|---------------| +|params|An array of parameters| + +### Return type: [Bool](API_docs/types/Bool.html) + +### Example ([now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +try { + $MadelineProto->update2fa(['password' => 'current password', 'new_password' => 'New password', 'email' => 'daniil@daniil.it', 'hint' => 'ponies']); +} catch (RPCErrorException $e) { + if (strpos($e->rpc, 'EMAIL_UNCONFIRMED_') !== false) { + $Bool = $MadelineProto->account->confirmPasswordEmail(['code' => $MadelineProto->readline('Enter your email code: ')]); + } else { + throw $e; + } +} +``` diff --git a/template/!X.md b/template/!X.md new file mode 100644 index 0000000000..ec30994107 --- /dev/null +++ b/template/!X.md @@ -0,0 +1,11 @@ +--- +title: !X +description: Represents a TL serialized payload +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: !X +[Back to constructor index](index.html) + +Represents a TL serialized payload. +Typically you would want to provide a simple constructor or a method array here (method name under `_` as with constructors). diff --git a/template/Bool.md b/template/Bool.md new file mode 100644 index 0000000000..29aa87e0a5 --- /dev/null +++ b/template/Bool.md @@ -0,0 +1,10 @@ +--- +title: Bool +description: Represents a boolean. +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Bool +[Back to types index](index.html) + +Represents a boolean. diff --git a/template/DataJSON.md b/template/DataJSON.md new file mode 100644 index 0000000000..b7fca5c01a --- /dev/null +++ b/template/DataJSON.md @@ -0,0 +1,10 @@ +--- +title: DataJSON +description: Any json-encodable data +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: DataJSON +[Back to constructor index](index.html) + +Any json-encodable data. diff --git a/template/InputCheckPasswordSRP.md b/template/InputCheckPasswordSRP.md new file mode 100644 index 0000000000..d7eaf0e357 --- /dev/null +++ b/template/InputCheckPasswordSRP.md @@ -0,0 +1 @@ +You can also directly provide a password as a string. diff --git a/template/InputDocument.md b/template/InputDocument.md new file mode 100644 index 0000000000..01aad31026 --- /dev/null +++ b/template/InputDocument.md @@ -0,0 +1 @@ +You can also provide a [MessageMedia](MessageMedia.html), [Message](Message.html), [Update](Update.html), [Document](Document.html) here, MadelineProto will automatically convert it to the right type. diff --git a/template/InputEncryptedChat.md b/template/InputEncryptedChat.md new file mode 100644 index 0000000000..39b13615ce --- /dev/null +++ b/template/InputEncryptedChat.md @@ -0,0 +1,8 @@ +You can directly provide the [Update](Update.html) or [EncryptedMessage](EncryptedMessage.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntax can also be used: + +```php +$%s = -147286699; // Numeric chat id returned by requestSecretChat, can be positive or negative +``` + diff --git a/template/InputFile.md b/template/InputFile.md new file mode 100644 index 0000000000..6028f63392 --- /dev/null +++ b/template/InputFile.md @@ -0,0 +1,8 @@ +The following syntax can also be used: + +```php +$%s = 'filename.mp4'; // The file path can also be used +$%1$s = 'https://google.com'; // A URL can also be used +``` + +You can also use async streams, HTTP response objects, and [much more](https://docs.madelineproto.xyz/docs/FILES.html#downloading-files)! diff --git a/template/InputMedia.md b/template/InputMedia.md new file mode 100644 index 0000000000..eb602370de --- /dev/null +++ b/template/InputMedia.md @@ -0,0 +1 @@ +You can also provide a [MessageMedia](MessageMedia.html), [Message](Message.html), [Update](Update.html), [Document](Document.html), [Photo](Photo.html), [InputDocument](InputDocument.html), [InputPhoto](InputPhoto.html) here, MadelineProto will automatically convert it to the right type. diff --git a/template/InputMessage.md b/template/InputMessage.md new file mode 100644 index 0000000000..ace6a0b804 --- /dev/null +++ b/template/InputMessage.md @@ -0,0 +1,7 @@ +The following syntax can also be used: + +```php +$%s = 142; // Numeric message ID +``` + + diff --git a/template/InputPhoto.md b/template/InputPhoto.md new file mode 100644 index 0000000000..f430af0518 --- /dev/null +++ b/template/InputPhoto.md @@ -0,0 +1 @@ +You can also provide a [MessageMedia](MessageMedia.html), [Message](Message.html), [Update](Update.html), [Photo](Photo.html) here, MadelineProto will automatically convert it to the right type. diff --git a/template/KeyboardButton.md b/template/KeyboardButton.md new file mode 100644 index 0000000000..69a1b90637 --- /dev/null +++ b/template/KeyboardButton.md @@ -0,0 +1,21 @@ +Clicking these buttons: + +To click these buttons simply run the `click` method: + +```php +$result = $%s->click(); +``` + +`$result` can be one of the following: + + +* A string - If the button is a keyboardButtonUrl + +* [Updates](Updates.html) - If the button is a keyboardButton, the message will be sent to the chat, in reply to the message with the keyboard + +* [messages.BotCallbackAnswer](messages.BotCallbackAnswer.html) - If the button is a keyboardButtonCallback or a keyboardButtonGame the button will be pressed and the result will be returned + +* `false` - If the button is an unsupported button, like keyboardButtonRequestPhone, keyboardButtonRequestGeoLocation, keyboardButtonSwitchInlinekeyboardButtonBuy; you will have to parse data from these buttons manually + + +You can also access the properties of the constructor as a normal array, for example `$button['name']` diff --git a/template/Method.md b/template/Method.md new file mode 100644 index 0000000000..c4baa61157 --- /dev/null +++ b/template/Method.md @@ -0,0 +1,12 @@ +--- +title: "%s" +description: "%s" +grand_parent: "Telegram RPC API" +parent: "Methods" +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png%s +--- +# Method: %s +[Back to methods index](index.html) + + + diff --git a/template/PhoneCall.md b/template/PhoneCall.md new file mode 100644 index 0000000000..9918a418a9 --- /dev/null +++ b/template/PhoneCall.md @@ -0,0 +1 @@ +See [here »](https://docs.madelineproto.xyz/PHP/danog/MadelineProto/VoIP.html) for the full documentation! \ No newline at end of file diff --git a/template/ReplyMarkup.md b/template/ReplyMarkup.md new file mode 100644 index 0000000000..63ccc23351 --- /dev/null +++ b/template/ReplyMarkup.md @@ -0,0 +1,6 @@ +For simplicity, you can also provide a bot API markup object, one of: +- [bot API InlineKeyboardMarkup](https://core.telegram.org/bots/api#inlinekeyboardmarkup) +- [bot API ReplyKeyboardMarkup](https://core.telegram.org/bots/api#replykeyboardmarkup) +- [bot API ReplyKeyboardRemove](https://core.telegram.org/bots/api#replykeyboardremove) +- [bot API ForceReply](https://core.telegram.org/bots/api#forcereply) + diff --git a/template/Type.md b/template/Type.md new file mode 100644 index 0000000000..016d2a3035 --- /dev/null +++ b/template/Type.md @@ -0,0 +1,19 @@ +--- +title: %s +description: constructors and methods of type %1$s +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png%s +--- +# Type: %s +[Back to types index](index.html) + +%s + +### Possible values (constructors): + +%s + +### Methods that return an object of this type (methods): + +%s + diff --git a/template/Updates.md b/template/Updates.md new file mode 100644 index 0000000000..2a21f2b5b2 --- /dev/null +++ b/template/Updates.md @@ -0,0 +1,15 @@ +You can use the following methods to extract information from this constructor: + +```php +// Extract an array of Update constructors +$vector_of_update = $MadelineProto->extractUpdates($Updates); + +// Extract an updateNewMessage, updateNewChannelMessage, updateEditMessage, updateEditChannelMessage constructor +$message_update = $MadelineProto->extractMessageUpdate($Updates); + +// Extract a message constructor +$message = $MadelineProto->extractMessage($Updates); + +// Extract a message ID +$message = $MadelineProto->extractMessageId($Updates); +``` diff --git a/template/User.md b/template/User.md new file mode 100644 index 0000000000..ef5270d15b --- /dev/null +++ b/template/User.md @@ -0,0 +1,35 @@ +You can directly provide the [Update](Update.html) or [Message](Message.html) object here, MadelineProto will automatically extract the destination chat id. + +The following syntaxes can also be used: + +```php +$%1$s = '@username'; // Username + +$%1$s = $update; // Update objects received in the event handler + +$%1$s = 'me'; // The currently logged-in user + +$%1$s = 44700; // bot API id (users) +$%1$s = -492772765; // bot API id (chats) +$%1$s = -10038575794; // bot API id (channels) + +$%1$s = 'https://t.me/danogentili'; // t.me URLs +$%1$s = 'https://t.me/joinchat/asfln1-21fa_'; // t.me invite links + +``` + +You can also provide one of the following objects, instead, MadelineProto will handle conversion automatically: + +- [Chat](Chat.html) +- [User](User.html) +- [InputPeer](InputPeer.html) +- [InputDialogPeer](InputDialogPeer.html) +- [InputNotifyPeer](InputNotifyPeer.html) +- [InputUser](InputUser.html) +- [InputChannel](InputChannel.html) +- [Peer](Peer.html) +- [DialogPeer](DialogPeer.html) +- [NotifyPeer](NotifyPeer.html) +- [Chat](Chat.html) + + diff --git a/template/boolFalse.md b/template/boolFalse.md new file mode 100644 index 0000000000..a3fd4f1a87 --- /dev/null +++ b/template/boolFalse.md @@ -0,0 +1,10 @@ +--- +title: boolFalse +description: Represents a boolean with value equal to false +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# boolFalse +[Back to constructor index](index.html) + +Represents a boolean with value equal to `false`. diff --git a/template/boolTrue.md b/template/boolTrue.md new file mode 100644 index 0000000000..3e6866f9b0 --- /dev/null +++ b/template/boolTrue.md @@ -0,0 +1,10 @@ +--- +title: boolTrue +description: Represents a boolean with value equal to true +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# boolTrue +[Back to constructor index](index.html) + +Represents a boolean with value equal to `true`. diff --git a/template/bytes.md b/template/bytes.md new file mode 100644 index 0000000000..ff1d00fbe5 --- /dev/null +++ b/template/bytes.md @@ -0,0 +1,13 @@ +--- +title: bytes +description: A string of variable length +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: bytes +[Back to constructor index](index.html) + +```php +$bytes = "simple string of bytes"; +``` + diff --git a/template/chunks.md b/template/chunks.md new file mode 100644 index 0000000000..ec073df826 --- /dev/null +++ b/template/chunks.md @@ -0,0 +1,6 @@ + +## Return value + +If the length of the provided message is bigger than 4096, the message will be split in chunks and the method will be called multiple times, with the same parameters (except for the message), and an array of [%s](../types/%s.html) will be returned instead. + + diff --git a/template/constructor-example.md b/template/constructor-example.md new file mode 100644 index 0000000000..68ffcded4c --- /dev/null +++ b/template/constructor-example.md @@ -0,0 +1,5 @@ +### Example: + +``` +$%s = %s; +``` diff --git a/template/constructors-index.md b/template/constructors-index.md new file mode 100644 index 0000000000..2dc26b1c7f --- /dev/null +++ b/template/constructors-index.md @@ -0,0 +1,10 @@ +--- +title: Constructors +description: List of constructors +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructors +[Back to API documentation index](..) + +%s diff --git a/template/disallow.json b/template/disallow.json new file mode 100644 index 0000000000..6f7ab35a45 --- /dev/null +++ b/template/disallow.json @@ -0,0 +1,41 @@ +{ + "__messages.getHistory": "Please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html)", + "__channels.getMessages": "Please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html)", + "__messages.getMessages": "Please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html)", + "account.updatePasswordSettings": "You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https:\/\/docs.madelineproto.xyz for more info)", + "account.getPasswordSettings": "You cannot use this method directly; use $MadelineProto->update2fa($params), instead (see https:\/\/docs.madelineproto.xyz for more info)", + "messages.receivedQueue": "You cannot use this method directly", + "messages.getDhConfig": "You cannot use this method directly, instead use $MadelineProto->getDhConfig();", + "auth.bindTempAuthKey": "You cannot use this method directly, instead modify the PFS and default_temp_auth_key_expires_in settings, see https:\/\/docs.madelineproto.xyz\/docs\/SETTINGS.html for more info", + "auth.exportAuthorization": "You cannot use this method directly, use $MadelineProto->exportAuthorization() instead, see https:\/\/docs.madelineproto.xyz\/docs\/LOGIN.html", + "auth.importAuthorization": "You cannot use this method directly, use $MadelineProto->importAuthorization($authorization) instead, see https:\/\/docs.madelineproto.xyz\/docs\/LOGIN.html", + "auth.logOut": "You cannot use this method directly, use the logout method instead (see https:\/\/docs.madelineproto.xyz for more info)", + "auth.importBotAuthorization": "You cannot use this method directly, use the botLogin method instead (see https:\/\/docs.madelineproto.xyz for more info)", + "auth.sendCode": "You cannot use this method directly, use the phoneLogin method instead (see https:\/\/docs.madelineproto.xyz for more info)", + "auth.signIn": "You cannot use this method directly, use the completePhoneLogin method instead (see https:\/\/docs.madelineproto.xyz for more info)", + "auth.checkPassword": "You cannot use this method directly, use the complete2falogin method instead (see https:\/\/docs.madelineproto.xyz for more info)", + "auth.signUp": "You cannot use this method directly, use the completeSignup method instead (see https:\/\/docs.madelineproto.xyz for more info)", + "users.getFullUser": "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https:\/\/docs.madelineproto.xyz for more info)", + "users.getUsers": "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https:\/\/docs.madelineproto.xyz for more info)", + "channels.getChannels": "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https:\/\/docs.madelineproto.xyz for more info)", + "channels.getFullChannel": "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https:\/\/docs.madelineproto.xyz for more info)", + "messages.getFullChat": "You cannot use this method directly, use the getPwrChat, getInfo, getFullInfo methods instead (see https:\/\/docs.madelineproto.xyz for more info)", + "contacts.resolveUsername": "You cannot use this method directly, use the resolveUsername, getPwrChat, getInfo, getFullInfo methods instead (see https:\/\/docs.madelineproto.xyz for more info)", + "messages.acceptEncryption": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz for more info on handling secret chats", + "messages.discardEncryption": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz for more info on handling secret chats", + "messages.requestEncryption": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz for more info on handling secret chats", + "phone.requestCall": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz#calls for more info on handling calls", + "phone.acceptCall": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz#calls for more info on handling calls", + "phone.confirmCall": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz#calls for more info on handling calls", + "phone.discardCall": "You cannot use this method directly, see https:\/\/docs.madelineproto.xyz#calls for more info on handling calls", + "updates.getChannelDifference": "You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead.", + "updates.getDifference": "You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead.", + "updates.getState": "You cannot use this method directly, please use the [event handler](https://docs.madelineproto.xyz/docs/UPDATES.html), instead.", + "upload.getCdnFile": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info", + "upload.getFileHashes": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info", + "upload.getCdnFileHashes": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info", + "upload.reuploadCdnFile": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info", + "upload.getFile": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info", + "upload.saveFilePart": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info", + "upload.saveBigFilePart": "You cannot use this method directly, use the upload, downloadToStream, downloadToFile, downloadToDir methods instead; see https:\/\/docs.madelineproto.xyz for more info" +} diff --git a/template/double.md b/template/double.md new file mode 100644 index 0000000000..6a0545ce05 --- /dev/null +++ b/template/double.md @@ -0,0 +1,10 @@ +--- +title: double +description: A double precision floating point number +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: double +[Back to constructor index](index.html) + +A double precision floating point number, single precision can also be used (float). diff --git a/template/index.md b/template/index.md new file mode 100644 index 0000000000..4c2b3c0b86 --- /dev/null +++ b/template/index.md @@ -0,0 +1,17 @@ +--- +title: "Telegram RPC API" +description: "%s" +has_children: true +has_toc: false +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Telegram RPC API + +[Back to main documentation](..) + + +[Methods](methods/) + +[Constructors](constructors/) + +[Types](types/) diff --git a/template/int.md b/template/int.md new file mode 100644 index 0000000000..59ad4e6570 --- /dev/null +++ b/template/int.md @@ -0,0 +1,10 @@ +--- +title: integer +description: A 32 bit signed integer ranging from -2147483648 to 2147483647 +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int +[Back to constructor index](index.html) + +A 32 bit signed integer ranging from `-2147483648` to `2147483647`. diff --git a/template/int128.md b/template/int128.md new file mode 100644 index 0000000000..2f28592d0c --- /dev/null +++ b/template/int128.md @@ -0,0 +1,10 @@ +--- +title: int128 +description: A 128 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int128 +[Back to constructor index](index.html) + +A 128 bit signed integer represented in little-endian base256 (`string`) format. diff --git a/template/int256.md b/template/int256.md new file mode 100644 index 0000000000..6a67124c18 --- /dev/null +++ b/template/int256.md @@ -0,0 +1,10 @@ +--- +title: int256 +description: A 256 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int256 +[Back to constructor index](index.html) + +A 256 bit signed integer represented in little-endian base256 (`string`) format. diff --git a/template/int512.md b/template/int512.md new file mode 100644 index 0000000000..756bedce57 --- /dev/null +++ b/template/int512.md @@ -0,0 +1,10 @@ +--- +title: int512 +description: A 512 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int512 +[Back to constructor index](index.html) + +A 512 bit signed integer represented in little-endian base256 (`string`) format. diff --git a/template/int53.md b/template/int53.md new file mode 100644 index 0000000000..90a1e5ef7c --- /dev/null +++ b/template/int53.md @@ -0,0 +1,10 @@ +--- +title: integer +description: A 53 bit signed integer +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: int53 +[Back to constructor index](index.html) + +A 53 bit signed integer. diff --git a/template/long.md b/template/long.md new file mode 100644 index 0000000000..4465a550d2 --- /dev/null +++ b/template/long.md @@ -0,0 +1,10 @@ +--- +title: long +description: A 32 bit signed integer ranging from -9223372036854775808 to 9223372036854775807 +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: long +[Back to constructor index](index.html) + +A 64 bit signed integer ranging from `-9223372036854775808` to `9223372036854775807`. diff --git a/template/method-example.md b/template/method-example.md new file mode 100644 index 0000000000..8e1c5a8ff5 --- /dev/null +++ b/template/method-example.md @@ -0,0 +1,15 @@ +### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): + + +```php +if (!file_exists('madeline.php')) { + copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php'); +} +include 'madeline.php'; + +$MadelineProto = new \danog\MadelineProto\API('session.madeline'); +$MadelineProto->start(); + +$%s = $MadelineProto->%s(%s); +``` + diff --git a/template/methods-api-index.md b/template/methods-api-index.md new file mode 100644 index 0000000000..5ffa801351 --- /dev/null +++ b/template/methods-api-index.md @@ -0,0 +1,38 @@ +--- +title: Methods (API) +description: List of methods +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Methods +[Back to API documentation index](..) + +[Go to the new description-version method index](%s) + +$MadelineProto->[logout](https://docs.madelineproto.xyz/logout.html)(); + +$MadelineProto->[phoneLogin](https://docs.madelineproto.xyz/phoneLogin.html)($number); + +$MadelineProto->[completePhoneLogin](https://docs.madelineproto.xyz/completePhoneLogin.html)($code); + +$MadelineProto->[complete2FALogin](https://docs.madelineproto.xyz/complete2FAlogin.html)($password); + +$MadelineProto->[botLogin](https://docs.madelineproto.xyz/botLogin.html)($token); + + +$MadelineProto->[getDialogs](https://docs.madelineproto.xyz/getDialogs.html)(); + +$MadelineProto->[getPwrChat](https://docs.madelineproto.xyz/getPwrChat.html)($id); + +$MadelineProto->[getInfo](https://docs.madelineproto.xyz/getInfo.html)($id); + +$MadelineProto->[getFullInfo](https://docs.madelineproto.xyz/getFullInfo.html)($id); + +$MadelineProto->[getSelf](https://docs.madelineproto.xyz/getSelf.html)(); + + +$MadelineProto->[requestCall](https://docs.madelineproto.xyz/requestCall.html)($id); + +$MadelineProto->[requestSecretChat](https://docs.madelineproto.xyz/requestSecretChat.html)($id); + +%s diff --git a/template/methods-index.md b/template/methods-index.md new file mode 100644 index 0000000000..6fc8a5a936 --- /dev/null +++ b/template/methods-index.md @@ -0,0 +1,37 @@ +--- +title: Methods +description: What do you want to do? +parent: "Telegram RPC API" +has_children: true +nav_order: 3 +has_toc: false +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# What do you want to do? +[Go back to API documentation index](..) + +[Go to the old code-version method index](api_%s) + +* [Login](https://docs.madelineproto.xyz/docs/LOGIN.html) + +* [Change 2FA password: update2FA](https://docs.madelineproto.xyz/update2fa.html) + +* [Get all chats, broadcast a message to all chats: getDialogIds, getDialogs, getFullDialogs](https://docs.madelineproto.xyz/docs/DIALOGS.html) + +* [Get the full participant list of a channel/group/supergroup: getPwrChat](https://docs.madelineproto.xyz/getPwrChat.html) + +* [Get full info about a user/chat/supergroup/channel: getFullInfo](https://docs.madelineproto.xyz/getFullInfo.html) + +* [Get info about a user/chat/supergroup/channel: getInfo](https://docs.madelineproto.xyz/getInfo.html) + +* [Get the ID of a user/chat/supergroup/channel/update: getID](https://docs.madelineproto.xyz/getId.html) + +* [Get info about the currently logged-in user: getSelf](https://docs.madelineproto.xyz/getSelf.html) + +* [Upload or download files up to 4 GB: uploadFrom*, downloadTo*](https://docs.madelineproto.xyz/docs/FILES.html) + +* [Make a phone call and play a song](https://docs.madelineproto.xyz/docs/CALLS.html) + +* [Create a secret chat bot](https://docs.madelineproto.xyz/docs/SECRET_CHATS.html) + +%s diff --git a/template/null.md b/template/null.md new file mode 100644 index 0000000000..1c1812ad71 --- /dev/null +++ b/template/null.md @@ -0,0 +1,10 @@ +--- +title: null +description: Represents a null value +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# null +[Back to constructor index](index.html) + +Represents a `null` value. diff --git a/template/parse_mode.md b/template/parse_mode.md new file mode 100644 index 0000000000..1ba9856034 --- /dev/null +++ b/template/parse_mode.md @@ -0,0 +1,60 @@ + +## Usage of parse_mode: + +Set parse_mode to html to enable HTML parsing of the message. + +Set parse_mode to Markdown to enable markdown parsing of the message. + +The following tags are currently supported: + +```html +
a newline +bold works ok, internal tags are stripped +bold +italic +italic +underline +strikethrough +strikethrough +strikethrough +inline fixed-width code +
pre-formatted fixed-width code block
+
pre-formatted fixed-width code block
+URL +Mention by username +Mention by user id +Mention by user id +Custom emoji: 👍 +Custom emoji: 👍 +
Pre tags can have a language attribute
+Spoiler +Spoiler +``` + +You can also use normal markdown ([bot API MarkdownV2 syntax](https://core.telegram.org/bots/api#markdownv2-style)), note that to create mentions you can also use the `mention:` syntax like in html: + +```markdown +*bold \*text* +_italic \*text_ +__underline__ +~strikethrough~ +||spoiler|| +*bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold* +[inline URL](http://www.example.com/) +[inline mention of a user](tg://user?id=123456789) +![👍](tg://emoji?id=5368324170671202286) +\`inline fixed-width code\` +\`\`\` +pre-formatted fixed-width code block +\`\`\` +\`\`\`php +pre-formatted fixed-width code block written in the PHP programming language +\`\`\` + +[Mention by username](mention:@danogentili) +[Mention by user id](mention:186785362) +[Mention by user id](tg://user?id=186785362) +[👍](emoji:5368324170671202286) +[👍](tg://emoji?id=5368324170671202286) +``` + diff --git a/template/photoStrippedSize.md b/template/photoStrippedSize.md new file mode 100644 index 0000000000..9608d86d79 --- /dev/null +++ b/template/photoStrippedSize.md @@ -0,0 +1,35 @@ +--- +title: photoStrippedSize +description: Just the image's content +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Constructor: photoStrippedSize +[Back to constructors index](index.html) + + + +Just the image's content + +### Attributes: + +| Name | Type | Required | Description | +|----------|---------------|----------|-------------| +|type|[string](../types/string.html) | Yes|Thumbnail type| +|bytes|[bytes](../types/bytes.html) | Yes|Thumbnail data| +|inflated|[bytes](../types/bytes.html) | Yes|JPG image data| + + + +### Type: [PhotoSize](../types/PhotoSize.html) + + +### Example: + +```php +$photoStrippedSize = ['_' => 'photoStrippedSize', 'type' => 'string', 'bytes' => 'bytes']; +``` + + + + diff --git a/template/reply_markup.md b/template/reply_markup.md new file mode 100644 index 0000000000..14f9503b9d --- /dev/null +++ b/template/reply_markup.md @@ -0,0 +1,6 @@ + +## Usage of reply_markup + +You can provide bot API reply_markup objects here. + + diff --git a/template/string.md b/template/string.md new file mode 100644 index 0000000000..95353ffd00 --- /dev/null +++ b/template/string.md @@ -0,0 +1,10 @@ +--- +title: string +description: A UTF8 string of variable length +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: string +[Back to constructor index](index.html) + +A UTF8 string of variable length. The total length in bytes of the string must not be bigger than 16777215. diff --git a/template/types-index.md b/template/types-index.md new file mode 100644 index 0000000000..730268f206 --- /dev/null +++ b/template/types-index.md @@ -0,0 +1,9 @@ +--- +title: Types +description: List of types +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +# Types +[Back to API documentation index](..) + diff --git a/template/waveform.md b/template/waveform.md new file mode 100644 index 0000000000..8867f420ca --- /dev/null +++ b/template/waveform.md @@ -0,0 +1,16 @@ +--- +title: waveform +description: An array representing the waveform of a voice message +nav_exclude: true +image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png +--- +## Type: waveform +[Back to constructor index](index.html) + +The waveform of a voice message is represented by an array of 100 elements, containing integers ranging from 0 to 31. + +```php +$waveform = array_fill(0, 100, 0); +$waveform = array_fill(0, 100, 31); +``` +